mcpbeat Sign in

Pr Review Comments Agent Skill

Posts review findings from a JSON file as inline comments on a GitHub Pull Request, attaching each comment to its file and line. Use when you have a list/JSON of review findings (each with a file path, line number, and a message such as summary/failure_scenario) and want them published on a PR as inline review comments. Triggers include "post these review comments on the PR", "associate comments to files in the PR", "publish review findings to PR #N", or having a JSON array of {file, line, summary} to turn into PR comments.

4k tokens
context cost
the whole folder, loaded on every use
3
files
ships runnable scripts
0
copies elsewhere
how many repositories repackaged it
316
stars on the repo
on the repository, not the skill itself

Install

one command, takes just this skill from the repository
npx skills add https://github.com/giuseppe-trisciuoglio/developer-kit --skill pr-review-comments

The instruction itself

7 sections, as written by the author

PR Review Comments

Publish a JSON array of review findings as inline comments on a GitHub Pull Request,

each anchored to its file and line. Uses the GitHub API through the authenticated

gh CLI, so no token handling is needed.

Prerequisites

  • gh CLI installed and authenticated (gh auth status). The script auto-detects the

repo with gh repo view; pass --repo OWNER/REPO to override.

  • The PR number to comment on.
  • A JSON file: an array of objects. Required keys per object: file, line.

Message comes from summary and/or failure_scenario (combined into the body), or an

explicit body. See references/json-schema.md for the full

schema and a sample.

Key constraint: only diff lines are commentable

GitHub only accepts an inline comment if the target line is part of the PR's diff.

line is the line number in the new file (use side: "LEFT" for removed lines).

The script fetches the PR diff, validates every finding against the actual hunks, and

skips any whose line is outside the diff — reporting them at the end so nothing is

lost silently. There is no way to attach a line comment to an unchanged, undiffed line.

Workflow

  • Confirm the JSON path and the PR number. If the repo isn't obvious, run gh repo view.
  • Dry-run first to see what will be posted and what gets skipped:
   scripts/post_pr_comments.py --pr <N> --json <path> --dry-run
  • Review the "Postable" / "Skipped" counts with the user. If lines were skipped because

the diff moved, the line numbers in the JSON may be stale — reconcile before posting.

  • Post for real, choosing the mode (see below):
   # Grouped (default): one PR review bundling all comments
   scripts/post_pr_comments.py --pr <N> --json <path> --event COMMENT

   # Individual: one separate inline comment per finding
   scripts/post_pr_comments.py --pr <N> --json <path> --mode individual
  • Report back the created review/comment URLs and the list of any skipped findings.

Choosing the mode

| Mode | Endpoint | Use when |

|------|----------|----------|

| grouped (default) | POST /pulls/{n}/reviews | Publishing a set of findings as one review. One notification; can set --event APPROVE \| REQUEST_CHANGES \| COMMENT. |

| individual | POST /pulls/{n}/comments | Adding standalone comments incrementally, or when each finding should be its own thread/notification. |

Default to grouped with --event COMMENT unless the user wants a verdict or separate threads.

Options reference

--pr N              PR number (required)
--json PATH         JSON array of findings (required)
--repo OWNER/REPO   Override auto-detected repo
--mode grouped|individual   Default: grouped
--event COMMENT|APPROVE|REQUEST_CHANGES   Grouped-mode verdict (default COMMENT)
--review-body TEXT  Top-level summary body for the grouped review
--commit SHA        Commit to anchor to (default: PR head SHA)
--dry-run           Validate and print payloads without posting

Notes

  • Multi-line range comments: include start_line (and optional start_side) in the JSON

object alongside line; the script passes them through.

  • Always --dry-run before a real post on an unfamiliar PR — stale line numbers are the

most common failure and the dry-run surfaces them as "skipped" without side effects.

  • The script is the reliable path; don't hand-roll gh api calls for this — it handles

diff validation, repo/commit detection, and body assembly consistently.

Other skills for the same job

different authors, same section of the catalogue
Receiving Code Review
by ZhanlinCui
×7

Use when receiving code review feedback, before implementing suggestions, especially if feedback seems unclear or technically questionable - requires technical rigor and verification, not performative agreement or blind implementation

2k tokens
Requesting Code Review
by ZhanlinCui
×6

Use when completing tasks, implementing major features, or before merging to verify work meets requirements

2k tokens
Git Commit
by github
vendor ×3

Execute git commit with conventional commit message analysis, intelligent staging, and message generation. Use when user asks to commit changes, create a git commit, or mentions "/commit". Supports: (1) Auto-detecting type and scope from changes, (2) Generating conventional commit messages from diff, (3) Interactive commit with optional type/scope/description overrides, (4) Intelligent file staging for logical grouping

799 tokens
Github Code Review
by ComeOnOliver
×3

Comprehensive GitHub code review with AI-powered swarm coordination

13k tokens
Karpathy Guidelines
by hyyhf
×3

Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code to avoid overcomplication, make surgical changes, surface assumptions, and define verifiable success criteria.

629 tokens
Code Reviewer
by google-gemini
vendor ×2

Use this skill to review code. It supports both local changes (staged or working tree) and remote Pull Requests (by ID or URL). It focuses on correctness, maintainability, and adherence to project standards.

795 tokens
Agent MD Refactor
by softaworks
×2

Refactor bloated AGENTS.md, CLAUDE.md, or similar agent instruction files to follow progressive disclosure principles. Splits monolithic files into organized, linked documentation.

4k tokens
Commit Work
by softaworks
×2

Create high-quality git commits: review/stage intended changes, split into logical commits, and write clear commit messages (including Conventional Commits). Use when the user asks to commit, craft a commit message, stage changes, or split work into multiple commits.

2k tokens

How to use it

Copy the folder

Take giuseppe-trisciuoglio/pr-review-comments from the repository into ~/.claude/skills for personal use, or into .claude/skills inside a project.

Check the name does not clash

The agent identifies a skill by the name field in its header. Two skills with the same name cannot sit side by side — one of them will be ignored.