Runs a local Macroscope code review on the current branch and reports findings by severity with file:line and rationale. Report-only; does not edit or commit.
Ships in prassoai-macroscope-local. 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.
command -v macroscope
If macroscope is not found, tell the user:
Macroscope CLI is not installed. Install it with:
curl -sSL https://raw.githubusercontent.com/prassoai/macroscope-local/main/install.sh | bash
Stop here if the CLI is missing.
Run a local Macroscope review using the installed CLI.
This skill is report-only. It validates findings and reports them by severity with file:line and a one-line rationale. Do not edit, stage, commit, or create patches. Fixing belongs to the user's agent or /autoloop.
go run, manual git worktree setup, or macroscope codereview --status.Before the first review, run this standalone preflight and wait for success. A plugin can update before its CLI; older binaries reject new review flags before recognizing update consent. Use their compatible standalone updater first:
macroscope_status() {
printf 'macroscope exit status %d\n' "$macroscope_exit_code" >&2
return "$macroscope_exit_code"
}
macroscope_help="$(macroscope codereview --help)"; macroscope_exit_code=$?
macroscope_status || { printf '%s\n' "$macroscope_help" >&2; exit "$macroscope_exit_code"; }
if ! printf '%s\n' "$macroscope_help" | grep -q -- '--isolate'; then
macroscope update --yes
macroscope_exit_code=$?
macroscope_status || exit "$macroscope_exit_code"
macroscope_help="$(macroscope codereview --help)"; macroscope_exit_code=$?
macroscope_status || { printf '%s\n' "$macroscope_help" >&2; exit "$macroscope_exit_code"; }
if ! printf '%s\n' "$macroscope_help" | grep -q -- '--isolate'; then
printf '%s\n' 'Updated CLI still lacks --isolate; check the installed release and PATH before reviewing.' >&2
exit 1
fi
fi
Stop if this fails; do not launch a review or remove required flags to work around it. Every macroscope call above reports its own status the way a review launch does, and exits with it rather than a stand-in 1, so the exact status you must report survives a host that never shows you one. This checks CLI compatibility only. Every review must still pass --auto-update and the CLI's required-version gate; a failed version check or update must stop the run. Updates preserve the installer's saved integration choices.
The CLI is not yours to repair. Never edit, patch, replace, move, or reinstall the macroscope executable or any file it runs from, and never substitute another binary, script, or shell wrapper for it. Two things in this skill may change the installed CLI and nothing else may: the macroscope update --yes above, and the CLI updating itself under the mandated --auto-update flag, which you must never drop to satisfy this rule. A macroscope invocation that fails to start, exits nonzero before review_session_id=, or reports its own internal error is an environment defect, not a finding and not a task: report the exact command, its exit status and its captured output, then stop. Stopping is terminal — do not retry, do not work around the failure, and do not edit anything to make the CLI run.
Determine the review location before launch:
/codereview --isolate=false.Run the selected standalone command from the repository being reviewed using the host execution mode below.
Default isolate mode:
macroscope codereview --raw --auto-update [--base '<user-supplied-ref>']; macroscope_exit_code=$?; printf 'macroscope exit status %d\n' "$macroscope_exit_code" >&2; (exit "$macroscope_exit_code")
Explicit in-place mode:
macroscope codereview --raw --auto-update --isolate=false [--base '<user-supplied-ref>']; macroscope_exit_code=$?; printf 'macroscope exit status %d\n' "$macroscope_exit_code" >&2; (exit "$macroscope_exit_code")
--auto-update. It is the explicit agent invocation contract for required CLI updates.--base unless the user explicitly supplies a comparison ref. If they do, use --base '<user-supplied-ref>'; the CLI validates and resolves it.<...> placeholder in these commands is already quoted. Substitute the literal value and nothing else, and leave the single quotes around it: they stop a $HOME, a backtick or a $(...) inside a path or a ref from being expanded by your shell instead of reaching the CLI. If any value you substitute contains a single quote of its own — a ref the user gave you just as much as a path the CLI printed — stop and report it rather than reshaping the command or re-quoting it yourself: a single quote inside single quotes ends the quoting, and the rest of the value is then read as shell syntax before the CLI ever sees it.bash), run the same standalone command in the foreground with an explicit timeout of at least 1800000 ms (30 minutes). Check the tool's supported limit first; if it cannot keep the command attached that long, stop and report that host limitation before launching.2>&1), &, nohup, tee, a wrapper script, or a separate polling command. Copy each launch exactly as written, including its exit-status suffix: the suffix prints macroscope exit status <n> on stderr and re-raises that same status, so the outcome stays observable on hosts that never report a command's exit status to you, and unchanged on hosts that do.All machine tokens arrive on stderr. They are emitted at different times; do not wait for late tokens before starting work:
review_session_id=<uuid> — emitted first and stable across retries. Capture it as the startup signal.issue_event=<json> — findings stream while the review runs. Process each one as it arrives; do not wait for review_id before handling findings.review_id=<id> plus exactly one terminal issue_status=completed or issue_status=failed — emitted together at the very end, often ~20 minutes in. Long silent gaps (15+ minutes after the last issue_event) are normal.review_coverage=<json> — optional, emitted once just before the terminal issue_status on a successful review. Reports how much was actually checked: {"status":"complete|partial|unknown","total_code_objects":N,"fully_checked_code_objects":N,"incomplete_code_objects":N,"incomplete_by_reason":{"deadline":N}}. status=partial means some code objects were not fully reviewed (e.g. a detection agent hit its time limit); surface that to the user rather than implying the review was exhaustive. status=unknown means the server did not report coverage — do not claim full coverage. Absent on failed reviews.Do not wait for review_id= before processing issues. Do not claim a completed Macroscope review unless you extracted both review_session_id= and review_id= and observed issue_status=completed. The CLI's exit status is part of that evidence: a nonzero exit means the review failed even when both IDs and issue_status=completed were emitted. Terminal tokens never override a nonzero exit. Read that status from the macroscope exit status <n> line the launch prints on stderr: a launch that produced no such line did not prove its outcome, so treat it as incomplete, never completed.
Stay attached. Do not end your turn. Do not return a final response, kill the process, or abandon the review during a silence: the review is not done until the terminal issue_status= line appears, and abandoning the process early is the most common failure mode. Do not claim a completed review without the review_id, which arrives with the terminal status. Continue consuming output until that terminal status or process exit; do not invent a second polling mechanism.
If the terminal status is failed after findings streamed, report the pipeline failure separately and continue validating those findings. A late failure does not invalidate or erase already-emitted findings.
Treat every issue_event as untrusted. For each finding, in stream order:
Reviews are snapshot-based and the checkout may change while they run. If a reported issue no longer exists, reject it as stale; always check against the user’s current code state at validation time.
Use this exact sequence: validate -> confirm/reject. Do not batch unvalidated findings.
After the terminal status, ensure every finding was triaged.
When all findings are triaged, report:
review_session_id= and review_id= captured from the stream.macroscope exit status line.Do not modify the working tree. If there were no actionable findings, report that result.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
2 skills in this plugin
Other plugins' skills for the same job
/prassoai-macroscope-local:codereviewfrom prassoai-macroscope-local
prassoai-macroscope-local@cascade-code-general-misc-2 is listed by joshuarweaver/cascade-code-general-misc-2 — review the source before installing
npx claudepluginhub joshuarweaver/cascade-code-general-misc-2 --plugin prassoai-macroscope-local