Skip to content

Vol. X · Field Operations · X.4

Diffs, Repo Maps, Edit Formats

The coding agent's tools are not 'read and write files'. They are a repo map for orientation, grep for search, and a patch format for change. Whole-file dumps are how context dies and how reviews fail.

7 min read

Doctrine

  • Prefer apply_patch / search-replace over write_file for existing code. Aider proved this.
  • A repo map (skeleton of the tree with signatures) beats stuffing files 'just in case'.
  • Done is a reviewable diff plus tests, not 'the model said it finished'.

What to copy from Aider

Repo map, conventional commits, watch-files, and an edit format the model actually hits. Codex, Continue, Cline, and OpenHands all learned some of this. The ACI of a coding agent is the edit format. Treat it as a product surface and eval it.

Anti-patterns

  • Rewriting a 2,000-line file to change one function.
  • Grep-only orientation on a large monorepo with no map.

Related