skills/gentamura/dotfiles/pr-address-bot-reviews

pr-address-bot-reviews

SKILL.md

PR Address Bot Reviews

Triage and resolve bot-generated PR feedback with a consistent workflow.

Supported Sources

  • coderabbitai[bot]
  • chatgpt-codex-operator

Add more bot logins when needed.

Workflow

1. Collect Feedback

  • Identify the target PR number (from current branch PR or user input).
  • Fetch PR review data with gh:
    • reviews
    • review comments
    • issue comments
  • Filter feedback to supported bot authors.

2. Normalize and Group

  • Deduplicate repeated suggestions.
  • Group by file/path and concern type:
    • correctness/bug risk
    • security
    • performance
    • maintainability/style
    • test/documentation gaps

3. Decide Actionability

Classify each item into:

  • must-fix: clear bug/risk/regression
  • should-fix: strong improvement with low downside
  • skip-with-reason: incorrect assumption, out-of-scope, or high-cost low-value
  • needs-user-decision: product/architecture tradeoff

4. Implement Needed Changes

  • Apply must-fix and agreed should-fix items.
  • Keep changes scoped to the PR intent.
  • Run relevant checks/tests for touched areas.

5. Respond on PR

  • For fixed items: reply with what changed.
  • For skipped items: reply with concise rationale.
  • For tradeoffs: ask explicit decision questions.
  • Reply in the correct channel:
    • Inline review thread: prefer skills/pr-address-bot-reviews/scripts/reply-to-review-comment <pr> --login <bot-login> --path <file> [--line <line>] "<response>"
    • Lower-level flow remains available: find-review-comment-id then pr-thread-reply
    • General PR note: use gh pr comment

6. Report Back to User

  • Summarize by category:
    • fixed
    • skipped (with reason)
    • pending decision
  • Provide changed files and verification commands run.

Decision Heuristics

  • Prefer concrete evidence over bot confidence.
  • Reject suggestions that conflict with project conventions.
  • Reject speculative refactors that increase scope without reducing risk.
  • Escalate when the fix changes behavior, API contract, or data model.

Minimal Command Sequence

gh pr view <number> --json number,title,body,reviews,comments,files
gh pr view <number> --comments
# preferred single-command inline review reply flow
skills/pr-address-bot-reviews/scripts/reply-to-review-comment <number> --login <bot-login> --path <file> [--line <line>] "<response>"
# lower-level two-step flow when you want explicit control
skills/pr-address-bot-reviews/scripts/find-review-comment-id <number> --login <bot-login> --path <file> [--line <line>]
skills/pr-address-bot-reviews/scripts/pr-thread-reply <number> <comment_id> "<response>"
# optional general PR note
gh pr comment <number> --body "<response>"
# implement code changes
git add <files...>
git commit -m "<message>"
git push

Script Split

  • scripts/reply-to-review-comment: thin entrypoint that resolves the target review comment id and posts the reply
  • scripts/find-review-comment-id: resolve a single inline review comment id from bot login + path + optional line
  • scripts/pr-thread-reply: post a reply to a known inline review comment id

This keeps comment discovery and reply posting separate internally while still exposing a one-command path for routine use.

Weekly Installs
4
First Seen
14 days ago
Installed on
gemini-cli4
opencode4
codebuddy4
github-copilot4
codex4
kimi-cli4