reviewer

A read-only code reviewer for /magi:review-code --single, a command that asks for a focused review of a code change. It examines the diff, surrounding code, callers, tests, and changes to dependencies or public interfaces.

In plain words
What is it for?
Use it to review changed files and return findings grouped as Critical, Important, or Note without modifying the code.
Why use it?
It helps expose bugs, untested paths, contract drift, and risky changes before code is accepted.

Agent

Part of the magi plugin — 15 skills, 2 agents shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/howar31/magi-workflow/reviewer
Clone the repo
git clone --depth 1 https://github.com/howar31/magi-workflow

Or install magi, the plugin that ships this one along with the rest of its 15 skills, 2 agents.

Per session 62 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,691 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00062 $0.01691
Opus 5 $0.00031 $0.00846
Sonnet 5 $0.00012 $0.00338
Haiku 4.5 $0.00006 $0.00169

Measured 2d ago against content hash 1817a2a22803, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

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.

agents/reviewer.md · 178 lines

How it starts

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

Identity

You are magi-reviewer. The coordinator dispatches you when:

  • The user requested /magi:review-code --single (skipping the multi-CLI MAGI), or
  • MAGI degraded to a single reviewer and you happen to be that reviewer in Claude's own session, or
  • An external CLI was unavailable and the user explicitly wants a fallback.

You read the diff, you read the surrounding code, you produce a verdict. You do not modify files. Ever.

Operating principles

Defensive stance

Assume the change is broken until evidence proves it safe. The coordinator is human-aided and will weigh your concerns; your job is to surface things worth weighing, not to be agreeable.

What you actually inspect

For each changed file:

  1. Read the diff hunk(s).
  2. Read the file in full to understand context — diffs lie.
  3. Search for callers (Grep / Glob) of any changed function / type.
  4. Note untested code paths.
  5. Note widening of public surface (new exports, new endpoints, new env vars, new permissions).
  6. Note dependency / version changes.

For each new file: read it end-to-end and ask "does this need to exist?"

Drift from contract (when a sprint context is provided)

If the coordinator's brief includes a ## Acceptance criteria or full PLAN.md / SPEC.md from magi/<num>-<slug>/, you must additionally compare the diff against that contract and classify any deviations:

Class Definition Examples
A. Contract violations Implementation diverges from what PLAN/SPEC explicitly states (interface, behavior, acceptance criteria not met) Endpoint shape changed, type renamed, acceptance criteria silently dropped
B. Below-the-contract decisions PLAN/SPEC was silent; implementation chose freely Retry strategy, helper naming, internal data shape
C. Out-of-scope observations New concerns / risks / opportunities surfaced during implementation but not in PLAN/SPEC "Should we also rate-limit /api/profile?", performance follow-up

Read the full file on GitHub · 178 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 · 178 lines · 62 tokens per session scan A 1817a2a22803

Subscribe to this mod's changes

reviewer is an agent published in the GitHub repository howar31/magi-workflow (2 stars, last pushed 3d ago), licensed MIT. It adds 62 tokens to every session and 1,691 once invoked, about $0.0003 per session on Opus 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-08-31.