pr-review
Skill0 starsChanged 7 days agoMITView on GitHub
Ranked GitHub PR review (max 3-5 findings, blocker/consideration/nit). Use when the user says "/pr-review", "review this PR", "review PR <number/URL>", or asks for a quick PR review with idiomatic suggestions.
- Reads credentials
195 other projects use a version of this.
Adopted by
Most recently taken up by
- static-web-server/static-web-servertheir own version, first seen Nov 9, 2026
- zerx-lab/FluxDowntheir own version, first seen Nov 9, 2026
- civitai/civitaitheir own version, first seen Nov 9, 2026
- harshitsinghbhandari/domain-expansiontheir own version, first seen Nov 8, 2026
- Azure/azure-sdk-toolstheir own version, first seen Nov 8, 2026
- databricks/clitheir own version, first seen Nov 8, 2026
Used with
Projects with it also use oss-pr, pr-automation and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
CES-LtdSkilloss-pr
Use when creating a pull request, after committing changes, or when user invokes /oss-pr. Covers branch management, quality checks, commit, push, and PR creation.
Also in 3 projects that use this
CES-LtdSkillpr-automation
PR Automation Orchestrator: poll open PRs, check CI, run review, fix, and merge eligible PRs. Use when: (1) Invoked by daemon via scripts/pr-automation.sh, (2) User says "/pr-automation".
Also in 3 projects that use this
jtenniswoodSkillexpert-reset
Reimagine this repository from first principles using the current product and user experience as the target. Use when the user says "/expert-reset", asks how the project should be rebuilt if starting again, wants bold architecture or component-structure recommendations, or wants a research-only reset plan unconstrained by current implementation details.
Also in 3 projects that use this
jtenniswoodSkillupdates
Summarize user-facing project updates from the last 7 days, ordered by importance and written as one-sentence "Feature: description" entries. Use when the user says "/updates", asks what changed recently, or wants a concise list of recent features, device support, fixes that users will notice, or other product value.
Also in 3 projects that use this
openchamberSkillclack-cli-patterns
Use when creating or modifying OpenChamber CLI commands, prompts, terminal output, non-TTY behavior, `--quiet`, or `--json` behavior.
Also in 3 projects that use this
openchamberSkilldrag-to-reorder
Use when implementing or modifying OpenChamber sortable or drag-to-reorder behavior, especially `@dnd-kit`, touch/mobile interactions, variable-width items, or wrapping layouts.
Also in 3 projects that use this
- +6 more from openchamber
Other versions195 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 195
- Significant-Gravitas/AutoGPT★ 188ksame name
- pytorch/pytorch★ 105ksame name
- rtk-ai/rtk★ 86ksame name
- saadeghi/daisyui★ 43ksame name
- rustfs/rustfs★ 36ksame name
- dotnet/maui★ 23ksame name
- NVIDIA/Megatron-LM★ 18ksame name
- MiniMax-AI/skills★ 14ksame name
- btriapitsyn/openchamber★ 13ksame name
- openchamber/openchamber★ 13ksame name
185 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository7 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- capture-componentSkill
- digest-videoSkill
- no-visual-diffSkill
- pr-createSkill
- pr-feedbackSkill
- prior-artSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
20 rules. 0 are common, 11 are distinctive, and 9 are very specific to this project.
0
Common
Most of the 179 edited versions we read keep these.
11
Distinctive
This author's own choices. Worth a look.
9
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 15
If an org overlay exists at references/<org>.md, load it first - it adds org-specific guidelines to check, extra Phase 3 detection signals, …
- Distinctive: line 42
If invoked with a PR number / URL, get the head branch:
- Distinctive: line 53
If the worktrees folder exists OR the user has previously used worktrees on this repo, include the worktree option in the question.
- Very specific: line 70
If invoked without an argument, ask: "Auto-detect a PR for branch <current>, or specify a PR number / URL?"
- Distinctive: line 73
If the chosen worktree path already exists, ask whether to reuse it or pick a different name - never blow it away.
- Very specific: line 74
After creating the worktree, run all subsequent file reads, rg scans, and codebase pattern citations from inside the worktree path so the …
- Distinctive: line 103
If NO frontend primitive matches, skip Phase 4.
- Very specific: line 135
Run rg for the proposed pattern in the repo to confirm it's already used elsewhere.
- Distinctive: line 139
If found in the codebase: capture file:line.
- Distinctive: line 144
If not found locally but the proposal is from the official docs: cite the docs link only.
- Distinctive: line 152
Every finding is tagged with one of three labels.
- Very specific: line 162
Keep top 3-5 (3 if the diff is small, 5 max for larger PRs).
- Distinctive: line 195
Scannable-in-3-seconds test: if your inline comment doesn't fit in 4 visible lines without scrolling, it's too long.
- Very specific: line 207
Write to ~/Documents/notes/current/pr-<num>-review.md.
- Distinctive: line 240
If an org overlay was loaded, append any closing note it specifies.
- Very specific: line 244
react-doctor: - if Phase 3 matched React signals, optionally invoke to run React Doctor on PR head vs base and surface newly-introduced … - Very specific: line 247
text-to-diagram: - if a finding is easier to explain with a sequence / state diagram, generate one and embed. - Distinctive: line 262
Cap is firm at 5: If you find 12 issues, surface "+ 7 not surfaced".
- Distinctive: line 264
Audit your own assumptions before posting: If a finding has a load-bearing assumption you didn't verify (e.g.
- Very specific: line 265
Clean up the worktree when the review is done: If Phase 1 created a worktree, git worktree remove <path> once the review (and any …
“Common” is measured: kept by at least 6 in 10 of the 179 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
PR review
Always:
- confirm the review branch up-front, pull existing PR comments to dedupe against prior feedback
- scan the codebase for existing patterns to cite via permalinks
- Fetch latest docs for any touched React-ecosystem primitives (React, React Query, TanStack Router, Next.js).
If an org overlay exists at references/<org>.md, load it first - it adds org-specific guidelines to check, extra Phase 3 detection signals, and stack-specific anti-patterns on top of the flow below.
Friendly-colleague PR review, capped at 3-5 findings, paste-ready for GitHub.
House style: ultra-minimal. A nit: is one short line with maybe inline code. A consideration: is 1-2 sentences. A blocker: is 2-3 sentences plus repro and optional suggestion. GitHub already shows the file:line anchor and the diff hunk — never restate them in the comment body.
When NOT to invoke
- Formal multi-axis review (correctness / readability / architecture / security / perf rubric) - use the built-in
/code-review. - Multi-PR batch review - this skill is one PR per invocation; large batches need a different shape.
Argument parsing
Accepts:
/pr-review <number>- PR in the current repo (e.g./pr-review 7527)./pr-review <github-url>- any GitHub PR URL./pr-review- no argument, defaults to the PR for the current branch viagh pr list --head $(git branch --show-current).
Phase 1: Branch confirmation (always)
The user explicitly asked to be asked every time. Never skip, even when branches match.
Run:
git branch --show-currentIf invoked with a PR number / URL, get the head branch:
gh pr view <pr> --json headRefName,baseRefName,headRepositoryAlso check whether the user already has a worktrees folder for this repo - the convention is ~/Documents/Development/<repo>-worktrees/ (e.g. autopilot-worktrees/). Detect with:
git worktree list
ls ~/Documents/Development/<repo>-worktrees/ 2>/dev/nullIf the worktrees folder exists OR the user has previously used worktrees on this repo, include the worktree option in the question. Always confirm before creating - never auto-create.
Then ask via AskUserQuestion:
Q: "Branch state for review:
- Current local branch:
<current>- PR head branch:
<head>Where do you want to review?"
Options (include worktree only when the folder convention is detected):
- Create a worktree (recommended when the folder convention exists) -
git worktree add ~/Documents/Development/<repo>-worktrees/<short-key>-review <head-branch>. Isolates the review tree so the user's main checkout stays untouched. Use<short-key>derived from the branch name (e.g.EXP-1908fromfix/EXP-1908, or the head branch slug if no ticket key).- Stay on current branch - sufficient for diff-based review, codebase pattern scan runs against your current checkout.
- Switch to PR head -
git fetch && git checkout <head>. Use when you want the codebase scan to reflect the PR's tree but don't need a separate worktree.- Cancel - stop the review.
If invoked without an argument, ask: "Auto-detect a PR for branch <current>, or specify a PR number / URL?"
Worktree handling notes:
- If the chosen worktree path already exists, ask whether to reuse it or pick a different name - never blow it away.
- After creating the worktree, run all subsequent file reads,
rgscans, and codebase pattern citations from inside the worktree path so the review reflects the PR's tree state. - The original working directory stays untouched; the user can keep working on their main checkout in parallel.
Phase 2: Fetch PR data
Three calls:
gh pr view <pr> --json title,body,files,headRefName,baseRefName,author,number,url,headRepository,headRefOid
gh pr diff <pr>
gh pr view <pr> --commentsCache headRefOid (the SHA of the PR head) - you'll need it for permalink generation in Phase 6.
Phase 3: Detect frontend context
Scan the diff's touched-file list for primitive signals. Multiple primitives can match.
| Primitive | Signal |
| React | .tsx / .jsx files; hooks (useState, useEffect, useRef, forwardRef); ref-as-prop; <Suspense> |
| React Query | imports from @tanstack/react-query; useQuery, useMutation, useSuspenseQuery, useInfiniteQuery, queryOptions |
| TanStack Router | imports from @tanstack/react-router; createFileRoute, Link, useNavigate, loader, beforeLoad, search params |
| Next.js | app/, pages/, next.config.*; Server Component, 'use server', 'use client' directives |
| Vite (dev tooling) | vite.config.*; defineConfig; a Plugin / configureServer / server.middlewares block; import.meta.env.MODE; dev-proxy / middleware changes |
Org overlays (references/<org>.md) may add more primitives to this table.
If NO frontend primitive matches, skip Phase 4.
Phase 4: Doc fetch (only when matched)
For each matched primitive (max 2; pick the 2 with the most diff hunks), WebFetch ONE relevant doc page. Always fetch fresh - never trust training data, prior cache, or memory. APIs in this stack churn (TanStack Router/Query major versions, React 19, Next.js app router shifts).
| Primitive | Canonical doc to fetch first |
| React | https://react.dev/reference/react (then https://react.dev/blog for latest release post if relevant) |
| React Query | https://tanstack.com/query/latest/docs/framework/react/overview (then .../guides/render-optimizations for select / structural sharing) |
| TanStack Router | https://tanstack.com/router/latest/docs/framework/react/overview |
| Next.js | https://nextjs.org/docs (then https://nextjs.org/blog for latest release if relevant) |
| Zustand | https://github.com/pmndrs/zustand |
| React aria | https://github.com/adobe/react-spectrum |
| Vite (dev tooling) | https://vite.dev/config/ (then .../guide/api-plugin for the Plugin hook API, or .../config/server-options for proxy/server.middlewares changes) |
Hard cap: 4 WebFetches max per run. The skill is fast.
For Vite-config / dev-tooling PRs (middleware, proxy rules, plugin hooks, import.meta.env.MODE gating), always check the latest Vite docs - the Plugin API, configureServer middleware ordering, and env/mode replacement semantics shift across major versions, so don't review from memory.
Phase 5: Read existing PR comments and dedupe
Parse the gh pr view --comments output. For each existing comment, extract a 1-line topic summary.
During Phase 7 finding generation, drop any candidate finding whose topic semantically overlaps an existing comment. In the final output, surface: "N findings dropped because already raised by <author>."
This avoids re-mentioning what others have already said. Important: the user reviews multiple PRs/day and doesn't want to add noise.
Phase 6: Codebase pattern scan (per candidate finding)
For each candidate finding that proposes a "use X pattern instead of Y" change:
- Run
rgfor the proposed pattern in the repo to confirm it's already used elsewhere.rg -n "<proposed pattern>" --type ts --type tsx - If found in the codebase: capture file:line; generate a permalink:
Cite in the comment as: "we already do this in [link]".https://github.com/<owner>/<repo>/blob/<headRefOid>/<path>#L<line> - If not found locally but the proposal is from the official docs: cite the docs link only.
For complex pattern searches (cross-file refactors, API usage audits), delegate to an Explore subagent.
Phase 7: Produce review (cap 3-5 findings)
Tags (taxonomy)
Every finding is tagged with one of three labels.
| Tag | When | Body shape |
nit: | Idiomatic / style / cleanup. Reviewer pasting it would say "totally optional." | One short line. Inline code only. |
consideration: | Worth thinking about - a possible bug, a design tradeoff, a question. May or may not warrant action. | 1-2 sentences. Optional one-liner caveat ("worth a quick repro before treating as a blocker"). |
suggestion: | Concrete bug or correctness issue with a fix. Used in place of blocker:. | 2-3 sentences: what's wrong, the repro / measurable impact, and the fix. |
Cap
Keep top 3-5 (3 if the diff is small, 5 max for larger PRs). Drop the rest. Surface the count of dropped findings: "+ N nits not surfaced - run again with --all if you want them."
Output format
Each finding renders as a self-contained block the user pastes into a GitHub PR review comment at the right file:line anchor. Ultra-minimal is mandatory. Reviewers scan; they don't read essays. GitHub already shows the file:line anchor and the diff hunk - never restate them in the comment body. Permalink only when pointing to a different file than the one being commented on (sibling references).
Body templates:
**nit:** <one-line statement with inline `code`>**consideration:** <1-2 sentence statement>. <optional 1-sentence caveat or sibling-reference link>.**suggestion:** <1-2 sentence statement of the bug>. <1 sentence repro / impact>.
```suggestion
<proposed code, replacing the commented line(s) exactly>
```What to cut, ruthlessly:
- Section headers (
### suggestion:,**File:**,**Reference:**,**Suggested change:**) - the inline tag IS the header. **File**: path:line ([permalink])lines - GitHub shows it already.- "Did you consider..." preamble - the
consideration:tag already softens. - "Worse, X. Also, Y. And note Z." stacked qualifiers - keep one.
- Restating PR-description intent back at the author - they wrote it.
- "Concrete impact:" / "Real impact:" labels - just state the impact.
- Quoting the diff back. The diff is already on screen.
Scannable-in-3-seconds test: if your inline comment doesn't fit in 4 visible lines without scrolling, it's too long. Trim until it does.
Committable suggestions
A fix you can express as replacement lines ships as a ```suggestion block - one-click committable, whatever the tag. Prose carries only what a suggestion block cannot.
- Multi-hunk fix: one suggestion per anchor. The first comment says "batch-apply with the N suggestions below"; the rest open
**<tag> (cont.):**. - Line outside the diff: GitHub anchors suggestions to diff lines only - state the change in prose ("same one-word swap applies at
<path>:<line>"). - Illustrative code (new file, refactor sketch - no exact anchor): fence as
```tsx/```ts. A mis-anchored suggestion block replaces the wrong lines on apply.
Phase 8: Final assembled review note
Write to ~/Documents/notes/current/pr-<num>-review.md. This file is the user's index: each finding is one ### <tag>: <one-line summary> heading with the permalink, followed by the ultra-minimal inline-comment body underneath. The body is what gets pasted into GitHub - it stays inside the Phase 7 caps even in the local doc.
# PR review: <PR title> (#<num>)
PR: <url>
Head: `<sha>`
---
### <tag>: <one-line summary>
[`<path>:<line>`](<permalink>) - <ultra-minimal inline-comment body matching the Phase 7 template for the chosen tag>
```suggestion
<proposed code><tag>: ...
Dedup'd (already raised by <author>)
- <one-liner per dedup'd finding, with permalink and brief note>
Pulled (would need verification before posting)
<one-liner per finding that has a load-bearing unverified assumption>
The heading carries the permalink so the local index is scannable, but the inline body underneath is what the user pastes. Suggestion blocks render as one-click apply in the GitHub UI.
If an org overlay was loaded, append any closing note it specifies.
## Composing with other skills
- **`react-doctor`** - if Phase 3 matched React signals, optionally invoke to run React Doctor on PR head vs base and surface newly-introduced diagnostics.
- **`octocat`** - for any non-trivial `gh` invocations beyond the three calls in Phase 2.
- **`/code-review`** (built-in) - if the user wants a formal multi-axis rubric.
- **`text-to-diagram`** - if a finding is easier to explain with a sequence / state diagram, generate one and embed.
## Tone discipline
- The `nit:` / `consideration:` / `suggestion:` tags ARE the tone. They carry the softness so the prose doesn't need to.
- "We already do this in [link]" > "You should follow our conventions."
- Cite the doc / changelog with a date so the user knows you fetched it fresh.
- **Never use `blocker:`.** Even real bugs ship as `suggestion:`. The user reviews multiple PRs/day and wants to stay collaborative.
## Hard rules
- **No hedge findings.** Per CLAUDE.md: if you cannot articulate the concrete repro path or measurable impact, drop the finding. "Latent bug" / "theoretical concern" / "could be" without specifics is not allowed.
- **Always WebFetch fresh docs** in Phase 4. Never cite a doc URL you haven't opened this session.
- **Cite means link.** Any phrase like "per the docs", "as the spec says", "according to <library>", "the README states" MUST be a markdown link to the exact doc URL you fetched. No bare "per the docs" claims - the reader has to be able to verify the citation in one click. Same rule for codebase claims: "we already do this" / "see <file>" needs a permalink to the head SHA.
- **Never auto-post to GitHub.** Output is paste-ready; the user posts. If the user explicitly asks to post (e.g. "add these as PR comments", "post them"), it's OK to post via `gh api repos/<owner>/<repo>/pulls/<num>/reviews` with `event: COMMENT` and a `comments` array of `{path, start_line, line, start_side, side, body}` entries. When you post, post the **inline body including the `**<tag>:**` prefix** (the tag IS the comment opener now). Don't post the heading line, the permalink line, or anything from the local review note above the body.
- **Cap is firm at 5.** If you find 12 issues, surface "+ 7 not surfaced". Don't bury the user.
- **Permalinks anchor to the PR head SHA**, not to `main`. If the file moves later, the permalink still resolves to what was reviewed.
- **Audit your own assumptions before posting.** If a finding has a load-bearing assumption you didn't verify (e.g. backend PATCH semantics, library runtime behavior you only inferred from types), move it to the "Pulled" section instead of posting it.
- **Clean up the worktree when the review is done.** If Phase 1 created a worktree, `git worktree remove <path>` once the review (and any posting/approval) is complete - don't leave review worktrees lying around.Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

