AI-assisted code review prompts
Prompt patterns that make AI code review useful by asking for concrete risks, line references, migration impact, and missing tests.
Takeaway
AI review is most useful when the prompt asks for falsifiable findings instead of general impressions.
01
Ask for risks before praise
A review prompt should ask for bugs, regressions, security concerns, accessibility gaps, and missing tests first. Summaries are useful only after the concrete findings are visible.
02
Ground feedback in files and behavior
Tell the assistant to cite file paths, line references, user-visible behavior, and the test that would catch the issue. Feedback that cannot be tied to a changed behavior should be treated as a suggestion, not a blocking finding.
03
Close with verification
After changes are made, run the same checks a human reviewer expects: lint, tests, builds, and focused manual flows. The final review note should state what passed and what remains untested.