mm scripts: default to MiniMax-M3.1-Flash-Preview with per-script effort

Flash is the default model; --m3 falls back to M3, --effort overrides.
Defaults: max (review-minimax, review-loop, mm-worktree-task), medium
(explore), low (ci-triage). ask-minimax-run applies MINIMAX_EFFORT to
Flash models when --effort is not passed. Bump stale fixture date.
This commit is contained in:
Paul O'Reilly
2026-10-13 10:23:53 +13:00
parent d6e0220bf5
commit 840d7509e1
16 changed files with 134 additions and 30 deletions

View File

@@ -1 +1 @@
{"documents": [{"name": "notes.md", "updated_at": "2026-09-01T00:00:00Z"}, {"name": "old-notes.md", "updated_at": "2020-01-01T00:00:00Z"}]}
{"documents": [{"name": "notes.md", "updated_at": "2026-10-10T00:00:00Z"}, {"name": "old-notes.md", "updated_at": "2020-01-01T00:00:00Z"}]}

View File

@@ -27,6 +27,16 @@ assert_contains() {
fi
}
assert_not_contains() {
local label=$1 needle=$2 haystack=$3
if [[ "$haystack" != *"$needle"* ]]; then
printf " ${GREEN}PASS${NC} %s\n" "$label"; PASS=$((PASS + 1))
else
printf " ${RED}FAIL${NC} %s\n" "$label"
printf " expected NOT to contain: %s\n" "$needle"; FAIL=$((FAIL + 1))
fi
}
assert_eq() {
local label=$1 expected=$2 actual=$3
if [[ "$expected" == "$actual" ]]; then
@@ -70,10 +80,20 @@ echo "== dryrun =="
DRY_OUT="$("$SCRIPT" --repo skynet/gac-scratch --run 42 --dryrun 2>&1)"
assert_eq "dryrun exits 0" 0 $?
assert_contains "dryrun shows gac command" "inspect skynet/gac-scratch --run 42" "$DRY_OUT"
assert_contains "dryrun shows model pin" "MiniMax-M3[1m]" "$DRY_OUT"
assert_contains "dryrun defaults to Flash" "MiniMax-M3.1-Flash-Preview" "$DRY_OUT"
assert_contains "dryrun default effort low" "--effort low" "$DRY_OUT"
assert_contains "dryrun defers fetch" "not fetched in dryrun" "$DRY_OUT"
assert_contains "dryrun shows job passthrough default" "job: auto" "$DRY_OUT"
echo "== dryrun --m3/--effort =="
M3_OUT="$("$SCRIPT" --repo skynet/gac-scratch --run 42 --m3 --dryrun 2>&1)"
assert_eq "m3 dryrun exits 0" 0 $?
assert_contains "m3 dryrun shows M3 model" "MiniMax-M3[1m]" "$M3_OUT"
assert_not_contains "m3 dryrun sends no effort" "--effort" "$M3_OUT"
EF_OUT="$("$SCRIPT" --repo skynet/gac-scratch --run 42 --effort high --dryrun 2>&1)"
assert_contains "explicit effort overrides default" "--effort high" "$EF_OUT"
"$SCRIPT" --repo o/r --run 1 --effort bogus --dryrun >/dev/null 2>&1; assert_eq "bad effort exits 1" 1 $?
echo "== fake logs: redaction + failing step in prompt, exit 0 =="
OUT0="$TMP/out0.md"
RUN_OUT="$(CI_TRIAGE_FAKE_LOGS="$FAKE_LOGS" CI_TRIAGE_FAKE_JSON="$FAKE_OK_JSON" CI_TRIAGE_FAKE_TRIAGE="$FAKE_TRIAGE" \

View File

@@ -83,7 +83,15 @@ assert_contains "dryrun shows worktree path" ".claude/worktrees/mm-testslug" "$D
assert_contains "dryrun shows branch name" "mm/testslug" "$DRY_OUT"
assert_contains "dryrun shows bundle path" "testslug-bundle.md" "$DRY_OUT"
assert_contains "dryrun shows the ask-minimax-run command" "ask-minimax-run" "$DRY_OUT"
assert_contains "dryrun command uses MiniMax-M3[1m] model" 'MiniMax-M3[1m]' "$DRY_OUT"
assert_contains "dryrun command defaults to Flash model" 'MiniMax-M3.1-Flash-Preview' "$DRY_OUT"
assert_contains "dryrun default effort max" "--effort max" "$DRY_OUT"
M3_OUT="$("$SCRIPT" "$TEST_UUID" --slug testslug --m3 --dryrun 2>&1)"
assert_eq "m3 dryrun exits 0" "0" "$?"
assert_contains "m3 dryrun uses M3[1m] model" 'MiniMax-M3[1m]' "$M3_OUT"
assert_not_contains "m3 dryrun sends no effort" "--effort" "$M3_OUT"
EF_OUT="$("$SCRIPT" "$TEST_UUID" --slug testslug --effort low --dryrun 2>&1)"
assert_contains "explicit effort overrides default" "--effort low" "$EF_OUT"
"$SCRIPT" "$TEST_UUID" --effort bogus --dryrun >/dev/null 2>&1; assert_eq "bad effort exits 1" "1" "$?"
assert_contains "dryrun bundles recent doc notes.md" "notes.md (bundled below)" "$DRY_OUT"
assert_contains "dryrun lists old doc as available only" "old-notes.md (available only)" "$DRY_OUT"
assert_not_contains "dryrun does not bundle stale doc body" "Stale notes, should not be bundled" "$DRY_OUT"

View File

@@ -19,6 +19,9 @@ assert_contains "dryrun banner" "[dryrun]" "$out"
assert_contains "nothing launched" "nothing launched" "$out"
assert_contains "task text is the spec template" "OUT OF SCOPE: reporting that a symbol" "$out"
assert_contains "context included" "Context: closes bug 1234" "$out"
assert_contains "defaults to Flash" "--model MiniMax-M3.1-Flash-Preview --effort max" "$out"
out_m3=$("$SCRIPT" launch --kind spec --name spec-Y --file "$TMP/spec.diff" --m3 -n 2>&1)
assert_contains "--m3 uses M3 with no effort" "--model MiniMax-M3 --allowedTools" "$out_m3"
assert_contains "output path uses tag" "spec-X-r1-result.md" "$out"
assert_contains "present default listed" "$TMP/bp/spec-driven-development.md" "$out"
assert_contains "absent default skipped" "default file absent, skipped" "$out"

View File

@@ -27,6 +27,16 @@ assert_contains() {
fi
}
assert_not_contains() {
local label=$1 needle=$2 haystack=$3
if [[ "$haystack" != *"$needle"* ]]; then
printf " ${GREEN}PASS${NC} %s\n" "$label"; PASS=$((PASS + 1))
else
printf " ${RED}FAIL${NC} %s\n" "$label"
printf " expected NOT to contain: %s\n" "$needle"; FAIL=$((FAIL + 1))
fi
}
assert_eq() {
local label=$1 expected=$2 actual=$3
if [[ "$expected" == "$actual" ]]; then
@@ -68,7 +78,15 @@ echo "== dryrun =="
DRY_OUT="$("$SCRIPT" --worktree "$REPO" --dryrun 2>&1)"
assert_eq "dryrun exits 0" 0 $?
assert_contains "dryrun shows branch" "branch: feature" "$DRY_OUT"
assert_contains "dryrun shows model pin" "MiniMax-M3[1m]" "$DRY_OUT"
assert_contains "dryrun defaults to Flash" "MiniMax-M3.1-Flash-Preview" "$DRY_OUT"
assert_contains "dryrun default effort max" "--effort max" "$DRY_OUT"
M3_OUT="$("$SCRIPT" --worktree "$REPO" --m3 --dryrun 2>&1)"
assert_eq "m3 dryrun exits 0" 0 $?
assert_contains "m3 dryrun shows M3 model" "MiniMax-M3[1m]" "$M3_OUT"
assert_not_contains "m3 dryrun sends no effort" "--effort" "$M3_OUT"
EF_OUT="$("$SCRIPT" --worktree "$REPO" --effort high --dryrun 2>&1)"
assert_contains "explicit effort overrides default" "--effort high" "$EF_OUT"
"$SCRIPT" --worktree "$REPO" --effort bogus --dryrun >/dev/null 2>&1; assert_eq "bad effort exits 1" 1 $?
assert_contains "dryrun shows deny list" "Bash,WebFetch,WebSearch" "$DRY_OUT"
assert_contains "dryrun prompt has findings format" "NO FINDINGS" "$DRY_OUT"
assert_contains "dryrun shows checklist" "shell=True" "$DRY_OUT"