While traditional neural scaling laws dictate how a model's performance improves with more training data and parameters, there is a second, less-theorized dimension to scaling: inference compute. If a model fails a complex reasoning task on the first try, it might succeed on the tenth or hundredth attempt, provided there is a mechanism to verify the correct answer.
Until now, the "pass@k" metric—the probability of getting at least one correct answer in $k$ independent tries—has largely been treated as an empirical observation. This paper introduces a statistical framework to predict the shape of these curves, providing a theoretical bridge between inference compute costs and performance gains during generation.
The Memorization Ansatz and Subjective Difficulty
To understand how extra inference attempts pay off, the author proposes a memorization ansatz. Rather than analyzing the complex internal weights of a transformer, the framework treats the AI as a "noisy retriever" that has memorized the training distribution but occasionally fails to output the correct sequence.
A core innovation of this work is modeling the "failure probability" of a dataset using a Beta distribution. This accounts for the reality that task difficulty is not uniform; some problems are inherently "easy" for the AI, while others are "hard."
By integrating over this Beta distribution, the author derives a closed-form mathematical expression for the pass@k metric. The parameters of the distribution ($\alpha$ and $\beta$) act as a "fingerprint" for how a specific model perceives the difficulty of a specific dataset. This allows researchers to solve an inverse problem: by observing a model's empirical pass@k curve, one can mathematically derive the "perceived difficulty" distribution of the underlying dataset.
The Power Law of Patience
Building on the pass@k derivation, the paper defines a new metric called inference loss, which represents the expected error rate after $k$ trials. The most significant finding is that inference loss follows a predictable power law: $\mathcal{L}_{\text{inference}} \approx k^{-\beta}$.
This power-law decay means that the returns on extra inference attempts diminish predictably, much like the returns on extra training data. Furthermore, the framework acknowledges that real-world attempts are rarely perfectly independent—a model might get "stuck" repeating the same flawed reasoning path. To correct for this, the author introduces an "effective number of independent trials" ($k_{\text{eff}}$), successfully aligning theoretical predictions with the correlated nature of actual model sampling.
Empirical Validation and Universality
The theoretical model was validated against two vastly different datasets, demonstrating its universality:
- MATH Benchmark: The framework achieved a near-perfect fit for empirical pass@k curves generated by state-of-the-art LLMs (Gemma-2B, Llama-3-8B, and Pythia-2.8B) on complex reasoning tasks.
- Fashion-MNIST: To test the theory's generalizability beyond language, the author trained a Variational Autoencoder (VAE) to reconstruct images. The same statistical laws accurately described the VAE's success rate over multiple generation attempts.
By providing a formula that connects total inference cost (FLOPs) to coverage, this framework allows practitioners to calculate compute trade-offs. Engineers can now mathematically determine the "sweet spot" between deploying a larger, more expensive model for a single attempt versus querying a smaller, cheaper model multiple times.
Limitations and Future Work
While this simple model of inference scaling is highly predictive, it relies on a few key assumptions that warrant future investigation:
- The "Oracle" Assumption: The current framework assumes the presence of a "perfect verifier" (like a code compiler or deterministic math checker) to identify the correct answer among $k$ attempts. In open-ended creative tasks, verification is often as difficult as generation.
- Static Training: The paper treats the model as a finished product. A critical next step is investigating how training scaling interacts with inference scaling. Does increasing parameter count simply shift the pass@k curve, or does it fundamentally alter the difficulty exponent $\beta$?
- Correlation Heuristics: The power-law decay used to model correlations between successive trials is currently a heuristic. Future work could explore more sophisticated mechanistic models of how an LLM's "train of thought" becomes redundant over repeated samples.
Ultimately, this framework lays the groundwork for a unified theory of neural scaling—one that accounts for both the compute spent building a model and the compute spent using it.
Summary updated