Triage unresolved PR review comments, produce a severity-ordered fix plan, then resolve or fix each issue with subagents. Use when addressing PR feedback before merge.
From dev-toolkitnpx claudepluginhub casper-studios/casper-marketplace --plugin dev-toolkitThis skill uses the workspace's default tool permissions.
Guides Next.js Cache Components and Partial Prerendering (PPR) with cacheComponents enabled. Implements 'use cache', cacheLife(), cacheTag(), revalidateTag(), static/dynamic optimization, and cache debugging.
Migrates code, prompts, and API calls from Claude Sonnet 4.0/4.5 or Opus 4.1 to Opus 4.5, updating model strings on Anthropic, AWS, GCP, Azure platforms.
Details PluginEval's skill quality evaluation: 3 layers (static, LLM judge), 10 dimensions, rubrics, formulas, anti-patterns, badges. Use to interpret scores, improve triggering, calibrate thresholds.
Fetch all unresolved PR review threads, deduplicate across bots, triage by severity, and produce a fix plan for human approval. After sign-off, resolve ignored threads and spawn subagents to fix real issues.
/pr-comments — auto-detect PR from current branch/pr-comments 608 — specific PR number# Auto-detect from current branch, or use the provided PR number
gh pr view --json number,headRepositoryOwner,title,headRefName,baseRefName
Use GraphQL to get thread resolution status — this is the only reliable source of truth.
gh api graphql -f query='
{
repository(owner: "{OWNER}", name: "{REPO_NAME}") {
pullRequest(number: {PR_NUMBER}) {
reviewThreads(first: 100) {
nodes {
id
isResolved
isOutdated
path
line
comments(first: 20) {
nodes {
databaseId
author { login }
body
path
line
originalLine
createdAt
url
}
}
}
}
}
}
}'
Paginate if hasNextPage is true. Collect every thread.
isResolved == falseisOutdated — the diff may have moved; flag these for extra scrutinygh api --paginate "repos/{OWNER}/{REPO_NAME}/issues/{PR_NUMBER}/comments?per_page=100"
Filter to comments from human reviewers only (not bots). These are often the most important.
Multiple bots often flag the same underlying issue on the same file/line. Group them.
Threads targeting the same file within a 5-line range likely address the same issue. Merge them into a single logical issue.
Each bot uses different severity markers:
| Bot | Format | Example |
|---|---|---|
coderabbitai[bot] | Emoji badge in body | 🟠 Major, 🟡 Minor, 🔴 Critical |
gemini-code-assist[bot] | SVG image alt text | ![medium], ![high], ![low] |
chatgpt-codex-connector[bot] | Shield badge | P1, P2, P3 |
devin-ai-integration[bot] | HTML comment metadata | Parse devin-review-comment JSON for severity |
Map all to a unified scale: Critical > Major > Medium > Minor > Nitpick
When multiple bots flag the same issue at different severities, take the highest.
For each deduplicated issue, determine:
security | bug | correctness | performance | accessibility | style | config | docsFlag as ignore candidate if ANY of these apply:
.md, config, migrations) with no security implicationsisOutdated == true) where the code has already changedWrite the plan to .claude/scratchpad/pr-{PR_NUMBER}-review-plan.md.
# PR #{PR_NUMBER} Review Plan — "{PR_TITLE}"
**Branch:** {branch_name}
**PR URL:** {pr_url}
**Threads fetched:** {total} total, {unresolved} unresolved, {outdated} outdated
**Bot breakdown:** {count per bot}
---
## Issues to Fix (ordered by severity)
Only include issues that will actually be fixed. Items classified as ignored in Phase 2 go EXCLUSIVELY in the Ignored section below — never list them here.
### 1. [{SEVERITY}] {Short description of the issue}
- **File:** `path/to/file.ts#L{line}`
- **Category:** {category}
- **Flagged by:** @bot1, @bot2
- **Comment URL:** {url to first comment}
- **What's wrong:** {1-2 sentence explanation in plain english}
- **Suggested fix:** {concrete description of what to change}
> Original comment (from @bot1):
> {relevant excerpt — strip boilerplate/badges}
---
### 2. [{SEVERITY}] ...
---
## Ignored (with reasoning)
Each ignored item appears ONLY here — not duplicated in the Issues to Fix section above.
### I1. @{bot} on `path/to/file.ts#L{line}`
- **Why ignored:** {specific reason — e.g., "contradicts project convention in AGENTS.md to not use explicit return types", "outdated thread, code already changed", "style nitpick on a config file"}
- **Original comment:** {link to comment}
### I2. ...
---
## Summary
- **{N} issues to fix** across {M} files
- **{K} comments ignored** ({reasons breakdown})
- Estimated complexity: {low/medium/high}
After writing the plan, tell the user:
Review plan written to
.claude/scratchpad/pr-{PR_NUMBER}-review-plan.md. {N} issues to fix, {K} ignored. Please review and confirm to proceed.
STOP HERE. Wait for the user to review and approve. Do not proceed until they confirm.
Once the user approves (they may edit the plan first — re-read it before executing):
For each ignored issue, resolve the GitHub thread with a brief comment explaining why:
# Post a reply comment on the thread
gh api -X POST "repos/{OWNER}/{REPO_NAME}/pulls/{PR_NUMBER}/comments" \
-f body="Acknowledged — {reason}. Resolving." \
-F in_reply_to={COMMENT_DATABASE_ID}
# Resolve the thread via GraphQL
gh api graphql -f query='
mutation {
resolveReviewThread(input: { threadId: "{THREAD_NODE_ID}" }) {
thread { isResolved }
}
}'
Use concise, specific dismiss reasons. Examples:
Group related issues that touch the same file or logical unit. Then launch parallel subagents (one per file or logical group) using the Task tool:
Launch a Task subagent (subagent_type: "general-purpose") for each group:
Prompt template:
"Fix the following PR review issue(s) on branch {BRANCH}:
Issue: {description}
File: {path}#{line}
What's wrong: {explanation}
Suggested fix: {fix description}
Read the file, understand the surrounding context, and make the fix.
After fixing, verify the change is correct.
Do NOT touch unrelated code."
subagent_type: "general-purpose" for each groupThese are almost always ignorable — but verify before dismissing:
as casts or non-null assertions — check project conventions before accepting