#!/usr/bin/env bash # B9 LIVE tuning probe — analyze baseline + compare baseline vs delegate_rescue on 3 tasks. # # Usage: # bash scripts/butler-eval-b9-tuning.sh # bash scripts/butler-eval-b9-tuning.sh --analyze-only set -euo pipefail ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" cd "$ROOT" export PYTHONPATH="$ROOT" export BUTLER_EVAL_LLM_BENCHMARK=1 ANALYZE_ONLY=0 while [[ $# -gt 0 ]]; do case "$1" in --analyze-only) ANALYZE_ONLY=1 ;; -h|--help) echo "Usage: $(basename "$0") [--analyze-only]" exit 0 ;; *) echo "Unknown: $1" >&2; exit 1 ;; esac shift done if [[ -f "$ROOT/.env" ]]; then set -a # shellcheck disable=SC1091 source "$ROOT/.env" 2>/dev/null || true set +a fi python3 - < base.passed: applied = apply_b9_failure_class_overrides(fc_analysis) if applied: print() print("=== Persisted failure-class overrides ===") print(json.dumps(applied, ensure_ascii=False, indent=2)) print() print( f"PROBE SUMMARY: baseline {base.passed}/{base.total} → " f"rescue {tuned.passed}/{tuned.total} → " f"failure_class {failure_class.passed}/{failure_class.total} " f"(best={best[0]})" ) PY