一键导入
review-pr
Works through PR review comments: triages findings, gets human input on non-trivial ones, applies fixes, and replies to each comment with the outcome.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Works through PR review comments: triages findings, gets human input on non-trivial ones, applies fixes, and replies to each comment with the outcome.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Publishes a clean normal feature or task branch and creates its pull request on explicit human request.
Instructions for writing good design plan artifacts. Use when specifically requested.
Instructions for writing good implementation plans artifacts. Use when specifically requested.
Instructions for executing implementation plans. Use when specifically requested.
Instructions for executing a task from an implementation plans. Use when specifically requested.
Instructions for investigating a codebase to answer a specific question.
| name | review-pr |
| description | Works through PR review comments: triages findings, gets human input on non-trivial ones, applies fixes, and replies to each comment with the outcome. |
Work through open review comments on a pull request. Triage each comment by severity and source, address bugs and clear fixes autonomously, escalate non-trivial decisions to the human, apply all approved fixes in a dedicated review branch, and reply to every comment with the outcome.
Use this skill when a PR has open review comments — from human reviewers or automated code reviewers (e.g. Copilot) — that need to be triaged and addressed.
This is a standalone skill triggered directly by humans after a PR is open.
Do not use when:
run-hotfix insteadrun-implementation or run-fix insteadreview-implementation-plan or
review-design-plan insteadThis skill calls review-code internally for code quality assessment and manages its own
--agents-review-{N} branch. Each round of review comments is a new cycle (N increments).
Your prompt must include:
If not provided, ask before proceeding. Do not guess.
Derive {project-name} from the PR title or branch name, prefixed with pr-review-
(e.g. pr-review-reprocess-items), five words or fewer. Determine the next review cycle number N by
counting existing pr-review--{N}.md artifacts in any existing project work directory for this PR.
All artifacts for this review cycle are stored in the same project work directory as the
original implementation (if one exists) or, if none exists, in a new
.artifacts/{YYYYMMDD}--{JIRA-ID}--{project-name}/ directory. For a new directory, extract {JIRA-ID}
by matching [A-Z]+-[0-9]+ against the parent feature branch name (e.g. FUS-123); if the branch
contains NO-TICKET, or no ticket pattern is found, omit the {JIRA-ID} segment entirely — do not
write the literal text NO-TICKET into the path. The artifact for this cycle is:
| Artifact | Description |
|---|---|
pr-review--{N}.md | Triage table, findings, decisions, and outcomes (N = zero-padded |
| 2 digits: 01, 02, ...) |
Create a review branch from the parent feature branch:
git switch {parent-branch}
git switch -c {parent-branch}--agents-review-{N}
where N matches the review cycle number of the pr-review--{N}.md artifact.
All fix commits are made on {parent-branch}--agents-review-{N}.
The --agents-review-{N} branch is local only. Do not push it to origin. It exists as a
local audit trail and is preserved after the squash.
After all fixes are approved and the quality gate passes, squash onto the parent branch and push the parent branch:
git switch {parent-branch}
git merge --squash {parent-branch}--agents-review-{N}
git commit -m "<review-fixes message>"
git push origin {parent-branch}
Do NOT delete the --agents-review-{N} branch — it is preserved locally as the full commit history.
Fetch all open review comments from the PR:
gh api repos/{owner}/{repo}/pulls/{pr}/comments \
--jq '.[] | {id: .id, path: .path, line: (.line // .original_line), body: .body, user: .user.login, url: .html_url}'
Also fetch any top-level PR review bodies:
gh pr view {pr} --comments
Ignore bot-generated dependency review comments and CI status comments. Focus on code review comments from humans and automated code reviewers (e.g. Copilot).
For each comment, classify:
human or bot (Copilot, automated reviewer, etc.)critical (incorrect behaviour, data loss, crash, security), significant
(design concern, performance, API contract), or trivial (style, naming, nit). Both
critical and significant must be addressed before the PR can merge; trivial items
are addressed at the principal's discretion.auto-fix — clear, unambiguous fix; no human input neededdiscuss — non-trivial; requires human decision before actingwon't-fix — clearly out of scope or already addressed; reply and closeWrite pr-review--{N}.md in the project work directory. Read
.agents/artifacts/pr-review/description.md for the canonical section definitions, and render
.agents/artifacts/pr-review/template.md.j2 to produce the initial file. Replace all dummy
content — every line drawn from the retro encabulator — with real content for this review cycle.
The rendered file must contain no placeholder text when submitted.
STOP — end your turn here.
Present the triage table to the human. For every comment marked discuss, explain the
tradeoff and ask for a decision. For every comment marked won't-fix, confirm the reasoning.
Wait for explicit human responses on all discuss and won't-fix items before proceeding.
Do not interpret silence as approval. Do not resolve multiple discuss items in a single
turn — present them one at a time if there are dependencies between them.
Before ending your turn, verify every item in this checklist:
Update the pr-review--{N}.md artifact with the human's decisions before moving on.
For each comment with disposition auto-fix or human-approved fix:
--agents-review-{N} branch.make qa and confirm it passes.git add -A
git commit -m "fix: <short description of fix>"
pr-review--{N}.md artifact against the comment.Group logically related fixes into a single commit where it makes the history cleaner.
Each commit must still pass make qa on its own.
After all fixes are committed and make qa passes on the full branch:
Propose a squash commit message to the human. Wait for approval.
Squash onto the parent branch (see Git workflow).
Push the parent branch.
For each addressed comment, reply on GitHub:
Addressed in <short-sha>
<One or two sentences describing what was changed and why.>
Use:
gh api repos/{owner}/{repo}/pulls/{pr}/comments/{comment-id}/replies \
-f body="Addressed in <sha>\n\n<summary>"
For each won't-fix comment, reply:
Won't fix: <brief rationale>
Re-request review from any human reviewers who left comments (skip bots):
gh pr edit {pr} --add-reviewer <handle>
Report completion to the human with:
pr-review--{N}.md artifact path