.agents/skills/autoreview/SKILL.md
Run the bundled structured review helper as a closeout check. This is code review, not Guardian auto_review approval routing.
Codex review is the default when no engine is set. It usually delivers the best review results and should remain the normal final closeout engine.
Use when:
codex review, nested reviewers, or reviewer panels from inside the review. The helper builds one bundle, calls one selected engine, validates one structured result, and stops.gh/Gitcrawl reports database disk image is malformed, run gitcrawl doctor --json once to let the portable cache repair before retrying review; do not bypass the shim unless repair fails and freshness requires live GitHub.gitcrawl doctor --json and inspect source_db_health, runtime_db_health, and portable_store_status before falling back to live GitHub.Dirty local work:
<autoreview-helper> --mode local
Use this only when the patch is actually unstaged/staged/untracked in the
current checkout. For committed, pushed, or PR work, point the helper at the commit
or branch diff instead; do not force --mode local / --uncommitted just
because the helper docs mention dirty work first. A clean local review
only proves there is no local patch.
Branch/PR work:
<autoreview-helper> --mode branch --base origin/main
Optional review context is first-class:
<autoreview-helper> --mode branch --base origin/main --prompt-file /tmp/review-notes.md --dataset /tmp/evidence.json
If an open PR exists, use its actual base:
base=$(gh pr view --json baseRefName --jq .baseRefName)
<autoreview-helper> --mode branch --base "origin/$base"
Committed single change:
<autoreview-helper> --mode commit --commit HEAD
or with the helper:
/Users/steipete/Projects/agent-scripts/skills/autoreview/scripts/autoreview --mode commit --commit HEAD
Use commit review for already-landed or already-pushed work on main. Reviewing
clean main against origin/main is usually an empty diff after push. For a
small stack, review each commit explicitly or review the branch before merging
with --base.
Format first if formatting can change line locations. Then it is OK to run tests and review in parallel:
scripts/autoreview --parallel-tests "<focused test command>"
Tradeoff: tests may force code changes that stale the review. If tests or review lead to code edits, rerun the affected tests and rerun review until no accepted/actionable findings remain. Once that rerun exits cleanly, stop; do not spend another long review cycle on redundant confirmation.
Run the helper directly so target selection, engine choice, structured validation, and exit status all stay in one path. If output is noisy, summarize the completed helper output after it returns; do not ask another agent or reviewer to rerun the review.
OpenClaw repo-local helper:
.agents/skills/autoreview/scripts/autoreview --help
agent-scripts checkout helper:
skills/autoreview/scripts/autoreview --help
Global helper from agent-scripts:
~/.codex/skills/agent-scripts/autoreview/scripts/autoreview --help
If installed from agent-scripts, path is:
/Users/steipete/Projects/agent-scripts/skills/autoreview/scripts/autoreview --help
The helper:
gh pr view worksorigin/main for non-main branches--engine codex, claude, droid, copilot, pi, and opencode; default is AUTOREVIEW_ENGINE or codex; Codex should remain the default when nothing is set--engine pi requires an explicit --model because the helper isolates Pi's config directory during review--mode commit --commit <ref> for already-committed work, especially clean main after landing--mode auto or forced to --mode branch for PR/branch work; do not force --mode local after committing--output or --json-output is set--dry-run, --parallel-tests, --prompt, --prompt-file, --dataset, --no-tools, --no-web-search, and commit refscodex exec with read-only sandbox and structured outputautoreview clean: no accepted/actionable findings reported when the selected review command exits 0Include:
Do not run another review solely to improve the final report wording. If the final helper run exited 0 and produced no accepted/actionable findings, report that exact run as clean.