My AI coding agents spend most of their time waiting
I timed every second of an overnight run where my Claude Code agents built features for Note to Self, my iOS app for texting yourself notes.
- 11 features in 14.6 hours, one at a time.
- The model only worked 26% of the time.
- After a few changes: twice as many features in the next run.
The setup
One Claude Code session is the manager. It doesn’t write code. For each feature it starts a fresh agent and takes it through the same steps:
- The agent writes a plan, and the manager approves it.
- It builds the feature, with UI tests and a screen recording of the simulator as proof.
- Two reviewers check the change at the same time: a fresh Claude Opus agent and GPT running in Codex.
- The agent fixes what they found and proves the feature again.
- The manager merges it and starts the next one.
Nothing ran in parallel. One agent and one simulator, for 14.6 hours.
How I measured it
The analysis agent got every transcript from the night: the 11 feature agents, the 11 Opus reviews, the 11 Codex logs, the manager’s own session and the git log. It split the night into phases from the manager’s transcript (plan, build, review, fixes), and then put every second of each phase into one bucket:
- A tool call lasts from its
tool_usetimestamp to itstool_result, and a background command until its task notification. - When calls overlap, the more expensive one wins: the full UI suite, then single UI test classes, unit tests, builds, simulator checks, everything else.
- A second inside a turn with no tool running is model time.
- A second after the agent ended its turn, waiting to be woken up, is idle.
- A shell command is classified by its description first and its command second.
It expects about 10% of the time to land in the wrong bucket at the edges, mostly between UI tests and simulator checks. Their total barely moves.
Where the time went
Two thirds of the night was the simulator. The model is fast. Proving the work is slow.
The details were more interesting than the totals:
- Unit tests are almost free: 47 runs took 13 minutes in total.
- UI tests are not. The agents ran single test classes 191 times while iterating, which took 198 minutes, and the full suite 20 times, at 6 to 15 minutes a run.
- They recorded about 73 takes for 11 proof videos, mostly by driving the app by hand from scratch tests and trying again when a frame looked wrong.
- Waiting for review cost about 4 minutes per feature. Opus took 2 to 5 minutes, GPT about 1, and they ran at the same time.
- The fix rounds after review took 289 minutes, a third of the night, and most of that was more simulator work.
- One feature bundled 8 small platform items and took 241 minutes, 28% of the night on its own. Its fix round alone ran longer than three of the other features did from start to finish.
Per feature, the fix rounds and the one oversized feature stand out:
- Plan
- Model
- Tests and builds
- Simulator checks, video
- Review wait
- Fix round
Table
| Plan | Model | Tests and builds | Simulator checks, video | Review wait | Fix round | Total | |
|---|---|---|---|---|---|---|---|
| UI test speed-up | 20 | 3.1 | 43.8 | 0 | 4 | 8.2 | 79 |
| Keyboard on launch | 1.2 | 3.5 | 12.5 | 1.4 | 4.4 | 6.3 | 29 |
| Share extension | 3.1 | 12.2 | 13.5 | 5 | 5.3 | 28.5 | 67 |
| Links and previews | 3.8 | 12.1 | 10.4 | 5.1 | 4.4 | 27.8 | 63 |
| Siri shortcut | 1.4 | 6.9 | 3.5 | 13.9 | 3.9 | 8.7 | 38 |
| Spotlight | 2.5 | 8.9 | 4.6 | 32.1 | 4.4 | 11.8 | 64 |
| New Note control | 1.4 | 6 | 6.3 | 8.7 | 4.2 | 19.8 | 45 |
| 8 platform items | 1.2 | 40.2 | 36.6 | 75.5 | 6.1 | 82.6 | 241 |
| Paste pictures | 2 | 10.4 | 10 | 19.6 | 5.8 | 21.9 | 69 |
| Navigation | 2.9 | 8.9 | 30.7 | 7.9 | 4.6 | 60.5 | 115 |
| Recently Deleted | 2.9 | 12.9 | 5.3 | 25 | 4.4 | 13.3 | 64+ |
The last feature’s fix round was still running when the analysis started, so its bar stops early.
The reviews were worth it. They raised 127 findings, and about 36 of them were real bugs. What they cost is the proof that has to run again after every fix.
I had already made the tests faster
The first of the 11 features was the UI test suite itself. 45 tests became 12 user journeys, each launching the app once and starting from seeded data instead of typing its own. The suite went from 875 seconds to 375, all green.
Two ideas from that feature didn’t make it:
- Speeding up animations with a launch argument saved 2.1%. The Opus review pointed out that two runs of the same suite already differed by about 7%, so the gain was noise, and it was dropped.
- Running the suite on three simulator clones at once took 274 seconds, but a motion test failed under the load, so the suite stays serial.
And UI tests still took a third of the night. A suite that takes 57% less time helps less than you’d think when it runs 20 times a night, on top of 191 runs of single classes.
What I changed
The analysis ranked the causes by minutes lost. These are the ones I acted on:
- Two features at a time, each in its own git worktree with its own simulator, paired so they touch different parts of the app. It is the only change that goes after the simulator share as a whole, because one feature’s tests no longer hold up the next one.
- Reviews start the moment the code is committed, while the tests run, so review fixes and test fixes land in one round.
- One proof video per feature, recorded around a committed UI test. The one feature that already did this needed 0.8 minutes for its video.
- The full UI suite once per feature, after the last commit, and only the affected tests while iterating.
- A fresh build before every test run.
One agent lost two video attempts to
test-without-buildingrunning a stale build. - Nits skip the fix round. 56 of the 127 findings were nits, and each one got its own cycle of reproduce, fix and rerun. Now they wait for one polish pass at the end.
What it should buy
The analysis estimates that two features at a time roughly doubles how many fit in a night, and that the other changes cut 30 to 40 minutes off an average 80-minute feature. Next overnight run? Twice as many features done. I’ll measure it the same way.
Measure your own
Paste this into Claude Code:
Read my Claude Code transcripts in ~/.claude/projects from the last 3 days. Use the tool call timestamps to split the wall-clock time into model, builds, tests, checks and waiting. Show a table.
If your agents build, run tests or drive a browser, I bet the model isn’t your biggest slice.