Download agent_reports_bgkf/t5_select.md from thibautforest/BatterySwapAI2026-Example: direct link, hf CLI and curl.
- Browser
- Download file 7.65 kB
-
https://huggingface.co/thibautforest/BatterySwapAI2026-Example/resolve/main/agent_reports_bgkf/t5_select.md
- Command line
-
hf download hf://thibautforest/BatterySwapAI2026-Example/agent_reports_bgkf/t5_select.md
-
curl -L -o t5_select.md https://huggingface.co/thibautforest/BatterySwapAI2026-Example/resolve/main/agent_reports_bgkf/t5_select.md
T5 selection-architecture lane — count-PINNED expected-gain selection (2026-08-23)
Question: the rank-4 public competitor selects by MARGINAL EXPECTED GAIN (risk x (no_schedule_cost - scheduled_cost) - (1-risk) x early_cost - service), with a geography-aware emergency term inside no_schedule_cost (their ablation: that term alone -14.6/scen in THEIR architecture). As a rank TILT on our champion order it is catastrophic (+135..+452, measured this evening — DEAD). Is the ARCHITECTURE — selecting by expected gain instead of blended rank, at the champion's exact count — any better?
Baseline: 60d65da head = Ft2RUL (values logbag(vm7), order .50 lb + .30 wiener + .20 gapHGB), plan_tsroute alpha 1.0 / ec_margin .8 / split_days 3 / timing_weight 2.0. SCORE 1541.3 (/tmp/ref_head_1541.csv).
Harness (/tmp/c31/, repo untouched)
- Cells: private copy of the T2 prediction cache (/tmp/c31/cells.pkl,
md5-pinned b093b6b7…) — per-(fold,origin) champion predictions captured
through a real
cv.run_bgkf(kind='@deployed'). Re-planned at the head planner state it reproduces /tmp/ref_head_1541.csv bit-exactly (240/240 cells, max diff 0.0) — the parity gate, passed before any arm. - Intervention: injected
rank_scorecolumn only (plan_tsroute's own documented order hook), planner code UNCHANGED.p42untouched, so n = round(alpha·sum p42) is identical per cell; the break-even top-up runs identically (curve-based, order-independent). Injecting rank_score = p42 is plan-inert (asserted per cell) — the plumbing adds nothing. - Count pin verified from the realized plans: swaps 2.26 vs 2.27, per-cell set size identical in 238/240 cells; the 2 exceptions (f1/s_46, f3/s_45, both near-end) are −1 battery because the non-empty break-even set is already inside the EG top-n so the union shrinks — same in every arm.
- risk = pred['p42'] (the cached Ft2RUL output IS the blend-rank-mapped calibrated probability: primary logbag(vm7) sorted values reassigned in 3-way-blend order — both roles the mission allows, one column).
- Expected gain, battery-varying terms only (the constant in-plan service
cost time_per_battery is order-invariant at pinned count — dropped):
EG = park + p42·obs_frac·geo − min_d curves[b,d]where park/curves = mc.cost_curves exactly (park replica asserted to 0.0 on all 240 cells), obs_frac = censor-masked death mass, and geo mirrors the evaluator's emergency loop per miss: round-trip travel + building change (skipped at the base building) + room change + swap (visit_h), overtime 2·max(clock−8,0) with clock = visit_h + return leg (mean-field self-carry of the evaluator's return-leg double-count quirk), daily-limit 100·(clock>24), weekly share 100·min(visit_h/24,1). Geography is real here: 3 of 24 buildings are 7.8–10.25h out; a dedicated miss trip there costs ~90–140 beyond late-days vs ~11 nearby.
Arms (paired vs 1541.3 on 48 origin-sums; swaps 2.26 everywhere)
| arm | selection order | SCORE | delta±SE | sig | W/L | wilcoxon | swaps |
|---|---|---|---|---|---|---|---|
| ega (full EG) | park + p·geo − minC | 1567.2 | +25.84±25.33 | 1.0 | 12/16 | .350 | 2.26 |
| egb (geo OFF) | park − minC | 1536.3 | −4.99±28.79 | 0.2 | 16/11 | .822 | 2.26 |
| egc (blend) | .5 rank(p42) + .5 rank(EG) | 1574.5 | +33.14±14.17 | 2.3 | 2/10 | .016 | 2.26 |
| egc_ng (blend, geo off) | .5 rank(p42) + .5 rank(EG_nogeo) | 1546.1 | +4.80±15.29 | 0.3 | 5/5 | .846 | 2.26 |
| egd (compact gate on ega) | geo only where mean visit_h≤8h | 1563.3 | +21.94±26.03 | 0.8 | 12/16 | .412 | 2.26 |
Geography term isolated (paired arm-vs-arm, same cells):
| contrast | delta±SE | sig | W/L | wilcoxon |
|---|---|---|---|---|
| geo term (ega−egb) | +30.83±15.60 | 2.0 | 2/11 | .033 |
| gated geo (egd−egb) | +26.93±15.35 | 1.8 | 2/9 | .067 |
| geo inside blend (egc−egc_ng) | +28.34±14.64 | 1.9 | 0/7 | .016 |
The compactness gate is nearly inert in our fold geometry: 215/240 cells have mean dedicated-trip hours ≤ 8h, so the gate leaves geo on almost everywhere (egd ≈ ega).
Mechanism (why the architecture loses at pinned count)
Churn vs the champion set (~45 batteries across ~40 cells per arm):
| arm | churned batteries | mean p42 | true death rate | remote (visit_h>8) |
|---|---|---|---|---|
| ega dropped | 46 | .276 | 23.9% (11/46) | 15% |
| ega added | 44 | .129 | 6.8% (3/44) | 23% |
| egb dropped | 46 | .279 | 23.9% (11/46) | 22% |
| egb added | 44 | .105 | 9.1% (4/44) | 7% |
p42 is CALIBRATED on both sides (realized death rates match the mean p42).
Expected gain deliberately trades likely-deaths for expensive-if-missed:
it drops .28-probability batteries to add ~.11-probability ones whose
miss would be costly (geo) or whose curves look sharp. At a PINNED count
that is a pure recall sacrifice — ~7 extra true misses across the panel,
each costing late-days plus a dedicated emergency trip (T2: 154/scen of
ops cost rides on misses). The geo term makes it strictly worse by
steering the added slots toward remote insurance (23% remote adds vs 7%
without geo). Since a miss's cost ≈ p42·(late_days + geo) and late-days
(hundreds) dominate geo (~11–140), ordering by p42 is already
near-optimal for the dominant term; EG's deviations from it mostly inject
day-quantile curve-estimation error into a slot-limited decision. Worst
at warmup origins (egb +38/scen s_0-7), where the curves are shakiest.
egb (geo-off margin, park − minC) is the only non-losing arm and it is a wash: mean −5.0 carried by single-cell coin flips (s_12 −668, s_15 −457 vs s_21 +427, s_4 +384), 5%-trimmed mean +1.7, Wilcoxon p .82. Panel block −17.0±38 (0.4σ, 12W/8L p .67) — nothing approaches any bar.
Why the competitor's −14.6 does not transplant
In their architecture the EG rule also SETS the count (select while EG > 0): the geography term there mostly acts as an appetite mechanism — it admits extra insurance swaps where a miss would be expensive, i.e. it buys recall. Count-pinning — which is exactly what our public evidence demands (count-coupled wins are untrustworthy, 4x) — removes that channel, and what remains of "geography-aware selection" is a reallocation from likely-deaths to remote maybes, which measurably loses. Combined with tonight's tilt result (geo as a rank tilt: +135..+452), the geography axis is dead in every count-flat form we can express.
Verdict
- Expected-gain selection does NOT beat blended-rank selection at pinned count: best arm −5.0±28.8 (0.2σ, rank-test flat), everything else worse.
- The geography term is not "part of the win we're missing" — inside the architecture it is a measured LOSS of +27..+31/scen (2σ, 2W/11L, consistent across full/gated/blend forms).
- The only ≥2σ results in the lane are losses (egc +33.1 at 2.3σ; geo term +30.8 at 2.0σ). Nothing to adopt; nothing worth a public probe.
- Caveats: geo uses a mean-field self-carry clock, a linear weekly-limit share and a flat room-change — approximations of the emergency loop, but the conclusion is invariant across three independent geo-on/geo-off contrasts; selection-set churn is small (~45 batteries), so cell deltas are lumpy — the sign of the geo term is nonetheless rank-significant.
Artifacts: /tmp/c31/{lib31,parity,arms}.py, parity log /tmp/c31/parity.log, arm CSVs /tmp/c31/arm_*.csv, selection sets /tmp/c31/sets_*.pkl, base replan /tmp/c31/base_replan.csv. Repo untouched (rank_score injection only; planner attrs saved/restored per call; modules md5-pinned against parallel-session races).