ci-arc-harness / run.sh
farguney's picture
Upload run.sh with huggingface_hub
b25ea25 verified
Raw
History Blame Contribute Delete
1.63 kB
#!/usr/bin/env bash
# CI ARC-AGI-3 offline run on HF Jobs, COMPACT-STATE build.
# Goal: confirm a single GeneralCIAgent decision now COMPLETES (was intractable
# at ~70003-leaf raw-field state) and capture the scorecard.
set -e
echo "=== ENV ==="
python --version
mkdir -p /work && cd /work
echo "=== EXTRACT PAYLOAD ==="
tar xzf /data/ci_payload.tgz
ls -1
echo "=== INSTALL (CI + arc-0-9-9 extra) ==="
pip install -q -e ".[arc-0-9-9]"
echo "=== IMPORT CHECK ==="
python -c "import arc_agi, arcengine; print('IMPORT_OK arc_agi', arc_agi.__file__)"
echo "=== CONFIG VALIDATE ==="
ci config validate --config configs/arc.offline.toml
echo "=== RUN OFFLINE (compact modeled state; 600s cap) ==="
set +e
START=$(date +%s)
timeout 600 ci run --config configs/arc.offline.toml --output /work/out > /work/run.log 2>&1
RUN_EXIT=$?
END=$(date +%s)
echo "RUN_EXIT ${RUN_EXIT} ELAPSED_S $((END-START))"
echo "=== LAST 120 LOG LINES ==="
tail -120 /work/run.log
echo "=== OUTPUT TREE ==="
find /work/out -type f 2>/dev/null | head -160
echo "=== TURN / TRACE SIGNALS (evidence a decision completed) ==="
grep -rIoh "\"turn_index\"[: ]*[0-9]*" /work/out 2>/dev/null | sort | uniq -c | tail -20
grep -rIoh "CERTIFICATE_ISSUED\|PLAN_PROPOSED\|BELIEF_COMMITTED\|ACTION_EMITTED\|EVIDENCE_UPDATED" /work/out 2>/dev/null | sort | uniq -c
echo "=== JSON ARTIFACTS (head) ==="
for f in $(find /work/out -name "*.json" 2>/dev/null); do echo "--- $f ---"; head -c 4000 "$f"; echo; done
echo "=== SCORECARD / SCORE GREP ==="
grep -rIn "levels_completed\|aggregate\|official_arc\|scorecard\|\"score\"" /work/out 2>/dev/null | head -60
echo "=== DONE ==="