Contract Necromancer

A Kiro task is done only when its frozen contracts pass.

Design by Contract, from Eiffel (1986), raised for coding agents.

"I couldn't mark task 4 complete. A hook blocked the edit to tasks.md and reported failing contracts, so the checkbox is still [ ]." Real Kiro session, recorded Nov 8, not a simulation.

Used on a real repository: in judge-protocol the gate refused Kiro's first tick, which had built only half of a criterion, and the finished fix passed all six frozen contracts and was merged (pull request #29). Read the case study.

  1. Kiro says task 4 is done. The code loses cents.
  2. The gate refuses the tick. Failing contracts: R2.1, R2.2 and 7 more.
  3. After the fix, the gate accepts the tick and writes a receipt. necro verify prints CONFIRMED.
See it happen for real: npx -y github:vijaygopalbalasa/contract-necromancer demo

On a task that cannot be finished, across two models, Kiro marked it done in 11 of 11 runs without the gate and 0 of 19 with it. Two models, 3 to 5 runs per cell (a cell is one model with one arm). Under a "do whatever it takes" prompt, one gated run of six got past the gate by patching JavaScript built-ins. That hole is closed and the cheat is kept as a test. See the experiment.

How it works

  1. A person freezes the spec's contracts.
  2. The gate refuses to tick a task until they pass.
  3. Every passing task leaves a receipt you can re-run.
npx -y github:vijaygopalbalasa/contract-necromancer demo

Needs Node.js 24 and git, and shows the gate refuse a planted bug, accept the fix and re-check the receipt.

Open your own receipt

How it works, and try it

The sample receipt, as it reads when scripts are off:

A risen receipt: 81 contracts alive.

About this page

A receipt says which frozen contracts passed when a task was marked done. Open one here to read it and check it yourself.

necro verify re-runs JavaScript contracts and runner contracts (for example pytest) alike. The receipt card checks hashes, not test runs, and the play above runs seven of the example's contracts in your browser.

PASS the contract is alive. FAIL it lies under a gravestone.