量化智能体编程评测(eval)中的基础设施(infrastructure)噪声
Quantifying infrastructure noise in agentic coding evals
段落导航
Agentic coding benchmarks like SWE-bench and Terminal-Bench are commonly used to compare the software engineering capabilities of frontier models—with top spots on leaderboards often separated by just a few percentage points.
像 SWE-bench 和 Terminal-Bench 这样的智能体编程基准(benchmark)常被用来比较前沿模型的软件工程能力——排行榜上的头部位置往往只相差几个百分点。
These scores are often treated as precise measurements of relative model capability and increasingly inform decisions about which models to deploy.
这些分数常被视为对模型相对能力的精确衡量,并越来越多地影响关于部署哪些模型的决策。
However, we’ve found that infrastructure configuration alone can produce differences that exceed those margins.
然而,我们发现仅基础设施配置一项就能产生超过这些差距的差异。
In internal experiments, the gap between the most- and least-resourced setups on Terminal-Bench 2.0 was 6 percentage points (p < 0.01).
在内部实验中,Terminal-Bench 2.0 上资源最充足与最匮乏的配置之间的差距为 6 个百分点(p < 0.01)。
Static benchmarks score a model's output directly—the runtime environment doesn’t factor into the result.
静态基准直接对模型的输出打分——运行时(runtime)环境不会影响结果。
Agentic coding evals are different: models are given a full environment where they write programs, run tests, install dependencies, and iterate over multiple turns.
智能体编程评测则不同:模型会获得一个完整环境,在其中编写程序、运行测试、安装依赖,并经过多个轮次迭代。
The runtime is no longer a passive container, but an integral component of the problem-solving process.
运行时不再是被动的容器,而是问题解决过程中不可或缺的组成部分。
Two agents with different resource budgets and time limits aren't taking the same test.
两个具有不同资源预算和时间限制的智能体(agent),参加的并不是同一场测试。
Eval developers have begun accounting for this.
评测开发者已开始考虑到这一点。
Terminal-Bench 2.0, for instance, specifies recommended CPU and RAM on a per-task basis in their latest 2.0 release.
例如,Terminal-Bench 2.0 在其最新的 2.0 版本中按任务分别规定了推荐的 CPU 和 RAM。
However, specifying resources isn't the same as enforcing them consistently.
然而,规定资源并不等于一致地强制执行这些规定。
Moreover, we discovered that enforcement methodology can change what the benchmark ends up actually measuring.
此外,我们发现强制执行的方法会改变该基准最终实际衡量的内容。
We run Terminal-Bench 2.0 on a Google Kubernetes Engine cluster.
我们在一个 Google Kubernetes Engine 集群上运行 Terminal-Bench 2.0。
While calibrating the setup, we noticed our scores didn't match the benchmark’s official leaderboard, and infra error rates were surprisingly high: as many as 6% of tasks were failing because of pod errors, most of which were unrelated to the model’s ability to solve the tasks.
在校准设置时,我们注意到我们的分数与基准的官方排行榜不一致,而且基础设施错误率高得惊人:多达 6% 的任务因 pod 错误而失败,其中大多数与模型解决这些任务的能力无关。
The discrepancy in scores came down to enforcement.
分数差异归根结底在于强制执行方式。
Our Kubernetes implementation treated the per-task resource specs as both a floor and a hard ceiling: each container was guaranteed the specified resources but killed the moment it exceeded them.
我们的 Kubernetes 实现把按任务设定的资源规格同时当作下限和硬性上限:每个容器都能保证获得指定的资源,但一旦超出就会被终止。
Container runtimes enforce resources via two separate parameters: a guaranteed allocation—the resources reserved up front—and a hard limit at which the container is killed.
容器运行时通过两个独立参数来强制执行资源限制:保证分配量——即预先预留的资源——以及容器被终止的硬性上限。
When these are set to the same value, there's zero headroom for transient spikes: a momentary memory fluctuation can OOM-kill a container that would otherwise have succeeded.
当二者被设为相同值时,就没有任何余量来应对瞬时峰值:一次短暂的内存波动就可能把原本会成功的容器 OOM 杀死。
To account for this, Terminal-Bench’s leaderboard uses a different sandboxing provider, whose implementation is more lenient, allowing temporary overallocation without terminating the container in order to favor infrastructural stability.
考虑到这一点,Terminal-Bench 的排行榜使用了另一家沙箱(sandbox)提供商,其实现更为宽松,允许临时超额分配而不终止容器,以偏向基础设施稳定性。
This finding raised a larger question: how much does resource configuration impact evaluation scores?
这一发现引出了一个更大的问题:资源配置对评测分数的影响有多大?
To quantify the effect of the scaffold, we ran Terminal-Bench 2.0 across six resource configurations, from strict enforcement of the per-task specs (1x), having them act as both floor and ceiling, to completely uncapped.
为了量化脚手架(scaffold)的影响,我们在六种资源配置下运行 Terminal-Bench 2.0,从严格执行每任务规格(1x)——让这些规格同时充当下限和上限——到完全不加限制。
Everything else stayed constant: same Claude model, same harness, same task set.
其他一切都保持不变:相同的 Claude 模型、相同的框架(harness)、相同的任务集。
In our experiments, success rates increased with resource headroom.
在我们的实验中,成功率随着资源余量增加而提高。
This was primarily driven by infra error rates dropping monotonically at each step, going from 5.8% at strict enforcement to 0.5% when uncapped.
这主要是由每一步基础设施错误率单调下降推动的,从严格执行时的 5.8% 降至不加限制时的 0.5%。
The drop between strict enforcement to 3x headroom (5.8% to 2.1%) was significant at p < 0.001.
从严格执行到 3x 资源余量之间的下降(5.8% 到 2.1%)在 p < 0.001 下显著。
With more headroom, fewer containers get killed for exceeding their allocation.
资源余量越多,因超出分配而被杀死的容器就越少。
From 1x through 3x, success scores fluctuate within the margins of noise (p=0.40).
从 1x 到 3x,成功得分在噪声范围内波动(p=0.40)。
Most of the tasks that were crashing at 1x would have failed regardless—which is something that we observed in the data.
大多数在 1x 下崩溃的任务无论如何都会失败——这是我们在数据中观察到的。
The agent explores, hits a resource wall, and gets preempted, but it was never on a path to a correct solution.
智能体进行探索,撞上资源墙,然后被抢占,但它从未处在通往正确解决方案的路径上。
Starting around 3x, however, this trend changes: success rates climb faster than infra errors decline.
然而,从大约 3x 开始,这一趋势发生变化:成功率上升速度快于基础设施错误率下降速度。
Between 3x to uncapped, infra errors drop an additional 1.6 percentage points, while success jumps almost 4 percentage points.
在 3x 到不加限制之间,基础设施错误率又下降了 1.6 个百分点,而成功率跃升了近 4 个百分点。
The extra resources enable the agent to try approaches that only work with generous allocations, such as pulling in large dependencies, spawning expensive subprocesses, and running memory-intensive test suites.
额外的资源使智能体能够尝试只有在大方分配下才有效的方法,例如拉取大型依赖项、启动开销高昂的子进程,以及运行内存密集型测试套件。
At uncapped resources, the total lift over 1x is +6 percentage points (p < 0.01).
在不加限制的资源下,相对 1x 的总提升为 +6 个百分点。
At the margins, tasks like rstan-to-pystan and compile-compcert significantly improve their success rates when getting memory headroom.
在边缘情况下,像 rstan-to-pystan 和 compile-compcert 这样的任务在获得内存余量时,其成功率显著提高。
Up to roughly 3x Terminal-Bench specs, the additional resources fix infrastructure reliability problems, namely transient resource spikes.
直到大约 3x Terminal-Bench 规格为止,额外资源修复的是基础设施可靠性问题,即瞬态资源峰值。
The sandboxing provider used by the Terminal-Bench maintainers is implicitly doing this behind the scenes; the eval gets more stable without getting easier.
Terminal-Bench 维护者使用的沙箱提供商在幕后隐式地做着这件事;eval 变得更稳定,但并没有变得更容易。
Above the 3x mark, however, additional resources start actively helping the agent solve problems it couldn't solve before, which shows that limits can actually change what the eval measures.
然而,超过 3 倍阈值后,额外资源开始主动帮助智能体解决它此前无法解决的问题,这表明限制实际上可以改变评测所衡量的内容。
Tight limits inadvertently reward very efficient strategies, while generous limits are more forgiving and reward agents that can better exploit all available resources.
严格的限制无意中奖励非常高效的策略,而宽松的限制更宽容,并奖励那些能更好地利用所有可用资源的智能体。
An agent that writes lean, efficient code very fast will do well under tight constraints.
一个能非常快速地编写精简、高效代码的智能体,在严格约束下会表现良好。
An agent that brute-forces solutions with heavyweight tools will do well under generous ones.
一个用重量级工具暴力求解的智能体,在宽松约束下会表现良好。
Both are legitimate things to test, but collapsing them into a single score without specifying the resource configuration makes the differences—and real-world generalizability—hard to interpret.
两者都是合理的测试对象,但如果不指定资源配置就将它们合并为单一分数,会使差异——以及现实世界的泛化能力——难以解读。
On bn-fit-modify, a Terminal-Bench task requiring Bayesian network fitting, some models’ first move is to install the standard Python data science stack: pandas, networkx, scikit-learn, and all their toolchain.
在 bn-fit-modify 这个需要贝叶斯网络拟合(Bayesian network fitting)的 Terminal-Bench 任务上,一些模型的第一步是安装标准的 Python 数据科学栈:pandas、networkx、scikit-learn, 及其整个工具链。
Under generous limits, this works.
在宽松限制下,这能行得通。
Under tight ones, the pod runs out of memory during installation, before the agent writes a single line of solution code.
在严格限制下,pod 在安装期间就内存耗尽,智能体还没写一行解题代码。
A leaner strategy exists (implementing the math from scratch using only the standard library), and some models do default to it.
存在一种更精简的策略(仅使用标准库从头实现数学计算),一些模型确实会默认采用它。
Others don’t.
其他模型则不会。
Different models have different default approaches, and the resource configuration determines which of those approaches happen to succeed.We replicated the core finding across different Anthropic models.
不同模型有不同的默认方法,而资源配置决定了其中哪些方法恰好会成功。我们在不同的 Anthropic 模型上复现了这一核心发现。
The direction of the effect was consistent, while the magnitude varied.
效应的方向一致,但幅度有所变化。
The same trends seem to hold on models other than Claude, but we haven’t rigorously tested them.
相同的趋势似乎也适用于 Claude 以外的模型,但我们尚未严格测试它们。
We also tested whether this pattern holds on evals outside Terminal-Bench by running a crossover experiment on SWE-bench.
我们还通过在 SWE-bench 上运行交叉实验,测试了这一模式是否在 Terminal-Bench 之外的评测中成立。
We varied the total available RAM up to 5x the baseline across 227 problems with 10 samples each.
我们在 227 个问题上将总可用 RAM 变化到基线的 5 倍,每个问题 10 个样本。
The same effect held, though the magnitude was smaller: Scores again increased monotonically with RAM, but were only 1.54 percentage points higher at 5x than 1x.
同样的效应依然存在,尽管幅度更小:分数再次随 RAM 单调增加,但在 5 倍时仅比 1 倍高 1.54 个百分点。
SWE-bench tasks are less resource-intensive, so a smaller effect is expected, but it shows resource allocation isn't neutral there either.
SWE-bench 任务对资源的需求较低,因此效应较小是意料之中的,但这表明资源分配在那里也并非中立。

Resource allocation isn't the only hidden variable.
资源分配并不是唯一的隐藏变量。
In certain configurations, time limits too start playing a role.
在某些配置下,时间限制也开始发挥作用。
In principle, every element of the evaluation setup can influence the final score, from the cluster health to the hardware specs, from the concurrency level to even egress bandwidth.
原则上,评测设置的每一个元素都可能影响最终分数,从集群健康状况到硬件规格,从并发级别到甚至出口带宽。
Agentic evals are end-to-end system tests by construction, and any component of that system can act as a confounder.
智能体评测(agentic eval)从构造上就是端到端系统测试,该系统的任何组件都可能成为混杂因素。
We have observed anecdotally, for instance, that pass rates fluctuate with time of day, likely because API latency varies with traffic patterns and incidents.
例如,我们偶然观察到通过率会随时间变化,这可能是因为 API 延迟随流量模式和事件而变化。
We have not formally quantified this effect, but it illustrates a larger point: the boundary between "model capability" and "infrastructure behavior" is blurrier than a single benchmark score suggests.
我们尚未正式量化这一效应,但它说明了一个更大的要点:“模型能力”与“基础设施行为”之间的边界比单一基准分数所暗示的更模糊。
A model provider can shield its eval infrastructure from this by dedicating hardware, but external evaluators can't easily do the same.
模型提供方可以通过专用硬件使其评测基础设施免受这一影响,但外部评估者很难轻松做到同样的事。
Public benchmarks are typically meant to measure pure model capabilities, but in practice they risk conflating them with infrastructure quirks.
公开基准通常旨在衡量纯粹的模型能力,但在实践中,它们有可能将其与基础设施的怪异之处混为一谈。
Sometimes this may be desirable, as it enables end-to-end testing of the entire stack, but more often it's not.
有时这可能是可取的,因为它能对整个技术栈进行端到端测试,但更常见的情况并非如此。
For coding evals meant to be shared publicly, running at multiple times and on multiple days would help average out the noise.
对于旨在公开分享的编码评测,在多个时间和多个日期运行有助于平均掉噪声。
The ideal scenario is to run each eval under the exact same hardware conditions—both the scaffold running the eval and the inference stack—as it would ensure perfect reproducibility across the board.
理想场景是在完全相同的硬件条件下运行每个评测——既包括运行评测的脚手架,也包括推理栈——因为这将确保全面实现完美的可复现性。
However, this may not always be practical.
然而,这并不总是切实可行。
Given how container runtimes actually enforce resources—via a guaranteed allocation and a separate hard kill threshold—we recommend that evals specify both parameters per task, not a single pinned value.
鉴于容器运行时实际上如何强制执行资源限制——通过一个保证分配量和一个单独的硬性终止阈值——我们建议评测为每个任务同时指定这两个参数,而不是一个单一的固定值。
A single exact spec sets the guaranteed allocation equal to the kill threshold, leaving zero margin: the transient memory spikes we documented at 1x are enough to destabilize the eval.
单一的精确规格会让保证分配量等于终止阈值,不留任何余量:我们在 1x 下记录到的瞬时内存尖峰,就足以使评测变得不稳定。
Separating the two parameters lets you give containers enough breathing room to avoid spurious OOM kills, while still enforcing a hard ceiling that prevents score inflation.
将这两个参数分开,可以给容器足够的喘息空间以避免虚假的 OOM 终止,同时仍强制执行防止分数虚高的硬性上限。
The band between them should be calibrated so that scores at the floor and ceiling fall within noise of each other.
两者之间的区间应经过校准,使得下限和上限处的分数彼此落在噪声范围内。
For instance, in Terminal-Bench 2.0, a 3x ceiling over the per-task specs cut infra error rates by roughly two-thirds (5.8% to 2.1%, p < 0.001) while keeping the score lift modest and well within noise (p = 0.40).
例如,在 Terminal-Bench 2.0 中,相对于每个任务的规格采用 3x 上限,将基础设施错误率降低了约三分之二(5.8% 到 2.1%,p < 0.001),同时使分数提升保持温和且完全落在噪声范围内(p = 0.40)。
That's a reasonable tradeoff: the infrastructure confounder is largely neutralized without removing meaningful resource pressure.
这是一个合理的权衡:基础设施混杂因素在很大程度上被中和,同时没有移除有意义的资源压力。
The exact multiplier will vary by benchmark and task distribution, and should thus be reported, but the empirical calibration principle is general.
确切的倍数会因基准和任务分布而异,因此应当报告,但基于经验的校准原则是通用的。
These findings have practical consequences beyond eval infrastructure.
这些发现具有超出评测基础设施的实际影响。
Benchmark scores are increasingly used as decision-making inputs, but this increased attention (and reliance) hasn’t always come with corresponding rigor in how they’re run or reported.
基准分数正越来越多地被用作决策输入,但这种日益增加的关注(和依赖)并不总是伴随着在其运行或报告方式上相应的严谨性。
As things stand today, a 2-point lead on a leaderboard might reflect a genuine capability difference, or it might reflect that one eval ran on beefier hardware, or even at a luckier time of day, or both.
就目前情况而言,排行榜上 2 分的领先可能反映真实的能力差异,也可能反映某次评测运行在更强悍的硬件上,甚至是在一天中更幸运的时间段,或者两者兼有。
Without published (or standardized) setup configurations, it’s hard to tell from the outside unless interested parties go the extra mile to reproduce objective results under identical conditions.
如果没有公开的(或标准化的)设置配置,外部很难判断,除非相关方付出额外努力,在相同条件下复现客观结果。
For labs like Anthropic, the implication is that resource configuration for agentic evals should be treated as a first-class experimental variable, documented and controlled with the same rigor as prompt format or sampling temperature.
对于像 Anthropic 这样的实验室,其含义是,智能体评测的资源配置应被视为一等实验变量,并以与提示词(prompt)格式或采样温度同样的严谨性进行记录和控制。
For benchmark maintainers, publishing recommended resource specs (as Terminal-Bench 2.0 does) can go a long way, while specifying enforcement methodology would close the gap we identified.
对于基准维护者,发布推荐资源规格(如 Terminal-Bench 2.0 所做的那样)会大有帮助,而明确强制执行方法将弥合我们发现的差距。
And for anyone consuming benchmark results, the core takeaway is that small score differences on agentic evals carry more uncertainty than the precision of the reported numbers suggests—especially as some confounders are simply too hard to control for.
而对于任何使用基准结果的人来说,核心要点是,智能体评测上的小分数差异所携带的不确定性,比所报告数字的精确度所暗示的要更大——尤其是因为有些混杂因素实在太过难以控制。
Until resource methodology is standardized, our data suggests that leaderboard differences below 3 percentage points deserve skepticism until the eval configuration is documented and matched.
在资源方法论尚未标准化之前,我们的数据表明,排行榜上低于 3 个百分点的差异值得怀疑,除非评测配置已被记录并匹配。
The observed spread across the moderate range of resource configurations in Terminal-Bench is just below 2 percentage points.
在 Terminal-Bench 中资源配置的中等范围内,观察到的差异略低于 2 个百分点。
Naive binomial confidence intervals already span 1-2 percentage points; the infrastructure confounders we document here stack on top of that, not within it.
朴素的二项置信区间已经横跨 1-2 个百分点;我们在此记录的基础设施混杂因素会叠加在其之上,而不是落在其中。
At the extremes of the allocation range, the spread reaches 6.
在分配范围的极端处,差异达到 6。
A few-point lead might signal a real capability gap—or it might just be a bigger VM.
几个百分点的领先可能意味着真实的能力差距——也可能只是更大的 VM。
Written by Gian Segato.
作者:Gian Segato。
Special thanks to Nicholas Carlini, Jeremy Hadfield, Mike Merrill, and Alex Shaw for their contributions.
特别感谢 Nicholas Carlini、Jeremy Hadfield、Mike Merrill 和 Alex Shaw 的贡献。
This work reflects the collective efforts of several teams working on evaluations for coding agents.
这项工作体现了多个致力于编程智能体评测的团队的集体努力。
Interested candidates who would like to contribute are welcome to apply at anthropic.com/careers.
有兴趣贡献的候选人欢迎在 anthropic.com/careers 申请。