AgentSkillsCN

address-pr-comments

对 PR 审核评论进行分类与修复。阅读评论内容,过滤掉误报(过时、误解、上下文不符、风格偏好),结合当前差异对比判断评论的相关性,并在确认无误后修复有效评论。当您需要“修复 PR 评论”“回应审核反馈”“处理 PR 反馈”时,可优先选用此技能。

SKILL.md
--- frontmatter
name: address-pr-comments
description: 'Triage and fix PR review comments. Reads comments, filters false positives (outdated, misread, wrong context, style preference), validates relevance against current diff, and fixes valid ones with confirmation. Use when: "fix pr comments", "address review feedback", "handle pr feedback".'

User request: $ARGUMENTS

If no PR specified: Detect PR from current branch. If detection fails, report and stop.

Default scope: All unresolved comments on the PR.

Goal

Classify all unresolved PR comments against false positive criteria, report triage findings, then fix actionable items with user confirmation per fix.

False Positive Detection

TypeDetection Signal
OutdatedSuggested change already exists in code; commit history shows it was addressed
Misread codeComment's premise contradicts what code actually does
Wrong contextComment references behavior/variables not present in the target code
Style preferenceNo functional or readability improvement—evaluate substance, not reviewer's tone
Resolved in threadReply discussion shows issue was already addressed or withdrawn

Classification:

  • Strong false-positive signal → false-positive
  • Real issue with clear fix → actionable
  • Unclear validity → uncertain (report, don't fix)

Output

Triage report: Classification, reasoning, and summary counts for each comment. Format flexibly based on volume.

Per-fix flow: For actionable items, show original comment and proposed change, await user confirmation before applying.

Constraints

ConstraintEnforcement
Verify before classifyingRead actual code and reply threads; never classify from comment text alone
Conservative on fixesUncertain → report only
Explain rejectionsEvery false-positive needs reasoning
Per-fix confirmationUser confirms each fix individually