#!/usr/bin/env bash # Protocol v2 VAI DeepSeek baseline, resumed with the same command. Endpoint and key: VOLVE_DIA_M34_API_BASE and # VOLVE_DIA_M34_API_KEY (env or .env). # scripts/run_m34_v2.sh smoke # development-well smoke check, T4 and T2 # scripts/run_m34_v2.sh full # T4/C4 and T2, three repetitions # scripts/run_m34_v2.sh estimate set -euo pipefail cd "$(dirname "$0")/.." PY="${PY:-.venv/bin/python}" export OMP_NUM_THREADS=4 MKL_NUM_THREADS=4 OPENBLAS_NUM_THREADS=4 TOKENIZERS_PARALLELISM=false run_python() { exec "$PY" -c ' import os import sys from volve_dia.paths import load_env load_env() os.execv(sys.executable, [sys.executable, *sys.argv[1:]]) ' "$@" } [[ -n "${RUNLOG_DIR:-}" ]] || run_python -m volve_dia.runlog -n "m34_v2_${1:-estimate}" -- bash scripts/run_m34_v2.sh "$@" stage="${1:-estimate}" budget="${2:-}" M=vai-deepseek-v4-1-flash step() { "$PY" -c 'import sys; from volve_dia.paths import load_env; load_env(); import os; os.execv(sys.executable, [sys.executable, *sys.argv[1:]])' scripts/15_m34_v2.py "$@"; } case "$stage" in estimate) step estimate ;; smoke) step qa --model $M --limit 6 --rep 0 --workers 2 --approved-budget-tokens "${budget:?budget}" step t2 --model $M --limit 50 --rep 0 --workers 2 --approved-budget-tokens "$budget" ;; full) step qa --model $M --approved-budget-tokens "${budget:?budget}" step t2 --model $M --approved-budget-tokens "${budget}" env -u RUNLOG_DIR bash scripts/run_m34.sh report ;; *) echo "Usage: $0 {estimate|smoke|full} [budget_tokens]" >&2; exit 2 ;; esac