Taming Imperfect Process Verifiers: A Sampling Perspective on Backtracking
Dhruv Rohatgi, Abhishek Shetty, Donya Saless, Yuchen Li, Ankur Moitra, Andrej Risteski, Dylan J. Foster
TL;DR
This paper investigates how to reliably guide language-model decoding at test time using imperfect process verifiers. It introduces Value-Guided Sampling with Stochastic Backtracking (VGB), a backtracking-based decoding algorithm that extends the Sinclair–Jerrum random walk to general tilt functions and approximate value estimates, thereby mitigating error amplification in long-horizon generations. The authors provide rigorous uniform-error and average-case guarantees for VGB, showing it achieves fast mixing and good coverage despite imperfect verifiers, and they show how to implement it efficiently even with large action spaces. Empirically, VGB demonstrates improved distributional fidelity and coherence across synthetic and real-language tasks, including constrained generation and code/test-case generation, at the cost of additional computation. Overall, the work bridges classical approximate-sampling theory with modern test-time alignment, offering provable guarantees and practical insights for robust long-horizon reasoning with language models.
Abstract
Test-time algorithms that combine the generative power of language models with process verifiers that assess the quality of partial generations offer a promising lever for eliciting new reasoning capabilities, but the algorithmic design space and computational scaling properties of such approaches are still opaque, and their benefits are far from apparent when one accounts for the cost of learning a high-quality verifier. Our starting point is the observation that seemingly benign errors in a learned verifier can lead to catastrophic failures for standard decoding techniques due to error amplification during the course of generation. We then ask: can this be improved with more sophisticated decoding strategies? We introduce a new process-guided test-time sampling algorithm, VGB, which uses theoretically grounded backtracking to achieve provably better robustness to verifier errors. VGB interprets autoregressive generation as a random walk on a tree of partial generations, with transition probabilities guided by the process verifier and base model; crucially, backtracking occurs probabilistically. This process generalizes the seminal Sinclair-Jerrum random walk (Sinclair & Jerrum, 1989) from the literature on approximate counting and sampling in theoretical computer science, and a conceptual contribution of our work is to highlight parallels with this literature. Empirically, we demonstrate on both synthetic and real language modeling tasks that VGB outperforms baselines on a variety of metrics.
