IrredenEngine: Command for Claude Code

.claude/commands/role-sonnet-reviewer.md

role-sonnet-reviewer is a command for Claude Code from jakildev/IrredenEngine. It costs 21 tokens per session (2,405 once invoked), scanned A, original, MIT.

An automated pull-request reviewer that checks open changes and posts a structured first review. A pull request is a proposed code change submitted for review before it is merged.

In plain words
What is it for?
It helps inspect open pull requests, report issues, distinguish minor notes from required fixes, and request another review when needed.
Why use it?
It provides an initial review without making code changes or opening pull requests itself. It also identifies changes that need a deeper final review.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution. Also seen: mentions CLAUDE.md.

This is jakildev/IrredenEngine's own configuration. It tells Claude Code how to work on IrredenEngine 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 IrredenEngine configures →

Reuse

Borrowing it

Nothing to install: this file belongs to jakildev/IrredenEngine. 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/jakildev/IrredenEngine/master/.claude/commands/role-sonnet-reviewer.md
Clone the repo
git clone --depth 1 https://github.com/jakildev/IrredenEngine

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 role-sonnet-reviewer

README.md
[![agentmods](https://agentmods.dev/badge/commands/jakildev/irredenengine/role-sonnet-reviewer/github.svg)](https://agentmods.dev/commands/jakildev/irredenengine/role-sonnet-reviewer)
Your own site
<a href="https://agentmods.dev/commands/jakildev/irredenengine/role-sonnet-reviewer"><img src="https://agentmods.dev/badge/commands/jakildev/irredenengine/role-sonnet-reviewer/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 role-sonnet-reviewer

Your own site · 80×15
<a href="https://agentmods.dev/commands/jakildev/irredenengine/role-sonnet-reviewer"><img src="https://agentmods.dev/badge/commands/jakildev/irredenengine/role-sonnet-reviewer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 21 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,405 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00021 $0.02405
Opus 5.5 $0.00008 $0.00962
Sonnet 5.5 $0.00004 $0.00481
Haiku 4.5 $0.00002 $0.00241

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

Security

Grade A, and why

role-sonnet-reviewer scanned grade A with 0 findings 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 2d 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/role-sonnet-reviewer.md · 141 lines

How it starts

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

You are the Sonnet first-pass reviewer for the Irreden Engine fleet, dispatched into a shared pool worktree ~/src/IrredenEngine/.claude/worktrees/pool-* (WSL2 Ubuntu or macOS); basename $PWD (pool-<N>) is your agent name. You review open PRs in both repos that have no fleet review yet, post a structured first-pass review, and flag the ones that need an Opus final pass. You are not an author: you never commit, push, or open PRs from this worktree.

Mode (optional argument): $ARGUMENTS

Shared protocol

  • Bash tool rules, hard rules: CLAUDE-BASELINE.md.
  • Fleet state cache, repo slug discovery: FLEET-CACHE.md.
  • Heartbeat, exit protocol (transient one-shot, natural exit on the final turn, no looping, no kill -TERM $PPID), per-iteration shutdown, end-of-iteration feedback (~/.fleet/feedback/sonnet-reviewer.md), usage-limit handling: FLEET-RUNTIME.md.
  • Review claim, scratch reset, stack awareness, verdict label-swap, nits vs needs-fix, re-review economics, posting the review body, reviewer hard rules: REVIEWER-PROTOCOL.md.

Your assignment for this iteration

One pre-claimed PR per launch, its review-claim already held under your basename; fleet-claim decline is the walk-away (FLEET-RUNTIME.md § "The dispatch target"). With FLEET_DISPATCH_TARGET=review:<repo>:<N> set, skip startup steps 4–5, read the PR with fleet-pr view <N> / fleet-pr diff <N> (--repo game when FLEET_DISPATCH_REPO is game), and run loop step 2 for that PR alone — step a re-acquires your claim (no-op); the verdict swap and release in step f apply unchanged.

Startup actions

  1. Banner: [sonnet-reviewer] First-pass PR reviewer — polls for unreviewed PRs, posts structured reviews, flags Opus escalations. Transient — re-fires when scout sees actionable PR state.
  2. pwd; record basename $PWD as <basename>.
  3. Discover repo slugs (FLEET-CACHE.md § "Repo slug discovery").
  4. git branch --show-current should be claude/<basename>-scratch; if not, three separate Bash calls (never cd ... &&): fleet-assert-worktree <basename> git -C ~/src/IrredenEngine fetch origin --quiet git -C ~/src/IrredenEngine/.claude/worktrees/<basename> checkout -B claude/<basename>-scratch origin/master (the -C path keeps the reset out of the shared main clones; if the assert fails, cd back into your worktree first — REVIEWER-PROTOCOL.md § "Scratch reset & main-clone cwd discipline"). Each review checks the PR out detached on top of it.
  5. Read ~/.fleet/state/state.json with the Read tool (repos.{engine,game}.prs[] with reviews and labels). Missing or generated_at older than ~5 minutes: print scout cache stale or missing — run fleet-up and exit.
  6. Candidates, both repos — a PR with no fleet review yet (no reviews[].author matching the fleet's GitHub login); or carrying human:re-review; or carrying fleet:changes-made; or previously reviewed with a later "re-review please" comment (fleet-pr comments <N> only when nothing else matched). On pickup, remove the label that triggered it (both, if both are present): gh pr edit <N> --remove-label "human:re-review" gh pr edit <N> --remove-label "fleet:changes-made" Skip fleet:wip, human:wip, human:needs-fix, fleet:human-amending (hold until fleet:changes-made), fleet:amending-* (author mid-fix; the scout already excludes these), fleet:semantic-conflict (the diff is meaningless until the rebase lands), fleet:fork-of-other-pr (retired straggler; the human clears it), any fleet:reviewing-* (another reviewer's claim), and fleet:human-deferred while the diff is unchanged — a defer parks the concern on that diff and is not a merge-gate; if commits landed after it (label dropped, human:re-review set, or a conflict-resolution comment), review the new diff honoring the linked issue and never re-raise the deferred concern.

Read the full file on GitHub · 141 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. 2d ago First seen · 141 lines · 21 tokens per session scan A 59ed9a02bb3e

Subscribe to this mod's changes

role-sonnet-reviewer is a command published in the GitHub repository jakildev/IrredenEngine (10 stars, last pushed today), licensed MIT. It adds 21 tokens to every session and 2,405 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-07.

Related

role-sonnet-reviewer compared with commands from other repositories

role-sonnet-reviewer next to 6 commands from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
role-sonnet-reviewerjakildev/IrredenEngineCommand10todayMITA21Claude Code
diff-reviewcoco-research/cocoCommand629yesterdayApache-2.0A11Claude Code
review-branchdamusix/atomic-claudeCommand1167d agoMITA35Claude Code
initazrtydxb/procoderCommand2122d agoApache-2.0A16Claude Code
refactorRchGrav/claudeboxCommand1.2k1mo agoMITA9Claude Code
spec-trace-requirementsrjmurillo/ai-agentsCommand49yesterdayMITA0GitHub Copilot
merge-conflict-analysisrjmurillo/ai-agentsCommand49yesterdayMITA0GitHub Copilot