Skip to content

docs(experiments): cusum_event measured — feasible, and without a gross edge (#341) - #684

Merged
eaitbrahim merged 1 commit into
mainfrom
exp-341-cusum-measurement
Sep 1, 2026
Merged

docs(experiments): cusum_event measured — feasible, and without a gross edge (#341)#684
eaitbrahim merged 1 commit into
mainfrom
exp-341-cusum-measurement

Conversation

@eaitbrahim

Copy link
Copy Markdown
Contributor

The measurement #341 asked for: pre-declared, then run. 168 trials, 24 assets, ~5 years of hourly candles, fees 0 / 0.006 / 0.012.

1. Feasibility: yes — and it contradicts the worry filed with the issue

#341 was filed with the concern that "gating cuts n on rules already below the admission floor." It does not.

assets with n ≥ 100 21 of 24
median n 553
range 32 – 884

A 5% cumulative move in an hourly crypto series is a common event, not a rare one. The three below the floor are the two PAXG pairs and TON — gold and the thinnest name in the universe, which is the expected shape. That objection is answered and shouldn't be repeated.

2. Profitability: no, and not marginally

fee PF median PF max above 1.0
0% 0.925 1.238 8 / 24
0.6% (maker, unreachable) 0.553 0.750 0 / 24
1.2% (taker, actual) 0.343 0.479 0 / 24

The intersection of n ≥ 100 and PF > 1.0 is empty across all 168 trials.

3. The diagnostic — this is the rsi_meanrev disease, not the turtle_breakout one

The number that matters is the zero-fee column: only 8 of 24 clear 1.0, median 0.925.

turtle_breakout at zero fee was profitable on 4 of 4 with a max of 2.713 — a real gross edge that cost destroyed, which is why cheaper execution was a coherent thing to want. This rule loses at a median before a single fee is charged. Same symptom as turtle at 1.2%, different disease — and the one execution cannot fix, because zero fee bounds from above everything an execution improvement could buy, and zero fee is already a loss.

4. The knob works exactly as designed, and converges to nothing

mult threshold median n PF median above 1.0
1 2.5% 1252 0.226 0
2 5.0% 553 0.343 0
3 7.5% 330 0.361 0
4 10.0% 224 0.379 0

Monotonic in the right direction — trading less does lose less per toll, so the mechanism is real. It is also converging to a ceiling well below 1.0 while n falls toward the floor. A fourfold threshold buys 0.15 of profit factor and costs 82% of the sample.

5. The source's own setting is the worst cell

mult=1 is the paper's 2.0–2.5%, which on this venue is exactly one round trip: lowest median PF (0.226) with the highest median n (1252) — the most trading at the least edge. That's #341's friction-scaling argument measured rather than asserted.

Honesty

Arm A is one pre-declared configuration, so it carries no selection bias. Arm B's per-asset best is a maximum of four draws and is stated as such — best cell CRV-USD at mult=4, PF 0.593, still 0.4 short, so the bias changes nothing either way. Screening result only: no walk-forward, no PBO (series_missing). Slippage held at 0.0005 throughout, so the zero column is zero fee, not zero cost.

The ledger row was written twice

Worth recording. Every non-int summary value must be a string: _decode_summary turns anything that isn't an int into a Decimal on read, so a JSON float round-trips to a different value and the row stops hashing to its own row_hash.

verify_chain caught it immediately. The corrupt trailing row was removed — restoring the chain to exactly its prior state, verified clean at 90 rows — and re-appended with the encoding every existing row already uses. The chain verifies at 91 rows.

Changed nothing else

A document, a driver script, a ledger row. No rule row added, nothing promoted, no config or allowlist touched. cusum_event stays registered and untraded.

The measured intersection goes from 0 of 90 to 0 of 114. That is the result, and publishing it is the point.

…oss edge (#341)

The measurement #341 asked for, pre-declared and then run. 168 trials across 24
assets on ~5 years of hourly candles, at fees 0 / 0.006 / 0.012.

FEASIBILITY: YES, AND IT CONTRADICTS THE WORRY FILED WITH THE ISSUE. #341 was
filed with the concern that gating cuts n on rules already below the admission
floor. It does not. At the shipped default n>=100 on 21 of 24 assets, median 553,
max 884 -- a 5% cumulative move in an hourly crypto series is a common event, not
a rare one. The three below the floor are the two PAXG pairs and TON, which is
the expected shape. That objection is answered and should not be repeated.

PROFITABILITY: NO, AND NOT MARGINALLY. At the 1.2% taker rate ZERO of 24 clear
PF 1.0 -- median 0.343, best 0.479 (AVAX-USD, n=601). At the 0.6% maker rate this
account cannot reach, still zero of 24. The intersection of n>=100 and PF>1.0 is
EMPTY across all 168 trials in both arms.

THE DIAGNOSTIC, WHICH IS THE POINT OF THE DOCUMENT. At ZERO fee only 8 of 24
clear 1.0 and the median is 0.925. turtle_breakout at zero fee was profitable on
4 of 4 with a max of 2.713 -- a real gross edge that cost destroyed, which is why
cheaper execution was a coherent thing to want. cusum_event has essentially NO
GROSS EDGE for cost to destroy: it loses at a median before a single fee is
charged. Same symptom as turtle at 1.2%, different disease -- the rsi_meanrev
one, and the one execution cannot fix, because zero fee bounds from above
everything an execution improvement could buy and zero fee is already a loss.

THE KNOB WORKS AND CONVERGES TO NOTHING. threshold_friction_mult 1 -> 4 raises
median PF monotonically 0.226/0.343/0.361/0.379 while cutting median n
1252/553/330/224. The mechanism is real -- trading less loses less per toll --
and it converges to a ceiling well below 1.0 while n falls toward the floor. A
fourfold threshold buys 0.15 of profit factor and costs 82% of the sample.

THE SOURCE'S OWN SETTING IS THE WORST CELL. mult=1 is the paper's 2.0-2.5% and is
exactly one round trip here: lowest median PF (0.226) with the highest median n
(1252), the most trading at the least edge. #341's friction-scaling argument,
measured rather than asserted.

Arm A is ONE pre-declared configuration, so it carries no selection bias. Arm B's
per-asset best is a maximum of four draws and is stated as such; its best cell is
CRV-USD at mult=4, PF 0.593 -- still 0.4 short, so the bias changes nothing in
either direction.

THE LEDGER ROW WAS WRITTEN TWICE, and the first one is not in the file. Every
non-int summary value must be a STRING: `_decode_summary` turns anything that is
not an int into a `Decimal` on read, so a JSON float round-trips to a different
value and the row stops hashing to its own `row_hash`. `verify_chain` caught it
immediately, the corrupt trailing row was removed -- restoring the chain to
exactly its prior state, verified clean at 90 rows -- and it was re-appended with
the encoding every existing row already uses. The chain verifies at 91 rows.

Changed nothing else: a document, a driver, a ledger row. No rule row added,
nothing promoted, no config or allowlist touched. cusum_event stays registered
and untraded, and the measured intersection goes from 0 of 90 to 0 of 114.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NzuKAe2RVrPt9acVAWjRyL
@eaitbrahim eaitbrahim self-assigned this Sep 1, 2026
@eaitbrahim
eaitbrahim merged commit 68f0ba0 into main Sep 1, 2026
1 check passed
@eaitbrahim
eaitbrahim deleted the exp-341-cusum-measurement branch September 1, 2026 23:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant