ad713af8

By: ValentinHirschi <valentin.hirschi@gmail.com>

cache sampling programs and focus both sides of thresholds

Compile the canonical graph bridge transactionally during warmup and borrow
it in sampling, summed evaluation and direct-momentum partitions. Invalidate
on mutable settings and refresh improved external data after in-place edits.
Give worker clones independent eager score buffers; evaluate borrowed channel
scores without per-draw program clones through one partition reduction.

Focus the inner radial branch on the distance to the threshold, sharing a
stable native inverse with implicit maps. Add signed-distance, tiny/subnormal,
Jacobian, reference, cache-lifecycle and worker-independence regressions.

Re-read and coordinate the amplitude and cross-section plan: cap amplitude
benchmarks at the kite and double box, develop LU-h and conditional host/side
maps in parallel, and run full GL638 pilots before automatic discovery is
finished. Record native sampling rescue as the next shared gate; document
actual double-box intersections and missing production cut-context bindings.
No amplitude or GL638 physical variance improvement is claimed yet.

Validation: core/API test compilation, 154 library sampling tests, both
saved-state/summed API regressions, core/API clippy, cargo fmt --all --check,
and git diff --check pass. No lint warnings on changed lines; unrelated old
warnings remain. API formatting follows its declared edition 2021. Runtime
caches are not serialized; state reload requires warmup, with no cache-payload
migration. The f64 bridge's rounded-seam error still needs native rescue.

User request:
Continue as planned, but re-read the plan, and establish how to best orchestrate progress on both front of amplitude surface advanced sampling, but also the overall goal of cross-section advanced sampling, that must eventually apply to GL638 and demonstrate improvement there.

Earlier amplitude request:
Continue as planned, but also add that the advanced sampling implementation should also be tested for amplitude multiloop graphs (not just the cross-section ones), where it is of course simpler as there are no cuksosky cuts. Spawn a subagent to propose good candidates, but the 6-photons 2-loop graphs in the presence of thresholds is an idea, but it may be slow to generate, I would then rather consider some UV finite scalar 2-loop amplitude topologies. Let a subagent what would be best.
This allows to not only test the implementation of advanced sampling on amplitude, but also test the new advanced surface maps in a simpler context with not cutkosky cut rescaling, and also monitor the impact on the variance for these cases.
GitHub
Time to Start Worker time Duration Time to finish Idle
Config 1s 10s 10s 12s 1s
Eval 2m11s 1m14s 1m14s 3m26s 1m59s
Build 3m11s 2h15m03s - - 3m14s
Test 5m45s 16m21s - - 0s
Deploy - - - - 8m28s
Suite 1s 2h32m51s - - 13m44s

Timeline

Config Eval Build Test Failed Retried Compressed gap
0s3m4m5m6m7m8m9m10m11m12m13m14m15m16m17m18m19m20m21m22m23m24m25m26m27m28m29m30m31m32m33m34m35m36m37m38m