flywheel: schedule eod_replay + nightly_tune in both compose scheduler blocks
The tuner was fiction in production: the 20:00 ET scheduler ran only premarket_eval (+ eod_reconcile), so learned_params.json sat 26 days stale and the whole-market dataset never grew. Both scheduler loops now run, in order, after the eval/reconcile pass: python eod_replay.py || echo "[scheduler] eod_replay FAILED" python nightly_tune.py || echo "[scheduler] nightly_tune FAILED" Order matters: replay grows the dataset first, the tuner fits after. 20:00 ET is after close, so replaying "today" is complete data — NOT look-ahead (replay is a labeling job, not a live gate). Deletes eod_replay.sh (dead cron-era wrapper pointing at a nonexistent venv; compose is the runner). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
b737acfc2c
commit
3e2d690b21
3 files changed
+10
-11
No files matched your search
@@ -191,6 +191,11 @@ services:
|
||||
if [ "$$(date +%H:%M)" = "20:00" ] && [ "$$(date +%u)" -le 5 ]; then
|
||||
python -m research.premarket_eval || echo "[scheduler] eval FAILED"
|
||||
python -m research.eod_reconcile || echo "[scheduler] reconcile FAILED"
|
||||
# Flywheel: grow the whole-market dataset first, then fit the tuner on
|
||||
# it. 20:00 ET is after close, so replay of "today" is complete data —
|
||||
# NOT look-ahead (replay is a labeling job, not a live gate).
|
||||
python eod_replay.py || echo "[scheduler] eod_replay FAILED"
|
||||
python nightly_tune.py || echo "[scheduler] nightly_tune FAILED"
|
||||
sleep 120
|
||||
fi
|
||||
sleep 20
|
||||
|
||||
@@ -133,6 +133,11 @@ services:
|
||||
echo "[scheduler] premarket_eval $$(date)"
|
||||
python -m research.premarket_eval || echo "[scheduler] eval FAILED"
|
||||
python -m research.eod_reconcile || echo "[scheduler] reconcile FAILED"
|
||||
# Flywheel: grow the whole-market dataset first, then fit the tuner on
|
||||
# it. 20:00 ET is after close, so replay of "today" is complete data —
|
||||
# NOT look-ahead (replay is a labeling job, not a live gate).
|
||||
python eod_replay.py || echo "[scheduler] eod_replay FAILED"
|
||||
python nightly_tune.py || echo "[scheduler] nightly_tune FAILED"
|
||||
sleep 120
|
||||
fi
|
||||
sleep 20
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
# End-of-day whole-market replay: what today's logic would have done + grow the
|
||||
# stored dataset for the tuner/verification. Schedule right after the close,
|
||||
# before nightly_tune (which then tunes on the freshly-grown data).
|
||||
# crontab -e -> 5 16 * * 1-5 /mnt/c/code/momentum/eod_replay.sh
|
||||
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
VENV_PY="/home/philip/.venvs/momentum/bin/python"
|
||||
cd "$ROOT" || exit 1
|
||||
mkdir -p "$ROOT/data"
|
||||
echo "=== eod_replay $(date) ===" >> "$ROOT/data/eod_replay.log"
|
||||
PYTHONPATH="$ROOT" "$VENV_PY" eod_replay.py >> "$ROOT/data/eod_replay.log" 2>&1
|
||||
Reference in new issue
Block a user