Spending an experiment budget with Bayesian optimization

← Back to Blog & Articles

Some functions are expensive to evaluate. A wet-lab assay takes days and costs real money, a high-fidelity simulation occupies a cluster for hours, and a training run of a model with a new architecture takes a night. In each case there is a number we want to push up (a yield, a stability margin, a validation score), a space of inputs we may vary, and a budget of at most a few hundred evaluations. Gradients are unavailable, the response is noisy or non-convex, and a grid is unaffordable.

Bayesian optimization treats this as a decision problem under uncertainty, in the spirit of Volume 1. It keeps a probabilistic surrogate of the unknown function, uses the surrogate’s uncertainty to decide which input to try next, evaluates it, updates the surrogate, and repeats. The surrogate is usually a Gaussian process, because its posterior is available in closed form and its uncertainty is calibrated when the model is right (see Shahriari et al., 2016, for a review). Active learning uses the same machinery for a neighbouring goal: not to find the maximum of a function but to learn the whole function as cheaply as possible. The two goals call for different rules, and the companion book example shows the difference in numbers.

this article builds the method from the posterior up, proves the main guarantees, and extends the loop to batches, two fidelities and unknown constraints. Every experiment compares against random search over many seeds, with bootstrap confidence intervals.

A note on data. The outline of this volume calls for public benchmark suites and a molecule dataset. None of those are available offline, so all functions here are small stand-ins written for this article: a two-dimensional function with Branin’s structure, a six-dimensional sum of Gaussian bumps in the style of Hartmann’s family, and a synthetic “molecule library” whose property oracle is an arbitrary smooth function of eight made-up descriptors. The library is not chemistry. Results on it show how the methods behave on a screening problem of this shape; they say nothing about any real compound, and a chemist or materials scientist must review descriptors, assay noise, synthetic accessibility and safety before any of this is used for real decisions. this article is educational and is not professional advice.

Continue with the book

Explore the full treatment, worked examples, and exercises in Applied AI for Generation and Control.


Companion article for Applied AI for Generation and Control, published by Choral Software. Article text and original examples © 2026 Choral Software. All rights reserved.

Scroll to Top