Files
claude-foundations/memory/script-review-minimax-run.md
Paul O'Reilly df243cd953 docs: memory + usage docs for review-minimax and ci-triage-minimax offloads
Four memory docs (2 skills, 2 wrapper scripts) + MEMORY.md index lines;
ask-minimax-usage.md gains both delegation targets. Records the gac
v0.0.2.10 token-discovery gap (needs GITEA_TOKEN_FILE pointed at
ai_admin/token; the wrapper defaults it).

Claude-Session: https://claude.ai/code/session_01Ku87DDWwbJkTx6SuV3sQDc
2026-09-11 13:48:22 +12:00

1.6 KiB

review-minimax-run

Quick reference

review-minimax-run --worktree <path> [--base main] [--out <file>]
    [--profile agent-runtimes] [--max-diff-lines 6000] [--max-turns 40]
    [--timeout 540] [--dryrun|-n]

Exit: 0 findings written · 1 usage/secrets/credential-diff/empty/oversize · 2 MiniMax failed / timeout / dirtied tree · 3 gate failure. Spec: small-scripts/specs/review-minimax-run.spec.md.

How it works

Materialises git diff base...HEAD (secret-excluding pathspecs) + log + stat into a scratch dir; runs ask-minimax-run --model "MiniMax-M3[1m]" --permission-mode default --allowedTools "Read,Glob,Grep,Write" --disallowedTools "…,Bash,…" from that dir with --add-dir for worktree (context reads) and out-dir; gates the findings file (severity block + resolvable citation, or NO FINDINGS); asserts the worktree is still clean; one retry with the out-file removed first (catches the exit-0-no-file MiniMax mode); never retries rc 124.

Test seams: REVIEW_MINIMAX_FAKE_JSON (canned envelope) + REVIEW_MINIMAX_FAKE_FINDINGS (plays the sub-session's Write) — gates still run, so tests cover exits 0/2/3 offline (tests/test-review-minimax-run.sh).

Gotchas

  • Credential-shaped diff content is a hard abort (exit 1), not a redaction — a credential in a branch diff is itself a finding for in-session review.
  • The citation gate requires a Location: path that resolves against the worktree; a bare :NNN (timestamps, counters) is not accepted.
  • Telemetry line on stderr reports contextWindow — should read 1000000; 200k means the [1m] pin or provider.env override is broken.