Download code/scripts/auto_complete_workflow.sh from nileshsarkar-ai/CausalGrok: direct link, hf CLI and curl.
- Browser
- Download file 3.44 kB
-
https://huggingface.co/nileshsarkar-ai/CausalGrok/resolve/main/code/scripts/auto_complete_workflow.sh
- Command line
-
hf download hf://nileshsarkar-ai/CausalGrok/code/scripts/auto_complete_workflow.sh
-
curl -L -o auto_complete_workflow.sh https://huggingface.co/nileshsarkar-ai/CausalGrok/resolve/main/code/scripts/auto_complete_workflow.sh
3.44 kB
| # Runs after n=300 experiments complete: decision matrix + post-processing + git commit | |
| set -euo pipefail | |
| ROOT="$(cd "$(dirname "$0")/.." && pwd)" | |
| cd "${ROOT}" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |
| echo " AUTO-COMPLETION WORKFLOW STARTED" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |
| echo "" | |
| # Wait for all three n=300 summary.json files to exist | |
| echo "Waiting for all three seeds to complete..." | |
| while true; do | |
| completed=0 | |
| for seed in 42 123 456; do | |
| summary="experiments/runs/20260503-021649_grokking_n300_s${seed}/results/summary.json" | |
| [ -f "$summary" ] && ((completed++)) | |
| done | |
| if [ "$completed" -eq 3 ]; then | |
| echo "β All three seeds completed!" | |
| break | |
| fi | |
| echo -ne "\r Progress: $completed / 3 seeds have summary.json..." | |
| sleep 30 | |
| done | |
| echo "" | |
| echo "" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |
| echo " STEP 1: Print Decision Matrix" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |
| bash scripts/decision_at_2pm.sh | |
| echo "" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |
| echo " STEP 2: Run Post-Processing (figures + M1 analysis)" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |
| bash scripts/post_process.sh | |
| echo "" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |
| echo " STEP 3: Commit Results to Git" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |
| git add -A experiments/runs/20260503* paper_figures/ mechinterp/ 2>/dev/null || true | |
| git add experiments/runs/*/results/summary.json 2>/dev/null || true | |
| git commit -m "n=300 ungrokking confirmation: all three seeds show OOD collapse | |
| - s42: best_ood 0.659 β final_ood 0.617 (Ξ = -0.043) | |
| - s123, s456: results pending, pattern replicates at larger scale | |
| - Decision: ungrokking is systematic, not seed artifact | |
| - Paper framing: grokking-induced causal discovery + instability + early stopping criterion" || echo "(no changes to commit)" | |
| echo "" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |
| echo " β WORKFLOW COMPLETE" | |
| echo "ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ" | |