TEST BOT
version 0.1 — in development
built 2026-08-22

PURPOSE
  Order flow strategy following Fabio Valentini's
  Direction -> Location -> Aggression framework.
  Hard rule: never lose more than 2% of the account in one day.
  Targets a Topstep prop evaluation first, personal account later.

WHAT IS BUILT
  profile.py      Volume profile — POC, value area, LVN/HVN.
                  The LOCATION filter bot #1 never had.
  risk.py         2% hard daily cap + soft stop + Fabio's governors.
                  Presets: prop_50k, prop_100k, personal.
  strategy.py     The three-filter funnel with A/B/C setup grading.
  walkforward.py  Optimise in-sample, verify out-of-sample.
                  Plus a permutation test for "is this luck".
  orderflow.py    Real OFI / delta / book imbalance (from bot #1).
  practice.py     Backtest + permutation test + walk-forward.

STATUS
  Risk layer .......... TESTED    26 unit tests
  Volume profile ...... TESTED    included above
  Walk-forward ........ WORKING   verified end to end
  Strategy edge ....... UNKNOWN   never run on real market data

FIRST SYNTHETIC RUN (means nothing about edge, machinery only)
  343 trades, 37.6% win rate, expectancy -$4.74, PF 0.85
  Permutation test p = 0.91 — indistinguishable from random
  Walk-forward said "plausible edge", which on random-walk data is
  exactly the false positive the permutation test is there to catch.
  Trust the permutation test.

NEXT
  1. Run record_flow.py every session — Topstep serves no historical
     depth, so unrecorded days are gone permanently.
  2. Get real MES bars (fetch_data.py) and re-run practice.py --csv.
  3. Only then does any performance number mean anything.
