strawberry/include/strawberry/learn
trvon d81ccbe7c8
gate: a bounded evaluation range, so out-of-sample evidence is possible
The in-sample check landed without any way to bound an evaluation, so every cell
was in-sample and every promotion path refused. Cutting the training bundles
earlier does not help: training spans the bundles, evaluation replays the whole
store with no lower bound, and the store keeps everything (retention 0), so
eval_first <= training_last always held.

replay --policy-eval gains --eval-after NS|auto (0 = unbounded). The bound is
applied where windows are ranked and where injected traces are planned, so the
periods partition only the out-of-sample span; auto derives it as the latest
training-range end over the loaded --eval-model files. Comparisons are written
without first + warm-up arithmetic so INT64_MAX timestamps cannot overflow. A
bound past the end of the store does not produce a silent empty cell: the cell
carries eval_error and promotion_gate refuses naming it.

Provenance also gets honest about width: training_last_ns is the last training
window's END (a window spans window_ns, so using its start left up to 60 s of
trained-on data looking disjoint), and the single-model path (model promote) now
uses the ranked span instead of the whole store, which had guaranteed a refusal.

Verified: R11c passes with 128 out-of-sample windows and a derived bound, and
unbounded returns to in-sample. Refuses an explicit bound later than all history.
2026-11-19 17:27:59 -07:00
..
features.hpp Review fixes: write->exec feature constant, accurate comments, tag-safe CI 2026-11-10 16:09:03 -07:00
inspection.hpp Stage 4: execute a promoted model's inspections, under guardrails 2026-10-27 21:03:57 -06:00
mlp.hpp gate: refuse in-sample and degenerate evidence, and identify the model 2026-11-19 16:20:40 -07:00
model_file.hpp gate: refuse in-sample and degenerate evidence, and identify the model 2026-11-19 16:20:40 -07:00
rarity.hpp Stage 6: load fleet overlay + sketch_surprisal_bits (query fleet-wide rarity for a tuple) 2026-11-08 05:38:00 -07:00
replay.hpp gate: a bounded evaluation range, so out-of-sample evidence is possible 2026-11-19 17:27:59 -07:00
shadow.hpp Stage 4: keep the live rarity model across daemon restarts 2026-10-27 23:25:01 -06:00
tokenize.hpp Add the tokenizer and rarity model for the learning stages 2026-10-26 21:21:28 -06:00
trace.hpp Replay and training take several trace files; fix an autostart label 2026-10-28 05:09:41 -06:00
train.hpp Stage 3.5a: fleet-train --max-node-share/--test-fraction/--split 2026-11-08 12:18:32 -07:00