Contents13 of 15Download the PDF (892 KB)

Before You Blame the ModelPart IV · The Truth: knowing if anything worked

Chapter 12Runtime

Speed lives outside the model

My agent spent 47 seconds parsing files before it asked the model a single thing.

2 min read

Agents feel slow, and everyone blames the model. Then you put timestamps on every step and the picture can change completely. Mine was reading and parsing 738 source files, twice, on every run before the first request. A cached, verified index halved the time to first request, from about 88 seconds to about 44.

Once I started looking, the harness was slow everywhere:

  • The sandbox. Each command ran in an isolated sandbox with about 425 mounts. Cutting that to 7 took per-command overhead from 2.7 seconds to 0.5.
  • The tokenizer. Counting tokens against a tokenizer on another machine took 0.65 seconds a call. On the same machine, 0.08.
  • The "10 seconds a turn" that wasn't. A speed number I'd been quoting came from a proxy's latency. The timestamps in my run logs said a turn really took 36 to 79 seconds: 9 to 22 in the model, 18 to 48 in my own code, and the rest in the gaps between them.
Time per turn, model versus harness
Fig. 12. Where a turn's time actually went, from per-step timestamps in my run logs rather than a proxy's latency. Whole turns took 36 to 79 seconds. Conditions: one coding task, one local model.

#More agents is not free speed

On one GPU serving my small open model, one agent generated about 53 tokens a second with a short context. Running four agents at once dropped each of them to about 31, roughly 40% slower. Growing a single agent's context from 4,000 to 60,000 tokens cost it only about 13%. Total output still went up, to about 2.3 times one agent's, so for throughput more agents can be worth it. But if you're waiting on one agent to finish, sharing the model hurt it far more than a long context did. Your hardware will differ, so measure it instead of assuming.

Even scores depend on the box. Anthropic reported a 6-point spread on Terminal-Bench 2.0 from infrastructure settings alone (Anthropic, "Infrastructure noise", Feb 2026). Numbers from a different machine come from a different experiment.

CodePythonSteal this · a per-turn timing log
t0 = time.monotonic(); resp = model(request)
t1 = time.monotonic(); result = run_tool(resp)
t2 = time.monotonic()
runlog.write(turn=n, model_s=t1 - t0, harness_s=t2 - t1,
              prompt_tokens=resp.usage.prompt_tokens)
Before You Blame the Model13 / 15