Context
Cadence sits inside a company where AI agents already co-authored a large share of commits, but delivery quality depended on ad-hoc prompting. I designed it as a delivery system for coding agents and wrote it myself, then ran it on real repositories. It is for the engineers and leads who have to trust what an agent hands them.
The problem
AI agents wrote code fast, but review gates were bypassed. The target repos had no required CI checks, so nothing stopped a confident but wrong change from reaching a reviewer.
I wanted agent delivery that is verifiable, bounded in cost and gated by humans, rather than one that relies on the model behaving well.
What I did
I built a state machine in Python: intake, spec, architect, tests, build, verify, integrate, report. Code decides transitions, retries, budgets and stop classes. The models only decide content.
Tests are written before code and hash-locked. An integrity scan rejects edits to locked tests, skips or suppressions, so an agent cannot make a test pass by changing it.
The verifier rejects by default. A second judge from a different model family reviews each change, and its findings must cite the diff.
I added stop classes for payments, DRM, auth, migrations and tenancy, which need a named human waiver. Each story also has budgets for tokens, dollars, active hours and CI minutes, and model runs get no GitHub or Jira credentials.
Then I ran it on a real 48-story feature spread across 7 repos and wrote regression drills for the gate rules.
Key decision
The key choice was to put correctness in code and keep models out of control flow. A prompt can ask a model to behave. Code can refuse to proceed.
The trade-off I accepted: I stopped replaying browser suites at every milestone, because a bug-fix merge cannot take two days. I kept story-level evidence instead.
Result
The feature run verified 46 of 48 stories across 7 repos, with about $737 of recorded model spend. I dropped the other 2 stories as unverifiable. The first dry run, a single story, completed verified for $39.28, and its spec step caught 3 real defects in the human-written story.
These are dry runs. Nothing has been merged or deployed yet. 40 of the 48 stories stopped at least once for a gate, and there is no live pull request flow so far.
What I learned
I would again make the gates code and keep the human at the gate. I would also set up required CI on the target repos and a pilot repo before the first run, because the next step is one production story behind the same gates.
Stack
- Python
- Claude Code
- Codex
- Playwright
- Three.js
- Git
