Measurement as a first-class citizen

New Issue

Three-layer plan making measurement a first-class citizen of the deterministic graph. Each layer moves semantics from ad-hoc code into declared structure:

  1. #280 — trustworthy time base. Bucket membership computes on normalized time, not raw provider stamps (today every consumer hand-rolls jitter rounding — or silently mis-buckets: the 08:59:59.4 bar counts toward the wrong candle).
  2. #281 — computation vocabulary. Four orthogonal standard cells (Sign, Select, CumSum, When). The fabric already carries the hard semantics (freshness-gated recompute, Firing::Any hold); When exposes it — after it, every existing reducer composes gated, unmodified.
  3. #282 — declared observability. Taps as the output-side twin of input_roles: the fragment declares measurement points, the harness/run mode binds recorders. An unbound tap is dead in the FlatGraph, so DCE removes the whole counter chain behind it — unobserved measurement evaporates at compile time; a reduce-mode sweep pays zero for study logic.

Trust is layered bottom-up: #281 graphs on unfixed candles compute precisely the wrong thing, and #282 taps would then publish it. Implementation may proceed independently; trust only stacks in order.

Deliberate boundary (tier ontology, not an oversight): order statistics (median) stay sink-side; multi-instrument inputs (e.g. a GER40 session gate on a UK100 study) stay harness/World tier.

Acceptance sketch: the origin question ("is the first UK100 5m candle after the DAX open a momentum indicator?") becomes expressible as a hand-authored blueprint (~50 nodes) plus one aura run --real UK100 with recording — zero lines of throwaway Rust.

Origin: UK100 open-momentum scratch study, 2026-07-17.

No due date
100% Completed