simulation/lab: correct the record on the bimodal prior

In this commit, we retract a claim this program has repeated since
exp-006. We said the champions rediscovered the bimodal liquidity
prior from failure traces alone; they did not. The harness prompt has
stated the bimodal hypothesis verbatim under environment truths since
the first committed version of run_gepa_code.py, so the hypothesis was
handed to every run that ever saw it. What the runs genuinely produced
is the prior's functional form, its constants, and the whole
per-directed-channel interval apparatus.

Verifying that claim turned up a sharper problem. The evolved
constants sit within about ten percent of the ExpFloat64()*0.05 that
sim_liquidity.go generates liquidity with, and the mainnet tier calls
AssignLiquidity with that same generator, so what we have been calling
mainnet validation is real topology and real policies carrying
synthetic balances drawn from the distribution the priors are fitted
to. The attempt-efficiency result rests on the intervals and survives;
the prior is calibration, and the mainnet number needs a liquidity
source we did not write before it goes anywhere near upstream.
This commit is contained in:
Olaoluwa Osuntokun 2026-07-26 02:33:34 -07:00
parent 9e35a302ed
commit e2c14e964c
3 changed files with 36 additions and 10 deletions

View file

@ -25,10 +25,19 @@ writeups live in `simulation/lab/experiments/` (exp-001…exp-009).
- Parameter tuning alone could NOT beat lnd's defaults (exp-002): the
paradigm is the lever, not the knobs.
- What the champions evolved (all pure Go, `simulation/champions/`):
dropped mission control and ALL time-decay; rediscovered the bimodal
liquidity prior from failure traces; invented per-directed-channel
liquidity intervals (lowerOK/upperFail bounds + evidence-count
confidence) — that's where the 8.6× attempt reduction comes from.
dropped mission control and ALL time-decay; invented
per-directed-channel liquidity intervals (lowerOK/upperFail bounds +
evidence-count confidence) — that's where the 8.6× attempt reduction
comes from. **Correction (WHY.md §0):** we long claimed they
"rediscovered the bimodal prior from failure traces." They did not —
the harness prompt has stated the bimodal hypothesis since the first
committed version. What was NOT supplied: the prior's functional
shape and constants, and the entire interval apparatus. Worse, the
evolved constants FIT OUR GENERATOR (`sim_liquidity.go` draws
`ExpFloat64()*0.05`; atomic1's low mode is `exp(x/0.055)`), and the
mainnet tier overwrites real balances with that same generator — so
the mainnet number is real topology and policies, synthetic
liquidity. Fixing that is the top pre-upstream task.
## Map

View file

@ -78,10 +78,14 @@ drowned success-rate deltas; penalties now saturate at 0.25 total.
- OOD corpus-v2 test: hb1 0.545 > seed 0.487 > lnd 0.357
- ~9 attempts/payment vs lnd's ~50, higher success on both.
What it discovered from failure traces alone: an explicit **bimodal
liquidity prior** (rediscovering lnd's own bimodal-estimator hypothesis)
+ per-edge liquidity bounds with confidence + risk-adjusted Dijkstra.
Clean (no exploit). Full detail + caveats: exp-006. Champion saved to
What it built: an explicit **bimodal liquidity prior** + per-edge
liquidity bounds with confidence + risk-adjusted Dijkstra. Clean (no
exploit). **Correction (2026-07-26, WHY.md §0):** this entry
originally read "discovered from failure traces alone." That is
wrong — the harness prompt has stated the bimodal hypothesis under
"environment truths" since the first committed version. The prior's
shape and constants and the whole interval apparatus were the run's
own work; the hypothesis was handed to it. Full detail + caveats: exp-006. Champion saved to
`champions/router_hb1_v1.go`. Sim audit (exp-005) fixed a critical
sandbox escape before it was exploited.

View file

@ -42,8 +42,21 @@ and per-attempt failure traces:
amount approaches capacity,
- floored/capped to [0.005, 0.985].
This is the same "funds sit at one end of the channel" hypothesis
lnd's bimodal estimator was analytically derived from — reinvented by
the LLM from failure feedback alone.
lnd's bimodal estimator was analytically derived from.
**Correction (2026-07-26, WHY.md §0):** this bullet originally
ended "reinvented by the LLM from failure feedback alone," and that
is false. The harness prompt states the bimodal hypothesis verbatim
under "environment truths worth exploiting," and has since the
first committed version of `run_gepa_code.py`. What the run
actually produced is the functional form (exponential low mode plus
logistic cliff), every constant in it, and the interval machinery
in the next bullet — real work, but not the discovery we claimed.
Sharper still: `0.025` here and `0.018` in mx_c3 sit close to the
`ExpFloat64()*0.05` that `sim_liquidity.go` generates with, so the
prior is fitted to our generator. Until a corpus carries liquidity
from some other source, treat the prior as calibration and the
intervals as the finding.
2. **Per-edge liquidity bounds with confidence.** `edgeProbability`
tracks `lowerOK` (largest amount known to pass), `upperFail` (smallest