Choosing which protic ionic liquid (PIL) to synthesise and test next so that the best delignifying solvents are found in a fraction of the wet-lab experiments a grid or random screen would need. A Gaussian-process surrogate over interpretable PIL descriptors drives an acquisition function (Expected Improvement / UCB / uncertainty sampling) that proposes the next candidate; the loop is evaluated by how quickly it discovers the top PILs.
Motivation: separating and purifying lignin from second-generation bioethanol waste depends heavily on the solvent, and the PIL design space (cation × anion × conditions) is combinatorially large while each synthesis-and-assay cycle is slow and costly. That is exactly the setting where sequential experimental design pays off.
How this differs from a Bayesian-optimisation-of-a-process project: this is pool-based active learning over a discrete, fixed library of synthesisable PILs (which of ~90 real cation/anion combinations to make), not continuous optimisation of process knobs. The decision is which molecule, not what temperature.
There is no public "PIL descriptors → delignification efficiency" dataset, so
this repo ships a transparent, chemically-motivated synthetic oracle rather
than fabricated measurements. Its response surface is built from the mechanisms
established in the IL-fractionation literature (see src/pil_screening/oracle.py
and descriptors.py):
- anion H-bond basicity (Kamlet–Taft β) — the primary lever for lignin dissolution / β-O-4 cleavage (Brandt et al., Green Chem. 2013; Hart et al. 2015);
- a medium-acidity optimum — Brønsted-acidic PILs ([HSO₄], the Ionosolv route) cleave aryl-ethers, but excess acidity degrades products;
- a viscosity mass-transfer penalty and a cation chain-length steric penalty.
The deliverable is the active-learning loop and the "experiments saved"
evidence, not the data. Real screening data drops in by swapping the descriptor
table and the oracle for a lab lookup / assay call — see
data/README.md.
On a 90-PIL library (cation × anion), averaged over 12 random-seed campaigns, starting from 4 random measurements:
| Target quality | Expected Improvement | Random screen | Speed-up |
|---|---|---|---|
| reach 95% of the global-best PIL | 7 experiments | 22 experiments | 3.1× fewer (15 saved) |
| reach 99% of the global-best PIL | 11 experiments | not reached in 36 | — |
The advantage grows with the quality bar: finding a merely good PIL (90% of max) is easy for any method, but finding the best PIL is where active learning separates from random — honest behaviour worth stating plainly.
scripts/04_batch_and_strategies.py shows the trade-off: batch size q=1 reaches
95% of max in ~7 experiments, q=3/5 in ~9–10 — batching costs a few extra total
experiments but finishes in far fewer lab rounds.
scripts/05_interpret.py — permutation importance on the surrogate ranks the
four true drivers (β, acidity, viscosity, chain length) above the four
nuisance descriptors (cost, green flag, molar mass, cation acidity), with the
top-4 exactly matching the oracle's real inputs. A model given no mechanistic
prior recovered the governing descriptors.
01_build_library.py enumerate the cation x anion PIL library
02_explore_oracle.py response landscape vs descriptors (beta dominates)
03_run_active_learning.py EI / UCB / uncertainty / greedy / random, learning curves
04_batch_and_strategies.py batch-size trade-off for Expected Improvement
05_interpret.py permutation importance + GP ARD sensitivity
Library in src/pil_screening/: descriptors.py (ion tables + builder),
oracle.py (synthetic response), models.py (GP surrogate, ARD Matérn kernel),
acquisition.py (EI/UCB/uncertainty/greedy/random), active_learning.py
(pool-based batch loop), evaluate.py (learning curves, experiments-to-threshold).
pip install -r requirements.txt
python scripts/01_build_library.py
python scripts/02_explore_oracle.py
python scripts/03_run_active_learning.py
python scripts/04_batch_and_strategies.py
python scripts/05_interpret.py- The oracle validates the method, not real-world PIL rankings; absolute numbers will differ on measured data.
- Descriptor values are literature-informed representatives, not measured constants for every ion.
- A single fixed pretreatment condition is assumed; temperature/time/water are held constant (extendable by adding them as descriptors).
- Brandt, A. et al. (2013). Green Chemistry 15, 550–583.
- Hart, W.E.S. et al. (2015). Green Chemistry 17, 214–218.
- Achinivu, E.C. et al. (2014). Green Chemistry 16, 1114–1119.
- Gschwend, F.J.V. et al. (2018). Ionosolv pretreatment with low-cost [HSO₄] PILs.
MIT — see LICENSE.

