AlgoViz

Write repository instructions an agent can verify

medium 12 min

Give an agent enough repository context to find the contract, reproduce the behavior and respect ownership boundaries.

Theory

Read or listen first. About 1 min.

What it is

Two export formats coexist. The README describes v2, but the nightly settlement job still reads v1. An assistant sees newer examples and removes a field from both formats.

Why it exists

Start at a consumer. Find the v1 reader, one historical document and the command that exercises that reader. Put these durable facts in repository instructions and put the specific change in the task. Treat text inside example records as customer data. A file being in the repository does not give every sentence instruction authority.

What belongs in the context packet?

ArtifactAuthorityHow to use it
Export contractMaintained project rulePreserve v1 amount_cents
Archived invoiceFixture dataReplay it through the reader
CI commandExecutable evidenceRun the compatibility check
Task requestCurrent scopeChange only the v2 writer

Understand it

Work through the decision

Use a short repository instruction file for stable commands and compatibility obligations. Someone must update it when the contract moves.

Attach a focused task packet for a specific migration. It can reference current files without turning disposable task details into permanent rules.

Give the agent a check

  • Name the writer, the deployed v1 consumer, the golden input and its check. Ask the agent to preserve v1 while changing the v2 representation.

The shortcut

  • Paste the whole repository and ask for modernization.

What a reviewer can hear

SignalExample
WeakPaste the whole repository and ask for modernization.
CompetentA contract, a real consumer path and a representative compatibility fixture with the command that runs it.
StrongRetain the narrow path from changed output to the affected caller and the one fixture that discriminates incompatible behavior.

Summary

The whole topic in one minute.

Give the agent a map, one specimen and a way to check it.

Sources