Bar-period split across Resample(tunable)/Session(baked) desyncs silently to 0 pips; Delay.lag leaks into param_space #96

Closed
opened 2026-06-17 18:53:03 +02:00 by Brummel · 0 comments
Owner

Surfaced by the GER40 research deep-dive fieldtest (docs/specs/fieldtest-research-breakout-deepdive.md).

Two coupled C34 (deform-vs-tune) violations surfaced while sweeping the
breakout's structural params.

(1) The bar period is one logical knob split across two nodes, uncoupled,
desyncing silently.
Resample::builder() exposes period_minutes as a
tunable param, but Session::builder(open, tz, period) bakes its period
(its rustdoc: "NOT scalar params, the declared param list is empty"). So a
Composite's param_space() carries resample.period_minutes but no Session
period. Sweeping resample.period_minutes = 30 while Session stays baked at 15
bootstraps and runs with no error, but the two clocks desync —
entry_bar.target == 3 no longer means "3rd 30m bar". Verified:

resample=15, session=15 (coupled, correct):   bars=1679  total_pips=-45.0
resample=30, session=15 (desynced, silent):   bars=839   total_pips= 0.0   <-- silently wrong
resample=30, session=30 (rebuilt blueprint):  bars=839   total_pips=+63.0

A coherent 30m strategy is reachable ONLY by rebuilding the Composite with
session_period = 30 (topology, not a sweep). The public sweep API silently
admits a structurally meaningless combination and returns a quiet 0.0 rather
than a diagnostic — the worst outcome.

(2) Structural deformers leak into the default param_space().
Delay::builder() ships lag as a tunable param; the breakout's delay.lag is
a STRUCTURAL constant ("previous bar's high" — varying it deforms the strategy,
the exact C34 discriminator). Yet it pollutes param_space() by default, so
GridSpace::new REQUIRES the researcher to enumerate delay.lag (or it
errors), and a naive random sweep would silently deform the strategy. The author
never opted in; the node's default builder() forces the pollution onto every
consumer. Resample.period_minutes has the same character.

Repro: cargo run --release --manifest-path fieldtests/research-breakout-deepdive/Cargo.toml --bin t3b_period_desync
(silent 0.0) and --bin t3_sweep (param_space() lists delay.lag).

Recommend (debug / planner): decide per node whether period_minutes /
lag are tuning knobs or structural constants. If structural, keep them out of
the default param_space() (or have the strategy author bind() them out and
make the demo model that for consumers). For the period specifically, either
make Session's period a tunable param so a single swept value feeds both, or
provide a coupling / derived-param mechanism so the two periods cannot desync.

**Surfaced by the GER40 research deep-dive fieldtest** (`docs/specs/fieldtest-research-breakout-deepdive.md`). Two coupled C34 (deform-vs-tune) violations surfaced while sweeping the breakout's structural params. **(1) The bar period is one logical knob split across two nodes, uncoupled, desyncing silently.** `Resample::builder()` exposes `period_minutes` as a **tunable param**, but `Session::builder(open, tz, period)` **bakes** its period (its rustdoc: "NOT scalar params, the declared param list is empty"). So a Composite's `param_space()` carries `resample.period_minutes` but no Session period. Sweeping `resample.period_minutes = 30` while Session stays baked at 15 bootstraps and runs with **no error**, but the two clocks desync — `entry_bar.target == 3` no longer means "3rd 30m bar". Verified: ``` resample=15, session=15 (coupled, correct): bars=1679 total_pips=-45.0 resample=30, session=15 (desynced, silent): bars=839 total_pips= 0.0 <-- silently wrong resample=30, session=30 (rebuilt blueprint): bars=839 total_pips=+63.0 ``` A coherent 30m strategy is reachable ONLY by rebuilding the Composite with `session_period = 30` (topology, not a sweep). The public sweep API silently admits a structurally meaningless combination and returns a quiet 0.0 rather than a diagnostic — the worst outcome. **(2) Structural deformers leak into the default `param_space()`.** `Delay::builder()` ships `lag` as a tunable param; the breakout's `delay.lag` is a STRUCTURAL constant ("previous bar's high" — varying it deforms the strategy, the exact C34 discriminator). Yet it pollutes `param_space()` by default, so `GridSpace::new` REQUIRES the researcher to enumerate `delay.lag` (or it errors), and a naive random sweep would silently deform the strategy. The author never opted in; the node's default `builder()` forces the pollution onto every consumer. `Resample.period_minutes` has the same character. **Repro:** `cargo run --release --manifest-path fieldtests/research-breakout-deepdive/Cargo.toml --bin t3b_period_desync` (silent 0.0) and `--bin t3_sweep` (`param_space()` lists `delay.lag`). **Recommend** (debug / planner): decide per node whether `period_minutes` / `lag` are tuning knobs or structural constants. If structural, keep them out of the default `param_space()` (or have the strategy author `bind()` them out and make the demo model that for consumers). For the period specifically, either make Session's period a tunable param so a single swept value feeds both, or provide a coupling / derived-param mechanism so the two periods cannot desync.
Brummel added the bug label 2026-06-17 18:53:03 +02:00
Brummel added this to the GER40 breakout as a World-consumable Composite blueprint milestone 2026-06-17 18:57:43 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Brummel/Aura#96