All essays

An Approval File Any Review Agent Can Follow

Put your approval rules in Git and take them with you when you switch review agents.

Agents can open pull requests faster than a team can review them. Let a review agent handle the typos and test fixture updates, and the humans have more time for the migration they actually need to talk about. Teams are already doing this. But who told the bot which changes were routine?

In my own repos, I can see who merged a PR right in Git. I shouldn’t have to go spelunking through a settings page to find out why a bot was allowed to approve it.

A docs change is routine in one repo. In another, someone follows those docs to deploy to production. The humans who maintain the repo know that difference. They should be able to write it down once.

Put the policy in Git

Put the rules in Git. If someone wants to let the bot approve changes to a new directory, they can open a PR and explain why. Six months later, you can find that conversation in the history.

Anthropic’s Claude Approvals already reads .claude/approvals.yml from Git. The rules say when Claude may approve and how many human approvals a change requires. That answers where to look. If your next review agent uses a different format, you have to rewrite the rules you already got working.

The approval policy is the team’s asset. Those rules come from knowing where your tests leave gaps or remembering which changes have broken a release. I want to be able to change review agents and bring those decisions along.

Claude Approvals policy reference

Start with paths

I’m proposing an open standard for the APPROVAL file and the rules review agents follow when they read it. Put the file at the repo root. In the example below, changes to CI, database migrations, or the APPROVAL file itself always go to a human. If a PR touches only docs and the required checks pass, the bot can approve it. Throw a migration into that same PR and it goes straight back to a human. When the path rules leave it open, how does the bot tell which code changes are safe enough to approve?

Read the draft spec

Classify the gray area

Can the bot approve this PR? The answer has to be yes or no. Same inputs, same decision. When the path rules give you a maybe, look at what the change actually does in this repo before you decide.

Two PRs touch the same API file. One tidies up a helper. The other breaks a client. Approve both and you’ve waved through a regression. Send both to a human and you’re back to asking someone to review every little refactor.

When the path rules leave a PR undecided, ask a classifier what you’d ask a reviewer. Does this break an existing API client? Does it give a caller a new permission? The team picks the model and sets how confident it has to be. It needs a confident no on every question. If it lacks the code or context to tell, or it’s unsure about even one answer, send the PR to a human.

APPROVAL
version: 1
deny_paths: ["APPROVAL", ".github/workflows/**", "db/migrations/**"]
approve_paths: ["docs/**"]
classification_approval:
  model: your-classifier
  questions:
    - id: api-compatibility
      question: "Does this change break existing API clients?"
      max_yes_score: 0.05
      min_no_score: 0.90

Choose a classifier and thresholds that fit the repository.

Approve exactly what you checked

Read the policy from the target branch. A PR doesn’t get to write its own rules. The required checks have to pass, and the approval covers the exact base and head commits and the policy used to review them. Push another commit or move the target branch and the merge gate needs a fresh decision.

This is a draft

If you maintain a repo, tell me which PRs you already trust a bot to approve. Which rule would you have trouble writing down? If you build review tools, show me where your implementation and someone else’s would make different calls on the same PR. That’s the stuff to work out while this is still a draft.

Read the draft spec