/magician:divine [PR/MR URL · branch · "working tree" · monitor <repo>]from magician
Performs research-grounded multi-lens code review of a PR/MR or changeset, severity-ranked with findings and fix suggestions. Use for auditing diffs; not for remediation.
Ships in magician. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Bundled command: if
kgis not found, run it as${CLAUDE_PLUGIN_ROOT}/tools/kgand give subagents that full path. If that is missing too (Claude chat ships no plugin tools), skip thekgsteps and search the code directly.
Review a change for correctness, security, simplification and test quality, grounded in its intent and in external truth. Rank by severity, tag each finding, give a fix. This is the on-demand, PR/MR-aware reviewer. /scrutinize reviews the branch diff mid-flow and remediates. /divine reports, and fixes only on request.
Remove the scan marker (rm -f .workspace/local/security-scan.active), then close with the quoted signal:
"Divine complete. <N Important, N Nit, N Pre-existing; N fixed, N closed with reason>. Fix in-repo with /scrutinize or /ward task ; verify with /certify, then /seal."
Trigger phrases: "do a code review", "review this PR/MR", "review my changes/diff/branch", "audit this MR". Not for the review that remediates (/scrutinize) or a security-only scan (/sentinel). /transmute invokes /divine as its G7 gateway, checked against .workspace/shared/research/<feature>-parity.md.
On review intent, announce:
"Auto-activating /divine for a structured code review. I will establish the change context, then confirm how deep to go."
The review speaks the dialect in lore/review.md. Nits are capped. Remediation runs at most three rounds, diff-only after the first, with a round ledger. The report contract is in Phase 4.
If REVIEW.md exists at the repository root, Read it first. Its values override the defaults, and its text goes into every lens prompt. Platform alternatives (/code-review, claude ultrareview --trust-workspace, the @claude review GitHub flow) are in lore/deep/review.md#platform-surfaces. Recommend one when it fits better.
Monitor mode: when $ARGUMENTS starts with monitor (/loop 1h /divine monitor <repo>: unattended, no fixes), skip the interactive phases and follow references/monitor-mode.md.
Read references/change-context.md. Resolve the target from $ARGUMENTS (a PR/MR URL, a branch, or "working tree"). Gather the diff and changed files, the base ref, the PR/MR description and tickets, CI status, and in-repo grounding. Drop the REVIEW.md skip paths. Summarize the change and its scale in two sentences, silently.
Four depths: Quick, Standard (default), Deep, Exhaustive. The matrix is in references/depth-and-research.md. A High-tier change per REVIEW.md gets Deep at least. At Deep or Exhaustive, or on unfamiliar ground, invoke /magic first for external truth. Prefer the latest coding model; suggest it, never switch silently (lore/models.md).
After the depth gate, run to completion without more questions: context reads, kg blast radius, lens dispatch, verification, the report. Re-gate only on side effects: a post to the PR/MR (Phase 5) and, on request, edits, commits and pushes (Phase 6). Web fetches show Claude Code's normal prompt. Doctrine: lore/autonomy.md.
First run mkdir -p .workspace/local && touch .workspace/local/security-scan.active. While the marker exists, the PreModelSwitch hook holds a model switch for confirmation. Remove it in the Completion Signal and on any early exit.
Lenses: magician:reviewer (correctness), magician:sentinel (security, supply chain), magician:simplifier (over-engineering), magician:verifier (tests, Deep and Exhaustive, always fresh). Pick the path by the measured diff size (lore/fold-first.md):
agents/<lens>.md as its checklist. Quick depth here makes no Agent call. A High-tier change dispatches its lenses fresh at any size..workspace/shared/diffs/<ref>.patch, then dispatch the lenses in parallel, in one message. Fork or fresh follows lore/deep/review.md#fork-or-fresh.Each spawn prompt is self-contained (goal, patch path, intent, grounding, REVIEW.md text, ledger path, return format). Templates in references/dispatch.md, contract in lore/subagent-context.md. On NEEDS_CONTEXT, add the input and re-dispatch.
Finders optimize for recall. Never tell a lens to be conservative or to skip nits. Phase 3 removes the noise, and it can only remove what the finders surfaced.
Try to refute every Critical and High finding against the code and the intent, in a fresh context, never in a fork. At Exhaustive, use independent votes. At Quick on a small diff, run this check in the main loop and state Verification: in-loop in the report. Keep the survivors, list the rest as dropped. Details in references/depth-and-research.md.
Deduplicate and rank, then read references/report-format.md and follow its template. The contract:
N Important, N Nit, N Pre-existing; N fixed, N closed with reason. Count it from the list you write.**[Important]**, **[Nit]**, **[Pre-existing]**) and cites file:line, never a bare file, with impact and fix.Present the report in chat. For a real PR/MR, offer to post:
A post publishes on the user's behalf. Confirm through `AskUserQuestion`, show the exact text, and check the GitHub/GitLab account before any `gh` or `glab` write. Never post without a clear yes.Commands and inline-comment format: references/report-format.md.
Offer fixes through AskUserQuestion. The default is "just report". The round flow, the ledger, and the commit and push gate are in references/remediation.md.
As a consumer, roll the lenses' Obstacles blocks into one report, separate from the findings. Memorize a confirmed pattern with ctx learn --add "<signature -> workaround>" in your own words, never secrets or PII. As a producer, on a non-clean run return the Obstacles block from lore/obstacles.md (fields: STATUS, OBSTACLE, BLOCKER, SEVERITY, WORKAROUND, RECURRENCE, SCOPE, NEXT) with what you completed.
references/change-context.md (opens in a new tab)references/depth-and-research.md (opens in a new tab)references/dispatch.md (opens in a new tab)references/monitor-mode.md (opens in a new tab)references/remediation.md (opens in a new tab)references/report-format.md (opens in a new tab)references/review-md-template.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
highThree short reads, in order
npx claudepluginhub alexander-tyagunov/magician --plugin magician25 skills in this plugin
/acceleratePerformance profiling and optimization, baseline first. Use when something is slow or must hit a latency/throughput target./almanacOne-time workspace setup; .workspace/, .gitignore, CLAUDE.md, optional AGENTS.md and REVIEW.md. Run once per project./autopsyBlameless post-mortem / RCA; timeline, 5-Whys, action items, committed write-up. Use after an incident or outage./blueprintTurns an approved spec into a TDD task plan, parallelism map and plan.md + plan.html. Use after spec approval, before coding.Other plugins' skills for the same job