/caddis-extras:cross-reviewfrom caddis-extras
Have a different vendor's model (agy Carbon by default; DeepSeek, GLM, any OpenAI-compatible endpoint) review the current diff. Use after a phase is green and before commit/merge, or for a second opinion on a risky diff.
Ships in caddis-extras. 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.
None: SKILL.md is the whole skill.
A different vendor's model has different blind spots. Claude reviewing Claude's diff shares those blind spots; an agy Carbon (default), DeepSeek, GLM or other OpenAI-compatible reviewer catches a different class of issue. This skill runs that second reviewer over the current changes and acts on its verdict.
/caddis:code-review — this is the cross-vendor complement.python "$TOOL" --check-config
Exit 0 prints which providers are available (agy-carbon needs no key, only agy on PATH and caddis_spend.py). Exit 3 means nothing is configured — stop and ask the user before reading any diff. Do not proceed, and do not silently skip the review.
Ask with AskUserQuestion which provider to set up, then write the key to ~/.caddis/keys.env as
DEEPSEEK_API_KEY=<key> (or the matching variable). That file sits outside every git repo, so it
cannot be committed by accident. Never put a key in the repo, in a command, or in a reply.
This used to fail mid-task with a commit pending — the worst moment to go hunting for a credential. A command that fails once at an inconvenient moment does not get retried, so the safety check is quietly lost and nothing records the loss. The script stays non-interactive because it also runs headless, where a stdin prompt hangs instead of asking; the asking is the agent's job.
If a key exists for a different provider than the one requested, the error names it and gives the
exact flag (--provider glm). Read the message before concluding anything is missing.
The default reviewer is agy Carbon (agy since 2026-10-21, Carbon since 2026-11-12; no key, but agy and caddis_spend.py must be present). For an HTTP
provider only the key is mandatory — the tool ships provider presets (deepseek, glm, openrouter):
REVIEW_API_KEY = <your provider key> # REQUIRED (exit 3 without it)
REVIEW_PROVIDER = deepseek # optional: agy-carbon | deepseek | glm | openrouter (default agy-carbon; agy-argon is an old name)
REVIEW_BASE_URL = ... # optional: overrides the preset's URL
REVIEW_MODEL = ... # optional: overrides the preset's model id
Switch provider with one flag: --provider glm (or REVIEW_PROVIDER=glm, in the env or in ~/.caddis/keys.env; flag, then env,
then keys file, then agy Carbon). To make DeepSeek the default again, add REVIEW_PROVIDER=deepseek to ~/.caddis/keys.env. Future-proofing: model ids
churn — the preset table in oss_review.py is the one place to edit a rename, and REVIEW_MODEL /
REVIEW_BASE_URL always win, so you can point at any new id without touching code.
From the repo root. Resolve the tool path deterministically — check only these two exact locations, in order, and never search the filesystem for it (see Rules below):
# THE PLUGIN COPY WINS. It is the one `caddis update` refreshes; a vendored copy is a snapshot
# of whatever caddis shipped the day someone copied it, and it never updates again.
if [ -f "${CLAUDE_PLUGIN_ROOT}/scripts/oss_review.py" ]; then
TOOL="${CLAUDE_PLUGIN_ROOT}/scripts/oss_review.py"
# A vendored copy that DIFFERS is a live hazard, not a curiosity — say so, do not stay silent.
if [ -f ".github/tools/oss_review.py" ] && ! diff -q ".github/tools/oss_review.py" "$TOOL" >/dev/null 2>&1; then
echo "[cross-review] WARNING: .github/tools/oss_review.py differs from the caddis copy and is"
echo " being IGNORED. Delete it, or keep the local change deliberately."
fi
elif [ -f ".github/tools/oss_review.py" ]; then
TOOL=".github/tools/oss_review.py" # no plugin present — the vendored copy is all there is
else
echo "oss_review.py not found at either known location — report this and stop. Do NOT search for it."
exit 3
fi
Why the plugin copy is first. It used to be second. On 2026-08-10 a repo ran a stale vendored
oss_review.pyand gotREVIEW: CLEANon a database write path that was never reviewed. The bug had been fixed on 2026-08-01 — the fix just never reached the caller, because a file someone copied weeks earlier silently won.caddis_gate.py vendor-driftnow fails on the same condition.
python "$TOOL" # review the working tree (staged+unstaged)
python "$TOOL" --range origin/main..HEAD # review a branch's commits
Optional flags: --cwd <repo>, --base-url <url>, --model <id> (override the env).
Diff-size ceiling. A diff over REVIEW_MAX_DIFF_CHARS (default 60,000 chars) is split into batches on whole-file boundaries and each batch reviewed separately (verdict is CLEAN only if every batch is). When agy Carbon is anywhere in the provider chain, each batch is also kept small enough that its whole prompt fits the agy command line (28,000 chars once quoted, so under about 27,000 diff chars, fewer when the diff has many "). A single file too big for agy gets its own batch: agy skips it and the next provider reviews it; with no other provider (no DeepSeek or GLM key) that is exit 3. Exit 4 means a single unsplittable file over the 60,000 ceiling, or too many batches — not an ordinary large diff. The ceiling exists because an oversized diff has been observed to come back either an empty response, or
worse, a REVIEW: CLEAN with zero real engagement. If you hit this, review that file separately or narrow --range; don't just raise --max-diff-chars without knowing the endpoint's real limit.
Verdict and scope. Only the last non-empty line of the reply counts, and it must be exactly REVIEW: CLEAN or REVIEW: BLOCKING; a reply that quotes the marker earlier and ends some other way has no verdict (exit 4). An explicit --range with no changes is exit 3 (a review of nothing is not CLEAN); the working tree with no changes is still CLEAN. When the secret filter drops some files, the output ends with REVIEW-SCOPE: PARTIAL (<n> file(s) excluded by the secret filter: <names>) and then the overall REVIEW: line. The exit code does not change, but those files were not reviewed: say so, and never report it as a full CLEAN.
--range has no changes, or every provider failed. Fix it (see Prerequisites) and re-run.python "${CLAUDE_PLUGIN_ROOT}/scripts/caddis_gate.py" review-tier --range <base>...HEAD (add --plan <plan> --phase <N> inside a plan; no TIER: line means tier 2).
Tier 0: gates only. Tier 1-small: your self-check only. Tier 1: one review by another vendor; stop at
the first CLEAN. Tier 2: one review by another vendor (two only when the owner asks). Fix blocking findings only;
park the rest. Re-review only the fix diff, and only when the fix changed logic. After 3 rounds, ask the owner.A diff over the batch ceiling is split into batches. Each batch prompt lists every file in the change, so a batch does not report the others as missing.
.caddis/reviews/, never in .caddis/parking-lot/: that folder holds only items to do later, one item per file, type: parking-lot (/caddis:park).find, Get-ChildItem -Recurse, or any other filesystem-wide search to locate
oss_review.py. Check only the two paths above. On Git Bash under Windows, find / (or any
search rooted at /) walks every mounted drive, not just the repo — it can hang or take minutes.
If neither path exists, stop and report it; don't go hunting for the file.What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub saajunaid/caddis-plugin --plugin caddis-extras81 skills in this plugin
/adopt-rbacPointer to the org's RBAC adoption skill. Use for "add RBAC to this app" or "adopt rbac-kit"./agent-md-refactorRefactor bloated agent instruction files (AGENTS.md, .cursorrules, .github/ files) into linked, progressively disclosed docs./agent-orchestrationBlueprint for orchestrating the agent pipeline from spec to planning, implementation, testing and debugging, plus when a second model is worth it, the intent→model map and cost guardrails.