TL;DR
Give an AI model a thousand tries at a tough math puzzle or a security defense, and a near-zero success rate can suddenly shoot up toward 100%. Testing every model millions of times to find these hidden capabilities and vulnerabilities is way too expensive, and current mathematical shortcuts for predicting them are statistically flawed. This paper introduces a clever statistical framework and an adaptive sampling trick that accurately forecast how models behave at massive scale—using just a tiny fraction of the compute budget.
What Problem Does This Paper Address?
Imagine you deploy a frontier Large Language Model (LLM) to millions of users. On a single attempt, it might fail to solve an Olympiad-level coding challenge, or successfully refuse a malicious "jailbreak" prompt. But what happens when a user—or an automated system—tries 1,000 times?
In AI evaluation, this is measured by $\text{pass}@k$: the probability that at least one attempt out of $k$ tries succeeds. Knowing $\text{pass}@k$ at massive $k$ is crucial both for safety (will a persistent attacker eventually break the model?) and capabilities (can we generate a working solution to train on?).
Directly measuring $\text{pass}@k$ for large $k$ requires generating thousands of responses per prompt, which is prohibitively expensive. Instead, researchers try to extrapolate high-$k$ behavior from a small budget of samples. However, the authors show that existing extrapolation methods break down when data is scarce, leaving us blind to rare risks and capabilities.
Methods
Standard approaches generally fall into two camps: fitting a straight line on a log-log plot (assuming a power law), or grouping per-problem success rates into discrete bins to fit a curve. Both introduce nasty statistical biases when sample counts are low.
To fix this, the authors rethink both how we model the data and how we collect it:
- Beta-Binomial Estimation: Instead of fitting lines to aggregated summary statistics or chopping probabilities into arbitrary bins, they model the underlying "difficulty" across a dataset's problems as a continuous Beta distribution. Because each attempt at a problem is a binary pass/fail (a Binomial process), they can fit a Beta-Binomial distribution directly to the raw counts of successes and trials using Maximum Likelihood Estimation. Once they have that underlying difficulty curve, predicting $\text{pass}@k$ for any $k$ is straightforward math.
- Dynamic Sampling: Standard evaluations spread their compute budget uniformly—giving every prompt, say, 10 tries. The authors realize that if a model solves a prompt on tries 1, 2, and 3, spending 7 more tries on it tells you nothing new about high-$k$ scaling. Their algorithm dynamically routes the fixed compute budget to the hardest problems (those with the fewest successes and attempts so far). Crucially, unlike older regression methods that require uniform sample counts per problem, the Beta-Binomial math naturally handles different trial counts for every prompt.
Datasets
The authors did not create new benchmarks, instead leveraging massive, pre-existing datasets from prior scaling-law studies that recorded $10,000$ actual attempts per problem (serving as the "ground truth"). They evaluated 3 to 6 models per dataset across three domains:
- AdvBench: Prompts testing safety and susceptibility to jailbreaking (evaluated on frontier models like GPT-4o, Claude 3.5 Opus/Sonnet, and Gemini 1.5 Pro/Flash).
- MATH: Challenging mathematical reasoning problems (evaluated across the Pythia model family, from 70M to 12B parameters).
- Code Contests: Competitive programming tasks (evaluated on Gemma 2B/7B and Llama 3 70B Instruct).
They also used synthetic problem-difficulty distributions to isolate and stress-test their dynamic sampling strategy.
Key Insights and Ideas
- Why Log-Log Regression Fails: Plotting $\text{pass}@k$ on a log-log graph and drawing a line violates basic rules of linear regression. Because all points are calculated from the same small pool of samples, the errors are correlated and have wildly different variances. Worse, true power laws often only kick in at high $k$; fitting to small $k$ captures early statistical noise, causing predictions to shoot past 100% (an impossible probability!).
- The Discretization Trap: Prior methods that bin success rates into log-scaled intervals accidentally overweight the "hard" end of the spectrum because the bins are wider near zero, leading to systematically pessimistic predictions.
- Obsess Over the Hardest Problems: Mathematically, how $\text{pass}@k$ scales at huge $k$ is governed almost entirely by the shape of the problem-difficulty distribution very close to zero. Distinguishing between an "easy" problem (25% pass rate) and a "very easy" problem (75% pass rate) is a waste of compute. Concentrating samples on the hardest outliers minimizes estimator variance.
Key Results
Using a constrained total budget (e.g., $10,000$ total samples spread across 100–200 problems, meaning direct measurement stops around $k \approx 50\text{–}100$), the authors extrapolated $\text{pass}@k$ all the way out to $k = 1,000$ and compared it against the $10,000$-sample-per-problem ground truth.
- Superior Extrapolation: Across virtually all models, datasets, and budgets, the Dynamic + Beta-Binomial estimator tracked the ground truth closely, minimizing Mean Squared Error (MSE).
- Avoiding Wild Divergences: As seen in the plots above (where the gray region shows direct measurement and the white region shows extrapolation), standard log-log regression wildly overestimates $\text{pass}@k$—frequently hitting the ceiling at 1.0—while the discretized-beta method consistently underestimates true scaling.
- Synthetic Stress-Tests: In synthetic tests featuring many easy problems and a few "hard outliers" ($10^{-4}$ success probability), dynamic sampling beat uniform sampling by orders of magnitude in MSE.
Limitations and Future Work
- Independent Attempts Only: The math assumes every attempt is an independent roll of the dice. It explicitly cannot model history-dependent strategies—such as an LLM reflecting on its past mistakes, debugging code using compiler feedback, or an attacker adaptively tweaking a jailbreak prompt over multiple turns.
- Distributional Assumptions: Even with infinite samples, if a benchmark's true problem difficulties don't resemble a smooth Beta distribution (for example, a dataset split strictly into two rigid clusters of "impossible" and "trivial"), the model's asymptotic prediction won't match reality perfectly.
- Theoretical Gaps: While the authors prove optimal sample allocation for a simplified frequentist estimator, proving variance reduction for their full multi-stage Bayesian dynamic sampler remains an open mathematical question for future work.
Summary updated