Working paper · AI engineering
The Heat Death of the Codebase?
On Paying Maxwell’s Demon a Day Rate
How many AI coding agents to run, and why review sets the limit.
Tom Baldwin · First published 29 September 2026 · revised 20 November 2026
Coding agents make changes cheaply, and you can run as many as the tokens allow. Every change still needs checking, and every change creates some waste: conflicts, regressions, fixes that need fixing. Run more agents and the waste grows faster than the output. This paper asks how many to run.
We’ve watched this happen in our own work. Agents gave us a massive jump in productivity at first, then a plateau, as we found more bugs, or introduced them, and had to fix them. The code isn’t necessarily worse, and may even be better, but there’s a lot more of it. Claude is better at catching code issues in review; we’re better at the architecture and the big picture.
We’ve seen the same shape before agents, with people writing the code. A complex system built in something like plain JavaScript and React sprints ahead with working prototypes and looks the better choice. Six months later it is bogging down in its own tangle, and it copes badly as the team grows. Bringing in TypeScript and automated checks at that point is slow and expensive, and an uphill battle. A system in something like Java starts slower and keeps going, because a compiler and its conventions do much of the checking from the first day. Agents make changes faster than any team, so they reach that point sooner, and the tools they are given decide how hard they hit it.
This paper is our attempt to put numbers on that shape. The model’s explanation is that the surge leaves behind change nobody has properly checked, and yesterday’s unchecked changes come back as today’s bugs. That backlog is a debt, and the plateau is the time spent paying it back. It also says why the tools matter: whatever a compiler checks never reaches a person’s queue, so less piles up.
Maxwell imagined a demon at a gate between two boxes of gas, checking each molecule and letting only the right ones through, so that disorder is held back for as long as it keeps looking. Your reviewers are that demon, and like it they only hold the disorder back while someone pays them to look.
Engineers call the energy an engine takes in but cannot turn into work its waste heat. This paper puts numbers on an agent fleet’s waste heat, with a model whose defaults come from published measurements going back to 1975, and boils it down to a rule of thumb for when you have no numbers yet.
The biggest lever is checking. In the model’s typical fleet, letting tests and tools take on 70% of the checking instead of half doubles the best fleet, from four agents to eight, without anyone planning for more agents (table 2).
How many agents should you run?
The typical fleet, with two reviewers: best at 4 agents. With JavaScript on, every input here can be changed.
| Agents | Finished changes/day | Rework | Limit |
|---|---|---|---|
| 1 | 3.6 | 40% | coordination |
| 2 | 6.4 | 41% | coordination |
| 3 | 8.4 | 41% | coordination |
| 4 | 9.3 | 42% | review |
| 5 | 9.2 | 42% | review |
| 6 | 9.1 | 43% | review |
| 7 | 9.0 | 44% | review |
| 8 | 8.9 | 44% | review |
| 9 | 8.9 | 45% | review |
| 10 | 8.8 | 45% | review |
1 Reading the answer
In words Run enough agents to keep your reviewers busy, a few more to cover the drag, and stop there.
A careful human reviewer checks about 200 lines an hour, and a single agent can produce more than one reviewer can properly read. So for teams with one or two reviewers and modest automation, review sets the limit, and the right number of agents is the number that keeps your reviewers fully used, plus a few to make up for the output lost to coordination.
Take the typical fleet, the calculator’s starting point. Two reviewers read about 1,200 lines a day between them, and with tools doing half the checking that covers about 2,400 lines of agent output. An agent produces about 900 lines a day, so the reviewers can keep up with about 2.7 agents. Allowing for the drag, the sizing formula says 4 agents, finishing about 9.3 changes a day, which is what the full model gives. The rule of thumb agrees: at that level of automation it allows two agents per reviewer, which is also 4.
There is also a ceiling that review capacity cannot lift. With typical values, past about eight agents on one codebase each extra agent causes more coordination and collisions than it adds in output.
Sizing to the reviewers is the theory of constraints applied to a fleet: size everything to the step that limits it. The calculator plans for reviewers to be busy 75% of the time, because, as Kingman showed and Reinertsen applied to product development, waiting time rises steeply as a reviewer approaches full use, and once work arrives faster than it can be checked the queue simply grows. The trial below ran past that point. Past this size finished output barely changes, but cost does: every extra agent burns tokens, and every change it makes joins the queue.
2 Where the waste comes from
Three forces pull a fleet’s output below the sum of its agents. Each has decades of evidence behind it in human teams, and early measurements suggest each shows up in agent fleets.
- ContentionSome steps happen one at a time: the merge queue, CI, a lock on a shared file, a human approving the change. This is Amdahl’s law. Cursor reported that twenty agents coordinating through locks “would slow down to the effective throughput of two or three”. After replacing the locks with a hierarchy of planners and workers, the same team ran hundreds of agents at once. How much contention a fleet has depends on how it is organised.
- CoherenceEvery pair of agents can step on each other, and the number of pairs, as Brooks counted them for people, grows with the square of the fleet. Agents must also catch up on what the others changed. Textual conflicts between agents’ pull requests are common: 48 of 115 sampled pairs from different agents (table 1), but our own test below found that few of them turn into rejected work.
- ReworkSome changes need fixing, and some fixes need fixing too. If half of all changes come back, you do twice the work. If every fix breaks at least one more thing, the work never ends.
Brooks described the last one in 1975: repairs tend to destroy a system’s structure and increase its disorder, until fixing stops making progress. He put the chance that a fix introduces a new defect at 20–50%. Lehman wrote that his law of increasing complexity may be an analogue of the second law of thermodynamics. Agents raise all three at once.
None of this needs the code to be worse. In our experience it isn’t necessarily worse, and may even be better; there is simply a lot more of it. Every change, good or bad, takes a reviewer’s time, and every change that comes back takes it twice. So read the model’s rework as the share of changes sent back, for whatever reason. The volume is in the model too, as the number of changes each agent submits a day and their size in lines. Changes that are sent back tend to come back more than once (appendix C).
3 What the data says
Default values in the calculator come from published measurements. Most are thin, so treat them as starting points and replace them with your own.
| Parameter | Default | Range | Evidence |
|---|---|---|---|
| Sent back or fixed later, people’s changes | 0.10 | 0.02–0.50 | About 7% of repairs inject a new defect (Capers Jones); 11.4% of Eclipse revisions induce a later fix (Śliwerski et al.); Brooks estimated 20–50% for fixes |
| Sent back, autonomous agents’ changes | 0.40 | 0.15–0.60 | Maintainers would not merge roughly half of agent PRs that passed the tests (METR, 2026); merge rates in the wild run from 43% to 83% by agent (Ehsani et al.) |
| Collision chance | 0.01 | 0–0.05 | The chance a concurrent change forces a redo. The best direct measurement is Uber’s: a 5% chance that two concurrent changes pass alone but break together, rising to 40% at sixteen (Ananthanarayanan et al.). Textual conflicts are far more common: 27.7% of 107,000 agent PRs conflict with their base branch (AgenticFlict), and pairs of PRs open together conflict in 19.8% of cases from the same agent and 41.7% across agents (Xu et al.). But in 48,000 agent PRs, concurrency barely changed the chance of rejection (our test, below): about 0.2% per concurrent PR where there is review |
| Share done one at a time | 0.10 | 0.05–0.40 | 0.12 estimated from one developer’s commit history with parallel agents (Khailo); about 0.37 implied by Cursor’s lock-based fleet (our inference from 20 agents doing the work of 2.5) |
| Coordination cost per pair | 0.01 | 0.002–0.035 | 0.032 chosen by hand in the same analysis, and for agents working in separate repositories, so it measures something other than agent coordination. Reasoning turns grow as about n1.7 across 260 multi-agent configurations on six agentic benchmarks, one of them SWE-bench Verified (Kim et al.), which is at least consistent with a pairwise term |
| Review speed | 200 lines/h | 150–400 | Kemerer & Paulk: review quality falls above 200 lines/hour. SmartBear/Cisco: sharp drop above about 500 lines/hour and beyond about 400 lines per session |
Telemetry from AI-heavy teams is consistent with the model. Faros AI reported 98% more pull requests merged, but review time up 91% and no gain in company-level throughput. DORA’s 2024 survey associated every 25% rise in AI adoption with a 7.2% fall in delivery stability. Both are what you would expect if output is capped by verification and the surplus turns into rework.
4 Tested against 48,000 agent pull requests
We tested the model’s collision term on AIDev (Li, Zhang and Hassan, 2025), a public dataset of pull requests written by coding agents. Two of the studies cited above, Xu et al. and Ehsani et al., use a subset of the same data. We wrote down the hypotheses, the analysis and what would count against the model before looking at any outcome, and published the results whichever way they came out.
They came out mostly against. Across 48,128 closed agent PRs in 455 repositories, a PR opened while many others were open was not rejected more often. Three of the four pre-registered predictions failed. The one that held was the mechanism: concurrent PRs touching the same files raised rejection slightly, by about 0.2% each, while those touching other files did not. A large share of the sample is agents merging their own PRs within seconds, with no review at all. In the 298 repositories that look review-gated, rejection did rise with concurrency, by about 0.2% per concurrent PR, but that analysis was done after seeing the data and the rise came from PRs touching different files. The load is on reviewers, and collisions between changes do not show, which fits Nachuma and Zibran’s finding on the same data that reviewer engagement is the strongest predictor of an agent’s PR being merged.
We changed the paper as a result. The default collision chance went from 5% to 1%, and the sizing formula now leads with review capacity.
5 A first controlled trial
We built a sandbox codebase with 220 small, tested feature requests and a harness that runs a fleet against it. Each task goes to its own cloud session running Claude Haiku 4.5. Every finished change is reviewed by a single automated reviewer, Claude Opus 5.5, which sends it back or approves it. Hidden tests then check approved changes before they merge. Before the full experiment, a trial ran one agent for 30 minutes, then twelve for 30 minutes. Two of the twelve were lost to a fault in our tooling, so the second half ran with ten.
The reviewer was fast: about 21 seconds a change, or about 150 reviews an hour once the gaps between them are counted, far quicker than any person, and it still became the limit. Each agent submitted about 14 new changes an hour, and the reviewer sent 39% back; counting merge conflicts and escaped defects too, 46% came back. With resubmissions, each agent created about 20 reviews an hour, so the reviewer could keep up with about seven agents, and with no drag that is where the sizing formula says review starts to bind. With ten running, the reviewer was busy 88% of the time and its queue grew throughout the window, from nothing to 29 changes waiting. With one agent it was idle most of the time. Five of the 65 first passes through the merge queue conflicted with work merged since they started and went back; with about ten merges since each one’s base, that is a collision chance of about 0.8% per pair, close to the paper’s default of 1%.
Automating review raised the limit, from a few agents to about seven here, but did not remove it, and a fleet of this speed reaches it quickly. Each change sent back costs a second review, so a reviewer at 39% spends about a third of its time re-reading changes it has seen before.
This is one trial on one afternoon, a rehearsal for the pre-registered experiment, so treat it as an illustration of the mechanism. The full experiment is drafted and its plan is public; it is not yet pre-registered, and it runs when its budget is settled.
6 When the reviewers are agents
The trial above already had one. An agent reviewer changes two things. Review capacity goes up several times over: the Opus reviewer could check the work of about seven agents, where a careful person can check the work of one or two. And a new number matters: the share of wrong changes it approves. In the trial, 2 of the 71 changes it approved, about 3%, failed hidden tests it never saw. Two is a small count: the true rate could be anywhere from under 1% to about 10%. Appendix D puts this into the model.
The escaped changes are unverified change that has been marked as checked. A fully busy reviewer of this speed approves about 100 changes an hour, so that is roughly three wrong changes an hour, and possibly as few as one every few hours or as many as ten an hour. Our hidden tests caught them; in most codebases nothing would, and they would come back later as bugs.
Each extra agent reviewer catches fewer of the first one’s escapes than an independent check would, because models tend to share blind spots (appendix E.2), so a stack of them has to stop at something that does not guess, or a person reading the change.
Agent reviewers are still worth having. They raise the review limit, and in our trial they let few wrong changes through. But they move the question from “who has time to read this?” to “who checks what the reviewer let through?”, and the answer to that one is still paid at a day rate.
7 Where the person goes
The model counts a person’s review in lines read, at about 200 an hour. That measure comes from people reading code other people wrote. As we said at the start, Claude is better at catching code issues in review, and we’re better at the architecture and the big picture.
So once agents read the code line by line, a person’s review capacity is better counted in decisions: does this change fit the design, and is it the change we wanted? Those decisions are harder to hand to a machine, and they are where a person’s time now goes furthest.
Some of them can still be moved into tools. The architecture and effect checkers in the first item of the next section turn a design decision into a check that runs on every change. Candor is one: it fails the build when a change breaks an architectural policy.
8 What moves the limit
Adding agents moves you along the curve; the changes below move the curve itself.
- Review ceilingDeterministic checks that answer a question a reviewer would otherwise answer by reading: type systems, contract and property tests, architecture and effect checkers. A deterministic check also removes a whole class of uncertainty, so reviewers read less of each change, and it doesn’t get tired at the thirtieth pull request of the day.
- ReworkGive agents the answers before they edit: fast tests, precise tasks, and tools they can ask what a change would affect. A change that fails a check inside the agent’s own loop is rework no reviewer ever sees.
- CollisionsSplit work so agents rarely touch the same files, keep changes small, and catch the collisions that merge cleanly but break behaviour.
- CoordinationHand only finished artifacts from one agent to the next. In one study, a shared log of who has claimed which task cut the share of agents redoing a teammate’s work from 78% to none (Sarkar). Organise agents as a hierarchy of planners and workers. When agents run on different machines or Claude accounts, give them a way to ask each other before they act: our Nattermatic lets one agent message another, and wakes it to answer.
- ContentionRemove steps that happen one at a time: parallel CI, and merge queues that test changes speculatively, as Uber’s does.
8.1 How far the limit moves
A plausible set of improvements, added in turn, looks like this. The inputs are illustrative.
| Change | Best fleet | Finished/day | Limit |
|---|---|---|---|
| Typical fleet | 4 | 9.3 | review |
| Automated checking 50% → 70% | 8 | 11.9 (+28%) | coordination |
| and rework 40% → 32% | 8 | 13.5 (+45%) | coordination |
| and collisions 1% → 0.7% | 9 | 13.8 (+48%) | coordination |
| and coordination cost 0.01 → 0.007 | 10 | 15.1 (+63%) | coordination |
Most of the gain comes from the first change. Raising verification capacity moves the limit from review to coordination, and the best fleet doubles from 4 agents to 8 without anyone planning for more agents. Cutting collisions is worth the least.
We will measure candor, our attempt at the first row, with Carnot’s compare mode on our own repositories, beside repositories that did not change, and publish the results whichever way they come out.
9 Let your agent do it
You do not need to move the sliders yourself. The carnot skill gives a coding agent a script that reads your repository’s history and measures the inputs:
- ReworkChanges later reverted, sent back in review, or followed within 14 days by a fix to the same files.
- CollisionsReal pairs of branches that were open at the same time, replayed with
git merge-treeto see whether they conflict. - OutputFinished changes per day and lines per change.
It works from GitHub pull requests, merged branches on any host, or plain commits. It asks you only for what history cannot show, such as how many people review and how much checking is automated, and then reports your fleet’s Carnot limit: the best size, what limits it and which change would help most. Its compare mode measures the same repository before and after a change, such as adopting a new verification tool. It runs locally, so no repository data leaves your machine.
10 Build tools instead of redoing work
Everything above treats a model as a worker: it produces a change, and someone has to check that change. A second way escapes most of the limit: use the model to build a deterministic, tested and understood tool that then does the job the same way every time.
| Model as worker | Model as toolmaker | |
|---|---|---|
| The model runs | every time the work is done | once, to build the tool |
| Checking is paid | on every use | once, then shared across every use |
| Uncertainty per use | the same each time | close to none |
| Scales with | your reviewers | how often the tool is used |
A compiler is the familiar case. Nobody reviews its output line by line, because the checking was done up front, thoroughly, and maintained since, and the result is reused millions of times. In this paper’s terms, a tool is crystallised work: once the structure is found, it stays put.
The most valuable tools to build are checkers. Each one moves another class of question out of a reviewer’s head and into a machine, which raises the automated share of verification: the lever that doubled the best fleet size in table 2. The effect compounds: models build checkers, checkers raise verification capacity, and more capacity lets you run more models safely. Carnot is an example: a tool, largely written with a model, that measures your fleet so that nobody has to guess.
This is the JavaScript and Java story from the start of the paper, seen from the other end. A compiler and a stack’s conventions are checkers someone has already built. A project that has more of them pays less for checking on every change, and with agents making changes that fast, the difference shows sooner.
This has limits. A tool is only as good as its specification, so the gap between what was specified and what was meant moves into the tool’s design, where a person checks it once instead of on every use. Tools still need maintenance, though far less than reviewing every output they replace. And novel, one-off judgement stays with the model as worker, and stays limited by review.
Heat death is not inevitable: while the checking is paid for, the structure holds (appendix E.4).
A The model
The appendices give the model, its tests and its background in full. The model starts from the three forces of section 2.
Coordination drag follows Neil Gunther’s Universal Scalability Law, which has been fitted to systems from databases to human teams. With N agents, raw throughput in single-agent units is
where α is the share of work that must happen one at a time and β is the cost of each pair staying in sync. On its own, this peaks at N* = √(1−α)/β. Rework rises with the fleet, because each change can collide with any of the N−1 others in flight:
Useful output is raw throughput that does not come back, capped by what reviewers can verify:
Here r₀ is the share of changes that come back when one agent works alone, and r(N), written r in equations 3 and 7, is that share with N agents. λ is the number of changes one agent submits per day, V is verification capacity in reviewed lines per day and h is lines per change. Rework hits whichever limit binds. Reviewers spend time on changes that come back, and agents spend time redoing them, so the factor (1 − r) multiplies both the raw output and the review ceiling.
The sizing formula is an approximation to where U peaks, chosen by testing against the full model. Equation 1 is the fleet size at which raw output reaches the review ceiling: solving λX(N) = V/h exactly when β = 0 gives (q(1 − α))/(1 − αq), and equation 1 is a simpler form that also allows for β. Equation 2 approximates the peak without a review limit: with no collisions it gives (1 − α)/√β, a little below Gunther’s √(1 − α)/√β.
A collision here means a conflict that forces a change to be redone. A textual conflict is often a quick rebase, so if most of yours are cheap, use the share that are not. And β should be measured separately from p, or fitted jointly: a β fitted to raw throughput already contains the rework that collisions caused, so pairing it with a non-zero p counts conflicts twice.
No heat engine can beat the Carnot limit, the ceiling on efficiency set by the conditions it runs in. The best finished output this model allows is the equivalent for an agent fleet, set by your collision rate, coordination costs and review capacity. The analogy is loose: Carnot’s limit depends only on the temperatures an engine works between, while this one depends on how the fleet is organised. The calculator in the main paper finds it.
B The sizing formula, and how well it holds up
The three equations below are shortcuts to the model in appendix A. Contention and coherence enter as the coordination drag of Neil Gunther’s Universal Scalability Law, and rework rises with the number of changes in flight. Finished work is then capped at what reviewers can check. Equation 1 is where the agents’ output, after drag but before rework, first fills that ceiling. Equations 1 and 2 are approximations, chosen by testing them against the full model, below; the third follows directly from it.
Fleet size where review is the limit
Most agents worth running
Finished work when review is the limit
where:
- q
- agents your reviewers can keep up with (review capacity ÷ one agent’s output)
- α
- share of work that waits its turn
- β
- coordination cost per pair of agents
- p
- chance two concurrent changes force a redo
- r
- share of changes that come back
B.1 Equation 1 is usually the answer
For most teams review is the limit (section 1), and q is the number of agents that keeps the reviewers fully used, before drag. The rest of the line adds the agents you need to make up for the output lost to coordination. If αq + βq² reaches 1, drag stops the fleet ever filling your reviewers, and equation 2 decides instead.
B.2 Equation 2 is the ceiling
Past the ceiling, each extra agent causes more coordination and collisions than it adds in output, whatever your review capacity. With typical values it is about 8 agents.
B.3 Equation 3 is what you get
When review is the limit, finished work is what your reviewers can check, less the share of changes that come back, r. Re-reviews of returned changes use the same capacity, which is why rework costs twice. Adding agents does not raise it; better verification, such as tests, types and automated checks, does. When the ceiling binds instead, finished work before rework is X(N) from equation 4: with typical values, about 3.5 agents’ worth from a fleet of eight.
B.4 How well it holds up
We tested the formula against the full model over 1,050 combinations of settings: α from 0.02 to 0.4, β from 0.001 to 0.035, p from 0 to 0.05, and review capacity from half an agent’s output to none at all. It picks a fleet within one agent of the best in 91% of cases. Running at its size delivers at least 91% of the best achievable output in every case, and 98% or more in nine cases out of ten.
B.5 Where the rule of thumb comes from
The rule of thumb is the formula with the details dropped. A careful person, with no help from tools, checks roughly what one agent produces, and every share of checking that tools take over multiplies what that person can keep up with: that is q again. Equation 2 gives about eight for typical values, but that is the ceiling with review taken away. The rule aims at the smallest fleet that gets close to the best output, which across the teams we simulated is usually five or fewer; a cap of four did as well. The cap is per codebase, because collisions and coordination only happen between agents working on the same code. Twelve agents spread across three projects are four per codebase and get in each other’s way far less, though they still share the people checking them.
B.6 Testing the rule
We tested the rule against the full model, and against simpler rules such as “always run four”, on randomly drawn teams: one to six reviewers, 0–80% of checking automated, and the ranges of α, β and p above. Output is nearly flat past the best size, so being close to the best output is easy; the test also asks whether a rule avoids paying for agents that add nothing, meaning no more than one agent per codebase beyond the smallest fleet that gets within 5% of the best.
On 20,000 simulated single-codebase teams the rule gets within 10% of the best output for 84% and does both for 67%, against 47–54% for “always four” or “always five” and 47% for “two per reviewer”. The sizing formula gets within 10% of the best output for 99% of these teams, but it aims at the peak, so it usually runs one agent more than it needs. The rule and its cap were chosen on the same simulated teams they are scored on, so these are fitted figures, and caps of four and five score the same.
On 8,000 simulated teams running two or three codebases that share their reviewers, searched over every way of splitting the agents, the rule does both for 54–57%, and no fixed number does better than 28%. The test script and its results are public. The rule assumes human reviewers; for agents as reviewers, see section 6.
C Returns cluster
The rework term treats every change alike: each has the same chance r of coming back, and so does each fix. Reviews of agent pull requests say otherwise. In AIDev, the public dataset of agent pull requests tested in section 4, 11% of reviewed changes in repositories where changes wait for review were sent back in review at least once. Of those sent back once, a quarter to over a third came back again, and the chance kept rising with each round. A few bad changes keep bouncing, and the total comes to between a fifth and a half more rework than a constant rate predicts; the range is there because the data cannot always tell one round of review from two. Fixes to human-written code also come back more often than first changes: about 10% of changes need a follow-up fix (table 1), while 22–33% of resolved bugs needed more than one fix (Park et al.), and at least 15–24% of fixes to shipped bugs in four large operating systems were themselves wrong (Yin et al.).
Counted as the share of changes sent back at least once, r is a floor, and the rework it implies should be scaled up. As the share of reviews that send a change back, the way the trial in section 5 counted it, it already includes the repeats. There the reviewer, a model, sent rework back at the same rate as first attempts, so on that small sample its returns did not cluster. Either way the repeats are re-reviews. If q counts only first submissions, review binds at fewer agents than equation 1 says; counted with resubmissions, as in section 5, it already allows for them.
A returned change might also spread its trouble, its fix breaking other agents’ work in turn. We looked for that in the same data, in review outcomes, and did not find it. A pull request whose files received a merged change that had needed rework was no more likely to be sent back afterwards than one whose files received a clean change, once the strictness of its reviewers was allowed for, though the data cannot rule one out. Such pull requests tended to be abandoned more often, but the data has no control to separate that from strictness. The exploratory analysis has the details. It cannot say how large each return was, because the dataset has no line counts.
D Agent reviewers in the model
An agent reviewer raises verification capacity V several times over, and brings a new number: the share of wrong changes it approves, its escape rate e. Finished work that is also correct becomes
and the escaped changes are unverified change that has been marked as checked (section 6).
D.1 Hurried reviewers let more through
Equation 7 treats e as a constant, and for people it is not. Across 617 programs, reviews at or below 200 lines an hour found 56–57% of code defects and faster ones 45–47%, and reviews above 800 lines an hour found 25 to 33 points fewer defects than the careful ones (Kemerer and Paulk). In one large open-source project, reviewers with longer queues of pending reviews were more likely to approve a change that later proved buggy, in every part of the project studied (Kononenko et al.). Both are correlations, and Kemerer and Paulk note the link may partly run the other way: a reviewer who finds more slows down to record it. Read as escapes, reviewing faster than the careful pace lets through roughly 1.2 times as many wrong changes, and above four times that pace roughly 1.7 times as many.
The model assumes that a fully used reviewer keeps the careful pace and the excess waits in a queue, where everyone can see it. The other way out is to speed up, and then the excess arrives as escapes, where nobody can. With typical values this barely arises: even at full use, with none of the 25% headroom the calculator plans for, the fleet only just peaks at what two careful reviewers can check. With one reviewer at full use it does. Take the careful reviewer’s escape rate to be the trial’s 3%. Holding the pace, two agents are best, at about 6 correct changes a day. Speeding up to keep up with eight agents gives about 11, while escapes rise from 0.19 to 0.44 a day.
On the model’s own accounting, where an escaped change costs only itself, the hurried reviewer comes out ahead. The trade turns once an escape costs more than some number of changes’ worth of later work, and that number depends on how much the careful reviewer already lets through: about 65 at an escape rate of 1%, about 20 at the trial’s 3%, and about 6 at 10%. What an escape really costs is one of the open questions below. So read the constant e in equation 7 as the rate at a careful pace, and the rule of thumb’s “no more than your reviewers can check” as meaning at that pace.
E Entropy, the demon and life’s checkers
E.1 Unverified change is entropy
We use the word in the spirit of Shannon: entropy as missing information, here the gap between what the code does and what you believe it does. Every unverified change widens that gap, and verification (tests, types, review, proofs) closes it again. The analogy is structural, with no physical energy cost claimed: the Landauer bound on erasing a bit is far too small to matter to an engineering budget. Only observing code removes uncertainty about what it does, and observing is work someone or something has to do.
Szilard, Landauer and Bennett worked out what Maxwell’s demon costs. Looking can in principle be almost free, but the demon has to remember what it saw, and clearing that memory for the next molecule has an unavoidable cost. Reviewers likewise have to keep track of what they have checked and clear their desk for the next change. Economists would recognise a cousin of Baumol’s cost disease: as generation gets cheaper and checking does not, checking takes a growing share of the cost.
E.2 The same limit, one level down
A language model is an engine of the same kind. It samples a plausible change, so every output carries some leftover uncertainty about whether it is right. Long tasks compound this: each step has some chance of going wrong, so the chance of finishing falls away with length, consistent with METR’s measurements of how long a task agents can complete.
Having another model check helps only so far: Stroebl, Kapoor and Narayanan showed that when a verifier sometimes passes wrong answers, generating more candidates and checking them cannot push accuracy past a ceiling set by how often the verifier waves a wrong answer through, however much compute you spend. A model reviewing a model’s work also tends to share its blind spots: different models agree on the same wrong answer far more often than chance would predict, so their errors only partly cancel. The reviewer in our controlled experiment is itself a model, so its escaped defects measure this.
The way out is to move checking onto machines that do not guess: types, tests, proofs and effect analysis. Inside what they cover they are cheap and almost never wave a wrong change through. But they only check what has been specified. The gap between the specification and what someone meant still needs a person.
E.3 Life’s checkers
Living cells have faced this problem for about four billion years, and several of their solutions carry over to code.
- Checking costs energyThe enzymes that copy DNA and build proteins tell right building blocks from wrong ones far better than binding energy alone allows, by spending energy on extra checking steps: kinetic proofreading, proposed by Hopfield and Ninio and supported by experiment (Hopfield et al.; Thompson and Stone). Bennett showed its lowest error rate is approached only as the energy burnt goes to infinity.
- Independent layers multiplyBase selection, proofreading and mismatch repair take DNA copying from about one error in 10⁴ to 10⁶ bases to about one in 10⁹ to 10¹⁰ per base per replication in bacteria and eukaryotes, because the layers catch errors largely by different mechanisms. Two models reviewing the same way do not have that property.
- Care where errors lastErrors in DNA are inherited, so its copying is extremely accurate; most proteins are replaced within hours to days and are built with errors around a million times more often (Drummond and Wilke). The main branch deserves the heavy checking; a throwaway branch does not.
- Slow down when checking falls behindWhen misfolded proteins pile up faster than the cell’s quality control can deal with them, the unfolded protein response throttles new synthesis and expands folding capacity until it catches up, holding output to what checking can handle, as equation 1 does.
- Structure narrows the searchA template or a crystal lattice constrains what can be built, so there is less to check. Types, schemas and specifications do the same for code.
E.4 Heat death is not inevitable
In physics, heat death is the fate of an isolated system, one that nothing flows into or out of. Living things and even hurricanes build and keep their structure because energy flows through them and they export the disorder; Prigogine called these dissipative structures, and contrasted them with equilibrium structures such as crystals, which hold their order without any further flow. A codebase under change is the first kind. A finished tool is closer to the second: it keeps its shape with little upkeep, as long as the code around it stays still. What flows through a codebase is change, and what carries the disorder back out is verification: reviewers, tests, checkers, and the tools that stay checked. While that verification is paid for, the structure holds. When it stops, each change pushes the codebase towards disorder, which for software means code that nobody understands.
F What is new here, and what is not
We searched the literature from Lehman and Brooks to the 2026 preprints, and read the closest neighbours in full. Each ingredient has prior art. We have not found the combination.
- EstablishedScalability laws applied to agents: Gunther applied his law to Brooks’s law in 2007; Mieczkowski et al. applied Amdahl’s law to teams of coding agents and named Gunther’s law as future work; Khailo applied Gunther’s law to one developer’s agents, with one measured point; Mikaduki modelled merge overhead; Bertalanič and Fortuna, and Li, Gu, Cai and Feng, found diminishing returns in agent count on reasoning tasks, though none measures merged code; Mathews made human judgement Amdahl’s serial fraction.
- EstablishedVerification as the new bottleneck, argued widely; Bhati counts it as a “verification tax”, and Stroebl, Kapoor and Narayanan showed an imperfect verifier caps resampling.
- EstablishedEntropy as a metaphor for software decay (Lehman, Brooks), made measurable by Hassan’s change entropy; Casserini et al.’s “agentic entropy”.
- EstablishedFlow and queueing: Goldratt’s theory of constraints, Reinertsen on queues in product development, and Tan on queueing in verification, planning review demand below 80% of capacity.
- Partly newA rework rate that rises with fleet size, from Uber’s measurements (Ananthanarayanan et al.), put into a scalability model; our test in section 4 found it much weaker.
- Partly newRework applied to the review ceiling as well as to output, standard in factory queueing (Hopp and Spearman) and new to agent fleets.
- Partly newA review-capacity ceiling on a fleet’s finished output. Tan models one reviewer’s queue without agent counts, collisions or rework; Mikaduki treats merge and test gates as capacity limits.
- NewThe sizing formula and the rule of thumb, their accuracy against the full model, and a pre-registered test of the collision term against real pull requests. The nearest closed form, Liang’s team size for human–agent work, counts only people and has no collision term or review ceiling.
G Calibrate it for your team
Most of your own numbers are cheap to get: an agent can read them from your repository’s history in minutes. We publish an agent skill, Carnot, that does this. Start with the first three; they decide most of the answer.
G.1 Measure review capacity
Count who checks the work, how many focused hours a day they spend on it, and how much of the checking tests and tools already do: roughly, the share of questions a reviewer would otherwise answer by reading that the tests, types and tools answer instead. This sets q, and q sets the fleet.
G.2 Measure r₀
Take the share of changes that need a follow-up fix or revert within two weeks, or that a reviewer sends back.
G.3 Measure p
Take pairs of changes that were open at the same time, and count the share that conflicted badly enough to need real rework beyond a quick rebase. Expect it to be small.
G.4 Sweep the fleet, if you need to
α and β cannot be read from history, and for most teams the defaults are close enough. If you want your own, you do not need a long experiment: run your usual fleet size and two or three sizes around it on comparable work, a day or two each, and count changes that were merged and stayed merged. Three sizes are the minimum for a fit and four give a check. Hold p at your measured value, so conflicts are not counted twice.
H Future work
These are the studies we would like to run, or to see someone run. Most need more compute, data or people than a working paper has, so if you can help with any of them, get in touch.
- The fleet sweepThe controlled experiment the trial in section 5 was a rehearsal for: one and twelve agents, with enough reviewers that review is not the limit, repeated enough times to tell linear scaling from the rival laws. The plan is public but not yet pre-registered, and the sweep runs when its budget is settled. A direct test of the review ceiling, one reviewer against several at twelve agents, is included if the budget allows.
- Bigger fleets, real codeThe same sweep at 24 and 48 agents, and on real codebases with real backlogs, where tasks overlap and depend on each other far more than in a sandbox.
- Agents reviewing agentsEscape rates for reviewers from different model families, alone and stacked, to measure how far their blind spots overlap and where a second reviewer stops paying for itself; and whether an agent reviewer, like a person, lets more through as its queue grows (appendix D.1).
- Many projects, one teamA field study of a team running agents across several codebases for weeks, to test the per-codebase cap and measure what switching between projects costs the people checking the work.
- Where escaped changes goA longitudinal study of changes that passed review but were wrong: how long they stay hidden, and how much later rework they cause.
- Moving the limitBefore-and-after measurements of tools that raise verification capacity, starting with candor (section 8.1).
- Human review of agent codeHow fast people can check agent-written changes, and how well, compared with the 200 lines an hour measured for human-written code.
I Limits
This is a model, and its defaults rest on few studies, some from vendors. It assumes collisions between pairs are independent and that every agent’s changes are in flight alongside every other’s. It treats rework as one rate; counted per change, that understates it (appendix C). Its collision term has now been tested once, on observational data, and mostly failed; the sizing formula was rewritten as a result. Speed-up curves for small teams of coding agents have been published, but no one has yet published a curve of merged, useful output against fleet size. Our one controlled trial shows review binding where the formula says it should, but it is a single trial, and the full sweep is still to run. We will publish its results here whichever way they come out.
References
- Ananthanarayanan, S. et al. Keeping master green at scale. EuroSys, 2019.
- Bennett, C. H. Dissipation-error tradeoff in proofreading. BioSystems, 1979.
- Bennett, C. H. The thermodynamics of computation: a review. International Journal of Theoretical Physics, 1982.
- Bertalanič, B., Fortuna, C. The Ringelmann effect in multi-agent LLM systems: a scaling law for effective team size. 2026.
- Bhati, H. Beyond code generation: reliability, verification, and cost economics in the agentic software development lifecycle. 2026.
- Brooks, F. P. The Mythical Man-Month, ch. 2 and 11. Addison-Wesley, 1975/1995.
- Casserini, M., Facchini, A., Ferrario, A. Beyond the “diff”: addressing agentic entropy in agentic software development. 2026.
- DORA. Accelerate State of DevOps Report. 2024.
- Drake, J. W., Charlesworth, B., Charlesworth, D., Crow, J. F. Rates of spontaneous mutation. Genetics, 1998.
- Drummond, D. A., Wilke, C. O. The evolutionary consequences of erroneous protein synthesis. Nature Reviews Genetics, 2009.
- Ehsani, R., Pathak, S., Rawal, S., Al Mujahid, A., Imran, M. M., Chatterjee, P. Where do AI coding agents fail? An empirical study of failed agentic pull requests in GitHub. MSR, 2026.
- Faros AI. The AI productivity paradox report. 2025.
- Goldratt, E. M., Cox, J. The Goal. North River Press, 1984.
- Gunther, N. J. A general theory of computational scalability based on rational functions. 2008.
- Gunther, N. J. Modeling the Mythical Man-Month. 2007.
- Hassan, A. E. Predicting faults using the complexity of code changes. ICSE, 2009.
- Hopfield, J. J. Kinetic proofreading: a new mechanism for reducing errors in biosynthetic processes requiring high specificity. PNAS, 1974.
- Hopfield, J. J., Yamane, T., Yue, V., Coutts, S. M. Direct experimental evidence for kinetic proofreading in amino acylation of tRNAIle. PNAS, 1976.
- Hopp, W. J., Spearman, M. L. Factory Physics. McGraw-Hill, 1996.
- Jones, C. Software defect origins and removal methods. 2012.
- Kemerer, C. F., Paulk, M. C. The impact of design and code reviews on software quality. IEEE TSE, 2009.
- Khailo, M. Why adding more AI agents makes your team slower. 2026.
- Kim, E., Garg, A., Peng, K., Garg, N. Correlated errors in large language models. ICML, 2025.
- Kim, Y. et al. (Google Research, Google DeepMind, MIT). Towards a science of scaling agent systems. 2025.
- Kingman, J. F. C. The single server queue in heavy traffic. Mathematical Proceedings of the Cambridge Philosophical Society, 1961.
- Kononenko, O., Baysal, O., Guerrouj, L., Cao, Y., Godfrey, M. W. Investigating code review quality: do people and participation matter? ICSME, 2015.
- Kunkel, T. A. DNA replication fidelity. Journal of Biological Chemistry, 2004.
- Kwa, T. et al. (METR). Measuring AI ability to complete long software tasks. 2025.
- Landauer, R. Irreversibility and heat generation in the computing process. IBM Journal of Research and Development, 1961.
- Lehman, M. M. Laws of software evolution revisited. EWSPT, 1996.
- Li, H., Zhang, H., Hassan, A. E. The rise of AI teammates in software engineering (SE) 3.0 (the AIDev dataset). 2025.
- Li, J., Gu, Z., Cai, Y., Feng, H. Scaling behavior of single LLM-driven multi-agent systems. 2026.
- Liang, J. The novelty bottleneck. 2026.
- Lin, W. (Cursor). Scaling long-running autonomous coding. 2026.
- Mathews, K. (Electric). Amdahl’s law for AI agents. 2026.
- METR. Many SWE-bench-passing PRs would not be merged into main. 2026.
- Mieczkowski, E. et al. Language model teams as distributed systems. 2026.
- Mikaduki, S. When more agents hurt: generalized Amdahl bounds for speculative parallelism in agentic software pipelines. TechRxiv, 2026.
- Nachuma, C., Zibran, M. When AI teammates meet code review: collaboration signals shaping the integration of agent-authored pull requests. MSR, 2026.
- Ninio, J. Kinetic amplification of enzyme discrimination. Biochimie, 1975.
- Ogenrwot, D., Businge, J. AgenticFlict: a large-scale dataset of merge conflicts in AI coding agent pull requests on GitHub. 2026.
- Park, J., Kim, M., Ray, B., Bae, D.-H. An empirical study of supplementary bug fixes. MSR, 2012.
- Prigogine, I. Time, structure and fluctuations. Nobel lecture, 1977.
- Reinertsen, D. G. The Principles of Product Development Flow. Celeritas, 2009.
- Sarkar, D. Before the pull request: mining multi-agent coordination. 2026.
- Śliwerski, J., Zimmermann, T., Zeller, A. When do changes induce fixes? MSR, 2005.
- SmartBear. Best practices for peer code review (SmartBear/Cisco study).
- Stroebl, B., Kapoor, S., Narayanan, A. The limits of inference scaling through resampling. 2024.
- Szilard, L. On the decrease of entropy in a thermodynamic system by the intervention of intelligent beings. Zeitschrift für Physik, 1929 (English translation in Behavioral Science, 1964).
- Tan, K. H. The verification bottleneck in AI-accelerated knowledge work: queueing epistemics, verification capacity, and adaptive human oversight. Open Access Journal of Multidisciplinary Research 2(9), 2026.
- Thompson, R. C., Stone, P. J. Proofreading of the codon-anticodon interaction on ribosomes. PNAS, 1977.
- Walter, P., Ron, D. The unfolded protein response: from stress pathway to homeostatic regulation. Science, 2011.
- Xu, G., Subramanian, A., Karthik, N. AI agent pull requests on GitHub: frequency, structure, and merge conflict rates. 2026.
- Yin, Z., Yuan, D., Zhou, Y., Pasupathy, S., Bairavasundaram, L. How do fixes become bugs? ESEC/FSE, 2011.
Revisions
This is a working paper and will change as the evidence comes in. Corrections are marked as corrections and say what was wrong.
- Restructured for people who run engineering teams: it opens with our experience, with agents and before them, the calculator follows the rule of thumb, and the main paper is in plain words, with the model, the formula, its tests and the physics and biology in appendices. New passages: the cost is mostly volume and rework, unchecked changes come back as bugs, and where a person's review goes once agents review code. No figure, finding or default changed.
- Correction. The first trial's collision rate was given as six of 69 changes and about 1% per pair, the paper's default; the record says five of 65 first merge-queue passes, about 0.8%. Its reviewer managed about 150 reviews an hour, not 170, so q is about 7 and review binds at about seven agents. The rule of thumb's test figures are now marked as fitted on the same draws they are scored on. The full experiment was described as designed and due after a pilot; its plan is drafted and not yet pre-registered, and it runs when its budget is settled. Smaller clarifications: the rule's cap is per codebase, equation 2's eight is the ceiling with review removed, and the calculator's per-agent rate counts resubmissions.
- Section 1 is now "The formula": the sizing formula moved into it, after a paragraph on where its three equations come from.
- Added section 10.1: review escapes rise when reviewers hurry, what that does past the review limit, and how to read equation 7 and the rule of thumb in its light. The controlled experiment's plan brought up to date: one agent against twelve with reviewers to spare, after a short pilot, and the review-ceiling test if the budget allows. Future work now asks whether an agent reviewer, like a person, lets more through as its queue grows. Added section 3.1: returns cluster, so the rework rate r counted per change is a floor; no knock-on was found in review, and abandonment is unresolved.
- First published as a working paper.
Running a fleet of coding agents, or about to?
Get in touchOr follow new writing in a reader: Atom feed.