How it works
A daily retro that fixes the agent workflow
Published · 7 min read· Anton Shubin

In short
- Have every agent run write down what slowed it, with a kind and the minutes it cost. Then one run a night reads that list and files the fixes.
- My retro changes no code. It may only file issues, close lessons and ask for a revert, and the engine does the fixes like any other work.
- In 3.7 weeks my runs recorded 1,253 lessons, 16,285 lost minutes. 51 of the fixes they point at are merged or done, and none was reverted.
- Merged issues per $100 rose from 10.1 to 12.7 in three weeks, then dipped to 12.6 in the fourth. I cannot prove the retro did that, and the post says why.
To improve an AI coding agent workflow over time, make every run write down what slowed it, then have one run a day read that list and turn the worst of it into issues. That is my daily retro. It runs at 00:05, it reads my engine's records, and it changes no code: it files issues, and the engine fixes them like any other work. In 3.7 weeks my runs recorded 1,253 lessons, worth 16,285 lost minutes.
The retro is the only meeting I have ever liked. Nobody talks, it costs about $1.86, and it is over before I wake up.
What does the retro read every night?
Issuemill
runs Claude Code headless on GitHub issues
in 11 of my projects. Every run may record a lesson: something that cost it time, with a kind, the
minutes lost and the tokens spent. "CI took 25 minutes" is a lesson of kind ci-wait. A reviewer
that sent the work back is a rejected-review. A task description that sent the agent the wrong way
is a wrong-brief. Every lead run also gets the open lessons in its own instructions, so the next
run knows about the trap before it steps in.
The engine adds one kind by itself. When Claude Code refuses a command a run tried, the engine
records it as a denied lesson, so a blocked tool shows up in the list even if the agent never
mentions it.
At 00:05, just after the daily spending limit resets, the retro starts. It reads:
- the open lessons, grouped by kind, with the
deniedones first; - every run of the day, with its cost, its turns and how it ended;
- the queue, the merge checks and the times main went red after a merge;
- the engine's timers and its own log, to see that everything that should have run did.
Here is what the runs recorded most often, from 6 to 30 November 2026:
| Kind of lesson | Old engine, 6 to 19 November | New engine, 19 to 30 November |
|---|---|---|
| Waiting for CI | 255 | not in the top five |
| Rejected review | 173 | 61 |
| Wrong brief | 109 | 22 |
| Command refused | 71 | 21 |
| Rework | 64 | not in the top five |
| Slow implementer | 63 | 16 |
| Merge conflict | not in the top six | 17 |
| All lessons | 1,053 | 200 |
On 19 November I moved the engine to a rebuilt one, which is why there are two columns. The second column covers fewer days, so only the order of the rows compares well.
What may the retro change, and what may it only file?
It may change nothing in code. That is the whole design. A run that reads every failure of the day and then edits the engine that produced them is a run I would have to review every morning, and I do not review code before it lands.
So the retro gets a short list of things it may do:
- File a GitHub issue for every kind of lesson that cost at least 30 minutes in the last 7 days,
one issue per kind, at the label
p1-tooling. If an issue for that kind is already open, it comments there instead of filing a second one. - File a refused command or a table it cannot read before anything else, even with no minutes measured. A blind spot hides waste, so it goes first.
- Close a whole kind of lessons once its issue is filed or its fix has merged, with the link as the reason.
- Check each fix merged in the last week against the numbers before and after it, and if a fix
made quality worse, file a
p2-highissue to revert it, even when the fix saved money. - Write each decision into a log: kept, reverted, filed, or nothing to do.
It reads the database with read-only queries, and it scans every issue body for secrets before it posts. Waste below the 30-minute bar is not filed. It goes into the daily digest instead, where I can see it without it costing an agent any time.
The fixes themselves go through the same queue as everything else: an implementer writes them, a reviewer agent checks them, and code merges them when CI is green. The retro is a manager who can only write tickets. I have met worse managers.
Which of its fixes stayed, and which were reverted?
When the retro closes a lesson, the reason holds the link to the issue or PR that deals with it. The closed lessons point at 73 different issues and PRs in 5 repositories. On 2 December they stood like this:
| What the closed lessons point at | Count | Where they stand |
|---|---|---|
| Pull requests | 25 | All 25 merged |
| Issues | 26 | Closed as completed |
| Issues | 22 | Still open |
None of the 51 landed fixes was reverted. In the whole period only one PR was reverted across all my public and private repositories, and it was not one the engine made.
I would love to tell you that this means every fix was good. It means something smaller: no fix was bad enough for me, the reviewer agent or the retro itself to undo it. The retro has a revert rule, and none of these fixes needed it.
The 22 open issues are the other half of the story. Filing is cheap. The retro can name a problem every night for a week, and if the queue has more urgent work, the issue just waits.
Did merged work per $100 move?
Yes, it went up. I cannot tell you the retro moved it. Here are the numbers per week, Monday to Sunday, with days counted in my local time, counting issues closed by a merged PR against the API list price of every run:
| Week | Merged issues per $100 | Did the retro run? |
|---|---|---|
| 6 to 8 November | 10.1 | From 8 November |
| 9 to 15 November | 11.3 | Every night |
| 16 to 22 November | 12.7 | Until 18 November |
| 23 to 29 November | 12.6 | Only from 28 November |
| 30 November to 1 December | 18.3 | Every night, 2 days only |
Over the whole period it was 846 merged issues for $6,970, or 12.1 per $100.
Three things stop me from calling this a win for the retro.
First, there is no number from before it. The retro was part of the engine from the first day, so I have nothing to compare against. The first week is three days long and already had the retro waiting for its first night.
Second, the dip is in the wrong place for a nice story. From 19 to 27 November no retro ran at all, because I had moved the engine and the new one did not get its retro until 28 November. The week of 23 November held at 12.6 with almost no retro. It was also a small week, because my 90% quota stop kept the engine idle until 24 November. So either the fixes kept working without anyone reading new lessons, or something else moved the number. I suspect both.
Third, the number is easy to fool. Split one issue into three and you get three merged issues for the same work. The retro's own instructions warn it about exactly that, and tell it to check merged PRs and changed lines per $100 as well before it calls a fix good.
The 18.3 for the last two days looks great, and two days is not a week. The next thing I check is whether the next four weeks hold that number, with the same table.
For context on what a merged PR costs in the first place, I priced all 859 of them. The 16 retro runs cost $29.74 in all, about what five median PRs cost.
What does it still get wrong?
The same lessons keep coming back. A rejected review was the second most common lesson in the old engine and the most common in the new one. A wrong brief was third and then second. Part of that is the reviewer doing its job, so this kind of lesson will never reach zero, and the retro cannot tell a useful rejection from a wasted one.
It does not know what caused what. A lesson records the link that closed it. It does not record whether the next week got better because of that fix, because of another one, or because I changed something by hand that afternoon.
It missed its own absence. For nine days there was no retro, and nothing in the engine filed that as a problem, because the thing that files problems was the thing that was missing. Now the retro checks that every timer fired, its own included. That check runs only on nights when the retro runs. I am aware of the irony.
And 109 lessons are still open. A list that never empties is the honest state of a workflow that keeps changing.
If you build your own, start with the lesson list and skip the retro for a week. Reading 50 lessons by hand tells you which kinds matter to you, and then the retro has a bar worth setting.


