skills/respond/SKILL.md
Respond to PR review comments with confidence-rated triage. Also checks and fixes build failures and merge conflicts before processing comments. Handles both inline review threads (anchored to diff lines) AND PR-level review body comments (summaries submitted with reviews, like Age tables or Copilot overviews). Use when the user says "respond to PR comments", "handle review feedback", "address PR reviews", "fix the build", "fix CI", "fix merge conflicts", or invokes /respond with a PR number. Also trigger when the user mentions a specific PR and wants to deal with reviewer suggestions — whether from Copilot, human reviewers, or bots. Checks CI status and mergeability first, then reads all unresolved review threads and review bodies, scores each suggestion 0-100, and presents a triage table. High-confidence fixes (>= 50) execute immediately while the user reviews uncertain items. Do NOT use to generate a new review — use /copilot-review for that.
npx skillsauth add paulnsorensen/dotfiles respondInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Read review comments on a PR, rate each one, and act based on confidence — fix the obvious ones immediately, push back on the bad ones, and ask about the uncertain ones while the fixes are already underway.
Before triaging comments, check the PR's build and merge status:
pull_request_read(method: "get_check_runs", owner, repo, pullNumber)
pull_request_read(method: "get", owner, repo, pullNumber) # check mergeable_state
Build failures: If any check run has conclusion: "failure", fetch the
failed job logs (gh run view <run_id> --log-failed) and fix the root cause
before processing review comments. Build fixes go first — review comments may
be moot if the build is broken.
Merge conflicts: If the PR's mergeable field is false or mergeable_state
is "dirty", rebase onto origin/main and force-push (with lease) before
processing comments. Stale conflicts block everything downstream.
Include build/merge status at the top of the triage table:
## PR #N Status
- **Build**: passing | failing (N jobs)
- **Merge**: clean | conflicts (rebase needed)
If both are clean, proceed to Phase 1. If fixes were needed, note what was done.
Determine owner/repo from the current git remote. Then fetch both inline review threads AND PR-level review bodies:
Inline review threads (comments anchored to specific diff lines):
pull_request_read(method: "get_review_comments", owner, repo, pullNumber)
PR-level review bodies (summary comments submitted with a review):
pull_request_read(method: "get_reviews", owner, repo, pullNumber)
Also fetch PR metadata for context:
pull_request_read(method: "get", owner, repo, pullNumber)
pull_request_read(method: "get_diff", owner, repo, pullNumber)
Filter to unresolved threads only (is_resolved: false). Skip outdated
threads (is_outdated: true) unless the user asks to include them.
Group comments by thread — a thread is a logical unit (one review suggestion and its replies). The first comment in a thread is the review suggestion; subsequent comments are the conversation.
Filter reviews to those with a non-empty body field. Reviews with empty
bodies are just containers for inline comments and can be ignored here.
A review body is a PR-level summary — things like Age Review tables, Copilot
overviews, or reviewer summaries submitted with CHANGES_REQUESTED or
COMMENTED state. These often contain multiple suggestions in a single body.
Deduplication: A review that has both a body AND inline comments will appear
in both fetches. Score the inline comments as threads (they have file context).
Only score the review body for suggestions NOT already covered by its inline
comments — check pull_request_review_id to link inline comments back to their
parent review.
For each unresolved thread or review body item, read:
Then assign a confidence score (0-100) representing how confident you are that the reviewer's suggestion is correct and valuable. This is your assessment of the suggestion's merit, not the reviewer's confidence.
Review body parsing: A single review body may contain multiple distinct suggestions (bullet points, numbered lists, table rows). Parse these into individual items when possible — each gets its own score and triage row. If the body is a single cohesive comment (e.g., "LGTM" or a general observation), treat it as one item.
Review state as signal: CHANGES_REQUESTED carries more weight than
COMMENTED — the reviewer explicitly flagged something as blocking. Factor this
into scoring (it raises confidence that the suggestion matters, though it
doesn't automatically make the suggestion correct).
Step 1 — Classify suggestion type:
| Type | Description | Base | Cap | |------|-------------|------|-----| | BUG | Correctness issue, logic error, crash | 50 | 100 | | SECURITY | Vulnerability, data exposure, auth bypass | 55 | 100 | | CONVENTION | Style, naming, project-standard deviation | 25 | 65 | | STYLE | Formatting, subjective preference | 15 | 45 | | SCOPE_CREEP | Unrelated improvement, "while you're here" | 20 | 55 | | VALID_CONCERN | Architectural, performance, maintainability | 40 | 90 |
Step 2 — Evidence grounding:
| Evidence | Modifier | |----------|----------| | Reviewer cites specific code with accurate analysis | +20 | | Suggestion references project convention or CLAUDE.md rule | +15 | | Generic observation without specific code reference | -10 | | Reviewer misreads the code or cites wrong line | hard cap 0 |
Step 3 — Context modifiers:
| Signal | Modifier | |--------|----------| | CHANGES_REQUESTED review state | +10 | | Reviewer is a maintainer/codeowner | +10 | | Bot reviewer (Copilot, CodeRabbit, etc.) | -10 | | Suggestion duplicates another thread | -15 | | Pre-existing issue not introduced by this PR | -15 |
Step 4 — Re-assess borderline (35-49): For items near the FIX threshold: re-read the reviewer's comment and the relevant code independently. Score a second time without looking at your first score. If the two scores diverge >15 points, the suggestion is ambiguous — keep as ASK. If both land >= 50, upgrade to FIX.
Present the full triage table so the user sees everything at once:
## PR #N Review Triage
| # | Score | Type | Reviewer | Location | Summary | Action |
|---|-------|------|----------|----------|---------|--------|
| 1 | 92 | BUG | copilot | auth.ts:42 | Missing null check on token | FIX |
| 2 | 85 | BUG | alice | api.ts:78 | Error not propagated to caller | FIX |
| 3 | 78 | VALID_CONCERN | alice | (review body) | Missing error handling in 3 endpoints | FIX |
| 4 | 60 | STYLE | copilot | utils.ts:15 | Extract to shared helper | ASK |
| 5 | 35 | SCOPE_CREEP | bob | index.ts:3 | Add backward compat shim | PUSH BACK |
| 6 | 20 | STYLE | copilot | (review body) | General "consider adding tests" | SKIP |
### Legend
- **FIX** (>= 50): Agree and implement — proceeding now
- **ASK** (30-49): Needs your call — what do you want to do?
- **PUSH BACK** (< 30): Draft reply below — edit or approve
For each row, include a one-line expansion (representative examples below):
### 1. Missing null check on token (92) — FIX
> copilot: `token` could be undefined when auth header is malformed
Plan: Add null guard before decode, return 401
### 3. Missing error handling in 3 endpoints (78) — FIX [review body]
> alice (CHANGES_REQUESTED): "The new endpoints in handler.rs don't propagate
> database errors — they silently return empty results."
Plan: Add error propagation in the 3 endpoints she identified.
### 4. Extract to shared helper (60) — ASK
> copilot: `formatDate()` is duplicated in 3 files
This is a real duplication but extracting now adds a shared module.
Worth it, or leave for a dedicated cleanup pass?
### 5. Add backward compat shim (35) — PUSH BACK
> bob: Users on v1 will break without a migration path
Draft reply: "This project is pre-release with zero users and no production
data — backward compatibility isn't a concern yet per our Early Development
Stance. We'll add migration support when there's something to migrate from."
Then immediately — in the same turn:
The triage table is informational, not a gate for high-confidence items. The user sees what's happening and can interrupt ("stop, don't fix #2") but the default is to move fast on the obvious stuff.
Read the relevant source file
Implement the fix
Reply acknowledging the fix:
Inline threads: reply to the thread:
add_reply_to_pull_request_comment(owner, repo, pullNumber, commentId, body)
Review body items: post a PR conversation comment referencing the review:
add_issue_comment(owner, repo, number: pullNumber, body: "Re: @reviewer's review — Fixed: <brief description>.")
Fixed — <brief description of what changed>.
Post the reply:
Inline threads:
add_reply_to_pull_request_comment(owner, repo, pullNumber, commentId, body)
Review body items:
add_issue_comment(owner, repo, number: pullNumber, body: "Re: @reviewer's review — <pushback explanation>.")
Keep the tone professional and specific — explain why, not just no
If any code was changed, commit the fixes (using the commit skill) and
push to the PR branch. Present a summary: files modified, threads replied to,
threads still pending user decision.
/copilot-review for thatis_resolved field is not always reliable across GitHub Apps — verify thread state manuallytools
Reconstruct what a past coding-agent session was doing so you can resume it — goal, files touched, last verified state, and the next step — by querying the session logs. Use when the user says "what was I working on", "recover that session", "reconstruct where I left off", "resume my last session", "what did that session change", "rebuild context from logs", or invokes /work-recovery. Report-only — it never scores or judges. Do NOT use for usage scoring (that is /skill-improver, /tool-efficiency, /prompt-analytics) or one-off interactive log queries (that is /session-analytics).
development
Curate this repo's hallouminate wiki (.hallouminate/wiki/, the repo:dotfiles:wiki corpus) — add or update architecture pages, per-harness docs, and gotchas. Use when the user says "update the wiki", "document this in the wiki", "refresh the harness docs", "add a wiki page", "curate the wiki", "the wiki is stale", or invokes /wiki-curator. Also use at session end to write back a non-obvious decision or gotcha worth preserving. Grounds the existing wiki first, follows one-topic-per-file conventions, verifies every external doc URL before writing, and reindexes. Do NOT use for general code search (that is cheez-search) or for editing AGENTS.md command reference.
tools
Audit how a tool, command, or MCP server is actually used across coding-agent sessions and produce calibrated recommendations — tool-vs-task fit, error forensics, fix recommendations, permission friction, MCP health, and token economics. Use when the user says "tool efficiency", "am I using X efficiently", "audit tool usage", "why does X keep failing", "how do I fix this error", "what should I change", "permission friction", "is this MCP worth it", "tool error rate", "fix recommendations", or invokes /tool-efficiency. Do NOT use for auditing a skill or agent definition (that is /skill-improver) or for one-off interactive log queries (that is /session-analytics).
tools
Analyze how prompts and skill routing behave across coding-agent sessions and produce calibrated recommendations — prompt-pattern analysis, routing accuracy, and knowledge gaps. Use when the user says "analyze my prompts", "prompt patterns", "is routing working", "which skill should have fired", "knowledge gaps", "what do I keep asking", or invokes /prompt-analytics. Do NOT use for auditing a single skill/agent definition (that is /skill-improver), tool/MCP efficiency (that is /tool-efficiency), or one-off interactive log queries (that is /session-analytics).