| name | address-review |
| description | Pull unresolved PR review comments and address them. Handles code fixes, spec proposal approvals/rejections, and pushes updates. Can be run multiple times until all comments are resolved. Use when this capability is needed. |
| metadata | {"author":"aqaliarept"} |
Address Review
This skill pulls unresolved review comments from the current branch's PR and addresses them. It handles code changes, spec proposal approvals, and pushes fixes.
Process
Step 1: Identify the PR and Feature Folder
- Run
git branch --show-current to get the current branch.
- Derive the feature folder:
- Strip the
feat/ prefix from the branch name.
- Extract the first path segment (everything before the second
/) — this is the feature slug.
- Feature folder =
spec/features/[slug]/
- Example:
feat/0023-payment-retry/eng-123-retry-endpoint → spec/features/0023-payment-retry/
- Example:
feat/0023-payment-retry → spec/features/0023-payment-retry/
- Use
gh pr view --json number,url,headRefName to find the open PR for this branch.
- If no PR is found, fail with a clear message.
Step 2: Pull Unresolved Comments
- Use
gh api repos/{owner}/{repo}/pulls/{number}/comments to get all review comments.
- Filter for unresolved/pending comments (not yet resolved by the author).
- Group comments by category:
Code Comments
General code review feedback — bugs, style, logic issues, suggestions.
Spec Proposal Comments
Comments that reference SPEC-PROPOSAL.md entries. Look for patterns like:
- "SPEC-PROPOSAL: approved" or "SP-001: approved" — reviewer approves the proposal
- "SPEC-PROPOSAL: rejected" or "SP-001: rejected" — reviewer rejects the proposal
- Other comments on SPEC-PROPOSAL.md lines
Step 3: Address Code Comments
For each unresolved code comment:
- Read the referenced file and line range.
- Understand the reviewer's concern.
- Fix the code to address the concern.
- If the fix requires test changes, update tests and ensure they pass.
- If the fix changes behavior covered by
spec:// references, verify the references are still correct.
Step 4: Handle Spec Proposals
Read SPEC-PROPOSAL.md from the feature folder (if it exists).
For Approved Proposals
- Read the proposal entry (e.g. SP-001).
- Apply the proposed change to the actual spec file (e.g. update
REQUIREMENTS.md, ADR.md, or DESIGN.md in the feature folder).
- Remove the approved entry from
SPEC-PROPOSAL.md.
For Rejected Proposals
- Read the rejection reason from the review comment.
- Revert any code that was written assuming the proposed spec change.
- Adjust the implementation to work within the existing spec.
- Remove the rejected entry from
SPEC-PROPOSAL.md.
- Update tests if the behavior changed.
Cleanup
If all entries in SPEC-PROPOSAL.md are resolved (approved or rejected), delete the file entirely.
Step 5: Run Tests
Run the full test suite (or at minimum, tests related to the changes) to ensure everything passes after the fixes.
Step 6: Commit and Push
- Stage all modified files.
- Commit with message:
fix(NNNN-slug): address review comments for {ISSUE-ID}
- Push to the current branch.
Step 7: Report
Present a summary:
- Number of comments addressed
- Code changes made
- Spec proposals approved/rejected and files updated
- Whether SPEC-PROPOSAL.md was cleaned up
- Test results
- Suggest running
/address-review again after the next review cycle
- If all comments are resolved and PR is approved, remind the user to merge the PR manually
Source: aqaliarept/sdd — distributed by TomeVault.