Back to Research

Code Review Agents Need Receipts

A practical review workflow for Cursor teams using agents, review receipts, MCP boundaries, and shared rules.

A Summer Morning, landscape painting by George Inness (1882).
ReviewRogier MullerJune 21, 20266 min read

This research library uses AI-assisted source research and drafting. Linked sources support product claims; analysis and proposed exercises are our interpretation. Unless an article documents a test and its results, do not read it as a hands-on review or an independently verified benchmark.

The best AI tool for code review is the one your team can constrain, audit, and teach; for Cursor users, that usually means combining Cursor Agent with explicit review receipts and narrow tool access. AI code review works best as a governed workflow, not as a magic second approver.

Agentic coding governance is the set of rules, permissions, review habits, and training that lets coding agents help without quietly changing your engineering standards. This is the practical core of an AI coding workshop: make the review path repeatable before you let more agents touch production code.

Pick the workflow before the tool

Start by deciding what the agent is allowed to review. A good first scope is boring but valuable: changed files, tests, migrations, API contracts, security-sensitive diffs, and missing documentation.

That matters because most code review tools are better at finding patterns than owning judgment. Cursor can inspect a branch and help reason through a diff, but your team still needs to decide what counts as a blocker.

Watch for comparing tools by demo output alone. When someone asks what is the best ai tool for code review, the more useful answer is: the one that leaves a review receipt your human reviewer can verify.

For a real repo, make the agent produce three things before a reviewer reads its comments: what it inspected, what it did not inspect, and what evidence supports each concern. That turns code review ai from a stream of suggestions into something your team can audit.

Put review rules where agents actually read them

Keep durable review rules in repository context, not in a chat prompt someone has to remember. In Cursor, that can mean a .cursor/rules/*.mdc rule for review behavior, plus an AGENTS.md file for cross-agent boundaries that also make sense to Claude Code or Codex.

The reason is simple: agents follow the context they can see. If your conventions live in a wiki, they may as well be folklore during an IDE review.

A practical AGENTS.md boundary might say that agents can suggest changes to billing code, but cannot apply migrations, rotate secrets, or mark a pull request as ready without a human owner. Nested AGENTS.md files are useful when one package has stricter rules than the rest of the repo.

Don't write one giant root instruction file. Broad rules become vague rules. Put local constraints close to the code they govern.

If you are formalizing this across multiple teams, pair the workflow with Governed AI Coding at Team Scale and the broader agentic coding governance topic.

Keep MCP access narrow during review

Model Context Protocol, or MCP is an integration standard that lets agents connect to external tools such as GitHub, issue trackers, docs, databases, and internal knowledge systems. For review work, treat MCP access like production access: useful, scoped, and logged.

A review agent often needs GitHub pull request metadata, test results, and maybe architecture docs. It usually does not need write access to Jira, customer data, deployment systems, or a production database.

This matters because an llm code review can become more risky when the agent has broad tools. The output may look like a comment, but the agent may also be able to fetch private context, mutate state, or trigger workflows.

Don't give every coding agent the same integration bundle. Use read-only servers by default. Add write tools only for narrow jobs, and make those jobs produce a receipt.

Train reviewers to ask for evidence

Engineering team training should teach reviewers how to interrogate the agent, not just how to invoke it. A good reviewer asks: which files did you inspect, what assumptions did you make, which tests did you run, and what would change your conclusion?

That matters because agents can be confidently incomplete. A review that misses a generated client, a migration, or a feature flag may sound polished and still be wrong.

Don't treat agent comments like peer comments. Human reviewers bring ownership, context, and accountability. Agents bring speed, breadth, and tireless pattern matching.

A small team skills exercise works well here. Take one merged pull request, ask Cursor Agent to review it with your receipt template, then have engineers mark each finding as useful, duplicate, unactionable, or wrong. Do that for five PRs and you will learn more than you would from a vendor comparison spreadsheet.

Copy this Cursor review receipt rule

Paste this into .cursor/rules/ai-review-receipt.mdc, then tune the checklist to your repo. The goal is not to make the agent verbose. The goal is to make every review traceable.

---
description: Require an auditable AI review receipt before agent-generated review comments are trusted.
globs:
  - **/*
alwaysApply: false
---

# AI review receipt

When asked to review a pull request, branch, or diff, produce a review receipt before giving recommendations.

## Review scope

- Branch or diff reviewed:
- Files inspected:
- Files intentionally skipped:
- External context used:
- MCP tools used, including read or write capability:

## Checks performed

- Build or typecheck evidence:
- Test evidence:
- Security-sensitive areas checked:
- Data migration or schema impact:
- API, event, or contract changes:
- Observability or logging impact:
- Documentation impact:

## Findings

For each finding, include:

- Severity: blocker, should-fix, consider, or note
- Evidence: file path and line range, test output, or documented rule
- Risk: what could break if ignored
- Suggested fix: the smallest safe change
- Confidence: high, medium, or low

## Boundaries

Do not approve the PR.
Do not apply migrations.
Do not modify secrets or deployment config.
Do not use write-capable MCP tools unless the human reviewer explicitly asks.
If evidence is missing, say so instead of guessing.

This rule is intentionally plain. Your team can add package-specific checks in nested rules or local AGENTS.md files.

Common questions

  • Can an LLM approve a pull request?

    An LLM should not be the final approver for production code. It can summarize risk, find missed tests, compare a diff against repository rules, and draft comments, but approval should stay with an accountable human reviewer. A safe default is agent suggests, human decides, CI verifies.

Further reading

Start with one receipt

Do not start by standardizing every agent. Add the review receipt rule to one active repo, use it on five pull requests, and let the evidence show you which guardrails your team actually needs.

Related training topics

Learn more

Learn more

Learn more

Learn more

Review is one step in the methodology.

Related research

Practise Review with the team

Book a date if you already want one.

See training
Best AI Code Review Workflow for Teams | Cursor Workshop