NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

GAUCHE: A Library for Gaussian Processes in Chemistry

Ryan-Rhys Griffiths, Leo Klarner, Henry Moss, Aditya Ravuri, Sang T. Truong, Yuanqi Du, Samuel Don Stanton, Gary Tom, Bojana Ranković, Arian Rokkum Jamasb, Aryan Deshwal, Julius Schwartz, Austin Tripp, Gregory Kell, Simon Frieder, Anthony Bourached, Alex James Chan, Jacob Moss, Chengzhi Guo, Johannes P. Dürholt, Saudamini Chaurasia, Ji Won Park, Felix Strieth-Kalthoff, Alpha Lee, Bingqing Cheng, Alan Aspuru-Guzik, Philippe Schwaller, Jian Tang

Introduction

In early-stage scientific discovery, data is the most expensive commodity. Whether designing a new drug or optimizing a chemical reaction, every "data point" represents hours or days of intensive lab work. Consequently, chemists need machine learning models that are sample-efficient—meaning they learn a lot from a little—and well-calibrated, meaning the model knows exactly how much it doesn't know.

Gaussian Processes (GPs) are the gold standard for this. They provide exact Bayesian inference and excellent uncertainty estimates, making them perfect for Bayesian Optimization (BO)—the process of using a model to decide which experiment to run next. However, standard GPs are designed for continuous, numerical inputs (like coordinates in space). Molecules, on the other hand, are structured objects: they are graphs of atoms, strings of characters (SMILES), or bit-vectors (fingerprints).

GAUCHE is a new open-source library that bridges this gap between probabilistic machine learning and the chemical sciences. By providing specialized "kernels" for molecular graphs, strings, and fingerprints, it enables researchers to use Gaussian Processes for high-stakes tasks like drug discovery and reaction optimization where data is scarce and uncertainty quantification is critical.

Methods: The Language of Chemistry

Before GAUCHE, there wasn't a unified, robust library that allowed GPs to "speak" the language of chemistry. The core contribution of GAUCHE is a suite of molecular kernels. In GP terms, a kernel is a function that defines how "similar" two inputs are.

GAUCHE architecture pipeline

GAUCHE introduces over 30 GPU-accelerated kernels categorized by representation:

  • Fingerprint Kernels: Includes the classic Tanimoto kernel (a staple in chemoinformatics) and scalar product kernels designed for bit and count vectors.
  • String Kernels: Designed to operate on SMILES or SELFIES strings by comparing contiguous subsequences, allowing the model to find patterns in chemical notation.
  • Graph Kernels: Leverages the Weisfeiler-Lehman (WL) algorithm to compare the actual topology of molecules.

Technically, GAUCHE is built on top of GPyTorch (for hardware-accelerated GP inference) and BoTorch (for Bayesian Optimization). It also introduces a SIGP class that allows it to interface with the GraKel library, enabling GPs to be trained on non-tensorial, structured graph inputs.

Datasets

The authors evaluated GAUCHE across a diverse range of chemical benchmarks:

  • Regression & Uncertainty Quantification (UQ): Photoswitch (392 molecules), ESOL (solubility of 1,128 molecules), FreeSolv (hydration energy), and Lipophilicity (4,200 molecules).
  • Chemical Reactions: Yield prediction for Buchwald-Hartwig (3,955 reactions) and Suzuki-Miyaura (5,760 reactions) cross-couplings.
  • Proteins: A newly collated dataset of 151 PETase protein sequences for fitness (melting point) prediction.

Key Insights and Ideas

  • GPs vs. Deep Learning: On small-to-medium chemical datasets, GPs frequently outperform Bayesian Neural Networks (BNNs) and Deep Ensembles. They are not just more accurate; their uncertainty estimates are significantly more reliable.
  • The Tanimoto Advantage: The Tanimoto kernel, especially when paired with "fragprints" (a combination of traditional fingerprints and functional group counts), emerged as a compelling option due to its balance of accuracy, calibration, and speed.
  • Strings are Surprisingly Strong: Despite SMILES strings being a somewhat "lossy" representation of 3D chemistry, string kernels performed exceptionally well, sometimes even beating graph-based methods.
  • Calibration is King for BO: The paper highlights that while deep models might get lucky with a low error, their poor uncertainty calibration makes them risky for Bayesian Optimization. GAUCHE’s GPs provide the calibrated confidence needed to trust a model's suggestion for the next expensive lab experiment.

Key Results

In head-to-head comparisons, GAUCHE-based GPs consistently achieved lower Root-Mean-Square Error (RMSE) and better Negative Log Predictive Density (NLPD)—a measure of how well the model's uncertainty matches reality—compared to state-of-the-art neural networks.

Bayesian Optimization performance on the ESOL dataset

In Bayesian Optimization tasks, GAUCHE models found optimal molecules significantly faster than random search. For example, when optimizing for properties in the ESOL dataset, GAUCHE models utilizing Expected Improvement (EI) with fragprints or SMILES required only a handful of iterations to identify top-performing candidates, vastly outpacing random exploration.

Limitations and Future Work

The authors note that GAUCHE currently focuses on core, robust implementations that are likely to work across many problems. This means some highly specialized or niche GP variants might not be included yet.

Additionally, while graph kernels are powerful, they can be computationally expensive as the number of molecules grows. Future work involves exploring more efficient ways to scale these structured kernels to massive chemical libraries and integrating more complex 3D structural information from proteins and crystals.

Summary updated

BibTeX
@inproceedings{griffiths2023gauche,
  author = {Ryan-Rhys Griffiths and Leo Klarner and Henry Moss and Aditya Ravuri and Sang T. Truong and Yuanqi Du and Samuel Don Stanton and Gary Tom and Bojana Ranković and Arian Rokkum Jamasb and Aryan Deshwal and Julius Schwartz and Austin Tripp and Gregory Kell and Simon Frieder and Anthony Bourached and Alex James Chan and Jacob Moss and Chengzhi Guo and Johannes P. Dürholt and Saudamini Chaurasia and Ji Won Park and Felix Strieth-Kalthoff and Alpha Lee and Bingqing Cheng and Alan Aspuru-Guzik and Philippe Schwaller and Jian Tang},
  title = {{GAUCHE: A Library for Gaussian Processes in Chemistry}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2023},
  url = {https://openreview.net/forum?id=vzrA6uqOis},
}
Figure