PR Code Review Skill

Use this skill when asked to review one or more pull requests. It covers reading diffs, forming opinions, and posting structured feedback.


Step 0 — Verify gh auth

Run gh auth status. If unauthenticated, tell the user and stop — do not attempt to read diffs or post comments without it.

Step 1 — Identify the PR(s)

Step 2 — Gather context

For each PR:

  1. Fetch the PR metadata: title, description, linked Jira ticket (if any), target branch.
  2. Read the full diff using gh pr diff <number>.
  3. For any function renamed, contract changed, or public API modified: use grep/Glob to find callers and read them. Diffs lack context — read the surrounding code.
  4. Read the PR conversation/comments using gh pr view <number> --comments to understand what has already been discussed. Do not re-raise issues already resolved in thread.
  5. If a Jira ticket is linked, use the Atlassian MCP connector to read the ticket description and acceptance criteria. If no ticket, no description, and no branch naming convention reveals intent — flag this as a process finding in the review.
  6. Check CI status with gh pr checks <number>. If checks are failing, determine whether the failure is pre-existing on the base branch or introduced by this PR. Failures introduced by this PR are at minimum a HIGH finding; test suite failures are a BLOCKER.

Step 3 — Understand intent before judging

Before forming opinions:

Step 4 — Review the diff

Evaluate the code across these dimensions:

Correctness

Security

Design & Simplicity

Readability & Maintainability

Test Coverage

Performance (flag only if relevant)

Step 5 — Classify findings

Assign each finding a severity:

Level Meaning
BLOCKER Must be fixed before merge. Correctness bug, security vuln, broken contract, or CI failure introduced by this PR.
HIGH Serious design or reliability issue. Should be fixed; needs discussion if deferred.
MEDIUM Real improvement but not blocking. Author should address or explicitly accept the risk.
LOW / NIT Style, naming, minor cleanup. Optional. Don’t block merge over these.
QUESTION Unclear intent — ask for clarification before judging.
PRAISE Something done especially well. Say it.

Do not manufacture findings to look thorough. If the code is good, say so.

Step 6 — Post the review

Inline comments

True inline comments (anchored to a file and line) require either:

Each inline comment body must open with “Farty Bobo says:” so the author knows who left it.

If neither the GitHub MCP nor gh api inline posting is feasible, fall back to referencing file.ts:42 inline in the consolidated summary instead — do not post top-level comment blobs pretending they are inline.

Consolidated summary

After inline comments, post a single top-level PR comment with this format:

## Farty Bobo's Code Review

**Verdict:** APPROVE / REQUEST_CHANGES / COMMENT

### Summary
<2–4 sentences: what the PR does, overall quality, biggest concern if any>

### Findings

#### BLOCKER
- `path/to/file.ts:42` — <finding>

#### What's Good
- <something done well>

---
_Reviewed by Farty Bobo_

Only include sections that have entries. Omit empty sections entirely. The template above shows two sections as an example — do not copy-paste all section headers when they are empty.

Verdict rules

Step 7 — Notify the user

After posting: