Agentic test processes, LLM benchmarks, and other notes on agentic coding from Galapagos Island
Dan Luu shares his extensive experience with AI coding agents over the past year, focusing on testing, benchmarking, and agentic loops. He compares fuzzing vs. LLM-driven bug finding, finding fuzzing faster with lower false-positives; evaluates 'caveman mode' with 50 runs showing inconsistent savings; highlights high variance in LLM benchmarks, making public evals nearly useless for individual users. He also discusses automated PR generation from support tickets, multi-persona false-positive reduction, and challenges in data analysis and autonomous loops. For engineers interested in real-world effectiveness of AI coding tools.
I've been using AI fairly heavily since last November and the whole thing is a funny experience. An agent will do something that, if a human did it, you'd immediately fire them. My reaction, of course, is to act as if this is great and spin up a thousand agents so they can do even more of that.
Mid-last year, I had GPT (maybe 5.0 or 5.1) try to find the source of a bug. Naturally, this code didn't have tests and git bisect wouldn't work, and it was a UI interaction bug for which I'm not even really qualified to write a test for, so I asked Codex to bisect between dates X and Y to find the commit that introduced this bug. Codex immediately told me the offending commit was after this date range (which couldn't possibly be correct). On telling Codex this was wrong, it then told me some commit that was obviously also not the offending commit once or twice. On telling it those were wrong, it then told me the offending commit was some plausible looking commit. When I asked it to prove or disprove its theory, it told me that it wrote a test and confirmed that the alleged commit was the breaking commit.
I then asked it to show me by making a video with the full developer end-to-end stack in the normal browser test environment. It claimed that it didn't have permissions to do that (which was a lie), but it could make video of the execution of the repro before and after the commit in playwright with the appropriate test code. The video was convincing and showed the feature working properly before the commit and failing to work after the commit. Something about this didn't feel right, so I tried reproducing the issue by hand before and after the commit and found out that the whole thing was a fabrication. The video made it look like Codex had reproduced the bug, but it was an artificial browser environment that was designed to create a fake repro, not the real environment.
Like I said, because this was non-ironically such a great experience, I immediately thought to myself, "how can I get more of this?" and started using agents more and more heavily until I was using coding agents heavily mid-late last year.
自去年十一月以来,我一直频繁使用 AI,整个过程颇为有趣。代理有时会做出如果换成人类员工你会立刻开除的事情。而我的反应当然是装作这很棒,然后启动一千个代理,让它们做更多同样的事。 去年年中,我让 GPT(可能是 5.0 或 5.1)找一个 bug 的根源。自然,这段代码没有测试,git bisect 也不管用,而且这是一个 UI 交互 bug,我甚至没有资格为它编写测试。于是我让 Codex 在日期 X 和 Y 之间进行二分查找,找出引入这个 bug 的提交。Codex 立刻告诉我,罪魁祸首提交在这个日期范围之后(这不可能正确)。我告诉它这个结果不对,它又给出了一个明显不是罪魁祸首的提交。我再次指出错误后,它给出了一个看起来合理的提交。当我要求它证明或反驳自己的理论时,它说它写了一个测试并确认那个提交是破坏性的提交。 然后我要求它展示完整的过程,在正常浏览器测试环境中录制端到端视频。它声称没有权限这么做(这是谎言),但可以用 Playwright 和相应的测试代码录制复现过程在提交前后的执行视频。视频很有说服力,展示了功能在提交前正常工作,提交后失效。但我觉得不对劲,于是手动在提交前后复现了问题,发现整个都是编造的。视频看起来像是 Codex 复现了 bug,但实际上是一个专门设计用于制造假复现的人工浏览器环境,而不是真实环境。 正如我所说,因为这非讽刺地是一次极好的体验,我立刻想:“怎样才能获得更多这样的体验?”于是开始越来越重度地使用代理,直到去年中下旬开始大量使用编码代理。
Since this post covers a relatively disparate set of topics, here's a brief outline.
Testing background
Some details on testing
Caveman mode
LLM variance
Misc
Agentic loops and writing this post
Some reasons people talk past each other
由于这篇文章涵盖的主题较为分散,以下是一个简要大纲。
测试背景
测试细节
“穴居人模式”
LLM 方差
杂项
代理循环与本文写作
人们为何彼此失语
Testing background
LLMs are highly leveraged when it comes to testing. In terms of the amount of effort it takes, it's easier than ever to hit a particular quality bar and yet, software seems to be lower quality than ever. A decade ago, we looked at the bugs I ran into in an arbitrary week. There were quite a few bugs then and I run into more bugs now, but I don't think this has to be the case.
For one thing, after a bug has been shipped, it's easier than it's ever been to use a data-driven approach to find and fix the bug. Just for example, at work, I tried creating a pipeline that goes from support ticket (chat or email) to pull request (PR). As far as I can tell, this works ok. Since I work for a company that has a traditional workflow, all of these fixes get reviewed by a human and, so far, we've had no known false positives.
Per unit of time invested, it's also possible to do more thorough testing. Personally, I think this can be effective enough that I'm fairly comfortable trying to ship a large volume of code via a "software factories" workflow because I've seen a testing-heavy no-review workflow that results in much higher quality than any review-reliant workflow I've seen or even heard of.
LLM 在测试方面具有很高的杠杆作用。就所需努力而言,达到特定质量门槛比以往任何时候都更容易,然而软件质量却似乎比以前更低了。十年前,我们观察了一周内我遇到的 bug。当时 bug 不少,现在更多,但我认为不必然如此。 首先,bug 发布后,采用数据驱动的方法来发现和修复 bug 比以往任何时候都容易。例如,在工作时,我尝试创建一条从支持工单(聊天或邮件)到拉取请求(PR)的流水线。据我所知,这效果还不错。由于我在一家采用传统工作流程的公司工作,所有这些修复都会经过人工审查,到目前为止,没有已知的误报。 每单位投入时间内,我们还可以进行更彻底的测试。我个人认为这可以足够有效,以至于我相当愿意尝试通过“软件工厂”工作流程大量发布代码,因为我看到过一种注重测试且不依赖审查的工作流程,其质量远高于我所见过或听说过的任何依赖审查的工作流程。
Like everybody, I have biases that fall out of my experiences. It just so happens that I spent the first decade of my career at a company whose test processes happen to work well in today's LLM environment. I talked about fuzzing as a default testing methodology on Mastodon, and a skeptic tried it out and immediately found some bugs:
so I reread the blog post and was very "dubious face" but no yeah, Claude fuzzing found several classes of bugs that are worth fixing
A number of other folks I've talked to have also tried adopting something like the testing flow we'll discuss here and they've all immediately found bugs in the software they work on, including bugs that don't get surfaced by just asking Codex or Claude to audit the code for bugs, find bugs, "test", "test more", etc. For example, Dennis Snell mentioned that he and a teammate, Jon Surrell, not only found bugs in the code they're working on, but also "in upstream dependencies, including the HTML specification, big-three browsers, and other open-source projects" with fairly low effort.
和所有人一样,我的偏见源于我的经验。碰巧的是,我职业生涯的头十年在一家测试流程恰好适用于当今 LLM 环境的公司度过。我在 Mastodon 上谈到将模糊测试作为默认测试方法,一位 skeptics 尝试后立即发现了一些 bug: “于是我重读了那篇博客文章,表情非常怀疑,但没错,Claude 模糊测试确实发现了几类值得修复的 bug。” 我交谈过的许多其他人也尝试了类似我们即将讨论的测试流程,并且立即在他们工作的软件中发现了 bug,包括那些仅通过要求 Codex 或 Claude 审查代码、查找 bug、“测试”、“更多测试”等无法发现的 bug。例如,Dennis Snell 提到,他和队友 Jon Surrell 不仅在他们的代码中发现了 bug,还以相当低的努力在“上游依赖项中发现了 bug,包括 HTML 规范、三大浏览器以及其他开源项目”。
In general, when I talk to software folks about testing, I'm coming from such a different place that they immediately look at me like I'm an alien, so let's talk about how we tested at this hardware company I worked for, Centaur, which informs my biases about how I like to work. Some of the things that we did that were or are unorthodox in the software world are:
- Hired dedicated QA / test engineers, with testing being a first-class career path on par with being a developer
- No code review by default
- Virtually no hand-written tests
- Constant testing via what programmers sometimes called property based testing, randomized testing, fuzzing, etc., although we just called those tests (hand-written tests were called "hand tests").
- Large regeression test suite (3 months wall clock to execute on compute farm)
- No unit tests
Just to give you an idea of the general structure, when I left (in 2013), we had about 1000 machines generating and running tests at all times for roughly 20 logic designers and 20 test engineers. This was on prem and the machines took up half a floor of the building we were in.
The general structure was that we had maybe 20% of machines running regression tests, and 80% generating and running new tests. Three months of regression tests is too much to gate commits on, so there was a much shorter list of tests that took maybe 10 minutes or so to run that people would run before committing. Those pre-commit tests would run on a special setup to run as quickly as possible, with overclocked machines that were the fastest machines money could buy, as well as a different simulator setup.
New failures would get found and reported as they happened and one to two engineers had a job of sorting through failures and triaging them (rejecting false positives, fixing issues in the test generator that caused them to generate false positives, etc.).
In terms of the magnitude of the impact, unless you count culture as a separate item, (1) was probably the biggest difference between us and a typical software company, but also the most irrelevant for readers here, so I'll relegate the discussion to a footnote1, except for this brief comment that testing is like any other skill; spending more time doing it improves skill and, since testing isn't a first-class career path at most major tech companies, people generally don't have the same level of testing skills at software companies as you see in some career CPU test engineers. In the same way that an engineer who who spends 20 years working on distributed systems or UX is going to be much better at it than an equally talented engineer who spends 5% of their time on distributed systems or UX, someone who spends 20 years working on testing is going to be much better at it than somebody who spends 5% of their time on testing.
总的来说,当我与软件从业者讨论测试时,我的出发点如此不同,以至于他们立刻像看外星人一样看着我。所以让我谈谈我在 Centaur 这家硬件公司是如何测试的,这塑造了我对工作方式的偏好。我们在软件领域所做的一些非正统(或曾经非正统)的事情包括:
- 聘请专职 QA/测试工程师,将测试作为与开发同等重要的职业路径
- 默认没有代码审查
- 几乎没有手写测试
- 持续使用程序员有时称为基于属性的测试、随机测试、模糊测试等方法进行测试,尽管我们只是称之为测试(手写测试则称为“手工测试”)
- 大型回归测试套件(在计算集群上执行需要 3 个月时间)
- 没有单元测试
为了让你对大致结构有所了解,当我离开时(2013 年),我们有大约 1000 台机器持续生成和运行测试,服务于大约 20 名逻辑设计师和 20 名测试工程师。这些机器部署在本地,占据了所在楼层的一半空间。 大致结构是,大约 20% 的机器运行回归测试,80% 的机器生成并运行新测试。三个月的回归测试时间太长,无法作为提交的门禁,因此有一个更短的测试列表,大约只需运行 10 分钟,人们在提交前会运行这些测试。这些预提交测试会在特殊设置上运行,以尽可能快速执行,使用超频机器(当时金钱能买到的最快机器)以及不同的模拟器设置。 新故障会在发生时被发现并报告,有一到两名工程师负责分类故障并进行分流(拒绝误报,修复导致误报的测试生成器问题等)。 就影响规模而言,除非将文化视为单独一项,否则(1)可能是我们与典型软件公司之间最大的区别,但对这里的读者来说也是最不相关的,因此我将讨论放在脚注 1 中,仅简要提及:测试和其他技能一样,花更多时间练习会提高技能。由于在大多数大型科技公司中,测试并非一流的职业路径,软件公司的测试技能水平通常不如某些职业 CPU 测试工程师。就像一位从事分布式系统或用户体验 20 年的工程师会比一位同等才华但只花 5% 时间在这些领域的工程师更擅长一样,一位从事测试 20 年的人会比只花 5% 时间在测试上的人更擅长测试。
(2) is one of the things that makes some of the test practices we used at the chip company suited to AI workflows. We didn't review code by default because we trusted our test practices enough that review didn't, in general, add much reliability. We were shipping fewer than 1 significant user-visible bug per year, and review was done on an as-needed basis when someone wanted an extra set of eyes on something they thought was particularly tricky2. With AI coding workflows, it's easy for one person to generate more code than any human or even any ten humans can review by hand. People have different levels of comfort with shipping code without review. Personally, I'm very comfortable shipping code without human review because I've seen it done on products that are technically more challenging than most software at most software companies.
I often see people say things like, "that's too much risk; we have millions of users" but, empirically, they're talking about a workflow that ships bugs at a rate that's maybe a thousand times higher per capita on raw count, with the ratio being much higher if you adjust for severity. If a company were shipping bugs at, say, a hundredth the rate we were at Centaur while relying primarily on review to catch bugs, then I could see their point, but that's not what's happening at the typical software company where people don't want to move away from human review because of the perceived risk of shipping bugs.
(2)是我们在芯片公司使用的部分测试实践之所以适合 AI 工作流程的原因之一。我们默认不进行代码审查,因为我们信任自己的测试实践,以至于审查通常不会显著增加可靠性。我们每年交付的严重用户可见 bug 少于一个,审查只在有人觉得某段代码特别棘手、需要额外检查时才进行。在 AI 编码工作流程中,一个人生成的代码量很容易超过任何人类甚至十个人类的手动审查能力。人们对未经审查发布代码的接受程度不同。就我个人而言,我非常乐意在没有人工审查的情况下发布代码,因为我在比大多数软件公司产品技术难度更高的产品上见过这种做法。 我经常听到人们说“风险太大;我们有数百万用户”,但根据经验,他们所说的工作流程每人的原始 bug 数量可能高出一千倍,如果按严重程度调整,比例更高。如果一家公司发布 bug 的速率是 Centaur 的百分之一,并且主要依赖审查来捕捉 bug,那么我能理解他们的观点。但通常软件公司并非如此,人们不愿放弃人工审查是因为对发布 bug 的感知风险。
(3) and (4) go hand in hand. Almost every software group I know of that's serious about reliability (various teams that ship reliable databases, distributed databases etc.) are at least directionally doing the same thing, although they might have a larger fraction of hand written tests. For the same reason it's considered a bad idea to rely on testing by interacting with the software yourself and observing whether or not the software appeared to work, it's a bad idea to rely on directly typing out the inputs to a test and the expected outputs. As previously discussed, it's just really inefficient to write tests by hand. For any given level of reliability, you'll get there more quickly if you prefer randomized test generation over hand-written tests.
(3)和(4)相辅相成。据我所知,几乎所有认真对待可靠性的软件团队(例如那些交付可靠数据库、分布式数据库的团队)至少在方向性上都在做同样的事情,尽管他们可能有更大比例的手写测试。出于同样的原因,依赖手动与软件交互并观察其是否工作被认为是个坏主意,直接手动输入测试输入和预期输出也是个坏主意。如前所述,手写测试效率极低。对于任何特定的可靠性水平,如果你倾向于随机测试生成而非手写测试,你会更快达到目标。
(5) fell out of having a lot of tests find a lot of bugs. In general, if a test found a bug that we later fixed, we'd keep the test in our regression test suite forever. It turns out, if you find a lot of bugs with good tests, you'll end up with a large test suite. But putting that aside and just looking at it from a test efficiency standpoint, the standard setup in software of having the same set of tests run in CI for each PR is extraordinarily inefficient if you think about the what's more likely to find a bug, running the same test a thousand times in a day or, in the same amount of test time, running a thousand different tests.
(5)源于大量测试发现大量 bug。通常,如果某个测试发现了一个 bug 并且我们后来修复了,我们会永远保留该测试在回归测试套件中。事实证明,如果你通过好的测试发现了很多 bug,你最终会得到一个庞大的测试套件。但撇开这一点不谈,仅从测试效率的角度来看,软件中常见的做法(每个 PR 在 CI 中运行同一组测试)极其低效。试想一下,在同样的测试时间内,是运行同一个测试一千次更有可能发现 bug,还是运行一千个不同的测试更有可能?
(6) came out of test efficiency concerns as well, in that we had a much smaller team than our competitors. That was a reason the company managed to survive for so long. While Intel was putting every x86 designer out of business other than AMD, our operating cost was low enough that the company survived until 2021, at which point it was acquired by Intel for $125M. With the company's tiny team size, it wouldn't have been possible to get reasonable test coverage with unit tests and hiring enough to do unit tests probably would've meant the company would've gone the way of the x86 efforts of Transmeta, Rise, Cyrix, TI, UMC, NEC, VM, etc., a decade or two sooner. From an efficiency standpoint, unit testing does pretty poorly.
(6)同样源于测试效率的考量,因为我们团队规模远小于竞争对手。这也是公司能够长期生存的原因之一。当英特尔将除 AMD 之外的所有 x86 设计者挤出市场时,我们的运营成本足够低,使得公司一直存活到 2021 年,随后被英特尔以 1.25 亿美元收购。由于公司团队规模极小,通过单元测试获得合理测试覆盖率是不可能的,而雇佣足够的人员进行单元测试可能意味着公司会像 Transmeta、Rise、Cyrix、TI、UMC、NEC、VM 等 x86 先驱那样早一二十年消亡。从效率角度看,单元测试表现相当糟糕。
To sum it up, we did quite a few things that most software people tell me are bad ideas (dedicated test engineers, no unit tests, no code review, etc.) and we had much higher quality than any software company I've worked for or any software I've used. Whenever I talk about this, people will say that this doesn't apply to software because CPUs only have X concerns and you can't do the same thing with Y. When I first switched from CPU design to software I thought that might be true, but I've since tried this testing methodology with every kind of Y that someone has mentioned this can't work for and it's worked for every single one, so I no longer find this very plausible (and the Xs generally involved incorrect assumptions of what hardware development is like). While there are real differences between hardware and software, when I've seen people lean on that as a reason that testing techniques don't carry over, it's been the case that the person is relying on some imagined factor that only seems relevant because the person doesn't know much about hardware development.
One significant difference was the ratio of effort that went into testing vs. development, but the fixed costs of fuzzing are fairly low, so this is scalable to any level of effort and the efficiency gains are still there. And, due to the gains in test efficiency, the ratio of effort wasn't as large as software engineers generally imagine. We had about a 1:1 ratio of test engineers to developers and then spent maybe 10% of our time in a "freeze" state, where the goal was to find bugs and not ship new features, so a zeroth order estimate for the overhead here is that we spent 55% of our effort on testing and 45% on development, or we could've put 2.2x the effort into development if we spent zero effort on testing. If you look at a software company that's shipping significant bugs many times faster than we did and you declare an emergency and get people to spend 55% of their effort on testing, I don't think the ratio changes too much. Maybe they get to half the previous ratio or something, but the level of effort isn't really what's making the difference.
Nowadays, another thing people will say is, why bother with fuzzing when you can just ask an LLM to find bugs? I've tried doing both quite a few times now and my experience has been that fuzzing generally wins on latency to find a bug, and it dominates on finding more bugs and having a lower false positive rate. LLMs have fairly high variance (more on this later), so just asking Codex or Claude to find a bug can sometimes win but, on average, fuzzing has won.
总而言之,我们做了许多大多数软件从业者告诉我不好的事情(专职测试工程师、没有单元测试、没有代码审查等),但我们的质量比我工作过的任何软件公司或使用过的任何软件都高得多。每当我谈论这个,人们会说这不适用于软件,因为 CPU 只有 X 种关注点,你不能对 Y 做同样的事。当我最初从 CPU 设计转向软件时,我也认为这可能成立,但后来我尝试了这种测试方法,针对人们说不可行的每一种 Y,结果都成功了,因此我不再认为这是有说服力的理由(而通常 X 涉及对硬件开发的不正确假设)。尽管硬件和软件之间存在真实差异,但当我看到有人以此作为测试技术不能迁移的理由时,往往是他们依赖某些想象中的因素,而这些因素只是因为他们对硬件开发了解不多才显得相关。 一个显著的区别是测试与开发的努力比例,但模糊测试的固定成本相当低,因此可以扩展到任何努力水平,且效率提升仍然存在。而且由于测试效率的提升,努力比例并不像软件工程师通常想象的那样大。我们的测试工程师与开发人员比例约为 1:1,然后大约有 10% 的时间处于“冻结”状态,目标是发现 bug 而非发布新功能,因此粗略估计测试开销为 55% 的努力用于测试,45% 用于开发。如果我们完全不进行测试,可以将 2.2 倍的努力投入开发。如果一家软件公司发布严重 bug 的速度比我们快很多倍,并且你宣布紧急状态,让人们将 55% 的努力用于测试,我认为比例不会变化太大。也许他们能让比例减半,但努力程度并非决定性因素。 如今,人们还会说,既然可以直接让 LLM 找 bug,何必费心做模糊测试?我多次尝试过两者,我的经验是模糊测试在发现 bug 的延迟上通常胜出,在发现更多 bug 和更低的误报率上也占优。LLM 的方差很高(稍后详述),所以直接让 Codex 或 Claude 找 bug 有时能赢,但平均而言,模糊测试胜出。
Some details on testing
Despite the very positive things I've said about LLMs testing, LLMs seem pretty bad at testing. However, for any level of testing effort, LLMs let you apply testing effort a lot more easily than before if steered properly.
An extreme example of this is that everybody I've talked to who cares about quality or testing at all finds the tests LLMs generate by default, or if you tell them "Write tests", "Write more tests", etc., to be poor. People tend to rate the tests as somewhere between worthless and marginally useful, depending on their standards.
For example, Em Chu (a compiler engineer) says:
The existing tests I'm working with aren't perfect, but are still above the bar LLMs seem to aim for, which I would describe as "thorough enough to smuggle a feature through human code review." For a compiler (compared to e.g. UI), where I'm guessing it's easier to write the average test, but a higher bar of correctness is generally expected of the end product, LLMs just suck. They are painfully bad at the adversarial "now, what if I do this" or "let's try the cross-product of everything" process humans use to write tests that actually find bugs
At the same time, I've seen a number of folks rave at how amazingly good LLMs are at testing when you tell them "Write tests", "Write more tests", etc. When I've looked into why people say LLMs are great at testing, what I've found is that people who did essentially no testing at all find LLMs to be great at testing. Well, that makes sense. If you go from basically zero testing effort to a tiny bit of testing effort, that's a huge win.
尽管我之前对 LLM 测试的评价非常正面,但 LLM 似乎并不擅长测试。然而,对于任何级别的测试努力,如果引导得当,LLM 能让你比以前更容易地投入测试努力。 一个极端的例子是,每一个我交谈过的关心质量或测试的人,都认为 LLM 默认生成的测试(或当你告诉它们“写测试”、“多写测试”时生成的测试)质量很差。人们通常评价这些测试介于毫无价值到勉强有用之间,取决于他们的标准。 例如,编译器工程师 Em Chu 说: “我目前使用的现有测试并不完美,但仍高于 LLM 似乎追求的水平,我将其描述为‘足够在人工代码审查中蒙混过关’。对于编译器(与 UI 相比),我认为写普通测试更容易,但最终产品通常期望更高的正确性标准,LLM 在这方面糟糕透顶。它们在对抗性思维(‘现在,如果我这样做会怎样’或‘让我们尝试所有组合的笛卡尔积’)方面极其薄弱,而人类正是利用这种过程来编写真正能发现 bug 的测试。” 与此同时,我也看到许多人对 LLM 在测试方面的表现赞不绝口,当你告诉它们“写测试”、“多写测试”时。我深入探究了为何人们认为 LLM 擅长测试,发现那些基本上从不做测试的人觉得 LLM 测试很出色。这有道理:如果你从零测试努力到一点点测试努力,那就是巨大的胜利。
As of June 2026, directing LLMs to do fuzzing / randomized testing feels similar. I've tried using an LLM to generate a fuzzer and, for most projects, this will turn up real and often serious bugs within minutes. However, on looking at what the LLM-created fuzzer is trying to test, I have the same reaction as a normal programmer who cares about quality looking at LLM-created tests. The coverage of the LLM-generated fuzzer is curiously bad and misses all kinds of basic things you'd expect a hastily human-written fuzzer to cover. Depending on whether you're a glass half empty or a glass half full person, you might say that this says something about the test coverage of most projects, or that it says something about the unreasonable effectiveness of fuzzing.
At a high level, LLM-generated fuzzers from SOTA models today don't do a good job of "thinking about" how inputs should be varied to elicit bugs. Then, if you naively tell it about how inputs should be varied and to combine these, it will also not combine bug ingredients in a reasonable way. It's possible to give instructions that will work well, but this heavily relies on the user to provide direction.
截至 2026 年 6 月,指导 LLM 进行模糊测试/随机测试的感觉类似。我尝试过用 LLM 生成模糊测试器,对于大多数项目,这能在几分钟内发现真实且通常严重的 bug。然而,当审视 LLM 创建的模糊测试器试图测试什么时,我的反应与关心质量的普通程序员看到 LLM 创建的测试时一样。LLM 生成的模糊测试器的覆盖范围出奇地糟糕,漏掉了你预期一个匆忙手写的模糊测试器应该覆盖的所有基本内容。根据你是乐观还是悲观,你可能会说这说明大多数项目的测试覆盖率低,或者说明模糊测试具有不合理的有效性。 从高层来看,当今最先进模型生成的 LLM 模糊测试器在“思考”如何改变输入以引发 bug 方面表现不佳。然后,如果你天真地告诉它如何改变输入并组合它们,它也不会以合理的方式组合 bug 要素。有可能给出能够很好工作的指令,但这高度依赖于用户提供方向。
If you're using randomized testing as "extra credit", to catch a few more bugs, or to replace traditional software testing processes, you can just tell an LLM to look for risky areas of the code and find invariants that might be violated and fuzz them. This works ok. When I've convinced people to try some randomized testing, they usually start here and find quite a few bugs they're happy to have found. Due to the nature of who's interested in trying out novel-to-them test techniques, this is often from people who've worked on some of the most well-tested and reliable code at the company and they can find bugs in their own relatively well-tested code.
If you want to use randomized testing to keep an agentic "software factories" workflow honest, then you need to have a way to deal with gaps in SOTA models because, when you're shipping the equivalent of hundreds or thousands of PRs a day into a project, everything that's not constrained from degrading will rapidly degrade.
At a high level, the entire system needs some kind of feedback that finds gaps and instructs whatever loop is making adjustments to the fuzzer to close the gaps. Recently, I've been testing things where I don't understand the domain and don't understand the project or the code, so I've been flying relatively blind and know that there will be a lot of gaps in what I come up with (and, as noted above, LLMs are terrible at this). But even in areas where I'm familiar with the domain and understand the code relatively well, there will still be some gaps because humans miss things and make mistakes, so there always needs to be some kind of feedback into the test setup that can find gaps and allow you or an agent to close the gaps.
如果你将随机测试用作“额外加分”,以捕捉更多 bug,或替代传统软件测试流程,你可以直接告诉 LLM 寻找代码中的风险区域,发现可能违反的不变量并进行模糊测试。这效果还行。当我说服人们尝试一些随机测试时,他们通常从这里开始,发现不少让他们高兴的 bug。由于有兴趣尝试新测试技术的人往往是那些在公司最经过测试和最可靠的代码上工作的人,他们甚至能在自己相对经过测试的代码中发现 bug。 如果你想用随机测试来保持“代理软件工厂”工作流的诚实,你需要一种方法来处理最先进模型中的空白。因为当你每天向项目交付相当于数百或数千个 PR 时,任何不受约束的东西都会迅速退化。 在高层次上,整个系统需要某种反馈,能够发现空白并指示进行调整的循环来填补这些空白。最近,我在测试一些我不理解领域、不理解项目或代码的东西,所以基本上是盲飞,并且知道我会遇到许多空白(如前所述,LLM 在这方面很糟糕)。但即使在我熟悉领域并相对理解代码的领域,也仍然会有一些空白,因为人类会遗漏事情并犯错,所以总是需要某种反馈进入测试设置,以发现空白并允许你或代理来填补它们。
I've been playing with various ways to have agents convene and reconvene to get agentic loops running better and, while that kind of thing helps, I haven't figured out a way to do do this well enough to create some kind agentic software quality improvement loop that doesn't rely on outside feedback, whether that's occasional human input, or shipping something (ideally only fractionally and with staged rollout) and then having the system monitor metrics/logs/traces/support tickets/whatever to use that as feedback. The support ticket to PR pipeline I mentioned above is one such feedback loop. The pipeline not only tries to generate a PR, it also tries to get the test setup to add test coverage that will find the bug and possibly surface other bugs, or will re-find the bug if there's a future regression. This seems to work ok-ish, in that it finds real bugs and improves test coverage, but I'm sure there's a lot of room for improvement.
我一直在尝试各种方法让代理聚集和重新聚集,以更好地运行代理循环。虽然这类方法有帮助,但我还没有找到一种足够好的方法来创建某种不依赖外部反馈的代理软件质量改进循环,无论这种反馈是偶尔的人工输入,还是发布某些东西(理想情况下仅部分发布并分阶段推出),然后让系统监控指标/日志/追踪/支持工单等,将其用作反馈。我上面提到的支持工单到 PR 的流水线就是这样一个反馈循环。该流水线不仅尝试生成 PR,还尝试让测试设置增加测试覆盖率,以发现该 bug,并可能暴露其他 bug,或者在将来出现回归时重新发现该 bug。这似乎效果尚可,能发现真实 bug 并提高测试覆盖率,但我相信还有很大的改进空间。
Relatedly, I've been wondering why LLMs are so bad at writing tests. On asking around a bit, I'm told that this is because the capabilities that LLMs have come out of people building RL environments which allow models to improve at tasks, sometimes in a generalizable way and sometimes not. I'm also told that there's a market for selling RL envs, but it's fairly thin because there aren't all that many buyers for them, and you really want to know someone at a lab who's a buyer or close to it. If you are such a person or can connect me with such a person, could you do me a favor and reach out to me (I'm fairly easily reachable on X, Mastodon, email, etc.). I'm curious about how this works and how plausible it is to sell an RL env for something like testing, optimization, or the longer horizon tasks discussed in this post, where it's easy to observe significant gaps.
与此相关,我一直在想为什么 LLM 在编写测试方面如此糟糕。经过一番询问,有人告诉我这是因为 LLM 的能力来自于人们构建的 RL 环境,这些环境允许模型在任务上改进,有时以可泛化的方式,有时则不然。我还听说存在销售 RL 环境的市场,但市场相当薄弱,因为买家并不多,并且你真的需要认识实验室中的买家或接近买家的人。如果你是这样的人,或者可以联系到这样的人,能否帮我联系一下(我在 X、Mastodon、电子邮件等上很容易找到)。我很好奇这如何运作,以及销售 RL 环境用于测试、优化或本文讨论的更长周期任务(其中很容易观察到显著差距)的可行性如何。
Back on the topic of testing, when fuzzing or doing any kind of bug auditing, detecting false positives is a critical part of the process. At least for now, having access to a model that's better than anything you can publicly use won't save you. A while back, Dennis Snell told me, frustratedly, that he spent the day wading through AI slop forwarded to his employer by Anthropic that came from their vaunted Mythos model that's too dangerous to release from the public. Anthropic was apparently doing the company some kind of favor or maybe doing some kind of EA security improvement, except that they didn't bother with having a reasonable false positive rejection process so they were just forwarding garbage to us. At the time, I was using a model that, if Fable is any indication, appears to be moderately less capable than Mythos, but I had no problem generating an endless stream of bugs (some of which were security issues) with no known false positives, which seems to indicate that having a reasonable setup around the model is a least as important as having the latest and greatest model.
回到测试的话题上,在进行模糊测试或任何类型的 bug 审计时,检测误报是过程中的关键部分。至少目前,拥有比任何公开可用模型更好的模型并不能拯救你。不久前,Dennis Snell 沮丧地告诉我,他花了一天时间清理 Anthropic 转发给他雇主的 AI 垃圾,这些垃圾来自他们吹嘘的、太危险而不能公开的 Mythos 模型。Anthropic 显然是在帮公司一个忙,或者是在进行某种 EA 安全改进,只是他们没有费心建立合理的误报拒绝流程,所以只是把垃圾转发给我们。当时,我使用的模型如果以 Fable 为参考,似乎能力略低于 Mythos,但我可以毫无问题地生成源源不断的 bug(其中一些是安全问题),且没有已知的误报。这似乎表明,在模型周围建立合理的设置至少与拥有最新最好的模型同样重要。
I've been trying custom workflows on a per-project / per-problem basis and don't exactly have a generic false positive rejection scheme, but there are various things that seem to be semi-generalizable. If you don't mind spending tokens, having independent agents repeatedly check an alleged bug reproduction (repro) substantially cuts the false positive rate. A couple months ago, I mentioned that I had good luck using different "personas" for reviews as well as for managing agentic loops and I got some responses with theoretical reasons this doesn't work well but, in practice, it seems to work fairly well. My workflow changes regularly and maybe a week after that discussion I started adding "contrarian" personas to the mix, which improved performance given the same wall clock or token budget.
For anything human reviewed, having some kind of artifact (e.g., a video if it's a bug that's expected to be apparent in the UI) is necessary. Without really explicitly trying to have the agent review this, just producing this at all seems to reduce the false positive rate somewhat, and then having the agent review the artifact reduces the false positive rate further. Asking agents to independently review the artifact (e.g., looking at the test code that produces the video vs. looking at the video itself) also reduces the false positive rate further. In general, getting independent perspectives seems to help a lot with reducing false positives. In the experiments I've run, this has been less effective than having agents with different personas / perspective per wall clock time or per dollar, but just asking the same question multiple times improves results, for reasons that should be obvious from the graphs in the LLM variance section.
Pretty much everything I've tried to reduce false positive rate has worked, so if you're not scaling up a workflow to the point where optimizing the costs matters, doing anything remotely reasonable seems to work fairly well.
我一直在针对每个项目/每个问题尝试自定义工作流程,并没有一个通用的误报拒绝方案,但有一些半泛化的方法。如果你不介意花费令牌,让独立代理反复检查声称的 bug 复现(repro)可以大幅降低误报率。几个月前,我提到我运气不错,使用了不同的“角色”来进行审查以及管理代理循环,我收到了一些回应,理论上认为这效果不好,但在实践中似乎效果不错。我的工作流程会定期变化,在那次讨论大约一周后,我开始在组合中加入“逆向”角色,这在不增加墙钟时间或令牌预算的情况下提高了性能。 对于任何需要人工审查的东西,某种形式的制品(例如,如果 bug 预期在 UI 中显现,则使用视频)是必要的。即使没有明确要求代理审查它,仅仅生成它似乎也能在一定程度上降低误报率,然后让代理审查制品能进一步降低误报率。要求代理独立审查制品(例如,查看生成测试代码的视频与查看视频本身)也能进一步降低误报率。总的来说,获取独立视角似乎对减少误报大有帮助。在我运行的实验中,这种方法在每墙钟时间或每美元上的效果不如使用不同角色/视角的代理,但仅仅是多次问同一个问题就能改善结果,原因从 LLM 方差部分的图表中应该显而易见。 我尝试过的几乎所有降低误报率的方法都有效,所以如果你不将工作流程扩展到成本优化至关重要的地步,任何看似合理的方法似乎都效果不错。
Caveman mode
I keep getting various tool and workflow recommendations and, when I look into it, I can almost never find good information on whether or not it makes sense to adopt the recommendation. Just for example, I've seen "caveman mode" recommended multiple times at work. Caveman mode allegedly reduces token usage and speeds up prompt resolution (the README claims 75% reduction in token usage, 65% reduction token usage, and 2x fewer tokens used, as well as a 3x speed increase).
Searching for information (just googling 'caveman mode', no quotes, the top hit that wasn't a link to caveman mode was this reddit thread where, of the three top comments, one is joke and the other two highly recommend it:
Just extreme brevity in a refreshing way... and dramatically lowered token count without any seeming impact on the analytical thinking... but i have no way to benchmark before and after.
Someone at work is testing it and it seems to actually save tokens AND work just as well.
Most of the rest of the top hits were also positive recommendations for caveman mode that purported to do some kind of eval (although they read like unfiltered LLM text) and the top hit on YouTube was one of the the biggest programming YouTubers saying
it actually works; it actually works quite well ... no, I'm not exaggerating
In a slack thread at work where people were recommending caveman mode, I asked if anyone had done a comparison, noting that the creator of caveman mode responded to the HN thread about caveman mode by saying it's a joke. Someone linked to an analysis of caveman mode that claims a significant win, but the analysis was an LLM-generated SEO spam article with numerous errors. When I politely pointed this out, the person who posted the link said "I only skimmed it".
我不断收到各种工具和工作流程的推荐,但当我深入了解时,几乎找不到关于采纳这些推荐是否有意义的好信息。例如,我在工作中多次看到“洞穴人模式”被推荐。洞穴人模式据称能减少令牌使用量并加速提示解决(README 声称减少 75% 的令牌使用、减少 65% 的令牌使用、使用 2 倍少的令牌,以及 3 倍的速度提升)。 搜索信息(直接在谷歌搜索 'caveman mode',不加引号),第一个不是洞穴人模式链接的顶部结果是这个 Reddit 帖子,其中三个顶级评论中,一个是玩笑,另外两个高度推荐: “以一种令人耳目一新的方式极度简洁……并且大幅降低了令牌数量,而对分析性思维似乎没有任何影响……但我没有办法进行前后对比。” “有人在工作时测试了它,似乎确实节省了令牌并且效果一样好。” 其余大部分顶部结果也是对洞穴人模式的正面推荐,声称进行了某种评估(尽管它们读起来像未经筛选的 LLM 文本),而 YouTube 上的顶部结果是一位最大的编程 YouTuber 说: “它确实有效;它确实效果很好……不,我没有夸张。” 在一次工作中推荐洞穴人模式的 Slack 讨论中,我问是否有人做过比较,并指出洞穴人模式的创建者在 HN 讨论中回应说那是个玩笑。有人链接了一篇分析洞穴人模式的文章,声称取得了显著胜利,但该文章是一篇包含众多错误的 LLM 生成的 SEO 垃圾文章。当我礼貌地指出这一点时,发布链接的人说“我只是浏览了一下”。
At that point, I decided to spend about 15 seconds apiece generating some caveman mode benchmarks (it seems like people call benchmarks evals now, so I should call these evals?) (previously discussed in more detail here).
To start with, I'd been using a lot of GPT-5.5 xhigh when this discussion came up a couple months ago and I benchmarked this thing, so let's look at how this looks for GPT-5.5 xhigh on the first benchmark, a simple benchmark where we ask the agent to optimize some code in wasm. Since this is something I spent 15 seconds prompting an agent to generate, I don't think it's worth spending a ton of time discussing the details, but one thing to note is that it's possible to do much better than any of the results an agent achieved here. I would expect a human doing this by hand or a human who's being prescriptive about what the agent should to do to get much better results than any of the AIs). For the optimization chart, 1.0 is no speedup and higher is better (below 1.0 means the "optimization" slowed things down). To give you an idea of what this looked like when running the experiments, you can click the buttons to follow along interactively or just play an animation.
We can see that, for the first benchmark (optimize a non-trivial algorithm in wasm), after one run, caveman is looking good. We get 1.027 speedup vs. 0.987, $12.10 vs. $23.10, and a wall clock time (of how long the agent took) of 8m51s vs. 14m9s. But we know that LLMs are stochastic, so we should probably run again. After a second run, we can see a big change in the results, with an average of 1.0 speedup for both, but caveman mode coming in at $12.45 in 8m64s vs. $40.38 in 17m57s. That's a huge cost savings that's in line with the claimed savings from caveman mode. It's a bit silly to narrate each step of the animation, but if we skip to the end, we can see that the average after 50 runs is in favor of caveman, with 1.03 vs. 1.01 speedup, and $17.97 in 13m46s vs. $24.21 in 16m52s. That's not as good as what we saw after two points, but that's still solidly in favor of caveman mode.
那时,我决定花大约 15 秒各生成一些洞穴人模式基准测试(现在人们似乎把 benchmark 称为 eval,所以我应该称它们为评估?)(之前在此处有更详细的讨论)。 首先,几个月前这次讨论出现时,我大量使用 GPT-5.5 xhigh,然后我对它进行了基准测试。让我们看看 GPT-5.5 xhigh 在第一个基准测试上的表现,这是一个简单的基准,要求代理优化一些 wasm 代码。由于这是我花 15 秒提示代理生成的,我认为不值得花大量时间讨论细节,但需要注意的一点是,代理取得的结果远非最佳。我期望手动完成或对代理有明确规定的人类能获得比任何 AI 好得多的结果。对于优化图表,1.0 表示没有加速,更高更好(低于 1.0 表示“优化”反而拖慢了速度)。为了让你了解实验运行时的样子,你可以点击按钮交互式地跟随,或者播放动画。 我们可以看到,对于第一个基准测试(优化 wasm 中的一个非平凡算法),一次运行后,洞穴人模式看起来不错。我们得到 1.027 的加速比 vs. 0.987,成本 $12.10 vs. $23.10,代理耗时(墙钟时间)8 分 51 秒 vs. 14 分 9 秒。但我们知道 LLM 是随机的,所以应该再运行一次。第二次运行后,结果发生了巨大变化,两者的平均加速比均为 1.0,但洞穴人模式的成本为 $12.45,耗时 8 分 64 秒,而标准模式为 $40.38,耗时 17 分 57 秒。这巨大的成本节省与洞穴人模式声称的节省相符。逐步叙述动画的每一步有点傻,但如果我们跳到结尾,可以看到 50 次运行后的平均值有利于洞穴人模式:加速比 1.03 vs. 1.01,成本 $17.97,耗时 13 分 46 秒,而标准模式为 $24.21,耗时 16 分 52 秒。这不如两次运行后那么好的结果,但仍然坚定地支持洞穴人模式。
I asked GPT-5.5 xhigh to do classical and Bayesian statistics on this and it produced a script that says that, for the Optimization 1 benchmark, the p-values for caveman having better speedup, cost, and wall clock time, are 0.1, 0.005, and 0.001, respectively. With Bayesian stats, we have P(caveman better) 0.958, 0.999, and 1.000, respectively. We can look at the plots for the other two benchmarks I spent 15 seconds on as well. Optimization 2 is another "optimize this code in wasm" benchmark, and Game AI is a task where the agent is asked to implement a board game AI for the game Lost Cities with a deadline of 10ms per move.
The results with these benchmarks look mixed. For Optimization 2, we have P(caveman better) = 0.17, 0.999, and 1.000, respectively, and for Game AI, we have P(caveman better) = 0.04, 0.79, and 0.73, respectively, so caveman actually gives worse results for Optimization 2 and Game AI, which is the opposite of what we saw for Optimization 1. BTW, I didn't cherry pick the order of these results to present some kind of surprising narrative reversal. If we were to stop here, we might think that caveman gives worse outcomes but saves money, or maybe it gives better outcomes on some tasks and worse outcomes on some tasks and saves money.
If we try a few more models (GPT-5.4 mini, GPT-5.4, GPT-5.5) at every effort level, we get the following averages, which makes the overall picture less clear (in the graphs below, up and to the left is better, down and to the right is worse; the arrows point from the baseline to caveman):
What are the patterns here? To name a few, for Optimization 1, caveman generally has better results than standard, but for Optimization 2 and Optimization 3, it's mostly the other way around, although there are exceptions. For cost, we can see a variety of patterns as well. There's enough variance between conditions (tasks as well as models and effort levels) that it's clear that we'd have to run a lot more conditions to get a clear picture of what's going on and, overall, the difference averages out to be small enough that it doesn't seem worth using caveman mode.
我让 GPT-5.5 xhigh 对此进行经典和贝叶斯统计分析,它生成的一个脚本显示,对于优化 1 基准测试,洞穴人模式在加速比、成本和墙钟时间上更好的 p 值分别为 0.1、0.005 和 0.001。在贝叶斯统计中,P(洞穴人更好) 分别为 0.958、0.999 和 1.000。我们也可以看看我花了 15 秒的其他两个基准测试的图表。优化 2 是另一个“优化 wasm 代码”的基准测试,游戏 AI 则是一个要求代理为游戏 Lost Cities 实现棋盘游戏 AI 的任务,每步时限 10 毫秒。 这些基准测试的结果看起来好坏参半。对于优化 2,P(洞穴人更好) 分别为 0.17、0.999 和 1.000;对于游戏 AI,P(洞穴人更好) 分别为 0.04、0.79 和 0.73。因此,洞穴人模式在优化 2 和游戏 AI 上实际上给出了更差的结果,这与我们在优化 1 上看到的相反。顺便说一句,我没有为了呈现某种令人惊讶的叙事反转而特意挑选这些结果的顺序。如果我们停在这里,可能会认为洞穴人模式结果更差但省钱,或者也许在某些任务上结果更好,在某些任务上结果更差,并且省钱。 如果我们尝试更多模型(GPT-5.4 mini、GPT-5.4、GPT-5.5),并在每个努力级别上测试,得到以下平均值,这使得整体情况更加模糊(在下图中,左上更好,右下更差;箭头从基线指向洞穴人模式): 这里的模式是什么?举几个例子,对于优化 1,洞穴人模式通常比标准模式结果更好,但对于优化 2 和优化 3,情况大多相反,尽管也有例外。在成本方面,我们也能看到各种模式。条件之间(任务、模型和努力级别)存在足够的方差,显然我们需要运行更多的条件才能看清到底发生了什么。总体而言,差异平均后很小,以至于不值得使用洞穴人模式。
LLM Variance
Recently, when new models have been released, I've done a search to see what people are saying about them. In general, there are a lot of contradictory comments out there. For example, when GPT-5.5 was released people said, variously, GPT-5.4 is better than 5.5 because it's better at staying on task while 5.5 wanders off and overthinks the problem, making 5.5 much more expensive and pointless; 5.5 is so much better than 5.4 that it's cheaper to use because it doesn't mess up and then get stuck fixing its own issues as much; 5.5 is cheaper than 5.4 because it works so well you can run at a lower effort level; 5.5 "just works" while 5.4 often fails and needs handholding, etc. Often, someone will run a benchmark and show that their statement is true.
Looking at these benchmarks, we can see support for all of these statements that I saw on reddit when searching for comments on GPT-5.5 shortly after release. In Optimization 1, GPT-5.4 has better results than 5.5 and is much cheaper. But in Game AI, GPT-5.5 is substantially better than 5.4, so much so that 5.5 high costs about as much as 5.4 xhigh, but with better results, and 5.5 medium is cheaper than high with significantly better results. With just these three evals, you can find support for every statement I saw people making about GPT-5.5 on release because all of the statements are sometimes true. And that's when we're averaging out variance with quite a few more runs than any reasonable person is going to make to support some comment they're throwing out on the internet.
最近,当新模型发布时,我会搜索人们如何评价它们。通常,会有大量相互矛盾的评论。例如,GPT-5.5 发布后,人们众说纷纭:GPT-5.4 比 5.5 更好,因为它更能专注于任务,而 5.5 会走神并过度思考问题,使 5.5 更昂贵且无意义;5.5 比 5.4 好得多,以至于使用起来更便宜,因为它不会搞砸然后陷入修复自身问题的循环;5.5 比 5.4 更便宜,因为它工作得如此之好,你可以在更低的努力级别下运行;5.5“直接可用”,而 5.4 经常失败需要手把手指引等等。通常,有人会运行一个基准测试并证明他们的说法是正确的。 查看这些基准测试,我们可以找到支持我在 reddit 上看到的关于 GPT-5.5 发布的每一条声明,因为所有声明在某些时候都是真的。而且我们是在用远高于任何理性人为在网上发表评论而进行的运行次数来平均方差。
In general, this kind of thing is why, when I see a metric or graph that summarizes a set of benchmarks, I think, "show me the distribution". Benchmarks of models often reduce to a single, nice, neat number, where you see that X is better than Y, which is better than Z. I find these to be basically meaningless, in that, if we're looking at the latest and greatest from OpenAI and Anthropic, we know there are reasonable benchmarks where X is better than Y and vice versa. If the set of benchmarks had a few more benchmarks that favored Y instead of X, the results would be flipped. For some kind of summary metric like that to be useful to me, it would have to be the case that the set of benchmarks perfectly mirrors the distribution and weight of tasks I do and that I can only choose a single model to use for all tasks. Since neither of those is true, it’s not clear what actionable information I can take away from these benchmarks.
总的来说,这解释了为什么当我看到一个总结一组基准测试的指标或图表时,我会想“给我看看分布”。模型基准测试通常简化为一个漂亮整洁的数字,告诉你 X 比 Y 好,Y 比 Z 好。我发现这基本上毫无意义,因为如果我们看 OpenAI 和 Anthropic 的最新最好模型,我们知道存在合理的基准测试让 X 比 Y 好,反过来也一样。如果基准测试集中增加几个偏向 Y 的测试,结果就会翻转。要让这种总结指标对我有用,基准测试集必须完美反映我执行的任务的分布和权重,并且我只能为所有任务选择一个模型。由于两者均不成立,我不清楚能从这些基准测试中提取到什么可操作的信息。
If we look at public benchmarks in more detail, the situation seems worse than it appears from the abstract argument above. Results are generally presented in fairly high precision, as if that's meaningful. For example, on one benchmark, we might see that (for example) GPT-5.5-xhigh is 1% better than Fable 5 medium, but at 19% lower cost. And then if we compare to Opus 4.8 maybe it's 13% worse than GPT-5.5 xhigh at 11% higher cost. If we want to know what this means, we can dig into the data and see that we have some benchmark that claims to be meaningful because it has this big set of diverse tasks, but they're all pass/fail tasks that get run 4 times and most tasks are either very easy and get 4/4 with the best models (except, due to some random noise, you sometimes see a random 3/4) or are very hard and mostly get 0/4. Then there's some small subset of tasks that actually determine the relative scores of these SOTA models. If you change out one of these for a different one, the results between the two highest scoring models can get flipped. If you change a few tasks (out of about 100), then you can see the apparently much worse Opus 4.8 move ahead of GPT-5.5. Change a few more tasks and GLM-5.2 can pull ahead.
When I see things like this, it reminds me of Miguel Indurain, who was enough of a household name when I was a kid that I'd heard of him even though I don't follow cycling. A few years ago, I was curious why household names in cycling since Indurain are all different archetypes from Indurain and it turns out the answer is that it's arbitrary. For arbitrary reasons, the Tour de France has become the most famous cycling race in the world and someone who has a dominant streak can become famous enough that they become known outside of cycling circles. For other arbitrary reasons, there was a period of time where the TdF had much longer time trial stages than it does now, which suits someone of Indurain's archetype. You tweak the benchmark a bit and Miguel Indurain goes from being a once household name to an all-time great time trialist that pretty much nobody has heard of unless they follow cycling.
如果我们更仔细地查看公开基准测试,情况似乎比上面抽象论证所显示的更糟。结果通常以相当高的精度呈现,仿佛有意义。例如,在一个基准测试上,我们可能看到 GPT-5.5-xhigh 比 Fable 5 medium 好 1%,但成本低 19%。然后与 Opus 4.8 相比,也许它比 GPT-5.5 xhigh 差 13%,但成本高 11%。如果我们想了解这意味着什么,可以深入数据,看到某个基准测试声称有意义,因为它有大量多样化的任务,但这些都是通过/失败任务,每个运行 4 次,大多数任务要么非常容易,最好模型得到 4/4(除了由于随机噪声,有时你会看到随机的 3/4),要么非常难,大多数得到 0/4。然后有一小部分任务实际决定了这些 SOTA 模型的相对分数。如果你将其中一个任务换成另一个,最高分的两个模型的结果就会翻转。如果你改变几个任务(在大约 100 个任务中),你会看到明显更差的 Opus 4.8 超过 GPT-5.5。再改变几个任务,GLM-5.2 就可以领先。 看到这些,让我想起了 Miguel Indurain,我小时候他很有名,连不关注自行车运动的我都听说过他。几年前,我好奇为什么自 Indurain 之后自行车界的家喻户晓的名字都是与 Indurain 不同类型的选手。结果发现答案是随机的。由于任意的原因,环法自行车赛成为世界上最著名的自行车赛,一个拥有统治力的选手可以变得足够出名,以至于为圈外所知。由于其他任意原因,有一段时间环法的时间赛段比现在长得多,这适合 Indurain 这种类型的选手。你稍微调整一下基准测试,Miguel Indurain 就从曾经的家喻户晓变成了一个几乎只有自行车迷才知道的史上最佳计时赛选手。
Back on the topic of coding agents, it's not clear who really needs to pay attention to these benchmarks that present summary metrics of how models are doing. As we noted above, as a user of models, these benchmarks don't meaningfully tell me which model I should use.
If many other users based their decisions on these benchmarks, then AI labs would need to care about their results on these benchmarks. But even though GPT-5.5 has been handily beating the various Opus 4.x models during 5.5's tenure on most of these benchmarks, Anthropic's business grew much faster than OpenAI's during the time period that the best publicly available models were GPT-5.5 and Opus 4.6/4.7/4.8, so much so that OpenAI has been giving companies free tokens to try to convince people to use GPT. My company was one of many to get months of free tokens and, during that time period, most people still primarily used Claude and Opus. Anthropic's revenue trajectory is incompatible with these benchmarks being major determinants of user choice, so I don't know why anyone should really care what these summary metrics show.
The last set of graphs we looked at shows how much variance we see across tasks, but from the prior set of graphs, we also saw a lot of variance within tasks with the same model and effort level. If we look at a small number of individual runs, then pretty much any conclusion is possible due to the variance between runs. Just for example if we look at Optimization 1, for GPT-5.5 xhigh, one standard deviation between runs is 0.075 (i.e., 7.5% performance increase / decrease). If we look at the average difference between the best and worst tested GPT, that's 1.055 (GPT-5.4 xhigh caveman) and 0.986 (GPT 5.4 mini low), which is less than 1 standard deviation (SD) across GPT-5.5 xhigh. For the actual graphs and not just summary statistics, we have:
回到编码代理的话题,不清楚究竟谁需要关注这些展示模型性能总结指标的基准测试。如上所述,作为模型用户,这些基准测试并不能有意义地告诉我该使用哪个模型。 如果许多其他用户根据这些基准测试做决策,那么 AI 实验室就需要关注它们在这些基准上的结果。但尽管 GPT-5.5 在其任期内轻松击败了各种 Opus 4.x 模型,在大多数公开基准上领先,但 Anthropic 的业务增长速度却快于 OpenAI,当时最好的公开模型是 GPT-5.5 和 Opus 4.6/4.7/4.8,以至于 OpenAI 一直在向公司提供免费令牌以说服人们使用 GPT。我的公司就是获得数月免费令牌的众多公司之一,但大多数员工仍然主要使用 Claude 和 Opus。Anthropic 的收入轨迹与这些基准测试作为用户选择主要决定因素的说法不符,所以我不知道为什么有人应该关心这些总结指标显示什么。 我们看到的最后一组图表显示了跨任务的大量方差,但从之前的一组图表中,我们也看到了在相同模型和努力级别下任务内部的大量方差。如果只看少量单次运行,那么由于运行之间的方差,几乎任何结论都可能成立。例如,以优化 1 为例,对于 GPT-5.5 xhigh,一个标准偏差为 0.075(即性能增减 7.5%)。若比较测试中最佳和最差 GPT 的平均差异,则为 1.055(GPT-5.4 xhigh 洞穴人模式)和 0.986(GPT 5.4 mini 低),这小于 GPT-5.5 xhigh 的一个标准偏差。以下是实际图表,而不仅仅是总结统计:
For every task, whatever the best condition is, it's easy to get a result where the best condition actually scores worse than a result from the worst condition. When I was chatting to Max Bittker, who's done a lot more benchmarking than I have because he runs an RL environment startup said:
Yeah - the level of noise from task to task and run to run is so high that it's no wonder the discourse ends up confused. Easy to make mistakes like "Wow, $new_model is amazing" -> "Oops, I was still using the old model the whole time", or "this new harness / prompting trick works great!"
But on the other hand, benchmarking has given me confidence in statements like "Opus models recover and debug confusing conditions much better than Sonnet models" and "Chinese models score well on SWE-Bench but underperform on novel tasks" with more statistical significance.
Another comment, this time loosely paraphrased because this is from memory, was that Matt Mullenweg said that, if you look at people who undertake high variance activities, like gamblers, they're often superstitious. You'll see somebody wear their lucky socks or have a specific routine they do before they sit down to play the slots. Using caveman mode or deciding which model is good because a coding agent coughed up a good result after trying it is not so different.
对于每个任务,无论最佳条件是什么,很容易得到最佳条件实际得分比最差条件结果还差的情况。当我和 Max Bittker 聊天时,他做了比我多得多的基准测试(因为他经营一家 RL 环境初创公司),他说: “是的——从任务到任务、从运行到运行的噪声水平如此之高,难怪讨论最终变得混乱。很容易犯错误,比如‘哇,新模型太棒了’ -> ‘哎呀,我原来一直在用旧模型’,或者‘这个新的提示调试技巧效果很好!’” 但另一方面,基准测试让我对一些说法更有信心,比如“Opus 模型在恢复和调试混乱条件方面比 Sonnet 模型好得多”,以及“中国模型在 SWE-Bench 上得分很高,但在新颖任务上表现不佳”,这些具有更多的统计显著性。 另一个评论,因为是从记忆中粗略引用的,Matt Mullenweg 说过,如果你观察从事高方差活动的人,比如赌徒,他们常常迷信。你会看到有人穿幸运袜子或在下注前有特定仪式。使用洞穴人模式或因为编码代理在尝试后碰巧产生了一个好结果就决定哪个模型好,与此并无太大区别。
I did the above and wrote the draft of this post before Fable was released, and then Fable was released, so just out of curiosity, I ran a few Fable benchmarks, at which point it was unreleased, so I also did a few runs with Opus 4.8.
Like I mentioned above, these are little benchmarks I created by typing to an agent for about 15 seconds a piece. With how coding agents let you scale processes, you could create a very large number of reasonable benchmarks in 15 seconds of a human time a piece, but this isn't some carefully designed setup for stamping out a bunch of these; it's just something I did because I wanted to get some kind of caveman mode comparison, and when I tried to have agents do this with no supervision, the benchmarks were completely worthless. With a little bit of time spent, the benchmarks seemed good enough for the purposes of evaluating caveman mode and determining that it's not worth further investigation. If I was planning on writing this up publicly, I would've spent a few more minutes making these benchmarks better in multiple ways, but I think they're good enough for the purposes of this variance discussion. I wouldn't read too much into the reuslts, but I did do a few basic checks such as looking at outlier results to make sure agents weren't cheating or there wasn't some issue (such as noise on the box) causing unusually poor runtime results, and the agents weren't cheating and the slowest results did reproduce on a quiet box, etc. And, that disclaimer aside, just like with the GPT benchmarks, we can see variance in these benchmarks that reflects the discussion that's happening online, e.g., Fable is great at some tasks and not so great at other tasks, and quite a few people are making claims about Fable's overall performance based on the performance on some small set of things they tried.
我在 Fable 发布前完成了上述工作并撰写了本文草稿,随后 Fable 发布了。出于好奇,我运行了一些 Fable 基准测试,当时它还未发布,所以我也用 Opus 4.8 做了几次运行。 如上所述,这些是我每次花大约 15 秒通过代理创建的小型基准测试。由于编码代理让你可以规模化流程,你可以用人类 15 秒的时间创建大量合理的基准测试,但这并非精心设计的批量生成设置;我只是想要一些洞穴人模式的对比,而且当我尝试让代理无监督地完成这些时,基准测试完全无用。花了一点时间后,这些基准测试对于评估洞穴人模式并确定其不值得进一步研究似乎足够好。如果我计划公开发布这些,我会花更多时间从多个方面改进这些基准测试,但我认为它们对于本次方差讨论的目的已经足够。我不会对这些结果过度解读,但我确实做了一些基本检查,比如查看异常结果以确保代理没有作弊或没有由于机器噪声等问题导致异常缓慢的运行时间,结果代理没有作弊,最慢的结果在静默机器上也能复现。总之,除了这个免责声明之外,与 GPT 基准测试一样,我们可以看到这些基准测试中的方差反映了网上正在进行的讨论,例如,Fable 在某些任务上表现出色,在其他任务上则不然,许多人基于他们在几个小任务上的表现就对 Fable 的整体性能做出断言。
Above, we discussed why it's not clear how I or any particular user of agents can usefully use these benchmarks that produce a ranking or a small tuple of numbers that allegedly tell you how good a model is. But even when drilling down into a benchmark, it's still not clear to me why, as a user, how I should change my behavior as a result of the benchmarks.
Just for example, something I've observed is that Opus 4.8 makes up bad rationalizations to explain things much more often than GPT-5.5. I've tried having them approach the same problem a number of times (I'll often ask both to solve a real problem I'm running into just to see what happens). These are often much larger problems than these benchmark problems, things like real debugging tasks or, in the case of building a game AI, instead of a simple prompt to produce an AI, an agentic loop and/or a series of instructions to get the agent to produce a fairly strong AI. I've asked a small handful of people and they've all observed the same thing with GPT-5.x vs. Opus 4.6/4.7/4.8, including people who prefer Claude and primarily use Claude and are more experienced with Opus than with GPT.
On the flip side, I've seen two benchmarks that measure how good models are at detecting false information and/or not making things up and those benchmarks both show that Opus is much better than GPT at this, to the point where, if the benchmarks show what one might expect them to show, the experiences I and other people have had seem impossible. For example, in one benchmark, a naive reading of the benchmark presentation is that Claude Opus and Sonnet are much better at detecting false information than any other model and Opus 4.8 is the absolute best and detects false information 95% of the time, including 95% of the time in software. The GPTs are terrible at this and rank below Qwen, Grok, Kimi, Minimax, Mimi, and Nemotron.
What's going on here? I'm not sure.
Maybe those benchmarks are measuring a different aspect of making things up than what the people I've talked to (and I) run into while working on real programming problems, or maybe this is a small sample size and the people I've talked to (and I) have just randomly gotten bad rolls of the dice from Opus, or maybe we're "holding it wrong" when it comes to using Opus. I suspect what's happening is that the benchmarks are measuring something different from what happens when you encounter incorrect rationalizations while coding or debugging, but to have any confidence in this I'd have to run some experiments that will be fairly expensive. If you want to support my doing experiments in general, you can subscribe to my Patreon or, if you're at an AI lab, give me some free credits to run experiments with.
上面我们讨论了为什么不清楚我或任何特定的代理用户如何有用利用这些产生排名或数字元组的基准测试。但即使深入某个基准测试,我仍然不清楚作为一个用户,我应该如何根据这些基准测试改变我的行为。 例如,我观察到的一点是,Opus 4.8 编造不合理理由来解释问题的情况比 GPT-5.5 频繁得多。我多次让它们解决同一个问题(我经常让两者解决我遇到的实际问题,看看会发生什么)。这些问题通常比基准测试问题大得多,比如真正的调试任务,或者对于构建游戏 AI 来说,不是简单的提示生成 AI,而是代理循环和/或一系列指令,让代理生成一个相当强的 AI。我问过一小部分人,他们都观察到 GPT-5.x 与 Opus 4.6/4.7/4.8 的相同情况,包括那些更偏好 Claude 并主要使用 Claude、且对 Opus 比 GPT 更有经验的人。 另一方面,我看到两个基准测试衡量模型在检测虚假信息和/或避免编造方面的能力,这两个基准都显示 Opus 在这方面远优于 GPT,以至于如果基准测试显示的是人们预期的结果,那么我和其他人经历的情况似乎不可能存在。例如,在一项基准测试中,粗略解读测试介绍会认为 Claude Opus 和 Sonnet 在检测虚假信息方面远胜其他模型,Opus 4.8 是绝对最好的,95% 的时间能检测到虚假信息,包括在软件方面 95% 的时间。GPT 在这方面表现糟糕,排名低于 Qwen、Grok、Kimi、Minimax、Mimi 和 Nemotron。 这是怎么回事?我不确定。 也许这些基准测试衡量的是编造的不同方面,而非我和我交谈过的人在实际编程问题中遇到的情况;或者样本量太小,我和我交谈过的人只是偶然从 Opus 得到了糟糕的结果;或者我们“使用方式不对”。我怀疑基准测试衡量的东西与实际编码或调试中遇到错误合理化的情况不同,但要对此有把握,我需要运行一些相当昂贵的实验。如果你想支持我进行实验,可以订阅我的 Patreon,或者如果你在 AI 实验室,可以给我一些免费信用额度来进行实验。
BTW, there's something analogous in the Game AI benchmark here, where Opus is substantially better than GPT, but when I tried to have to manage the process of creating an actually strong (superhuman) game AI, GPT seemed to do better because Opus kept falling into making things up / rationalizing nonsense failure mode. With no supervision, both were worthless and had their own failure modes, but when directed, GPT took less prodding to stay on track and keep doing things that could work. This is not reflected at all in the small Game AI benchmark where an xhigh run is a single prompt that "only" costs on the order of $10 and the small benchmark turns up the oppposite result as we see in doing the real version of the task.
But, the point here is that, even when you find benchmarks that measure something that seems to be the exact thing you care about, those benchmarks often don't end up matching what you see in practice. If you're a weirdo like me maybe you'll decide to spend a bunch of time and/or money running some experiments to figure out what's going on but, if you have some job you want to get done (maybe for your actual job), that's a fairly unreasonable thing to do.
顺便说一句,在游戏 AI 基准测试中也有类似情况:Opus 显著优于 GPT,但当我尝试管理创建真正强大(超人类)游戏 AI 的过程时,GPT 似乎做得更好,因为 Opus 不断陷入编造/合理化无意义故障模式。没有监督时,两者都毫无价值,各有各的故障模式,但有指导时,GPT 需要更少的推动就能保持正轨并持续做可能有效的事情。这在小型游戏 AI 基准测试中完全没有体现,该测试中一次 xhigh 运行只是一个“只”花费 10 美元的简单提示,小型基准测试显示的结果与我们在真正执行任务时看到的相反。 但这里的要点是,即使你找到了测量似乎正是你关心的事物的基准测试,这些基准测试通常最终也不会与你实际看到的结果相匹配。如果你像我一样是个怪人,你可能会决定花大量时间和/或金钱运行一些实验来弄清楚发生了什么,但如果你有需要完成的工作(可能是你的实际工作),那这就是相当不合理的事情。
Benchmarking and data analysis
For no particular reason, I've always liked designing experiments and measuring things. This was true long before I ever thought about careers and it's still true today. As discussed here, measurement is one of the primary themes of this blog, maybe the primary theme. Lucky for me, this lifelong hobby has been something I've been able to make a career out of. And even luckier, this skill seems to have been made relatively more valuable by coding agents3.
As we discussed above, testing is a rate-limiting factor in highly agentic workflows because when you let agents start doing a lot of things, anything that's not well tested gets stochastically degraded. The more you ship with agents, the worse this gets. If everything you do is like one of these model evals where every task is a pass/fail task and there's no way to really do better than simply not getting the task wrong, then you can make sure your tests are good enough and let agents go to town until tests pass and everything will be great. In practice, for almost all non-contrived problems, it's possible to have a solution that passes a strict correctness eval but is still better or worse in some kind of non-strict correctness sense. If you want to let agents go wild on a problem (whether this is fast and loose vibe coding or running autonomous agentic loops), now you have a benchmarking problem.
没什么特别的原因,我一直喜欢设计实验和测量事物。在我考虑职业之前很久就是这样,至今仍然如此。正如这里所讨论的,测量是这篇博客的主要主题之一,或许是首要主题。幸运的是,这个终身爱好让我能够以此谋生。更幸运的是,编码代理似乎让这项技能相对更值钱了。 如上所述,测试是高度代理化工作流程中的速率限制因素,因为当你让代理开始做很多事情时,任何未经充分测试的东西都会随机退化。你通过代理发布得越多,情况就越糟。如果你所做的每一件事都像这些模型评估一样,每个任务都是通过/失败任务,并且除了不出错之外没有其他办法做得更好,那么你可以确保测试足够好,然后让代理尽情工作直到测试通过,一切都会很好。但在实践中,对于几乎所有非人为设计的问题,都可能存在一个通过严格正确性评估的解决方案,但在某种非严格正确性意义上仍然有好坏之分。如果你想放开代理去解决问题(无论是快节奏的“氛围编码”还是运行自主代理循环),那么你就面临一个基准测试问题。
When left to their own devices, running in self-improving loops, agents seem fairly bad at this. There are various little things I've been doing for a few months that get some improvement here (having lots of agents think about things independently and reconvene over multiple iterations with a mix of contrarian agents, etc.), but they still don't seem great at this without human intervention.
One reason for this seems to be that agents are really bad at understanding data and doing data analysis. Doing this in the context of some kind of agentic loop or large problem is harder than doing a standalone data analysis, but when people just have an agent do a standalone data analysis, the results are generally terrible without a lot of guidance. Because it's so easy to have an agent do data analysis, I've seen quite a few agent led analyses and, at least so far, every one that I've seen is completely bogus. I've also done a fair number myself (I think people really underrate the value of getting completely bogus output from an LLM; more on this shortly) and found the same thing.
When I say complete bogus, I mean things like finding different numbers that aren't really related and somehow inferring something deep about their relationship, picking two numbers or examples out of many and coming up with a theory that contradicts other numbers in the data, making plots that show something meaningless (but often look pretty), etc. For a random concrete example, the last time I looked at an analysis produced by an agent (I glanced at this as I was writing this), someone had asked an agent to analyze the resource utilization of something. This was Opus 4.8 on max (Fable was disabled, so this was the best thing money could buy from Anthropic at the time) agent determined that 514% of the resources were being consumed by some task where it was impossible that more than 100% of the resources could possibly be consumed in any way. I have a colleague who sometimes comments on these things and will ask innocuous questions like "what does X mean?". Generally, he either gets no response or what appears to be some kind of AI-written response that's as incorrect as the first thing he replied to.
当代理自行运行在自我改进循环中时,它们在这方面似乎相当糟糕。我持续尝试了一些小方法几个月,取得了一些改进(让大量代理独立思考并通过多轮迭代重新聚集,混合逆向代理等),但它们在没有人干预的情况下似乎仍然不够好。 一个原因似乎是代理在理解数据和进行数据分析方面真的很糟糕。在某种代理循环或大问题的背景下做数据分析比单独的静态数据分析更难,但即使只是让代理做一个独立的数据分析,结果通常也很糟糕,除非有大量指导。由于让代理做数据分析非常容易,我见过不少代理主导的分析,至少到目前为止,我见过的每一个都完全虚假。我自己也做了不少(我认为人们严重低估了从 LLM 获得完全虚假输出的价值;稍后会详细说明),并且发现了同样的问题。 我说的完全虚假是指:找到并不真正相关的不同数字,然后以某种方式推断出它们关系的深刻含义;从众多数据中挑选两个数字或例子,提出一个与数据中其他数字相矛盾的理论;制作显示无意义内容的图表(但通常看起来漂亮)等等。举个随机的具体例子,最近一次我查看代理生成的分析(我写这篇文章时瞥了一眼),有人让代理分析某个资源的利用率。这是 Opus 4.8 在最高设置下(Fable 被禁用,所以这是当时从 Anthropic 能买到的最好的),代理确定某个任务消耗了 514% 的资源,而该任务无论如何都不可能消耗超过 100% 的资源。我有一位同事有时会评论这些事情,他会问一些无关紧要的问题,比如“X 是什么意思?”通常,他要么得不到回应,要么收到看起来像是 AI 写的回复,和最初他回复的错误的第一个东西一样错误。
Anyway, when I started using agents for data analysis, maybe in November 2025, I found the speedup to be pretty incredible. There are analyses that, roughly speaking, would've taken weeks that instead take hours.
I hesitate to even describe this next thing I've been doing because of how many completely bogus data analyses I'm already seeing, but something I've been doing a lot of, which I find to be a much larger speedup than doing a "normal vibe coded data analysis" is to run a simple agentic loop where the agent (or agents) "understand" and analyze the problem and then fix up the parts that need to be fixed for me to extract a good analysis from what the agent has produced.
How much this bogus LLM loop speeds things up depends on the problem, but the last time I tried it, I think a traditional pre-LLM analysis of the issue would've taken me some number of days. Let's say two days. With a workflow where I'm multitasking and poking the LLM when it needs poking, my guess is that it would've taken one to three hours of my time over the course of a day or two. With this "have the LLM loop on producing a result I know will be wrong" workflow, it took about five minutes of my time over the course of a few days to get an acceptable result. Literally every time I looked at any part of the analysis I hadn't previously corrected, the analysis was wrong (and, in some cases, I had to issue multiple corrections) but, somehow, the whole thing still moved a lot faster than if I tried to steer the LLM.
I think people are really underestimating the value of getting completely incorrect results out of an LLM. This is, non-ironically, a game changer in a positive way, when directed correctly.
There's something a bit odd about how incredibly bad SOTA models are at data analysis and how much they speed up human data analysis. I have this series of exercises in benchmarking, evals, and experimental design (part 1, part 2, part 3, part 4, part 5, part 6). When GPT-o3 was released, Tyler Cowen said that o3
wipes the floor with the humans, pretty much across the board ... I don't mind if you don't want to call it AGI. And no it doesn't get everything right, and there are some ways to trick it, typically with quite simple (for humans) questions. But let's not fool ourselves about what is going on here. On a vast array of topics and methods, it wipes the floor with the humans. It is time to just fess up and admit that.
This prompted me to try asking the questions from these exercises to SOTA models. They generally underperform what I'd expect from a reasonable junior colleague unless you specifically word the question so that models can answer the questions. If you just ask the question the way you'd ask the question to a reasonable human colleague in real life, they generally don't do well. This isn't just a theoretical problem that comes up when someone asks an evals homework question. This issue comes up any time you ask an agent to do some kind of empirical, open ended, longer horizon improvement task.
无论如何,当我大约在 2025 年 11 月开始使用代理进行数据分析时,我发现加速效果令人难以置信。有些分析粗略地说原本需要几周,现在只需要几小时。 我甚至犹豫是否要描述我一直在做的下一件事,因为我已经看到太多完全虚假的数据分析,但我经常做的一件事情是,运行一个简单的代理循环,让代理“理解”并分析问题,然后修正需要修正的部分,以便我从代理的输出中提取好的分析。我发现这比进行“正常的氛围编码数据分析”要快得多。 这个虚假 LLM 循环能加速多少取决于问题,但上次我尝试时,我认为传统的非 LLM 分析需要几天时间。假设两天。在一个我多任务处理并在需要时点拨 LLM 的工作流程中,我估计会在一天或两天内花费我一到三小时。而使用这种“让 LLM 循环生成我知道会错的结果”的工作流程,我只花了大约五分钟时间,在几天内得到了一个可接受的结果。每一次我查看任何我先前未修正的分析部分时,分析都是错误的(在某些情况下,我不得不进行多次修正),但不知何故,整个事情仍然比我试图引导 LLM 快得多。 我认为人们真的低估了从 LLM 获得完全错误结果的价值。非讽刺地说,当正确引导时,这确实是一个积极的游戏改变者。 有一点奇怪的是,最先进的模型在数据分析上如此糟糕,却又如此大地加速人类的数据分析。我有一系列关于基准测试、评估和实验设计的练习(第 1 部分、第 2 部分、第 3 部分、第 4 部分、第 5 部分、第 6 部分)。当 GPT-o3 发布时,Tyler Cowen 说 o3 “在几乎所有方面都秒杀人类……如果你不想称其为 AGI 也没关系。而且它并非所有都正确,有些简单的问题(对人类来说)可以欺骗它。但不要自欺欺人了。在大量主题和方法上,它秒杀人类。是时候承认了。” 这促使我尝试向最先进的模型提出这些练习中的问题。它们通常表现不如我期望的合理的初级同事,除非你特别措辞让模型能够回答问题。如果你像在现实生活中向合理的同事提问那样直接问,它们通常表现不好。这不仅仅是在有人提出评估作业问题时的理论问题。每当你要求代理进行某种经验性的、开放式的、长期改进任务时,这个问题都会出现。
I've seen this issue come up on a wide variety of real world problems, but it even comes up on contrived problems that don't have almost any of the messiness of real world problems. An example of this that I think is a nice problem is building board game AIs. This is a much easier problem to evaluate than most real-world problems because, at the end of the day, you want to beat humans and other AIs on a well-defined game that has a simple win/loss/draw result.
Agents can't really figure out how to do this when left to their own devices. To be fair to AIs, this problem is somewhat harder than internet commenters give it credit for. For example, if you just search for information on how to implement these things, you see all kinds of exchanges like this or this where someone who hasn't done it will explain why it's easy and someone who has will tell them it's harder than they think. Most of the online tutorials aren't very useful, to the point that the author of the well-regarded bulle library suggests that beginners avoid looking at "[a]lmost any article/blogpost/book on [a board game AI technique] that isn't backed by the author's strong [board game AI]". While the problem isn't exactly hard, it seems to have enough pitfalls to trip up most people (and all publicly avialable LLMs).
When I first started trying to implement a board game AI (this was in the GPT-5.1 to 5.2 days), I didn't know anything about board game AIs and tried having coding agents implement what they thought would work. Now that I know a bit about board game AIs, I can say that every direction GPT tried to suggest was bad and couldn't work. As an experiment, I tried this again recently, when GPT-5.5 and Opus 4.8 were the best publicly available models and they failed in the exact same way and suggested many of the exact same bad ideas (just to really make sure, I let them implement the bad ideas and they failed as expected).
I think, at some level, this is a fairly well understood gap in LLMs today. Coincidentally, around the time I was trying GPT-5.1 or 5.2 at this, the Code Clash eval was created, which also tests the same thing and found the same result
Unable to Iterate: Models struggle to improve over rounds, exhibiting a variety of failure modes.
Despite agents being terrible at setting direction and me not knowing anything about board game AIs, I was somehow able to cobble together a superhuman AI for Azul in about 5 hours of my time and get it to a crushingly strong level that's well above any other AI that was out there at the time (and I think still out there now) in about 20 hours of my time. The Azul world champion and probably strongest player in the world overall said:
the bot is quite insane now. def seems stronger than me, though to really test it i would have to play it like a turn-based game. with limited time on my end, i stand no chance 🙂4.
我在各种现实世界问题中看到过这个问题,但它甚至出现在几乎没有现实世界问题的杂乱的人为问题中。我认为一个很好的例子是构建棋盘游戏 AI。这个问题比大多数现实世界问题更容易评估,因为最终目标是击败人类和其他 AI,游戏具有简单的胜负平结果。 代理在自行其是时无法真正学会如何做到这一点。公平地说,这个问题比网络评论者认为的要难一些。例如,如果你搜索如何实现这些东西,你会看到各种交流,比如这个或那个,其中没做过的人会解释为什么容易,而做过的人会告诉他们比想象中更难。大多数在线教程不太有用,以至于广受好评的 bulle 库的作者建议初学者避免阅读“几乎所有没有作者强大[棋盘游戏 AI]支持的[棋盘游戏 AI 技术]文章/博客/书籍”。虽然问题不算特别难,但似乎有足够的陷阱让大多数人(以及所有公开可用的 LLM)绊倒。 当我第一次尝试实现棋盘游戏 AI(那是在 GPT-5.1 到 5.2 时代),我对棋盘游戏 AI 一无所知,并尝试让编码代理实现它们认为可行的方法。现在我对棋盘游戏 AI 有了一点了解,可以说 GPT 尝试建议的每个方向都很糟糕且不可行。作为实验,我最近又试了一次,当时 GPT-5.5 和 Opus 4.8 是最好的公开模型,它们以完全相同的方式失败,并提出了许多完全相同的糟糕想法(为了确认,我让它们实现了这些糟糕的想法,结果如预期般失败)。 我认为,在某种程度上,这是当今 LLM 中一个相当知名的空白。巧合的是,大约在我尝试 GPT-5.1 或 5.2 的时候,Code Clash 评估被创建,它也测试同样的事情并发现了同样的结果: “无法迭代:模型难以在多轮中改进,表现出多种失败模式。” 尽管代理在设定方向方面很糟糕,而且我对棋盘游戏 AI 一无所知,但我还是在大约 5 小时内拼凑出了一个超人类的 Azul AI,并在大约 20 小时内让它达到了碾压其他所有 AI 的水平(当时如此,我认为现在也是如此)。Azul 世界冠军,也可能是全球最强的玩家说: “这个 bot 现在相当疯狂。看起来确实比我强,不过要真正测试,我得像回合制游戏一样玩。在我时间有限的情况下,我毫无机会 🙂。”
As much as I'd like to be able to say there was "one weird trick", there were really two tricks, but two tricks isn't so bad, especially when they generalize to other kinds of projects as well. The two tricks were:
Look at the data / have some reasonable-ish evals
Solve problems systematically
None of this has to be very rigorous. In fact, I'd say this was all running on vibes (in the pre-vibe coding sense of the word). For the data side, for this project, I used a common habit for me, plotting a bunch of things that seemed relevant, eyeballing them, and then nudging things in a direction that I would hope improves things. A more rigorous (and possibly better) approach is to run a bunch of experiments from scratch, do "ablation" runs where you add or remove individual ideas, etc., and understand what each component does and what the impact is. But I wanted to get a strong AI while using as little of my time as possible and just training on my laptop and doing things rigorously seemed too expensive given those constraints.
I'm sure all of this would've been trivial for someone with ML experience, but there were a bunch of little things I had to observe and then find ways to deal with (which is something agents are currently terrible at). For example, in terms of figuring out a good set of evals to look at it, there are a few funny things. One is that you can easily make changes that reduce loss but don't change the win rate against actual opponents (humans or other bots) and vice versa. Another is that, if you try to track improvement in terms of how well your bot beats previous versions of itself, it's very easy to make a series of changes that allows the bot to beat all previous versions of itself and have an apparent Elo gain of 1000 or 2000 against prior versions that isn't any better against humans or bots that play in a different style. And, at the time, there was no superhuman bot that was available to play against, so you couldn't get a reasonable eval by just playing against a field of existing bots.
For a human, these aren't really hard problems. A reasonable human can look at one of these issues, think for a few minutes, and come up with a proposed solution that will probably work (and when it doesn't work, they can try another solution). But there's enough subtlety that agents don't do well at this today without supervision (to be fair to coding agents, many or most humans don't either—almost all of the bots I found to play against were fairly bad, despite people seeming to have spent a decent amount of time on a lot of them, with the one publicly available exception being the "PJF98" Azul bot in https://github.com/cestpasphoto/alpha-zero-general). There was one bot stronger than the PJF98 bot in existence, but it wasn't made generally available to play against and was just used to win one season on BGA (which was voided because using a bot is cheating) and then never seen again.
虽然我很想说有一个“奇招”,但实际上有两个技巧,但两个技巧也不错,尤其是它们也适用于其他类型的项目。这两个技巧是:
- 查看数据 / 拥有一些合理的评估
- 系统性地解决问题 这些都不需要非常严格。事实上,我认为这都是基于“氛围”(在氛围编码这个词出现之前的意义)。在数据方面,对于这个项目,我使用了一个常见的习惯:绘制一堆看似相关的东西,用肉眼观察,然后朝着我希望改进的方向微调。更严格(也许更好)的方法是运行一系列从头开始的实验,进行“消融”运行(添加或删除单个想法等),并理解每个组件的作用及其影响。但我希望在尽可能少花自己时间的同时获得一个强大的 AI,仅在我的笔记本电脑上训练,并且在这些约束下进行严格的研究似乎太昂贵了。 我确信对于有 ML 经验的人来说,所有这些都微不足道,但有一堆小事情我不得不观察并找到处理方法(这正是代理目前不擅长的)。例如,在确定一套好的评估指标方面,有一些有趣的事情。一是你可以轻松做出降低损失但不改变对实际对手(人类或其他 bot)胜率的改变,反之亦然。二是如果你试图以 bot 击败先前版本的程度来衡量改进,很容易做出一系列改变让 bot 击败之前所有版本,并获得相对于之前版本 1000 或 2000 的 Elo 增益,但对不同风格的人类或 bot 没有提升。而且当时没有超人类的 bot 可以对抗,所以你无法通过与现有 bot 对战获得合理的评估。 对于人类来说,这些并不是真正的难题。一个合理的人可以看这些问题,想几分钟,然后提出一个可能有效的解决方案(当它不工作时,可以尝试另一个方案)。但其中的微妙之处足以让代理在没有监督的情况下今天做不好(公平地说,许多或大多数人类也做不好——我找到的大多数 bot 都很差,尽管人们似乎花了不少时间在上面,唯一的公开例外是 https://github.com/cestpasphoto/alpha-zero-general 中的“PJF98”Azul bot)。还有一个比 PJF98 bot 更强的 bot 存在,但它没有公开可用,仅用于赢得 BGA 的一个赛季(因使用 bot 作弊被取消资格),然后销声匿迹。
The other trick I mentioned was taking a systematic approach. At a high level, this is because when dealing with an opaque system with some complexity, every time you see a symptom of a bug, there's a good chance this is a window into one or more other bugs that you don't know how to observe. If you non-systematically close the window without fixing the other bugs, those other bugs are still there; you just don't know how to find them anymore.
This is specifically the case when building a board game AI that uses a neural net because you have this net that's doing who-knows-what and some kind of search function that's doing who-knows-what and you can sometimes spot specific obviously bad moves. This is also generally the case with vibe coding and/or agentic loops because you have agents doing who-knows-what and you sometimes get a window into what's going wrong as the giant, overly complex, pile of code the agents produce will emit some kind of obviously bad behavior.
Specifically in the case of board games, I looked at the other Azul AIs that are out there. A lot of people had built bots, especially recently with coding agents making it so easy to build a bot. For some of those, you can actually see how the person tried to nudge the bot (for example, because they included the instructions they gave to Claude in their repo) and, AFAICT, the main reason these other bots were much worse despite more human time spent on the effort was a combination of using the wrong evals and fixing the symptom of a problem and not the cause.
For example, in one case where the author left the Claude instructions in the repo so you can see what they did, at one point, their bot was making a very bad move that's worse than a move that any human would play even if they'd just learned the game. The author instructed Claude to make a series of straightforward fixes that would stop the bot from making that move, which it did, but this didn't fix all of the other bad moves that fall out of the systemic problems the bot has; it just fixed the one very obvious symptom of a bad move that the author could see.
A vaguely analogous issue my bot had is that, at one point, my bot would almost always try to open in column 2. A simple fix that I think would've worked would be to tweak the bot to play in column 2 less often. I tried the various "obvious" fixes like increasing noise to increase exploration in self play, etc., but none of the obvious fixes worked other than directly reducing the value of column 2, but that has this other issue we discussed of not really solving the problem. In that specific case, a more systematic fix that worked and made that bot's play a lot more generally robust was to, at various points in the game, fork the game into a new game with different column permutations. The idea here is, the problem is that, on average, column 2 is the best column, so even if the bot opens in a different column, it will have this tendency to go back to the average best column due to the games it's seen in the past. If you're DeepMind, you can throw a bunch of money at this problem and have the bot play a lot more games and learn something else. But if you're running on a laptop, that could take a while and if you're trying to tweak the weight at which the bot should be nudged away from column 2, there's no way you're going to get a reasonably optimal set of weights to do this with. But if you (for example) sometimes, near the endgame, permute column 2 to column 4, the bot will learn that if you have a nearly filled column 4, it's a winning move to complete it, which will help the bot learn that earlier in the game, if you have a partially complete column 4, it makes sense to advance it to near completion, and so on and so forth, until, in the opening, the bot learns that in the opening, it should then open with a reasonable distribution.
For someone like me with no ML/AI background, getting the bot to superhuman performance was a series of puzzles like this that are a combination of figuring out what the right view of the data is to see problems and then tweaking this systematically to solve the problem. This is not so different from managing agentic loops for general problems. Michael Malis has said that running a "software factories" workflow feels like playing Factorio and I can see what he means by that.
我提到的另一个技巧是采取系统性方法。从高层次来看,这是因为当处理一个具有一定复杂性的不透明系统时,每次你看到一个 bug 的症状,这很可能是一个窗口,通向一个或多个你无法观察到的其他 bug。如果你非系统性地关闭窗口而不修复其他 bug,那些 bug 仍然存在;你只是不知道如何再找到它们了。 这在构建使用神经网络的棋盘游戏 AI 时尤为明显,因为你有一个不知道在做什么的网络,以及某种不知道在做什么的搜索函数,你有时能发现一些明显糟糕的走法。在“氛围编码”和/或代理循环中也是如此,因为代理在做什么你不知道,你有时会通过代理产生的庞大、过度复杂的代码堆表现出某种明显的错误行为来窥见问题所在。 具体到棋盘游戏,我查看了其他 Azul AI。很多人构建了 bot,尤其是最近编码代理使得构建 bot 非常容易。对于其中一些,你实际上可以看到人们如何尝试调整 bot(例如,因为他们将给 Claude 的指令包含在仓库中)。据我所知,这些其他 bot 尽管投入了更多人类时间却仍然差劲的主要原因,是使用了错误的评估和只修复问题的症状而非原因的结合。 例如,在一个案例中,作者将 Claude 指令留在了仓库中,你可以看到他们做了什么。当时他们的 bot 走出了一步非常糟糕的棋,比任何刚学会游戏的人类走出的棋都差。作者指示 Claude 做一系列直接修复来阻止 bot 走出那步棋,确实成功了,但这并没有修复 bot 系统性问题的所有其他糟糕走法;它只修复了作者能看到的一个非常明显的症状。 我的 bot 有一个大致类似的问题:有一段时间,我的 bot 几乎总是尝试在第 2 列开局。一个我认为可能有效的简单修复是调整 bot 以减少在第 2 列下的次数。我尝试了各种“明显”的修复,比如增加噪声以增加自我对弈中的探索等,但除了直接降低第 2 列的价值外,没有其他明显的修复起作用,但这又带来了前面讨论的无法真正解决问题的问题。在那个具体案例中,一个更系统性的修复奏效了,并且让 bot 的走法整体更加稳健,那就是在游戏的各个阶段,将游戏分支到具有不同列排列的新游戏。这里的想法是,问题在于平均而言第 2 列是最好的列,因此即使 bot 在其他列开局,由于过去看到的对局,它也会倾向于回到平均最佳的列。如果你是 DeepMind,你可以投入大量资金让 bot 玩更多对局并学习其他东西。但如果你在笔记本电脑上运行,这可能需要一段时间,而且如果你试图调整让 bot 远离第 2 列的权重,你不可能找到一组合理的最优权重。但如果你(例如)在残局附近有时将第 2 列置换为第 4 列,bot 将学到如果你有一个几乎填满的第 4 列,完成它是致胜一步,这将帮助 bot 学到在游戏早期,如果你有部分完成的第 4 列,推进到接近完成是有意义的,依此类推,直到在开局时 bot 学会以合理的分布开局。 对于像我这样没有 ML/AI 背景的人来说,让 bot 达到超人类表现是一系列这样的谜题,结合了找出正确的数据视角来发现问题,然后系统性地调整以解决问题。这与管理通用问题的代理循环并无太大区别。Michael Malis 说运行“软件工厂”工作流程感觉像玩 Factorio,我能理解他的意思。
Misc
I'm not sure how much value there is in talking about specific workflow tips and tricks since the half-life of these is so short. Before I was running more autonomous loops and was doing more human-in-the loop work, "my" agents would often do something that's in direct contradiction of AGENTS.md or other instructions. When I offhandedly mentioned this to Yossi Kreinin, he suggested adding a note at the bottom of my AGENTS.md to re-read instruction after compaction. For all I know, that's a superstitious act that did nothing, but it seemed to reduce the rate of this issue from a few times a day (when juggling a handful of agents at once, so maybe once every few agent-days) to once every week or two (maybe once every 100 agent-days or so). It seems like this isn't necessary anymore, so either this was a placebo that never did anything in the first place and I was just getting unlucky for a while, or the AI labs have added this as well. A trick we discussed in August 2024, back when LLMs would produce code but not run it by default, was to just have a loop that runs the code to make sure that it works and passes tests. That trick had a surprisingly long useful life considering how obvious and useful the trick was, but of course the big AI labs eventually realized how useful that was and they all have tools that do this now.
For the past few months, the "trick" I've been using is to have something that's vaguely in the same space as something like Gas Town, but with various little things to try to make it more reliable. It seems like Claude's Dynamic Workflows put half of these tricks into an easy to use package (I haven't used it since I'm told that it uses a waterfall model where things from one stage wait on the last one, but either that will be fixed at some point or someone will release something without that limitation) and Codex has some advertised but yet to be released features that seem targeted at doing the same thing. In principle, goal mode should package up most of the other half of the tricks, although it doesn't work nearly as well for now. Presumably that will improve and most of what I'm doing now will be available off-the-shelf within a couple of months? Like the tricks mentioned above, these are all things that are so obvious enough I don't know that there's much value in spending a lot of time talking about the details, but I'll put some brief comments in a later appendix in case anyone is curious.
The meta techniques discussed above have generalized fairly well for me on a variety of projects and they seem like they should be durable as long as agents can't just take a non-trivial problem description and fully solve the problem better than I can, at which point I won't have to worry about it because my economic value may be close to zero.
我不确定讨论具体的工作流技巧有多少价值,因为它们的保质期很短。在我运行更自主的循环之前,更多的是人在回路中的工作,“我的”代理经常做与 AGENTS.md 或其他指令直接矛盾的事情。当我随口向 Yossi Kreinin 提及时,他建议在 AGENTS.md 底部添加一条注释,要求紧凑后重新阅读指令。据我所知,这可能是一个什么都没做的迷信行为,但它似乎减少了这个问题的发生频率,从一天几次(同时处理几个代理时,可能每几个代理天一次)下降到一两周一次(可能每 100 个代理天一次)。现在似乎不再需要了,所以要么是安慰剂效应从一开始就没用,我只是有一段时间运气不好,要么是 AI 实验室也已经加入了这一点。我们 2024 年 8 月讨论过一个技巧,当时 LLM 会生成代码但默认不运行,就是让一个循环运行代码以确保它工作并通过测试。这个技巧虽然很明显且有用,但寿命出乎意料地长,当然大 AI 实验室最终意识到了它的价值,现在都有了这样的工具。 过去几个月,我一直在使用的“技巧”是某种与 Gas Town 类似但试图使其更可靠的东西。似乎 Claude 的动态工作流将其中一半技巧打包成了易于使用的形式(我还没用过,因为听说它使用瀑布模型,一个阶段的结果要等待前一个阶段,但要么之后会修复,要么会有人发布没有这个限制的版本),而 Codex 有一些已宣传但尚未发布的功能,似乎旨在做同样的事情。原则上,目标模式应该打包另一半技巧,尽管目前效果不佳。预计会有改进,我目前做的很多事情将在几个月内现成可用?正如上面提到的技巧,这些都是足够明显的东西,我不知道花大量时间讨论细节有多大价值,但我将在后面的附录中做简要评论,以防有人好奇。 上面讨论的元技术在各种项目上对我来说都泛化得很好,而且只要代理不能直接理解非平凡的问题描述并比我更好地完全解决它,这些技术似乎就应该持久——到那时我就不用操心了,因为我的经济价值可能接近于零。
Another meta idea that's been useful is the very obvious thought that coding agents are highly non-uniform in their effectiveness relative to humans. When discussing about traditional productivity, Fabian Giesen made this comment on how velocity improvements change how he works:
There are "phase changes" as you cross certain thresholds (details depend on the problem to some extent) where your entire way of working changes. ... There's a lot of things I could in theory do at any speed but in practice cannot, because as iteration time increases it first becomes so frustrating that I can't do it for long and eventually it takes so long that it literally drops out of my short-term memory, so I need to keep notes or otherwise organize it or I can't do it at all. Certainly if I can do an experiment in an interactive UI by dragging on a slider and see the result in a fraction of a second, at that point it's very "no filter", if you want to try something you just do it. Once you're at iteration times in the low seconds (say a compile-link cycle with a statically compiled lang) you don't just try stuff anymore, you also spend time thinking about whether it's gonna tell you anything because it takes long enough that you'd rather not waste a run. Once you get into several-minute or multi-hour iteration times there's a lot of planning to not waste runs, and context switching because you do other stuff while you wait, and note-taking/bookkeeping; also at this level mistakes are both more expensive (because a wasted run wastes more time) and more common (because your attention is so divided). As you scale that up even more you might now take significant resources for a noticeable amount of time and need to get that approved and budgeted, which takes its own meetings etc. There's something analogous about agentic coding velocity improvements. People sometimes make claims about how agentic coding is 100x or 1000x more productive. When I look at tasks I do, it's hard to really pin down a number because you can't effectively lift-and-shift a human workflow to agents, so I'm doing something very different from what I would've done in the first place. For example, we look at the idea discussed above of having agents look at every support ticket to convert support issues into PRs. If I were to claim some kind of speedup here, it would be a huge number, easily more than 1000000x. But of course I wouldn't read every support ticket myself, so such a claim is meaningless. A more reasonable way to estimate this would be to try to figure out what kind of traditional organizational structure would generate that many bug fixes using classical techniques and estimate the ratio, but the error bars on an estimate like that will be more than one order of magnitude and it's also not something that would've been done at any normal software company, so the comparison is once again meaningless. It's like someone who drives 20000 miles a year saying they saved 6000 hours and got a 15x speedup on their commute by driving because that's how long it would've taken to walk the same distance. It's clear that the driving enabled them to do things they wouldn't have been able to otherwise do, but there's no point in discussing the ratio.
Another example of a place where you can claim a massive speedup number, possibly more than 1000000x, that's a meaningless number is, when trying to get an LLM to generate a fuzzer in a semi-automated way, I've tried having an LLM look at the entire commit history and all bug fixes, as well as every plausibly related support ticket in history, to try to get the LLM-written fuzzer to be able to reproduce the bugs in some general way. This seems to have been useful to do, but it's hard to put a real number on the value.
另一个有用的元思想是,编码代理相对于人类的有效性高度不均匀。在讨论传统生产力时,Fabian Giesen 就速度提升如何改变他的工作方式发表了评论: “当你跨越某些阈值时(细节在一定程度上取决于问题),你的整个工作方式会发生‘相变’…… 有很多事情我在理论上可以在任何速度下完成,但实际上不能,因为随着迭代时间的增加,它首先变得如此令人沮丧,以至于我无法长时间做下去,最终它变得如此之长,以至于它实际上从我的短期记忆中消失,所以我需要做笔记或以其他方式组织它,否则我根本无法做到。 当然,如果我能通过拖拽滑块在交互式 UI 中做实验,并在不到一秒内看到结果,那么它是非常‘无过滤’的,如果你想尝试某事,你就直接去做。 一旦迭代时间进入低秒级别(比如说静态编译语言的编译-链接周期),你就不再只是尝试了,你还会花时间思考它是否能告诉你什么,因为它耗时足够长,你宁愿不浪费一次运行。 当你进入几分钟或几小时的迭代时间时,会有大量的计划来避免浪费运行,以及上下文切换(因为你在等待时做其他事情),还有笔记/记账;在这个级别,错误既更昂贵(因为浪费的运行浪费更多时间)也更常见(因为你的注意力如此分散)。 当你进一步扩大规模时,你现在可能会为一段明显的时间占用大量资源,并且需要得到批准和预算,这又需要自己的会议等等。” 编码代理的速度提升也有类似之处。人们有时声称编码代理的产量是原来的 100 倍或 1000 倍。当我查看我做的任务时,很难真正确定一个数字,因为你不能有效地将人类工作流“提升并转移”给代理,所以我做的事情与原本会做的事情截然不同。例如,上面提到的让代理查看每个支持工单并将其转化为 PR 的想法。如果我要声称某种加速,那将是一个巨大的数字,轻松超过 1,000,000 倍。但我当然不会自己阅读每个支持工单,所以这种说法毫无意义。更合理的估算方法是尝试找出什么样的传统组织结构会使用经典技术生成那么多 bug 修复,并估算比例,但这样估算的误差范围会超过一个数量级,而且任何正常软件公司都不会这样做,所以比较再次毫无意义。就像一个每年开车 20,000 英里的人说他们节省了 6,000 小时,并获得了 15 倍的通勤加速,因为步行同样的距离需要那么长时间。很明显,开车使他们能够做本来无法做到的事情,但讨论比例没有意义。 另一个可以声称巨大加速数字(可能超过 1,000,000 倍)但毫无意义的例子是,在尝试以半自动方式让 LLM 生成模糊测试器时,我尝试让 LLM 查看整个提交历史记录和所有 bug 修复,以及历史上每个看似相关的支持工单,以尝试让 LLM 编写的模糊测试器能够以某种通用方式重现 bug。这似乎很有用,但很难为价值定一个真实的数字。
Another thought, and it wasn't obvious to me in advance that this would be the case, is that LLMs seem to be a larger productivity multiplier for people who are relatively more expert at the thing they're trying to do. On looking around for commentary on this, I of course got pages full of LLM generated SEO spam and, after wading through it, I saw quite a few comments indicating the opposite. Basically, that anyone can do anything now. While that's more true than it used to be, it seems to be even more true that expertise in an area has become more valuable. Max Bittker had a comment that this is at least partially because LLMs are good at counterfeiting things, but that counterfeits aren't that good (yet?), and experts can tell the difference between a counterfeit and the real thing, which I thought was an interesting framing.
And following up on this 2015 post about how many people are underestimating how much AI will displace humans, in the past year, my median LLM-driven remote customer service interaction has been better than my median human remote customer service interaction (a well-paid human would provide a better experience than all but maybe one of my LLM-driven experiences, but companies don't want well-paid humans). The exact same line of reasoning that was rebutted in that post 2015 was repeated in 2022 on the release of ChatGPT. The line of reasoning is so popular that it's been a repeat thought leader viral hit every year since 2022 and I don't see that changing any time soon, but it still seems wrong to me today.
By the way, as we previously discussed, there are lots of ways to be an effective programmer, so I'm not saying what's discussed here is the best way to do things or even a very good way (I'm changing my workflow regularly as I figure out new things) but this is what I've been trying that seems to work better than a purely traditional workflow for me. Just given my background and interests, it's natural for me to take a systematic, evals-driven, approach to agentic coding. I've seen people use what is pretty much the opposite approach and make it work for them as well, where they move very quickly without almost any understanding of what's happening and, when they strike gold, they recursively put all of their effort into that. Not only is that not a great fit for my background, I don't think it would really work well for most of the problems I've worked on, which I select because they seem like a reasonable fit for how I approach problems. No doubt my workflow, ported to the problems the opposite kind of workflow is suited to, would also not work very well.
另一个想法是,LLM 似乎对那些在所做之事上相对更专业的人来说是更大的生产力倍增器,这一点我事先并不明显。在寻找相关评论后,我看到的当然是一堆 LLM 生成的 SEO 垃圾,经过筛选后,我看到不少评论持相反观点,基本上是说现在任何人都能做任何事情。虽然这比过去更真实,但似乎专业知识在某个领域变得更有价值了。Max Bittker 评论说,这至少部分是因为 LLM 擅长伪造事物,但伪造品还不够好(目前?),而专家能分辨真伪。我认为这是一个有趣的框架。 继 2015 年那篇关于多少人低估 AI 将取代人类的文章之后,在过去一年中,我经历的平均 LLM 驱动的远程客户服务互动比我经历的平均人类远程客户服务互动要好(一个高薪人类可能会提供比我所有 LLM 驱动的体验中除了一个之外更好的体验,但公司不想要高薪人类)。2015 年那篇文章反驳的完全相同的推理在 2022 年 ChatGPT 发布时被重复。这种推理如此流行,以至于自 2022 年以来每年都成为思想领袖的病毒式热门,我不认为它会很快改变,但直到今天在我看仍然是错误的。 顺便说一句,正如我们之前讨论的,成为高效程序员有很多方法,所以我并不是说这里讨论的是最佳方式,甚至不是很好(我定期改变工作流程,因为我发现了新东西),但这正是我尝试过的,似乎比纯粹的传统工作流程更适合我。仅就我的背景和兴趣而言,我对代理编码采取系统性的、评估驱动的方法是很自然的。我见过人们使用几乎相反的方法也能奏效,他们快速前进,几乎不了解正在发生的事情,当他们撞大运时,递归地把所有精力放在那上面。这不仅不适合我的背景,我也不认为它适用于我处理的大多数问题,我选择问题是因为它们似乎适合我处理问题的方式。毫无疑问,我的工作流程移植到相反工作流程适合的问题上,也不会很好。
Appendix: people talking past each other
It's always been the case that people talk past each other when they disagree, but this seems to be more of an issue when talking about agentic coding today than it has been for a lot of other topics.
Some of the major reasons I've seen for this are:
General incredulity
Workflow-based reliability differences
General workflow issues, i.e., "skill issue"
Differences in expectations
On general incredulity, moreso than at any other time in my life, I see people saying that X is impossible, nobody does X, and anyone who claims that they're doing X is a liar, when I know people (who I trust and are credible) doing X or I'm doing X. There's a lot of incredulity out there about AI. Eleven years ago, we looked at how people were saying AI can't possibly replace or displace humans even as it was already happening, but the kind of displacement there wasn't a serious fear for a typical middle-class person or programmer, so it wasn't as salient for folks I might run into "on the street" as it is today. Now that this is more "in your face" for people I'm running into, the amount of denying reality has shot up.
BTW, I find it quite reasonable that a lot of people are incredulous. For one thing, a lot of the positive claims about AI are incorrect. On average, wild, incorrect, claims get more traction than boringly precise and correct claims, so someone who isn't following this stuff is going to see a lot of incorrect claims that are easy to dismiss. It doesn't help that a lot of the people making these claims have a direct financial interest in the general success of AI companies, which makes it easy for skeptics to conclude that these people are all self-interested liars.
附录:人们如何彼此失语
当人们意见不一时,他们总是互相失语,但这在今天的代理编码讨论中似乎比其他许多话题更严重。 我看到的一些主要原因包括:
- 普遍的怀疑
- 基于工作流程的可靠性差异
- 一般工作流程问题,即“技能问题”
- 期望差异 关于普遍怀疑,在我生命中的任何其他时期,我都没有像现在这样看到人们说 X 不可能、没有人做 X、任何声称做 X 的人都是骗子,而我知道(我信任且可信的)人在做 X,或者我自己在做 X。关于 AI 的怀疑很多。十一年前,我们看到人们说 AI 不可能取代或替代人类,尽管它已经在发生,但那种替代对典型的中学阶级或程序员来说并不是严重的恐惧,所以对于我可能在“街上”遇到的人来说,它不像今天这样突出。现在对我来说,这更加“直接面对”,否认现实的程度急剧上升。 顺便说一句,我认为很多人怀疑是相当合理的。一方面,许多关于 AI 的正面宣称是不正确的。平均而言,疯狂的、不正确的说法比枯燥精确且正确的说法更能获得关注,所以不关注这方面的人会看到很多容易驳斥的错误说法。更糟的是,许多提出这些说法的人对 AI 公司的整体成功有直接的经济利益,这使怀疑者容易得出结论说这些人都是自私的骗子。
On workflow-based reliability differences, what I mean is that different workflows demand different levels of reliability and people who use a workflow that demands a higher level of reliability will often claim AI is useless because it can't do X reliability, missing that there are many effective uses that don't require that level of reliability. To take an extreme example, some people have done novel mathematical research and solved open problems using AI. Let's say, hypothetically, AI solves some open problem you're working on 1 out of every 100 times you try it and returns completely gibberish 99 out of 100 times. That seems great. Solving a serious open problem in math research 1 in 100 times is a pretty awesome result, even if doing a reasonable code review 1 in 100 times and producing a bad code review 99 out of 100 times would be a bad result.
For a less extreme example, for programming work, if you don't assume that the agent is 100% reliable and build systems to handle this, you can tolerate a much lower level of reliability than somebody who assumes the agent is reliable and needs some kind of human-in-the-loop correction to deal with cases where the agent isn't reliable. I regularly see people give advice saying, "don't use AI for X [because it won't work 100% of the time]" where I know someone who does X all the time and have some boring system for handling X not being 100% reliable. This is something you commonly have to do in programming regardless of whether or not you're dealing with agents, so why not use the same techniques you'd use to handle agents being unreliable?
Differences in scale also cause people to talk past each other as people have very different reliability demands at different scales. There's an old rule of thumb that, for traditional software systems, for every order of magnitude increase in scale, you need a different architecture. That's not really true, but it gets at this directionally correct idea that you really want different architectures at different scales. This is also true for using agents.
Just for example, one that I've seen come up repeatedly related to the earlier note that, on tasks that I do, adding a clear, strict, instruction in AGENTS.md to not do something fails once every week or two when juggling 10 agents, a failure rate of something like one per 100 rule-agent-days. Does this work? If you're doing human-in-the-loop coding with a relatively small number of agents and rule (say, 10 agents, 10 rules) with failures being non-catastrophic things that are usually caught by human review, this works fine. If you're running hundreds or thousands of agents or if you're shipping without review or other guardrails even with only a few agents and failures can cause serious problems, this doesn't work at all. While some techniques are scale invariant, many aren't.
Another kind of workflow issue is when people have a workflow that can't work for X and then conclude that nobody can do X because they weren't able to do X. I haven't thought too much about the specifics of what doesn't work, but Max Bittker had the following comments:
A few patterns I've noticed, not in order:
-
People sometimes have misconfigured environments: They're on an old model, they have a bunch of MCPs or after-market system prompts turned on, or the LLM is trying to deal with Windows or some unusual environment or IDE.
-
People sometimes trash their context window by using a single super long chat with lots of backtracking or single super-messy working directory.
-
Injecting accidental requirements via imprecise language, sending the LLM off on a harder task than they intended like building a matchmaking system before the core of the game
-
If you don't have a strong idea what you want or when you're done, you might under-specify and then collaboratively drift and change requirements over time and going nowhere in particular (many AI-psychosis vibe coders do this)
关于基于工作流程的可靠性差异,我的意思是不同的工作流程需要不同的可靠性水平。使用需要更高可靠性的工作流程的人经常声称 AI 无用,因为它不能达到 X 的可靠性,而忽略了有许多有效的用途并不需要那么高的可靠性。举一个极端的例子,有些人使用 AI 做了新颖的数学研究并解决了开放问题。假设 AI 在每尝试 100 次中解决你正在研究的一个开放问题 1 次,其余 99 次完全胡说。这看起来很棒。在数学研究中 100 次解决一次严肃的开放问题是相当了不起的结果,而如果 AI 做代码审查,100 次中有一次合理,99 次产生糟糕的审查,那将是一个糟糕的结果。 对于不那么极端的例子,对于编程工作,如果你不假设代理是 100% 可靠的并构建系统来处理这一点,你可以容忍比那些假设代理可靠并需要人在回路中纠正不可靠情况的人低得多的可靠性。我经常看到人们给出建议说“不要为 X 使用 AI [因为它不会 100% 工作]”,而我认识有人一直在做 X,并有一套枯燥的系统来处理 X 不是 100% 可靠的情况。这是你在编程中经常需要做的事情,无论你是否在处理代理,那么为什么不使用同样的技术来处理代理不可靠呢? 规模差异也会导致人们互相失语,因为不同规模的人有非常不同的可靠性需求。有一个老的经验法则,对于传统软件系统,规模每增加一个数量级,就需要不同的架构。这并不完全正确,但它指出了方向正确的想法:在不同规模下你真的需要不同的架构。使用代理也是如此。 例如,我反复看到的一个问题与之前的说明相关:在我做的任务中,在 AGENTS.md 中添加一条清晰严格的指令以禁止某事,当同时处理 10 个代理时,每两周左右会失败一次,失败率大约为每 100 规则-代理天一次。这能行吗?如果你做人在回路中的编码,代理和规则数量较少(例如 10 个代理,10 条规则),失败是非灾难性的且通常能被人工审查发现,这没问题。如果你运行数百或数千个代理,或者即使只有少数代理但没有审查或其他防护措施,并且失败可能造成严重问题,这就完全不行了。虽然有些技术是规模不变的,但很多不是。 另一种工作流程问题是当人们有一个无法为 X 工作的工作流程,然后得出结论说没人能做 X,因为他们自己做不到。我没有仔细思考哪些具体不起作用,但 Max Bittker 有以下评论: “我注意到的几个模式,按顺序:
- 人们有时环境配置错误:他们使用了旧模型,打开了大量 MCP 或第三方系统提示,或者 LLM 正在处理 Windows 或某些不寻常的环境或 IDE。
- 人们有时通过使用一个超长聊天(大量回溯)或单个超级混乱的工作目录来破坏上下文窗口。
- 通过不精确的语言注入意外需求,使 LLM 执行比预期更困难的任务,比如在游戏核心之前构建匹配系统。
- 如果你对想要什么或何时完成没有明确的概念,你可能规定不足,然后协作漂移,随时间改变需求,最终一事无成(许多 AI 精神病氛围编码者这样做)。”
Appendix: agentic loops and writing this post
As I noted in the alt text at the start of this post, I was very hesitant to write about AI for years because I'm up here in Galapagos Island, highly disconnected from what's happening because I haven't been reading social media much and I've also been doing a bad job at keeping in touch with folks who are really in the thick of it in SF.
I was convinced that it might make sense to write something in May, when I chatted with a couple folks from SF who were in town for PGConf. Even though they are in the thick of it and seem to be close to the cutting edge of what people are doing with agents, there were still things from my workflow that they thought were interesting. But, like I said, the half-life of particular workflow tips and tricks is short enough that I didn't think it would be useful to write up detailed notes on an exact workflow, which is why the main post has focused more on higher level ideas. I'm not sure what might actually be useful, but I'm going to try writing up something about the evolution of my workflow. As noted above, I don't think there was any point in time where my workflow was great, exactly, but it was useful and there always seemed to be a natural next step to make it a bit more productive.
附录:代理循环与写作本文
正如我在文章开头 alt 文本中所说,多年来我一直对写关于 AI 的内容犹豫不决,因为我在加拉帕戈斯岛上,与外界高度脱节——我不怎么看社交媒体,也疏于与旧金山圈内的朋友保持联系。 但在五月,我与几位来参加 PGConf 的旧金山朋友聊天后,我确信写点东西可能有意义。尽管他们身处核心且似乎接近人们使用代理的前沿,但我的工作流程中仍有他们认为有趣的东西。但正如我所说,具体工作流技巧的保质期很短,我认为详细记录一个精确的工作流程不会有用,因此正文更多地关注了更高层次的想法。我不确定什么可能真正有用,但我将尝试撰写关于我工作流程演变的内容。如上所述,我不认为我的工作流程在任何时间点有多么出色,但它很有用,并且似乎总是有自然的下一步来提高效率。
Back in the stone ages, before tools like Claude and Codex, I would sometimes just run a very simple loop that would just keep compiling the code and running the tests and re-prompting until everything passes, which I mentioned here in mid-2024. At the time, I didn't find this useful enough to use for anything where I knew what I was doing, but it enabled me to embed a little web game into that post and do other tasks that would've required me to learn something about an area where having actual expertise will probably never be particularly interesting to me, such as building a web app.
That kind of thing was mildly useful for quite a while when I wanted to accomplish some simple task, but I didn't start using agents much until running into the bisect/video story at the top of this post, and doing some other data analysis and seeing how much it could speed up data analysis. BTW, the bisect/video story came out of an analysis where I was wondering what the half-life of a working feature and/or bug fix is. Coincidentally, that analysis is linked to a couple of ideas in the post. First, the half-life turned out to be fairly short pre-LLM, which seemed like a point in favor of more testing if we wanted to turn the dial up on velocity (with or without LLMs). And, second, this is yet another analysis that would've taken long enough that I wouldn't have done it pre-LLM.
At some point mid-late 2025, I tried vibe coding some personal projects. I used Codex just because people said it gives you more quota on the subscription plans (I've since tried both and that seems to be accurate). At that point, my goal was to use as little of my time as possible on personal projects while getting the output I wanted, but I hadn't really done any vibe coding before and didn't have any idea what would work, but it quickly became apparent that I did the most naive possible loop, where I would just queue up a bunch of copies of "if X isn't done, implement X until complete; if X is done, ...". I wasn't reading anything about what other people were doing and the people I was personally talking to generally weren't using AI much, so I had no idea that the term "Ralph loop" had been coined in mid-2025 and people were doing various, less cumbersome, variants of this, although this wasn't really all that cumbersome (maybe 5 seconds or so to queue up the copies of the prompt once they're written).
早在石器时代,在 Claude 和 Codex 等工具出现之前,我有时会运行一个非常简单的循环:不断编译代码、运行测试并重新提示,直到所有测试通过,我在 2024 年年中提到过这个。当时,我觉得这对我擅长的事情没什么用,但它让我能够在那篇文章中嵌入一个网页小游戏,并完成其他需要我学习一些我可能永远不感兴趣的领域的任务,比如构建一个 Web 应用。 这类东西在我想完成一些简单任务时相当有用,但我直到遇到文章开头那个二分查找/视频的故事,以及做了一些其他数据分析并看到它可以极大地加速数据分析之后,才开始大量使用代理。顺便说一句,二分查找/视频的故事源于一项分析,我好奇一个工作特性或 bug 修复的“半衰期”是多少。巧合的是,这项分析与文章中的几个观点相关。首先,半衰期在 LLM 出现之前相当短,这似乎支持如果我们想提高速度(无论是否使用 LLM),就需要更多测试。其次,这是另一个在 LLM 之前需要很长时间所以我不会去做的分析。 在 2025 年中后期的某个时候,我尝试对一些个人项目进行“氛围编码”。我使用 Codex 只是因为人们说它在订阅计划中提供更多配额(我后来两种都试过,确实如此)。那时,我的目标是在个人项目上花尽可能少的时间,同时得到我想要的结果。我之前没做过氛围编码,不知道什么有效,但很快就发现我做了最简单的循环:我只需排队一串“如果 X 未完成,实现 X 直到完成;如果 X 已完成,则……”。我没有阅读其他人的做法,与我交谈的人大多也不太使用 AI,所以我不知道“Ralph loop”这个词在 2025 年年中被创造出来,人们在使用各种更简洁的变体,尽管我的方法也不算繁琐(一旦写好提示,排队大概需要 5 秒)。
And, in retrospect, this workflow wasn't so bad in terms of steering things in the right direction compared to a Ralph loop. I'd usually look at this a handful of times every day (right before bed, on waking up, maybe a couple other times) and, in general, every time I looked, things would not quite be right and I'd queue up some commands to nudge things in the right direction after looking at the logs/metrics/graphs/etc. that explained what was going on. Since this was for personal projects I was spending a small number of minutes a day on, I wasn't trying to maximize throughput and was just running a few things on each of two different laptops I have lying around. It would've been better to have more autonomous loops that can keep going indefinitely without refilling the queue by hand, but the actual time savings from that isn't really all that much, I think less than 10 minutes per day.
After doing that for a while, I started (sometimes) trying to run more autonomous loops earlier this year. Once again, I think this must've been somewhat behind the curve compared to whatever people are excited about at any given time, but it seemed to work ok. On starting to do that, I found that a lot of the tooling people were recommending wasn't really a great fit for managing agentic loops and the tooling that was designed for it seemed a bit "vibe"-y and would have reliability issues.
An example of the first thing is that Conductor was widely recommended at the time and it wasn't really made to support a lot of things I'd want to do. For example, Conductor has the concept of a workspace to separate things. I often want to invoke what one might call "higher order workspaces", where an agent (or a set of independent agents) decide what should be done with a list of items, after which each item should be fed into another agent (or independent set of agents) (possibly with some limit on agent concurrency), after which, etc., with some kind of graph structure determine how tasks move around, where there are reduce-like steps that look at the output from a bunch of tasks, and so on and so forth.. While it's technically possible to make Conductor do this, it wasn't really designed for it and, given that you can just tell agents to write scripts to create a structure like this, it seemed a lot simpler to just use custom vibe-coded scripts.
The kinds of tools that were designed for use of a lot of agents, like Gas Town, mostly seemed to be for less structured workflows, and they often seemed highly vibe coded and somewhat unreliable as a result, to the point that I wasn't sure why I would want to use one of them and not just cobble together something myself. What I mean there is, per the discussion in the long footnote about board games, if something doesn't meet a certain bar for quality and complexity, it's fairly easy to just make a version of it yourself. Even if the thing you make for yourself is buggier than the product, you can make sure that, given your workflow, it doesn't have bugs that impact your particular workflow, so you don't even have to meet the same overall quality bar as the product does for it to be better for you.
As a result, what I've ended up doing is making one-off loops for tasks that need to run for a while. There's probably an efficiency gain from building some kind of orchestrator that fits what I want, but I don't think I've really set up enough of these loops to know what I want, and what I want varies a lot depending on the problem. Sometimes I want to have certain metrics trigger a health check by an agent that can fix issues and sometimes I want an agent or set of agents to automatically be invoked after each iteration (whatever that means) to check on progress and sometimes I want agents to continuously check on progress. Sometimes I want a graph structure with some kind of multi-level triage, etc.
Because it's fairly easy to have an agent set up whatever arbitrary structure you want, I'll generally start with some kind of simple structure with some basic health checks and monitoring and then I'll check in on it periodically and try to make structural fixes to address issues so that the issue doesn't recur. In principle, something like this that's well set up could produce useful work indefinitely but, at least for what I've set up, these loops tend to degrade in productivity over time. Even if nothing is badly wrong, the loops are a lot more productive if I'm actively at the keyboard typing instructions to nudge things in various ways, while monitoring what's happening. If I leave one of these alone for a few days or a week, it will usually still be producing a non-zero amount of useful work, but not nearly as much as if I'd check in daily. I've tried various strategies to try to keep these loops more on track without intervention and I've found various things that can help, but I haven't figured out how to replace myself (yet?).
回想起来,这个工作流程在引导事情朝着正确方向前进方面,并不比 Ralph loop 差。我通常每天查看几次(睡前、醒来后,可能还有一两次),每次查看时事情都不太对劲,我会在看到解释情况的日志/指标/图表等之后排队一些命令来进行微调。由于这只是个人项目,我每天只花几分钟,我并不追求最大化吞吐量,只是在手边的两台不同笔记本电脑上各运行一些任务。如果有更自主的循环,可以无限期运行而无需手动补充队列,当然更好,但实际节省的时间并不多,我认为每天少于 10 分钟。 这样做了一段时间后,今年早些时候我(有时)开始尝试运行更自主的循环。同样,我认为这比当时人们热衷的任何东西都落后一些,但似乎效果还行。开始这样做时,我发现人们推荐的大量工具并不适合管理代理循环,而专为此设计的工具似乎有点“氛围”化,并存在可靠性问题。 一个例子是,当时 Conductor 被广泛推荐,但它并不能真正支持我想做的许多事情。例如,Conductor 有工作区概念来分隔事物。我经常想调用所谓的高阶工作区:一个(或一组独立)代理决定一个项目列表应该如何处理,然后每个项目被馈送到另一个代理(或独立代理组)(可能对代理并发有一些限制),依此类推,通过某种图结构决定任务如何移动,其中有类似归约的步骤查看一堆任务的输出,等等。虽然让 Conductor 做到这一点在技术上是可能的,但它并非为此设计,既然你可以直接让代理编写脚本来创建这种结构,似乎使用自定义的氛围编码脚本更简单。 那些为大量代理使用而设计的工具,比如 Gas Town,似乎主要用于非结构化工作流程,而且它们通常高度氛围编码,因此有些不可靠,以至于我不确定为什么要使用它们而不是自己拼凑一些东西。我的意思是,根据棋盘游戏的长脚注中的讨论,如果某些东西达不到一定的质量和复杂性门槛,你自己做一个版本是相当容易的。即使你为自己做的东西比产品有更多 bug,你可以确保它不会影响你的特定工作流程,因此它甚至不需要达到与产品相同的整体质量标准就可以对你更有利。 因此,我最终的做法是为需要运行一段时间的任务创建一次性循环。构建某种适合我需要的编排器可能会有效率提升,但我认为我还没有设置足够多的这些循环来知道我想要什么,而且我的需求因问题而异。有时我希望某些指标触发代理的健康检查以修复问题,有时我希望一个或一组代理在每次迭代后自动调用以检查进度,有时我希望代理持续检查进度。有时我需要某种具有多级分类的图结构等等。 由于让代理设置你想要的任意结构相当容易,我通常从一些简单的结构开始,包含基本的健康检查和监控,然后定期检查并尝试进行结构性修复以解决问题,使问题不再发生。原则上,设置得当的东西可以无限期地产生有用的工作,但至少对于我设置的东西,这些循环的效率会随时间退化。即使没有严重问题,如果我积极在键盘前输入指令以各种方式微调并监控进展,循环的生产力要高得多。如果我将一个循环搁置几天或一周,它通常仍会产生一些有用的工作,但远不及我每天检查的程度。我尝试了各种策略来使这些循环在没有干预的情况下保持正轨,我找到了一些有帮助的东西,但我还没有找到如何替代我自己(还没有)。
For example, in April/May 2026, I tried having a bunch of "personas" convene and reconvene to try to nudge the loop instead of doing it myself. At the time, I was trying to get a loop running smoothly that was doing some work on some code that uses CRDTs (which I know nothing about, BTW), so I tried diagnosing issues with something like "use independent agents to review as linus torvalds, kyle kingsbury, marc brooker, tptacek, dan luu, and 4 contrarian personas. have each think for a long time", with multiple iterations of this (yes, I do find it quite silly to invoke my own name). Each of these personas seemed to keep things on track in a different way, e.g., the "linus torvalds" persona would tend to push back against the loop's "natural" tendency to have things spiral out of control due by repeatedly adding unnecessary complexity, the "dan luu" persona would force the loop to measure things before implementing and also sometimes say things like "we must not rationalize XYZ" and push back on some bad reasoning. None of this was enough to replace human observation and intervention, but doing variations of this was enough to keep these loops running more smoothly, with less intervention required.
This kind of persona setup also improved things for architectural design, debugging, etc. Again, not so much that you wouldn't want a human at all, but enough that the human can do a bit less work.
All of this seems to work best if the human understands the common failure modes. For example, when asked to debug and explain when a bug was introduced, if just prompted to explain, even with multiple independent rounds of analysis, the agents would often come back with a completely incorrect explanation (maybe 50% of the time or so). When asked to confirm their hypothesis by actually executing code to check if the hypothesis is correct, that removed most incorrect explanations. Just adding forced checking to a simple prompt has a better success rate than having agents do independent analyses and cross-check each other (doing both together seems to have an even higher success rate).
A lot of getting value out of agents seems to be having some kind of understanding of their failure modes and then working around them. Earlier in the post, we noted that people aren't really going to be left behind if they're not using coding agents now and get started in M months because they can be at most M months behind, but will likely be much less behind than that because of how quickly things are changing. A major reason for this is, AFAICT, a lot of the skill involved in using agents is working around their failures. Of course AI labs want to fix these failures, which means new releases are designed to obsolete these skills as much as possible. This is possible to observe directly, in some failure modes that were quite common a year ago are now much rarer.
BTW, this is another reason I don't find a lot of benchmarks useful for me personally. In general, benchmarks have moved to trying not to "over explain" and instead act like a naive user who isn't very good at using agents. This is a reasonable thing for AI labs to care about because they want to make a product that needs as little expertise as possible to operate but, as a professional programmer, if there's way to work around some failure mode of agents, you're probably going to use it instead of acting like you're a benchmark, and you therefore get a very different result even if you're doing the exact task from some benchmark.
例如,在 2026 年 4 月/5 月,我尝试让一堆“角色”聚集和重新聚集,以尝试代替我来微调循环。当时,我正试图让一个循环平稳运行,该循环在处理一些使用 CRDT 的代码(顺便说一句,我一无所知),所以我尝试诊断问题,例如“使用独立代理以 linus torvalds、kyle kingsbury、marc brooker、tptacek、dan luu 和 4 个逆向角色的身份进行审查。让每个角色思考很长时间”,并多次迭代(是的,我觉得调用自己的名字很傻)。这些角色似乎各自以不同的方式让事情保持在正轨上,例如,“linus torvalds”角色倾向于对抗循环由于重复添加不必要的复杂性而失控的“自然”趋势,“dan luu”角色会强制循环在实现之前进行测量,有时还会说“我们绝不能合理化 XYZ”并抵制一些错误的推理。这些都不足以取代人类的观察和干预,但做这样的变体足以让这些循环更平稳地运行,需要的干预更少。 这种角色设置也改进了架构设计、调试等方面。同样,不足以让你完全不需要人类,但足以让人类少做一些工作。 所有这些似乎在人类理解常见失败模式时效果最好。例如,当要求调试并解释 bug 何时引入时,如果只是提示解释,即使经过多轮独立分析,代理也经常返回完全错误的解释(大约 50% 的时间)。当要求通过实际执行代码来确认假设是否正确时,这消除了大多数错误解释。仅在一个简单提示中加入强制检查的成功率就高于让代理进行独立分析并相互交叉检查(两者结合似乎成功率更高)。 从代理中获得价值的很大一部分似乎是理解它们的失败模式,然后绕开它们。在文章前面我们提到,如果现在没有使用编码代理,人们在 M 个月后开始也不会落后太多,因为事情变化很快。一个主要原因是,我认为,使用代理的许多技能在于绕开它们的失败。当然,AI 实验室想要修复这些失败,这意味着新版本旨在尽可能淘汰这些技能。这可以直接观察到,一些一年前很常见的失败模式现在变得罕见。 顺便说一句,这是另一个我发现很多基准测试对我个人没有用的原因。通常,基准测试已转向试图不“过度解释”,而是像一个不太会使用代理的天真用户。这是 AI 实验室合理的关注点,因为他们想要制造一个需要尽可能少专业知识就能操作的产品,但作为专业程序员,如果有办法绕开代理的某种失败模式,你很可能会使用它,而不是像基准测试那样行事,因此即使你执行的是某个基准测试的完全相同的任务,你也会得到非常不同的结果。
Thanks to Max Bittker, Dennis Snell, Em Chu, Yossi Kreinin, Peter Geoghegan, Michael Malis, @[email protected], Misha Yaugdin, and Jason Seibel for comments/corrections/discussion.
感谢 Max Bittker、Dennis Snell、Em Chu、Yossi Kreinin、Peter Geoghegan、Michael Malis、@[email protected]、Misha Yaugdin 和 Jason Seibel 的评论、更正和讨论。