Course outline
The CTO's playbook for AI coding agents · Module 2: Measuring impact
A metrics stack that holds up: five layers, one picture
Delivery, flow, quality, developer experience and cost: a layered metrics stack that shows whether agents help, where they hurt, and what it costs. Plus how to instrument each layer.
Lesson 6 / 20 · ⏱ 9 min
No single number tells you whether coding agents are working. What holds up under scrutiny is a small stack of layers that check each other: if speed goes up, quality should not go down; if quality holds, developers should not be burning out to hold it; and the whole thing has a price.
The stack
What each layer is for
| Layer | The question it answers | Why agents make it matter |
|---|---|---|
| Delivery | Are we shipping more, and more reliably? | The classic DORA four. The bottom line for engineering throughput. |
| Flow | Where does work wait? | Agents speed up writing code; the bottleneck usually moves to review and testing. Flow shows where it went. |
| Quality | Is faster also worse? | Generated code can pass review and fail later. Rework and escaped defects catch the delayed bill. |
| Developer experience | Is the speed sustainable? | Reviewing large AI diffs is tiring. A survey catches burnout and distrust before attrition does. |
| Cost | What did it cost per unit of value? | Tokens and seats are a new variable cost. Module 5 goes deep; here you just need the ratio. |
Instrument it in four moves
- 1
Week 1
Reuse what you have
Delivery and flow come from your pipeline and forge. Most teams can compute lead time, deploy frequency, cycle time and review wait from existing events with a script, before buying anything.
- 2
Week 2
Tag agent-assisted work
Add a lightweight label on PRs (a checkbox in the template, a commit trailer). Self-declared and imperfect, but it lets you slice every other metric by agent use.
- 3
Week 3
Define rework and escaped defects
Pick a rule and keep it: e.g. lines changed again within 21 days, bugs found in production linked to the PR that caused them. Consistency beats precision.
- 4
Week 4
Add the human and cost layers
A short quarterly survey, same questions every time. A monthly export of AI spend divided by merged changes. Then freeze definitions for at least two quarters.
If you’re also re-designing your lifecycle around agents, the AI-native SDLC guide covers where agents plug into each stage; this stack is how you check that it paid off.
How solid is your stack today?
📊 Metrics stack readiness
1. We can compute lead time and deploy frequency per team from pipeline data without manual work.
Not at allFully2. We can see how long PRs wait for a first review, and how that changed since agents arrived.
Not at allFully3. We have a stable definition of rework or escaped defects, applied the same way every month.
Not at allFully4. We can tell which PRs were agent-assisted, at least approximately.
Not at allFully5. We run a developer experience survey with the same questions every quarter.
Not at allFully6. We know our monthly AI spend and can divide it by merged or deployed changes.
Not at allFully
Before you move on
✅ Key takeaways
0 / 5 completed