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:
@@ -1,5 +1,5 @@
|
||||
#!/usr/bin/env bash
|
||||
# Launch a MiniMax M3 implementation sub-session in an isolated git worktree,
|
||||
# Launch a MiniMax implementation sub-session in an isolated git worktree,
|
||||
# with the prompt assembled from a planner work item. See specs/mm-worktree-task.spec.md.
|
||||
set -euo pipefail
|
||||
|
||||
@@ -15,7 +15,7 @@ usage() {
|
||||
cat <<'EOF'
|
||||
Usage: mm-worktree-task <item-uuid> [OPTIONS]
|
||||
|
||||
Launch a MiniMax M3 implementation sub-session (via ask-minimax-run) in an
|
||||
Launch a MiniMax implementation sub-session (via ask-minimax-run) in an
|
||||
isolated git worktree of the current repo, with the prompt assembled from a
|
||||
planner work item.
|
||||
|
||||
@@ -33,6 +33,9 @@ Options:
|
||||
--docs all|recent|none Which item documents to bundle (default: recent)
|
||||
--tools "<list>" Extra --allowedTools entries (comma-separated)
|
||||
--timeout <secs> Sub-session timeout (default: 1800)
|
||||
--m3 Use MiniMax-M3[1m] instead of the default MiniMax-M3.1-Flash-Preview
|
||||
--effort <level> Thinking depth low|medium|high|xhigh|max (default: max;
|
||||
not sent with --m3 unless given)
|
||||
--gate "<command>" Re-run this command in the worktree yourself, after
|
||||
the sub-session exits, against its LAST commit.
|
||||
Appended as a "Supervisor gate" section in the
|
||||
@@ -68,6 +71,8 @@ BASE="main"
|
||||
DOCS="recent"
|
||||
EXTRA_TOOLS=""
|
||||
TIMEOUT=1800
|
||||
USE_M3=0
|
||||
EFFORT_ARG=""
|
||||
GATE=""
|
||||
GATE_TIMEOUT=900
|
||||
UPLOAD=0
|
||||
@@ -87,6 +92,8 @@ while [[ $# -gt 0 ]]; do
|
||||
--gate) GATE="$2"; shift 2 ;;
|
||||
--gate-timeout) GATE_TIMEOUT="$2"; shift 2 ;;
|
||||
--context) CP_CONTEXT="$2"; shift 2 ;;
|
||||
--m3) USE_M3=1; shift ;;
|
||||
--effort) EFFORT_ARG="$2"; shift 2 ;;
|
||||
--upload) UPLOAD=1; shift ;;
|
||||
--collect) COLLECT=1; shift ;;
|
||||
--dryrun|-n) DRYRUN=1; shift ;;
|
||||
@@ -98,6 +105,9 @@ while [[ $# -gt 0 ]]; do
|
||||
esac
|
||||
done
|
||||
|
||||
if [[ $USE_M3 -eq 1 ]]; then MODEL="MiniMax-M3[1m]"; EFFORT="$EFFORT_ARG"; else MODEL="MiniMax-M3.1-Flash-Preview"; EFFORT="${EFFORT_ARG:-max}"; fi
|
||||
[[ -z "$EFFORT" || "$EFFORT" =~ ^(low|medium|high|xhigh|max)$ ]] || { err "--effort must be low|medium|high|xhigh|max"; exit 1; }
|
||||
|
||||
case "$DOCS" in all|recent|none) ;; *) err "--docs must be all|recent|none"; exit 1 ;; esac
|
||||
|
||||
if [[ -z "$UUID" ]]; then
|
||||
@@ -374,7 +384,7 @@ EOF
|
||||
|
||||
PROMPT_CONTENT="$(build_prompt)"
|
||||
|
||||
CMD="cd ${WORKTREE} && setsid nohup timeout ${TIMEOUT} ask-minimax-run --model \"MiniMax-M3[1m]\" --allowedTools \"${ALLOWLIST}\" --permission-mode acceptEdits --add-dir ${REPORT_DIR} -p \"\$(cat ${PROMPT_FILE})\" > ${STDOUT_FILE} 2>&1"
|
||||
CMD="cd ${WORKTREE} && setsid nohup timeout ${TIMEOUT} ask-minimax-run --model \"${MODEL}\"${EFFORT:+ --effort ${EFFORT}} --allowedTools \"${ALLOWLIST}\" --permission-mode acceptEdits --add-dir ${REPORT_DIR} -p \"\$(cat ${PROMPT_FILE})\" > ${STDOUT_FILE} 2>&1"
|
||||
|
||||
if [[ $DRYRUN -eq 1 ]]; then
|
||||
echo "[dryrun] mm-worktree-task — no changes will be made"
|
||||
@@ -510,7 +520,7 @@ info "launching ask-minimax-run (detached, timeout ${TIMEOUT}s)"
|
||||
cd "$WORKTREE"
|
||||
start=$(date +%s)
|
||||
set +e
|
||||
setsid nohup timeout "$TIMEOUT" ask-minimax-run --model "MiniMax-M3[1m]" \
|
||||
setsid nohup timeout "$TIMEOUT" ask-minimax-run --model "$MODEL" ${EFFORT:+--effort "$EFFORT"} \
|
||||
--allowedTools "$ALLOWLIST" --permission-mode acceptEdits \
|
||||
--add-dir "$REPORT_DIR" -p "$(cat "$PROMPT_FILE")" \
|
||||
> "$STDOUT_FILE" 2>&1
|
||||
|
||||
Reference in New Issue
Block a user