TL;DR
How do you steer a massive, closed-weight generative model toward a specific reward at inference time without doubling or tripling your compute budget? This paper introduces Learnable Chernoff Baselines (LCBs), a smart, adaptive twist on rejection sampling that guides step-by-step generation (like diffusion) using only black-box API access. It gives you provable mathematical guarantees on sample quality while letting you scale inference compute smoothly—even by fractional multipliers like 1.2×—leaving brute-force methods like Best-of-$N$ in the dust.
What Problem Does This Paper Address?
Suppose you have a pretrained generative model—say, an image diffusion model or a language model—and you want it to optimize a downstream reward (like safety, aesthetic quality, or strict formatting) without straying too far from its original behavior.
The gold standard is RL fine-tuning, which is expensive and impossible if the model weights are locked behind an API. The alternative is inference-time alignment: steering the model as it generates. Model-agnostic methods like Best-of-$N$ (generate $N$ full outputs, pick the best) or Sequential Monte Carlo (propagate $K$ parallel trajectories) only require black-box sampling access. However, they are blunt instruments: they force you to multiply your compute by discrete integers ($N \ge 2$), and their theoretical guarantees only kick in asymptotically as $N \to \infty$.
On the flip side, exact step-by-step rejection sampling can theoretically hit the exact mathematical target distribution, $p^*(x_0)$, without modifying weights. In practice, however, standard rejection sampling compares every intermediate step against the global maximum possible reward. If that bound is loose, acceptance rates plummet, and you end up trapped in an exponentially long loop of rejected proposals.
Methods
The authors focus on models that generate outputs via a Markov process over $T$ steps (continuous diffusion, discrete masked diffusion, or autoregressive LLMs). Standard theory tells us that to sample from the optimal KL-regularized reward distribution, we can tilt each step's transition probability using a soft-value function $v_t(x_t)$—essentially, the expected future reward from state $x_t$.
Given a learned estimate $\hat{v}_t$ of this value function, standard rejection sampling accepts a proposed step $x_t$ with probability $\exp(\hat{v}_t(x_t) - B)$, where $B$ is a static worst-case upper bound on reward.
What's new: The authors replace that static, pessimistic bound $B$ with a Learnable Chernoff Baseline (LCB), $B_{t+1}(x_{t+1})$. Instead of demanding each step measure up to the best possible outcome in the universe, LCB sets a local, state-dependent bar based on where the trajectory currently is ($x_{t+1}$).
To learn these baselines from sample trajectories without breaking the math of rejection sampling:
- They allow a tiny, user-chosen probability $\delta > 0$ that the value estimate exceeds the baseline (trading a sliver of exactness for massive speedups).
- They use Chernoff bounds (which rely on moment-generating functions) to certify this $\delta$ threshold, turning the theoretical Total Variation (TV) sampling error bound directly into a tractable empirical loss function.
- By minimizing this loss sequentially across timesteps, they ensure all step-wise baselines are mutually compatible, preventing approximation errors from blowing up over long horizons.
Datasets
Rather than relying on standard static benchmarks, the authors construct three controlled experimental setups to test continuous and discrete generation:
- Setting I (Synthetic Continuous): A 2D Mixture of Gaussians using a score-based DDPM, paired with a rare-event indicator reward ($r(x) = \mathbf{1}\{x < -7\}$) that has only $\sim 0.001$ probability mass under the unguided model.
- Setting II (Fixed-Prompt Discrete): Outputs sampled from LLaDA-8B (an 8-billion-parameter masked diffusion LLM) on a single prompt requiring a 3-sentence story where sentences start with "A", "B", and "C", scored by a programmatic syntax verifier.
- Setting III (Prompt-Conditioned Discrete): A newly constructed set of 512 fill-in-the-blank prompts (410 train, 102 held-out test) asking LLaDA-8B to complete polite-but-firm refusal sentences (e.g., "Thank you for your bid, but..."), scored by an external reward model (
Skywork-Reward-V2-Qwen3-1.7B).
Key Insights and Ideas
- Fractional Compute Scaling: Because $\delta$ is a continuous knob, LCBs break the "$2\times$ minimum" barrier of Best-of-$N$. You can spend just $1.16\times$ or $1.3\times$ the base compute to weed out bad steps early in the denoising process and get a substantial reward jump.
- Dimension-Independent Guarantees: Usually, rejection sampling dies in high dimensions. The authors prove non-asymptotic Total Variation error bounds showing that if the value function is sub-Gaussian step-to-step (which they prove holds for Gaussian mixture DDPMs), sampling accuracy and compute depend on noise schedules—not the ambient dimension of the data.
- Zero-Extra-Cost Baselines: In their most complex LLM experiment (Setting III), the authors simply set the baseline's base predictor to be the previous step's value estimate ($b_{t+1} := \hat{v}_{t+1}$). Learning the LCB then collapses into optimizing two scalar parameters per step—meaning almost zero training overhead beyond learning the value function itself.
- Composability: LCBs play remarkably well with others. Wrapping a cheap LCB sampler inside a small Best-of-2 or Best-of-3 pass compensates for noisy value-function estimates and dominates Best-of-$N$ across the entire compute-reward Pareto frontier.
Key Results
Across both toy continuous diffusion and 8B-parameter discrete language diffusion, LCBs closely mirror exact Rejection Sampling (RS) distributions at a fraction of the query cost:
- 2D Gaussian Mixture: LCB matches exact RS while using 12.5× fewer queries (effective $N = 5.5$ vs. $69.0$), and achieves comparable alignment to Best-of-40 using 7× fewer queries ($14\%$ of the proposals). Chaining LCB with Best-of-3 nails the true target distribution at effective $N=10$.
- LLaDA Verifiable Syntax: At strong alignment ($\alpha = 0.1$), exact RS requires $12.60\times$ effective queries to achieve an $83.2\%$ perfect constraint rate. LCB hits $81.8\%$ perfection at just $1.59\times$ effective queries—beating Best-of-2 ($74.6\%$ at $2.00\times$ compute) with $20\text{--}40\%$ fewer queries.
- LLaDA Held-Out Prompts: LCB generalizes cleanly to unseen prompts, shifting reward $Z$-scores significantly rightward while consuming only $1.07\times$ to $1.75\times$ compute, strictly dominating unguided Best-of-$N$ when chained with Best-of-$M$.
Limitations and Future Work
- Garbage In, Garbage Out on Value Estimates: Like any step-wise guidance method, LCB is bottlenecked by the quality of the learned soft-value function $\hat{v}_t$. Errors in $\hat{v}_t$ separate the sampled distribution from the true optimal target $p^*$.
- Scale of Evaluation: The authors note their empirical setups are lightweight validations of the theory; scaling up value-model training and evaluating on larger, more diverse benchmarks remains open.
- Future Directions: The authors suggest two contrasting paths forward: scaling up learned $\hat{v}_t$ models on massive datasets to slash prediction noise, or bypassing training altogether by pairing LCBs with heuristic, training-free guidance signals.
Summary updated