Back to Blog

Can a local model replace the coder in my agentic pipeline? 36 real-ticket runs

47 min read

Disclosure first. Claude models sit on both sides of this benchmark. Claude Fable 5.2 orchestrated every run and decided when a review was clean. Claude Code sessions built the harness (Opus 5.5 and Sonnet 5.5, going by the commit trailers on its source) and the ticket kits, including the hidden tests (Fable 5.2 subagents, going by the session records). Claude also did the failure analysis. Two of the six contestants are Claude models. The reviewer is an OpenAI model, and so is one contestant. Appendix B lists where this could tilt the result. Claude drafted this from the run records and my journal. A script checks every number against the data. The judgments are mine.

TL;DR

I run real tickets through an agentic pipeline: an orchestrator supervises, a coder writes the code, a second model reviews it. I wanted to know whether a model running on my own machine could take the coder's seat.

So I compared six coders, with the same orchestrator and reviewer, on three real tickets from a private production codebase, two repeats each: 36 runs from one frozen plan per ticket. Not everything else stayed fixed: the OS sandbox arrived after the first 10 runs, and one scoring rule changed before the last two coders ran. Neon joined after the first four coders finished, and Haiku after Neon. A run is shippable when the review comes back CLEAN and every hidden acceptance test, staged only after the coder exits, passes. 35 of the 36 runs were scored on them; an audit rule failed the other one first.

Head-to-head: shippable runs, time, cost and tokens per run for the six coders, with tokens in each provider's own units
  • The three flagship hosted models shipped every run. Opus 6/6, Astra (gpt-6-astra) 6/6, Neon (Gemini 4 Neon) 6/6.
  • The two local models shipped 3 of 12. All three were on the warm-up ticket, whose plan named the function to change and the helper to call, and in all 12 warm-up runs, hosted and local, Fable's first brief spelled out that one-line change. Two of the three local diffs that shipped also include test assertions from its fix briefs. On the medium and hard tickets they went 0 for 8, and none of those 8 runs reached a review.
  • They failed differently. Gemma's final worktrees passed every hidden test in 5 of its 6 runs, but in 3 of those it hit the 3-hour coder cap before any review. Two of those three, both on T2, include production code from Fable's fix briefs. One of Qwen's six scored worktrees passed every hidden test, and two others held none of its edits.
  • One caveat changes how to read the local result. Claude Code, which ran the local models, assumed a 1,000,000-token context window; Ollama served 262,144 tokens. 7 of the 8 local runs that hit the time cap ran past the real window and never compacted (summarised older turns to make room), so part of what failed is that pairing, not only the models. An addendum re-ran those 8 runs with the window fixed: all 8 compacted and 1 of 8 shipped, against 0 of 8, too few to call a change. In that run Gemma applied production code that Fable's fix briefs spelled out.
  • "Free" was the most expensive per result. A local coder is priced at $0, but the orchestrator still has to supervise it. Pooling the coder and orchestrator usage in a coder's six runs at API list prices and dividing by the runs that shipped gives $21.88 for Qwen and $15.02 for Gemma, against $7.91 to $12.92 for the flagship coders.
  • The orchestrator was 61% of the measured cost. The 36 runs recorded $263.06 of coder and orchestrator usage at API list prices, and $159.17 of it was the orchestrator. Part of that share is arithmetic: the 12 local runs count their coder at $0, and in the 24 hosted runs the share was 51%. The reviewer's cost was not measured.
  • Haiku, the small hosted model, shipped 4 of 6. Both misses were path slips, and one was failed by an audit rule that changed mid-benchmark.

The sample is small: 6 runs per coder, 3 tickets, one repository. Treat this as a field report, not a leaderboard.

Why this isn't a chat benchmark

A chat benchmark asks which model writes the best answer to one prompt. In my pipeline the coder works alone in a git worktree for two minutes to three hours, running tests and fixing review findings, and all that matters is whether the change can ship.

So this one replays real, already-merged tickets through the pipeline I use for real work, with a different coder each time, and lets hidden acceptance tests judge the code. I had four reasons to ask: the cost of hosted coders, keeping client code on my own machines, not depending on API quotas and rate limits, and curiosity. Only the coder's inference moved to my machine. The orchestrator and the reviewer stayed hosted.

The setup

One run: frozen inputs go to the Fable orchestrator, which sends every code change to the coder, runs the project's tests, checks the diff itself when a run reaches review, and asks a fixed reviewer. After Fable exits, the harness audits the logs and, if the audit passes, runs the hidden tests.

The orchestrator is Claude Fable 5.2 (claude-fable-5-2, high effort) running my /ec-implement skill. It creates a worktree, dispatches the coder, runs the project's tests and sends failures back. Before the first review it reviews the diff itself and sends its findings to the coder; then it asks the reviewer and relays those findings. It stops at a CLEAN verdict or after 5 rounds; its own review does not count as a round.

The reviewer is gpt-6.1-sol at medium effort, called through a wrapper named codex-review, the same for every run and not a contestant.

The coder is the part I swap:

NameModelRuns onStarted through
Opusclaude-opus-5-5, high effortAnthropicClaude Code (claude -p)
Astragpt-6-astra, high effortOpenAICodex CLI (codex exec)
Neongemini-4-neon-highGoogleAntigravity CLI (agy)
Haikuclaude-haiku-5-5, high effortAnthropicClaude Code (claude -p)
Qwenqwen3-coder-nextmy machine, through OllamaClaude Code pointed at Ollama
Gemmagemma4:31bmy machine, through OllamaClaude Code pointed at Ollama

I call Opus, Astra and Neon the flagship models. Haiku is Anthropic's small, cheap model; the report's charts label it "frontier" only because it is hosted.

The local models run on an M5 Max with 128 GB of memory. Qwen is an 80B mixture-of-experts model with about 3B parameters active, quantized to Q4_K_M, at 55 GB loaded. Gemma 4 31B shows 30 GB loaded on Ollama's MLX runner, but up to 64 GiB in long sessions, with peaks up to 90 GiB. Ollama serves both with a 262K-token context. Counted runs went one at a time, and before a local run the harness makes sure Ollama has no other model loaded; GPU use was not measured.

The rules

These keep the coder the only thing I vary on purpose. A coder here is the model with its CLI and that CLI's tools. Appendix B lists what else changed.

  1. The orchestrator never edits code. Fable runs without edit tools and sends failures and review findings back to the coder; the audit voids a run when a file in the final diff was added or modified between coder passes or after the last one.
  2. No fallbacks. A worker log that records an unassigned model voids the run. For Astra and Neon that record is the model the session started on, not the model behind each response.
  3. The same limits for everyone. 5 review rounds, 180 minutes of coder time and 360 minutes per run. The coder cap counts only time inside the coder's own process, so a slow reviewer cannot push a slow model over it.
  4. The same starting point. The same base commit and frozen plan, written once per ticket by Fable: what to change and why, with no new function names and no test code, though a plan can point at existing code. The plans are detailed, and the warm-up plan went furthest: it named the function to change and the existing helper to reuse, and it listed seven test scenarios. Fable's briefs from it differed: on T1's first repeat Gemma's said the callers were checked and off limits, Astra's said to check and fix them, and Astra added a caller guard that Gemma's diff lacks. In Astra's second repeat Fable had the same guard removed as unreachable, and both versions shipped.
  5. No extra context, as far as I could enforce it. From the original ticket history, the coder gets the description. Later ticket comments are left out because they describe the solution. Codex's memory feature is off for Astra. Other stores were weaker: the issue tracker and the Antigravity CLI's index of past sessions stayed readable, and the reviewer's memory isolation was never verified (appendix B).
  6. No peeking. Each run works in its own copy of the repository (the run records call it the sandbox; it is not the OS sandbox), holding the base commit and nothing later. The real checkout and the hidden tests sat on the same machine. The OS sandbox denied reads of both in 26 runs. In the first 10 only the after-run audit covered them: it found no coder tool call that read either, only one Qwen command that quoted the checkout's path inside test data (item 8 below).
  7. Stop before ship. No push, no pull request, no deploy.

Shippable means the review reached CLEAN and every hidden test passes; correct means every hidden test that ran passed, review or not (skipped and todo tests excluded; at least one must run, and none was skipped). Capped runs are scored on what they left behind. CLEAN is Fable's verdict, not parsed from the reviewer, but in 25 of the 26 runs reported CLEAN the last review round the harness could identify carries the pipeline's no-findings marker; in the other it could identify no round, but its transcript shows a second-round review with no findings on the scored commit.

The tickets

All three tickets come from one private production service in plain JavaScript on Node 22. Being private lowers the risk that a model saw the code in public training data. I can't show the tickets or the code, only their size.

TicketSizeThe original merged fixHidden testsFailing before the fix
T1warm-up38 lines added in 2 files108
T2medium342 lines added in 6 files1815
T3hard551 lines added in 8 files98

The repository's history holds 270 ticket ids; 16 were shortlisted by size and test coverage and read in full. Two early favourites fell out: one named the exact file, line and fix, which would test instruction-following more than coding, and the other had merged tests that pinned choices the ticket never asked for. All three selected tickets already proposed an implementation approach before Fable wrote the frozen plans.

Fable 5.2 subagents in a Claude Code session wrote the hidden tests from the merged fixes. A suite counts only if it fails on the commit before the fix for a behavioural reason, not an import error, and passes on the merged commit. Tests use public entry points and loose assertions, checking what the ticket asked for rather than the original names, and each suite was also run against a second correct fix written a different way, to check that it does not simply reward copying the original design.

The host repository has a flaky test: on T3, with the hidden tests staged, its full suite passed in only 4 of 7 identical runs, always failing in the same unrelated file. The orchestrator is told which file and to re-run it once, so no coder is blamed for it. A run could ship without a green suite: in 12 of the 14 shippable T2 and T3 runs, Fable's last full-suite run on the scored commit failed in that file, and only the file was re-run. Fable was uneven: an Astra run on T2 and an Opus run on T3 got a second re-run, which passed, while two Neon runs on T2 and an Opus, a Neon and a Haiku run on T3 shipped with the file failing twice.

How the harness works

The harness is 2,514 lines of TypeScript that Node runs directly, with no build step and no dependencies, plus 217 tests, in the revision the number check reads; it changed during the runs. A cleaned-up copy of its source is public at https://github.com/eibrahim/model-bench; it is not line for line the code that ran these runs, so its counts differ.

One wrapper decides who codes

The pipeline skill has no benchmark mode. Fable's run prompt carries the rules: never edit code, stop after review round 5, stop before shipping, and for every code change run this from the worktree, brief on standard input:

bench-worker --run "$RUN" --kind implement < "$BRIEF"

Every later pass uses --kind fix.

The wrapper starts the coder's own CLI with approval prompts skipped, in all 36 runs; only the last 26 also had the OS sandbox below. It pins every model slot to the contestant, so Claude Code cannot hand work to a smaller subagent model. It hashes the tracked and non-ignored files in the worktree before and after the pass, logs the coder's output, and kills the coder when the 180-minute budget runs out, with an exit code Fable treats as CODER CAP. The batch file keeps 92 attempt records, counted or not, and none names an orchestrator edit or a worker on the wrong model.

For an endpoint that is not Anthropic's, Claude Code gives up on a request after 5 minutes without a byte, less than a 31B model on one GPU can need to read its prompt. The local routes raise that to 30 minutes, a change that landed after the first three local runs, all on T1.

The sandbox

The OS sandbox around one run, holding Fable, the coder, git, the tests and the reviewer wrapper. It may read and write its own run folder, write temp folders, review logs and tool state, and reach the web and the model server. It may not read the real checkout, the private kits, other runs or SSH keys, write anywhere else except /dev, or connect to ssh and common database ports, Docker or other agents' sockets, or ports listening at run start other than the model server and remote ports 80 and 443. Settings, skills and hooks are read-only. Two holes: the reviewer's commands run in its own read-only sandbox, outside this profile's read rules, and one system utility may start outside it.

The orchestrator runs inside a macOS sandbox-exec profile that is generated for each run, passed inline so the coder cannot swap it, and inherited by every process it starts except through the two holes below; on sandboxed runs the harness also runs its post-run git commands and the hidden tests under it, and scores outside it. 26 of the 36 counted runs ran inside it; the first 10 predate it (both T1 repeats of Opus, Astra, Qwen and Gemma, and the first T2 run of Opus and Astra). The CLIs' settings, instructions, skills, plugins and hooks are read-only; other state that later sessions read stays writable, because the CLIs rewrite it every run, and for Claude Code that includes its tool-server configuration.

Two holes are deliberate. The reviewer's CLI applies its own sandbox, which cannot nest, so sandbox-exec itself may start outside; the reviewer's commands then run under its own read-only profile, where this profile's read rules do not bind them; the audit voids a run whose review output cites the kits or another run's folder. And macOS refuses setuid programs inside a sandbox, so one system utility may start outside it. The first four sandboxed runs lacked that exception, and T3's hidden tests use the utility, so Opus's and Astra's first T3 runs scored 2/9 until a rescore with it gave 9/9. The diagram shows the later profile. This contains a coder that wanders, and only detects a hostile one where it can. Signals are not restricted: in two runs a coder cleared stuck test runners with a pkill pattern that could match my own processes.

The audit

After every run the harness reads the logs and decides whether the run counts. It voids a run if a file in the final diff was added or modified between coder passes or after the last one, if Fable called an edit or subagent tool, if a worker log shows an unassigned model or a capacity fallback, if a command tried to start its own sandbox or a nested reviewer CLI, or on an infrastructure failure: a quota or login error, a review round with no review, a process group that survived the kill. A voided run gets up to 2 retries. The file check has blind spots: nothing is compared before the first pass, a deleted file never voids a run, and a change made during a coder pass counts as the coder's, although the orchestrator keeps working then.

A coder tool call that names a forbidden path is different. Since Nov 21, unless something else voids the run, it is scored OUTSIDE READ, a fail, with no hidden tests; before that it voided the attempt. The audit is a text match over tool calls, so it fails a run for a path it matches even when nothing was read, as run 11 in the failure table shows.

Results

Scoreboard: every run by coder, ticket and repeat, with hidden tests passed, review rounds and wall-clock time. Shippable runs: Opus 6/6, Astra 6/6, Neon 6/6, Haiku 4/6, Gemma 2/6, Qwen 1/6.

The superscripts in the scoreboard number the 11 runs that did not ship, as in the failure table further down.

Shippable and correct

CoderShippableCorrectHidden tests passed
Opus6/66/674/74
Astra6/66/674/74
Neon6/66/674/74
Haiku4/65/665/65
Gemma2/65/669/74
Qwen1/61/633/74

25 of the 36 runs were shippable: 11/12 on T1, 7/12 on T2 and 7/12 on T3. One Haiku run was never scored on hidden tests, so its total is out of 65 and its 5/6 under Correct means 5 known passes and one unknown.

Look at the gap between Gemma's two columns. In 3 of its 4 capped runs the code it left behind passed every hidden test, but it hit the coder cap before any review. That is not finished work: in runs 4, 5 and 10 the coder's own tests were still failing or hanging at its last check, and in run 4 Gemma never reran its own tests after its final edits. Qwen was not close on the larger tickets: 10/18 and 3/18 on T2, 6/9 and 2/9 on T3, and the 3/18 is an empty diff, because that coder edited the sandbox's main checkout. With no change at all, 12 of a coder's 74 hidden tests pass (2 of 10 on T1, 3 of 18 on T2 and 1 of 9 on T3 in each repeat).

Cost, and the orchestrator tax

CoderCoder per runFable per runTotal per runFable's sharePer shippable run
Opus$4.06$4.12$8.1850%$8.18
Astra$8.94$3.99$12.9231%$12.92
Neon$2.88$5.03$7.9164%$7.91
Haiku$1.44$4.74$6.1777%$9.26
Gemma$0 (local)$5.01$5.01100%$15.02
Qwen$0 (local)$3.65$3.65100%$21.88

Each column is rounded on its own, so a row can be a cent off. The last column pools the coder and Fable usage recorded in a coder's six counted runs, at API list prices, and divides it by the runs that shipped. It is not the price of one successful run.

Supervision had a cost on every route. Fable averaged $3.65 to $5.03 per run by coder, and single runs ranged from $2.05 to $8.34. Six runs per coder are too few to say how the coder changes the orchestrator's cost.

The coder's price is only part of a run's cost. Across their six counted runs, Haiku's coder cost averaged 65% lower than Opus's, and its cost per run, coder plus orchestrator, 25% lower. Because Haiku shipped 4 of 6, its cost per shippable run was 13% higher than Opus's. By the pooled figure, Qwen cost 2.7 times as much per shippable run as Opus, and Gemma 1.8 times.

Astra was the most expensive to run: $12.92 per run, 58% more than Opus. Their CLIs reported similar coder token counts per run (Astra 6.2M, Opus 6.5M), each in its own provider's units. Astra's coder cost $8.94 per run and Opus's $4.06, because Astra's list price is higher for every kind of token.

Speed

Hidden-test pass rate against wall-clock minutes, one mark per hidden-scored run, 35 of 36. Every scored hosted run is at 100%; most local runs sit past three hours.
CoderMedian wall clockMedian coder timeFastest runSlowest run
Opus51 min29 min4.9 min115 min
Astra48 min30 min7.1 min68 min
Neon54 min31 min8.0 min101 min
Haiku42 min24 min5.7 min176 min
Gemma191 min180 min38 min195 min
Qwen182 min180 min18 min189 min

Wall clock runs from the orchestrator's start to its exit. It leaves out setup before launch, model loading and the hidden-test run, but includes Fable's own setup, such as the worktree and dependency install.

Both local median coder times are the 180-minute cap, not speeds: 8 of the 12 local runs used all of it, and Qwen's fastest run is the one halted early. The fair comparison is T1, the one ticket the local models finished: the hosted coders took between 4.9 and 11.4 minutes, and the three local runs that shipped between 38.2 and 106.5 minutes.

Tokens

Tokens recorded per coder, split between the coder and the orchestrator. Across six runs, Qwen recorded 302.7M tokens, including 290.9M attributed to the coder.

"Tokens recorded" counts what the logs say each model read or wrote, including cache reads. Each CLI counts in its own model's tokens, so counts compare across providers only roughly. The local totals are approximate (appendix B).

Per run, coder and orchestrator together, the three flagship coders recorded between 10.3M and 11.3M tokens, and Gemma 10.5M. Haiku recorded 25.4M, 2.3 times as much as Opus. Qwen recorded 50.5M, 4.6 times as much as Opus, and its six runs account for 42% of the coder and orchestrator tokens tallied for the 36 counted runs.

Review rounds

Review rounds per run, by coder and ticket, 0 to 5; a round is one reviewer call. No local run on T2 or T3 reached a review. A ring marks the Haiku run the audit failed after a CLEAN second round.

Green dots are shippable runs. Orange dots passed every hidden test but never reached a CLEAN review. Red dots are neither. The ring is run 11, failed by the audit after a CLEAN review.

Hosted runs that reached review used between 1 and 5 rounds. Over their six runs Opus used 11, Astra 9, Neon 12 and Haiku 12. No run ended at the round cap without a CLEAN verdict. Only 3 of the 12 local runs reached a review, all on T1. A round is one reviewer call: Astra's and Haiku's second T1 runs each spent one on unchanged code, as the first reply gave no explicit clean verdict.

Size rank

Size rank puts shippable runs first, then the rest, and sorts each group by fewest changed lines (added plus deleted in the recorded diff), for each ticket and repeat. The run records call it blindRank, left over from a plan to rank the diffs by hand with names hidden. I had no time to rank 36 diffs blind.

Changed lines for the runs that shipped (a dash marks a run that did not):

Ticket, repeatOpusAstraNeonHaikuGemmaQwen
T1, first121157173109129249
T1, second110118221121123–
T2, first408450846477––
T2, second446450602–––
T3, first109113182286–––
T3, second1320137221321762––

Opus wrote the smallest shippable change in 5 of the 6 rows.

The median rank per coder is Opus 1, Astra 2, Haiku 3, Neon 4, Gemma 4.5 and Qwen 5. Read that with care. The coders worked under a standing instruction from my setup to write the least new code (appendix B), so these are sizes under that instruction. For runs that did not ship the count means little: 2 of Qwen's left an empty diff, and one capped run's recorded diff lists a file twice. On T2's second repeat, Qwen's empty diff, at 3/18, ranks fourth, ahead of Gemma's and Haiku's unshipped diffs at 18/18. And a larger diff may simply carry more tests, or more scope: part of Astra's 157 lines on T1's first repeat is the extra caller guard in rule 4.

How the failures happened

11 of the 36 runs did not ship. The root causes come from trace analysis by Claude: run 1 was diagnosed during the batch, and for each of the other 10 one agent proposed a cause from the logs and a second tried to refute it. Each cause is the one sentence the results page shows. In them a gate is the pipeline's formal check with the full test suite, a fix pass is any coder pass after the first, and the sandbox is the run's own copy of the repository, not the OS sandbox.

#RunOutcomeHidden testsRoot cause
1Qwen, T1, second runHALTED2/10The coder left its isolated worktree and committed its (plausible) fix directly on the sandbox's main checkout; Fable halted per ec-implement's main-checkout guard, so no review ran and the scored topic branch was empty.
2Qwen, T2, first runCODER CAP10/18The coder spent 46 minutes rerunning its own failing tests until the never-compacted session overflowed the local model's context window; one reply degenerated into repeated text and eight later turns each took over eight minutes, exhausting the 180-minute cap before any review.
3Qwen, T2, second runCODER CAP3/18The coder made all its edits in the sandbox's main checkout, leaving its assigned worktree unchanged; it hit the time cap after its conversation overflowed the local model's 262k-token context window and ten responses, each reprocessing the whole prompt, took 97 of its 180 minutes.
4Gemma, T2, first runCODER CAP18/18Averaging about nine tokens per second, the coder spent 90 minutes of its 144-minute first pass stuck on its own failing tests, then overflowed its context; the 36-minute fix pass hit the time cap before any gate or review.
5Gemma, T2, second runCODER CAP18/18To fix about ten lines of its new tests, the coder spent 76 minutes on four attempts to rewrite the whole test file, three rejected as malformed and most degenerating into repeated characters; its first pass used 143 of its 180 minutes, so no review ran.
6Haiku, T2, second runHALTED18/18The coder dropped the worktree segment from a file path and twice applied a documentation edit to the sandbox's main checkout instead of its isolated worktree; Fable halted per ec-implement's main-checkout guard before any gate or review, although the code passed every hidden test.
7Qwen, T3, first runCODER CAP6/9The coder replaced the main module wholesale, breaking that module's existing test file, spent two hours debugging its own code and tests, and lost half an hour when the local model's context window overflowed; that test file was still failing and nothing was committed when the time cap expired, before any gate or review.
8Qwen, T3, second runCODER CAP2/9The coder introduced a file-system bug in its first draft and never fixed it; after 47 minutes the never-compacted conversation overflowed the model's context window, and eight-minute prompt re-reads plus two runaway outputs ate most of the remaining budget before anything was committed, gated or reviewed.
9Gemma, T3, first runCODER CAP4/9Averaging under seven tokens per second, the local model kept rewriting whole files, losing over an hour to rejected or redone tool calls; its first pass overflowed its context at minute 150 and stalled twenty minutes, leaving unfinished, uncommitted work and no time for review.
10Gemma, T3, second runCODER CAP9/9The local coder's change passed all hidden tests, but two outputs that hit the 32,000-token limit, a third long output cut off at the cap and two full re-reads of its 210,000-plus-token prompt after cache misses took 92 of its 180 minutes and its own test kept hanging, so it hit the cap uncommitted.
11Haiku, T3, first runOUTSIDE READnot scoredThe coder redirected one test log to a mis-built path that climbed out of its run directory into the operator's home folder; the sandbox blocked the write, but the after-run audit scored it as an outside read, failing a run already reviewed clean.

Qwen did not converge. Each capped run wrote a first draft early and spent the rest of its budget debugging; in run 2 it made 101 runs of the same test file in 46 minutes. The pipeline halts a run when a coder's edit is still in the main checkout after its pass, as in run 1. On T2 one Haiku run reverted such edits within its pass and shipped; the other did not and was halted (run 6). In run 3 the cap ended the pass first, so Qwen's worktree was scored empty.

Gemma passed the hidden tests and ran out of time in 3 of its 4 capped runs. In the 3 first passes that ended with a usage record it generated between 6.8 and 20.4 tokens per second of API time, the time the client spent waiting on model requests, much of it thrown away on whole-file rewrites and on edits rejected because the text to replace did not match the file.

Under both: a context-window mismatch, found only after the runs. This part is my setup, not the models. Claude Code's records show a 1,000,000-token window for both local models; Ollama served 262,144 tokens. In all 22 local coder passes no compaction completed: Qwen's sessions never attempted one, and Gemma's tried only in the three passes that ended with "Prompt is too long". All 4 capped Qwen runs and 3 of the 4 capped Gemma runs hit the real limit. Qwen's server then silently dropped the oldest half of the context and reprocessed what remained on later requests, roughly seven to nine minutes each time, and every capped Qwen run produced at least one runaway reply; in run 2 about 95 of the 180 minutes went this way. Gemma's server rejected a request as too long, ending the pass. A 262,144-token window is not generous for this work: on the hard ticket a single Opus pass peaked at 202K tokens of context and a Haiku pass at 407K. Claude Code gives those models a 1M-token window, so it did not matter for them.

I can't say how these runs would have ended with working compaction. Qwen's debugging was not converging before the window filled: in run 7 a fresh 60-minute second pass never overflowed and failed the same way. Gemma was slow either way. But a real share of the lost time belongs to the pairing of Claude Code, Ollama and these models, and to a setup that gave the client the wrong window.

Haiku lost two runs to path slips, not to a review or a test. In run 6, 2 of its 18 edits went to the main checkout and the pipeline halted the run; its code passed all 18 hidden tests. In run 11 nothing was read: the OS sandbox blocked two test-log writes to forbidden paths, and Haiku moved the log to a temp folder each time. The review reached CLEAN, but the audit matched the first path's text and the rule failed the run. I have left the score as the rule produced it.

Addendum: the local runs again, with the context window fixed

After the 36 runs, I re-ran the 8 local runs on T2 and T3 with Claude Code set to the context window Ollama serves. The 36 counted runs and every table and chart above are unchanged and remain this article's result. Repeats 1 and 2 are the original counted runs, 3 and 4 the addendum.

What changed. Every local coder pass now starts Claude Code with CLAUDE_CODE_MAX_CONTEXT_TOKENS=262144, the window Ollama serves, and CLAUDE_CODE_AUTO_COMPACT_WINDOW=180000, so it compacts the conversation, summarising older turns, before reaching that window. Tickets, plans, base commits, hidden tests, limits and orchestrator settings stayed the same. So did the model tags and Ollama 0.40.14; the run records store no weight digest.

The addendum runs used one pinned Claude Code, 2.1.329 (3 of the original 8 ran 2.1.327 and 5 ran 2.1.329), a skill list one or two skills longer, a later harness commit with a sandbox change for another CLI's state folder, the pipeline files of the original repeat 2 runs (repeat 1 used earlier versions), and the new outside-read rule, where an outside read is a failed run with no hidden tests; the original 8 ran under the old rule, where it voided the attempt. The rule change touches one run on each side: the counted Qwen T2 repeat 2 is the retry of an attempt voided for outside reads the sandbox had refused, and Qwen's T3 repeat 3 in the addendum did the same and stands as OUTSIDE READ. The addendum ran back to back on Nov 23 and Nov 24; the original 8 ran from Nov 18 to Nov 21, between other coders' runs.

Compactions are the ones Claude Code completed.

TicketCoderRepeatOutcomeHidden tests passedReview roundsCoder minutesCompactions
T2Qwen1CODER CAP10/1801800
T2Qwen2CODER CAP3/18 †01800
T2Qwen3CODER CAP18/1801808
T2Qwen4HALTEDnone (empty diff) †0120.85
T2Gemma1CODER CAP18/1801800
T2Gemma2CODER CAP18/1801800
T2Gemma3CODER CAP18/1811802
T2Gemma4CLEAN18/183174.62
T3Qwen1CODER CAP6/901800
T3Qwen2CODER CAP2/901800
T3Qwen3OUTSIDE READnot scored ‡01807
T3Qwen4HALTEDnone (empty diff) †01203
T3Gemma1CODER CAP4/901800
T3Gemma2CODER CAP9/901800
T3Gemma3CODER CAP2/901802
T3Gemma4CODER CAP7/901803

† In these 3 runs the coder made its edits in the sandbox's main checkout, not its worktree, so the scored diff is empty and the hidden tests score the untouched code: 3/18 on T2, 1/9 on T3. The orchestrator halted both addendum runs, shown as none (empty diff). In the counted run it let the pass run to the coder cap, so that run is CODER CAP and keeps its recorded 3/18. The harness's audit does not flag edits made outside the worktree.

‡ All five of the coder's outside reads were refused by the sandbox, so nothing was read. The audit still fails the run as OUTSIDE READ, with no hidden tests.

What the numbers show. With 2 runs per ticket and coder in each set, these are counts, not rates.

  • Every addendum run compacted, and none overflowed: between 2 and 8 compactions per run, 32 in all, with no request past the 262,144-token window and none rejected as too long (for Gemma judged from prompt sizes and status codes, as Ollama's MLX runner logs no truncation).
  • Compacting used part of the 3-hour coder cap. By Claude Code's own count, Gemma's addendum compactions took 12% to 17% of each run's coder time, 103.2 minutes across its 4 runs; Qwen's took 3% to 16%, 43.9 minutes in all.
  • 1 of the 8 addendum runs shipped, against none of the original 8: Gemma's T2 repeat 4, CLEAN after 3 review rounds, using 174.6 of its 180 minutes of coder time. 2 of 8 reached a review, both Gemma on T2. One of the two, repeat 3, reached its review after the two-hour cut below ended its first pass at 120 minutes. Repeat 4's final suite failed only the flaky file, also on re-run; on the untouched base that file failed twice in three runs. Fable's last two fix briefs gave the code for its review fixes, a new database query, its call site and a list entry, and Gemma applied them. All 4 of Gemma's T2 runs in both sets passed 18/18 hidden tests. On T3 no local run shipped or reached a review in either set.
  • Qwen shipped 0 of 4: two runs edited the main checkout and were halted, one is OUTSIDE READ, and its T2 repeat 3, the only one scored on its own code, passed 18/18 at the coder cap.
  • Gemma's T3 scores moved as much within a set as between them: 4/9 and 9/9 originally, 2/9 and 7/9 in the addendum.

The two-hour cut. The orchestrator's own two-hour limit on a background command ended coder pass 1 at 120 minutes in 3 addendum runs (Gemma's T2 repeat 3, Qwen's T3 repeats 3 and 4) and once in the original 8 (Qwen's T3 repeat 1, run 7). Three of those 4 went on with fix passes to the full 180 coder minutes; Qwen's T3 repeat 4 stopped at 120, because the orchestrator halted it after the cut. In Qwen's T2 repeat 4 the command waiting on the coder hit the same limit while the coder kept running. The orchestrator then found its edits in the sandbox's main checkout and stopped it at 120.8 minutes.

Cost. The orchestrator cost $47.56 for the 8 addendum runs, against $36.55 for the original 8. Most of the difference is in Gemma's runs, and most of that in the two T2 runs that reached a review, at $8.32 and $10.91. With 2 runs per ticket and coder, the gap does not measure what the fix costs.

The addendum's results page, built by the harness from the 8 run records with no hand edits, is at https://www.emadibrahim.com/model-bench/addendum.html. It shows the untouched code's 3/18 and 1/9 for the two halted Qwen runs.

Surprises and what broke

These are the harness failures worth passing on.

1. A coder walked out of its worktree and into my real checkout. On Nov 18 a local coder guessed where my real checkout lives, worked there for 50 minutes, committed on the real main and ran a git checkout that discarded uncommitted work in three unrelated files. Nothing was pushed, and the 92-line diff was recovered from its log. Telling a coder to stay in its directory is not containment. The sandbox is the fix, and closing its gaps took five rounds of adversarial security review.

2. Output-token counts were far too low, because Claude Code's stream repeats a small early usage snapshot on every message event; the real totals are in the result event that ends each segment. In the log that exposed the bug, the parser counted 376 output tokens and the final usage record 13,633, about 36 times as many. A second bug turned up while this article was checked: the Antigravity CLI's output count already includes thinking tokens, and the harness added them again. Correcting Neon's six run records, here and on the results page, lowered its coder cost from $3.43 to $2.88 per run.

3. The quota detector would have killed runs for reading source code that contains usage-limit phrases. It now reads only error, system and diagnostic output.

4. The hang alert never fired, because retry loops are chatty. A stuck Gemma run logged a retry notice for every 5-minute timeout, so the watchdog saw life. A liveness check has to measure progress, not bytes. The alert's timer now ignores retry notices and other status events.

5. A guard burned 42 attempts in seconds. It refused to start a run if the repository holding the pipeline's skill files had moved to a new commit since the batch began, and another agent's rollout moved it to one mid-batch without touching anything the pipeline uses. 14 queued runs used up all 3 of their attempts almost instantly. A check that runs before the work starts must pause the batch, never fail the run. It does now.

6. The sandbox broke things that only show in real use. A loopback deny broke the project's own tests, and a write deny on a SQLite database in WAL mode crashed a CLI at startup with an error that looked like "no quota".

7. The toolchain moved under the benchmark. In five days on a shared machine, Claude Code updated itself at least three times and another agent replaced the Codex CLI. An upstream change moved the pipeline's reviewer model setting mid-batch, one of 4 accepted changes to its pinned files, so the harness now pins gpt-6.1-sol. All 26 tool-version records, kept from the eleventh counted run on, note a version that differs from the batch's start.

8. The audit was wrong three times early, and arguably once late. In the warm-up it voided runs for a path followed by a full stop, a hallucinated path and a quoted home-directory path in test fixture data; a reaudit command recovered one, a valid Qwen run with 49 minutes of coder time. The late case is run 11.

Limitations

Appendix B is the full list of caveats. The ones that matter most: a small sample in one JavaScript repository; Claude on both sides; a context window almost four times the real one for the local models, which the addendum's 8 runs are too few to settle; a sandbox, toolchain and scoring rule that changed during the batch; partial isolation, with my own plugins active for the coders; and a warm-up plan close to the answer, the only ticket on which local runs shipped among the 36.

What's next, and how to reproduce it

I keep a big hosted model as the coder. I will try the small hosted model on easy tickets.

This data cannot yet say whether the local models do better with their real context window over more runs than the addendum's 8, whether Gemma ships with a longer budget, whether a harness built for local models changes the picture, or whether any of this holds on a second repository or under a different orchestrator.

The harness's source is at https://github.com/eibrahim/model-bench, under the MIT licence. It needs macOS for sandbox-exec, Node 22.18 or later in the 22 line (or Node 23.6 or later), Claude Code for the orchestrator, the Codex CLI for the reviewer, the coder CLIs you want to compare, and Ollama for local models. You supply your own orchestrator pipeline as a Claude Code skill that follows the contract in the README. My tickets and hidden tests are private, so you bring your own: a Node.js git repository with an origin remote and an npm test script, and for each ticket a kit with the ticket text, the commits before and after the fix, and hidden *.test.js tests for Node's built-in test runner that fail before the fix and pass after. Then, from the harness checkout:

bin/bench kit-check <ticket>     # prints parentFailed, mergedPassed and fullSuiteMergedPassed; it exits 0 either way
bin/bench plan <ticket>          # run it once per ticket and keep that plan for the whole batch
bin/bench batch init --tickets <a,b,c> --coders opus,astra,neon,haiku,qwen,gemma --reps 2
bin/bench batch run              # one run at a time, with retries, pauses and alerts
bin/bench report                 # build the results page from the run records

A usable kit has all three flags true. The kit check names the tests that failed before the fix but not why, so check yourself that they fail on behaviour and not on an import error.

Not everything on my results page comes from these five commands. bench reaudit re-ran the audit of one counted run and bench rescore the hidden tests of two. The 53 set-aside attempt records were moved by hand to a separate list in the batch file, which scoring skips, Neon's six run records were corrected by hand (item 2), a one-off script outside the harness added the size rank, and the root-cause sentences were written into the run records after the trace analysis.

The full results page, with every run, is here: https://www.emadibrahim.com/model-bench/results.html

Appendix A: method notes

Hidden tests are staged only after every process group the run started has stopped; if one survives, the run is void (a process that detached from those groups could outlive this, an accepted risk). The tests are copied into the worktree, run with Node's test runner and removed, under the OS sandbox's profile in 25 of the 35 runs with a hidden-test score.

The watchdog checks the logs once a minute. It emails me when neither log has shown progress for 10 minutes, kills a run at the 360-minute cap, and voids a run when a live log shows a capacity fallback, an exhausted quota or an unexpected Claude model.

Prices are API-equivalent: tokens multiplied by list price. For the Claude routes the harness takes the cost Claude Code reports, within 1% of list price for Fable and Opus on every run. One interrupted Haiku pass reported none and is priced from its tokens; Astra and Neon are priced from tokens. Neon ran on a subscription. Its $2.88 coder estimate uses Gemini API prices. Fable supervision adds $5.03 per run. The list prices were checked against the official pricing pages on Nov 22, 2026:

ModelInputCache readCache writeOutput
Fable 5.2$8$0.20$16$40
Opus 5.5$4$0.20$8$20
Haiku 5.5, prompts up to 100,000 tokens$0.10$0.01$0.20$0.50
Haiku 5.5, longer prompts$0.50$0.05$1$2.50
gpt-6-astra$10$1$12.50$50
Gemini 4 Neon$3$0.15none listed$15

Prices are in dollars per 1 million tokens; local coders are $0. Claude cache writes are priced at the one-hour rate, the only kind these runs wrote; the Astra logs recorded no cache writes.

Traces. The harness turns the parsed logs into one trace per run; Neon's tool calls and coder token counts are missing from its traces. Traces explain failures and are never used for scoring.

The number check matches each number written in digits against facts computed from the run records or sourced by hand, and checks the main tables cell by cell; it does not check counts in words, dates, code or what a sentence claims about a number.

Appendix B: the full list of caveats

  • Small sample, one repository. 6 runs per coder, 3 tickets, 2 repeats, one JavaScript service. Changing the outcome of one run moves a coder's rate by about 17 percentage points, and other stacks could rank the coders differently.
  • The orchestrator does more than route. Fable wrote the plans and every brief and decides when a review is CLEAN. It reviewed the diff itself in all 26 runs that reached the reviewer, sent its own findings to the coder in at least 13, and some briefs name the exact lines to change or give ready-made code: on T1 the first brief spelled out the production change in all 12 runs, two of the three local runs that shipped contain test assertions from fix briefs word for word, and in one Fable listed every step after Gemma's first pass made no edits. Fable assigned every code edit to the coder. The audit flagged no orchestrator edit in a counted run. Opus and Haiku share its vendor and CLI, and may simply read its briefs better.
  • The reviewer is not neutral ground either. It is an OpenAI model, like Astra, which used the fewest review rounds of the four hosted coders; six runs cannot say whether that is the coder or the pairing. Its memory feature was never confirmed off.
  • Context was not walled off. The issue tracker's credentials file, the CLIs' session folders with earlier transcripts and the web stayed reachable, and the Antigravity CLI keeps an index of past sessions with the text of each brief and reply; the sandbox made it read-only, not unreadable, and it was updated between runs, so each of Neon's three second-repeat runs began with its first run on the same ticket in the index. The logs show no tool call that ran the tracker's tool, the code host's tool, curl or wget, and no coder tool call that named the index or another session's files, but they cannot show what a CLI passed to its model on its own.
  • My own plugins were active for the coders. A ruleset that asks for the least new code shows in all 56 passes of the four Claude Code coders, all 13 Astra passes and 14 of Neon's 16 passes (the other two are stored in a form I could not read). A development-workflow guide was loaded in the same 56 passes and opened by the Astra coder itself; the 14 readable Neon conversations do not contain it, and the other two are unknown.
  • The first 10 counted runs had no OS sandbox and no full toolchain record, though their orchestrator logs name its Claude Code version. Neon and Haiku ran all theirs inside it, as did all eight local runs on T2 and T3. For the local models that split follows the tickets: all four local T1 runs, including the only three local runs that shipped, predate it.
  • The toolchain and the pipeline's files changed during the batch (item 7 under what broke).
  • The four Claude Code coders had different inventories: 26 tools and 80 skills for the local passes, 35 tools and 99 skills for Haiku, and 27 or 35 tools and 98 skills for Opus.
  • One machine and one recorded tag per local model (Qwen at Q4_K_M, Gemma in Ollama's MLX build); the run records hold no weight digests. Other hardware or quantization would change speed and maybe quality.
  • The 3-hour cap is a choice. A longer budget might have shipped some of Gemma's capped runs; I do not know. None of its four capped runs among the 36 reached a review. One capped addendum run did, and ran out of time with two findings open.
  • Prices are API-equivalent, not what I paid; most of this ran on subscriptions. Astra is priced at the short-context rate; its largest request in Codex's session records was 127,109 input tokens, under OpenAI's 272K threshold for the higher rate.
  • Not counted at all: the reviewer's tokens and cost, GPU power, the hardware and my time. The $263.06 also leaves out Fable's three planning runs ($9.57 by their logs), the one-line account check sent to the orchestrator model before each run ($13.64 for the 36, by Claude Code's own session records), the shake-out runs and every voided or excluded attempt.
  • The local token totals are approximate. The 9 killed local passes (8 at the coder cap, 1 by the orchestrator's two-hour limit on a background command) wrote no final usage record, so their output counts as zero. The input figure is the request size Ollama reports when a response starts, not the tokens the server then processed, and in Qwen's capped runs it kept growing past the context window. Read the local figures as the client's records, not as a server-side count.
  • Review time and finding counts are left out, because the harness could not always match the reviewer's logs to a run. I report rounds.
  • The figures here relabel the results page, the harness's own output, which I did not change: no "best" badge for near-ties or coders that missed a run, labels for what each chart counts and times, and a marker for run 11. The page says the root causes were written by hand; they came from the trace analysis.
  • Nobody was blind. The run folder's name includes the coder, and the orchestrator and the reviewer can see paths.
  • Claude wrote the hidden tests, and they may lean toward the original authors. The merged fixes were probably written by Claude or Codex agents, and Fable 5.2 subagents derived the tests from them and wrote the second fix each suite was checked against. I read none of the hidden tests myself.
  • One rule changed mid-benchmark, between coders. Until Nov 21 a coder's outside read voided the attempt, which was run again; after that it scored as a fail. Opus, Astra, Qwen and Gemma made all 24 of their runs under the old rule, Neon and Haiku all 12 of theirs under the new one. Of two Qwen attempts on T2 voided for outside reads, the first (item 1) would be void under either rule, as the orchestrator's own commands also named forbidden paths. Holding the hand exclusions in the last item fixed, the second would instead have been a failed run in place of its retry (run 3): Qwen would still have shipped 1 of 6, at $22.88 instead of $21.88 per shippable run, with 30 of 56 hidden tests passed instead of 33 of 74. Haiku's run 11 got no retry, and Haiku's 4 of 6 and its cost per shippable run depend on how a retry would have ended.
  • Three counted runs follow a voided attempt still in the batch file's attempt list: Opus's first T1 run (the full-stop path match in item 8), Opus's second T2 run (the reviewer had no quota left in the third review round) and Qwen's second T2 run (an outside read). Both voided Opus attempts had reported CLEAN, but their hidden tests never ran. Qwen's first T2 run (run 2) reruns the attempt in item 1.
  • Two runs were rescored: Opus's and Astra's first T3 runs, failed by the sandbox's missing utility exception, not their code (the sandbox section).
  • 53 attempt records were set aside by hand: 45 that never started a run (42 refusals from the bug in item 5, 3 from a GPU check while the previous model was still loaded), the attempt in item 1 (rerun as run 2) and seven cut short or voided by harness or infrastructure faults. Qwen's first T1 run, which shipped, followed three earlier attempts, one of which ran 41.8 minutes and reported CLEAN after one review round before the audit voided it. Gemma's second T1 run followed two attempts stopped while requests were timing out (item 4). Four more attempts that were cut short left a run folder but no record, and Qwen's third earlier attempt before its first T1 run is one of them. So the run in which Qwen escaped into my real checkout is not one of the 36.