Skip to content
August Brooks
Experiments

BEDD, and the Component That Was Not There

A readiness audit, a ghost component, and a harness for measuring what a refusal costs

Finding

A readiness audit found the detector was a ghost — fields consumed as if live while returning hardcoded fallbacks, influencing no decision. It now runs in observe-only mode, and a separate harness measures what each rejection reason actually costs.

Date
Status
Ongoing

A note on scope. BEDD — a Behavioral Entropy Divergence Detector — and its companion State Parity Audit are filed as provisional patents and are therefore patent pending. This write-up covers what the detector is for and how it was tested. It does not describe the detection mechanism, its thresholds, or its feature construction, and it will not until the filing position allows. Free method disclosure on a pending application is not reversible.

Every figure below is from paper trading. No result here is from live capital, no return figure appears anywhere in this piece, and nothing in it is forward-looking.

What it is for

Dark Matter X is an autonomous trading system: it reads market state, selects a strategy posture, sizes positions, manages exits, and enforces its own risk floor, under a structural authority that may reject a trade for a fixed set of enumerated reasons and never on a subjective quality judgment.

BEDD sits underneath that as signal research. Its job is to notice when the behaviour of a market has diverged from the behaviour the system's current posture assumes — a regime-change detector expressed in behavioural rather than price terms. What it is emphatically not is a gate: no intelligence layer in this system is permitted to become one.

The audit found it had never existed

The genuinely interesting result here is not about markets.

A war-readiness audit — a sweep for components that are believed built, are referenced by other components, and do nothing — logged BEDD as a believed-built-but-absent component. The finding, recorded verbatim in the issue register:

A component assumed to exist — "BEDD, built by a prior session" — is referenced but does nothing. No BEDD file or class exists in the repository; only ghost fields bedd_status and bedd_entropy that always read fallbacks.

Three separate call sites consumed those fields. One of them supplied a hardcoded constant. An entropy calculation that did exist elsewhere was computing something unrelated — a regime posterior — and discarding it.

The failure mode is worth naming precisely, because it is not a bug in the ordinary sense. Nothing crashed. No test failed. No log line said anything was wrong. Every consumer read a plausible value, and the system's behaviour was exactly what it would have been if the component had been deleted — which it effectively had been, by never having been written. A field that always returns a fallback is indistinguishable from a working field right up until you ask what it is actually made of.

The register entry that closed it added the check that catches the class of problem rather than the instance: if any decision path reads one of these fields expecting a real value, assert the producing component exists and writes it. A ghost field consumed as if live is a red condition.

BEDD has since been built and wired in observe/shadow mode — it records what it would have said, and gates nothing.

The harness: measuring what a refusal costs

The second piece of work is the one with the most transferable idea in it.

The system's structural authority logged every rejection with a symbol and a reason, but not the order that would have been placed. That meant the value of every rejection reason was unmeasurable. The largest single force shaping the book — a concurrency cap — had fired 3,440 times and nobody could say whether it had protected the account or cost it.

A reject-counterfactual harness was built to answer that:

  • The rejection line now also carries the would-be order. This is logging only, and it is proven to be logging only rather than asserted: strip every logger call from the previous revision and from the current one, and the remaining decision AST is identical. The rejection stands, unchanged.
  • A relay writes the counterfactual record after the rejection is final, and deduplicates by opportunity rather than by event. A blocked candidate is re-rejected on every scan tick, so raw hits are not would-be trades. Measured across the record: 4,642 raw rejections collapse to 641 opportunities, a factor of 7.2. The rule deliberately undercounts.
  • An offline, read-only scorer replays forward bars through the same exit rules the live system uses, is pessimistic on same-bar ambiguity, reports would-be expectancy per reason with a Wilson floor, and refuses to report any reason with fewer than 20 observations.

Its own caveats are stated in the harness rather than in a footnote: fills are idealized, and the rejected trade would itself have changed the book, whose path is not modelled. It is an indicator, not proof.

And it is advisory only. Nothing in it gates trading. A rule shown to be costly becomes a pre-registered change an operator approves — not an automatic adjustment.

The validation record

Validation is built in sections, each unit-tested before use rather than after:

SectionScopeState
1Survivorship-free, point-in-time data integrityPasses
2Structural parity between backtest and live pathsStructural parity proven
2Behavioural parityBlocked — no clean window
5Deflated Sharpe, PSR, PBO, MBLImplemented, unit-tested before use

Two things about that table are the point of including it.

Behavioural parity is blocked and is reported as blocked. There was no clean window in which to establish that the backtest path and the live path behave identically, so the claim is not made. Structural parity — that the two paths run the same code — is proven separately and is a weaker statement.

Section 5 exists because backtest enthusiasm is the enemy. Deflated Sharpe, probabilistic Sharpe, probability of backtest overfitting and minimum backtest length are all measures of how much a result should be discounted for the number of times you looked. Building them before promoting a strategy is the whole discipline: strategies are not promoted on backtest performance but survive a validation gauntlet against survivorship-free data, and "done" means observed running in production rather than passing in a notebook.

Status

Ongoing. BEDD runs in observe mode and gates nothing. The counterfactual harness is advisory. Behavioural parity remains unproven, and until it is, no result from the backtest path is claimed to describe the live path.

The provisional filings remain pending, and the mechanism stays unpublished until that position changes.