claude-sdk-rs: Command for Claude Code

.claude/commands/review-PR.md

review-PR is a command for Claude Code from bredmond1019/claude-sdk-rs. It costs 0 tokens per session (2,177 once invoked), scanned A, original, Apache-2.0.

A command that reviews a GitHub pull request, a proposed set of code changes, against a work block's acceptance criteria. It checks the project's required checks, reviews the difference from the target branch, and posts a verdict on GitHub.

In plain words
What is it for?
Use it with a pull-request number and, when needed, a plan name. It is intended for pull requests produced by the project's roadmap workflow but can also review other specification-based requests.
Why use it?
It combines automated gates with a requirements-based review instead of relying only on whether the code runs. This helps catch changes that do not satisfy the original specification.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

This is bredmond1019/claude-sdk-rs's own configuration. It tells Claude Code how to work on claude-sdk-rs itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything claude-sdk-rs configures →

Reuse

Borrowing it

Nothing to install: this file belongs to bredmond1019/claude-sdk-rs. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/bredmond1019/claude-sdk-rs/main/.claude/commands/review-PR.md
Clone the repo
git clone --depth 1 https://github.com/bredmond1019/claude-sdk-rs

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for review-PR

README.md
[![agentmods](https://agentmods.dev/badge/commands/bredmond1019/claude-sdk-rs/review-pr/github.svg)](https://agentmods.dev/commands/bredmond1019/claude-sdk-rs/review-pr)
Your own site
<a href="https://agentmods.dev/commands/bredmond1019/claude-sdk-rs/review-pr"><img src="https://agentmods.dev/badge/commands/bredmond1019/claude-sdk-rs/review-pr/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for review-PR

Your own site · 80×15
<a href="https://agentmods.dev/commands/bredmond1019/claude-sdk-rs/review-pr"><img src="https://agentmods.dev/badge/commands/bredmond1019/claude-sdk-rs/review-pr.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,177 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.02177
Opus 5.5 $0.00000 $0.00871
Sonnet 5.5 $0.00000 $0.00435
Haiku 4.5 $0.00000 $0.00218

Measured 11d ago against content hash 3e0d653cdfa7, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

review-PR scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

base = subprocess.run(
.claude/commands/review-PR.md · 223 lines

How it starts

The opening of the file, as written. The whole thing — 223 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Review PR — Spec-aware review for a branch-train PR.

Checks out the PR branch, runs the project's gating suite + emoji gate, reviews the diff against the block's Acceptance Criteria, and posts a verdict via gh pr review.

Designed for PRs produced by a roadmap orchestration run in default (PR) mode. Can also review any PR for a spec-based block by pointing at the spec manually.

Variables

$ARGUMENTS — <PR#> [plan-slug]

  • <PR#> — required. The GitHub PR number (integer).
  • [plan-slug] — optional. The plan slug (e.g. roadmap-and-task-updates) to scope state lookup when multiple block-orchestration-state.json files exist.

Examples:

/review-PR 42
/review-PR 42 roadmap-and-task-updates

Instructions

Step 0 — Parse arguments

Extract PR# (required integer) and optional plan-slug. If PR# is absent or not an integer, stop and print:

Usage: /review-PR <PR#> [plan-slug]
  PR#        GitHub PR number (required)
  plan-slug  plan slug to scope state lookup (optional; omit when there is only one plan)
Examples:
  /review-PR 42
  /review-PR 42 my-plan

Step 1 — Fetch PR metadata

gh pr view <PR#> --json number,title,headRefName,baseRefName,state,url,reviews

Capture:

  • headRefName — the PR's source branch (the block branch).
  • baseRefName — the branch the PR targets.
  • state — if MERGED or CLOSED, stop and report: "PR # is already ."
  • reviews — existing reviews (context only; do not let prior reviews override this run's findings).

Step 2 — Locate the orchestration state

Search for the state file:

find planning -name "block-orchestration-state.json" 2>/dev/null

If plan-slug was given, filter to planning/<plan-slug>/sdlc/block-orchestration-state.json.

If multiple files remain after filtering, pick the one whose blocks map contains an entry with branch == headRefName. If still ambiguous, list the candidates and ask the user to re-run with a plan-slug.

Read the selected state file (parse as JSON). Find the block entry where blocks[slug].branch == headRefName. Extract blockSlug (the map key). Derive specFile = planning/<blockSlug>/tasks.md.

Read the full file on GitHub · 223 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 223 lines · 0 tokens per session scan A 3e0d653cdfa7

Subscribe to this mod's changes

review-PR is a command published in the GitHub repository bredmond1019/claude-sdk-rs (23 stars, last pushed 1mo ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 2,177 tokens. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-26.

Related

review-PR compared with commands from other repositories

review-PR next to 6 commands from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
review-PRbredmond1019/claude-sdk-rsCommand231mo agoApache-2.0A0Claude Code
speckit.spex.submitrhuss/cc-spexCommand1223d agoApache-2.0A15Claude Code
merge-conflict-analysisrjmurillo/ai-agentsCommand49yesterdayMITA0GitHub Copilot
gitazrtydxb/procoderCommand21111d agoApache-2.0A20Claude Code
factoryfelvieira/claude-skills-fvCommand282d agoApache-2.0A47Claude Code
repo-audittractorjuice/arc-kitCommand2.3k2d agononeA29Claude Code
advanced-code-review-contextaxiomantic/spellbookCommand112d agoMITA19Claude Code