Files
pokerfreak/src/bin/twin_gate.rs
T
mmintelandClaude Opus 4.8 1492fb6a38 Synthetik-Labor: Population, Zwillings-Tor, adaptive Liga, Optimizer, Sim-to-Real
Ersetzt die irrefuehrende Oracle-Leiter durch eine ehrliche Messmethodik
(Oracle aus, Read via Memory/Posterior gegen eine gezogene Gegner-Population).

Stufen:
- 0 Exploitation-Luecke: +18.98 bb/100 gegen die gezogene Population
- 1 Kalibrierung an echte HUD-Daten (lesen/kalibrierung.py)
- 2 Zwillings-Tor (EGTA + Exploitability-Waechter): Offense +43.95,
  Boden gto -36.25 (verliert gegen Balancierte - die Oracle-verdeckte Wurzel)
- 3 Adaptive Liga L0-L3 (reaktiv / modellierend / Liga)
- 4 Sim-to-Real: HUD-Gap (sim::simreal) + Outcome-Abgleich (lesen/liveabgleich.py):
  real -266.75 vs Sim +43.95 => Gap -311; A/B-Pipeline + Runbook fertig,
  nur der geldechte Live-Lauf unter beiden Armen bleibt offen
- 5 Optimizer (Diagonal-CMA-ES, parallel): Nemesis -414.81 bb/100

Befunde und Architektur in docs/notizen/. Lab-Tests gruen
(Rust lib 92/0, python liveabgleich/kalibrierung/gegnersignal gruen).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-11-11 09:57:32 +01:00

44 lines
2.2 KiB
Rust

//! Stufe 2 of the synthetic lab: the TWIN GATE — print the three axes that replace the bb/100 ladder.
//!
//! One engine build, scored on: population EV (does it still exploit a varied field), the robustness
//! floor (its EV against the single worst archetype — the balanced players are the overfit catcher),
//! and river exploitability (an exact best-response distance on a fixed battery). "Never ship a loser"
//! becomes: lose no axis. Use `Gate::passes` in a regression harness to compare two builds.
//!
//! Run: `cargo run --release --bin twin_gate`.
use rechner::sim::population::Population;
use rechner::sim::twin_gate::{evaluate, TwinBudget};
const SEED: u64 = 0x5EED_0001;
fn main() {
let pop = Population::micro();
// Full budget: tightens the floor CIs the lean run left wide. The two balanced archetypes run a
// solver per decision, so this is the slow run (~1 h) — but it is the production-scale measurement.
let budget = TwinBudget::default();
println!("=== Stufe 2: das Zwillings-Tor (ersetzt die bb/100-Leiter) ===");
println!(
"Population {}x{} Austeilungen, Archetypen {} Austeilungen, River-Batterie {} Iter.\n",
budget.pop_opponents, budget.pop_deals, budget.archetype_deals, budget.river_iters
);
let r = evaluate(&pop, budget, SEED);
println!("OFFENSE — Population-EV (Memory, erschlossen)");
println!(" {:+.2} bb/100 (Exploitation-Luecke {:+.2})\n", r.population_ev_bb_per_100, r.exploitation_gap_bb_per_100);
println!("ROBUSTHEIT — EV je Archetyp (Memory), Boden = schlechtester:");
for (name, ev, ci) in &r.archetypes {
let mark = if *name == r.worst_archetype { " <- BODEN" } else { "" };
println!(" {name:10} {ev:+8.2} bb/100 +-{ci:.2}{mark}");
}
println!(" Boden: {} {:+.2} bb/100 +-{:.2}\n", r.worst_archetype, r.worst_ev_bb_per_100, r.worst_ci95);
println!("DEFENSE — River-Exploitability (exakte Best Response, {} Spots)", r.subgames);
println!(" Mittel {:.2} bb/100, Max {:.2} bb/100 (0 = unausbeutbar)\n", r.mean_exploitability_bb_per_100, r.max_exploitability_bb_per_100);
println!("Tor-Regel fuer einen Kandidaten: Population-EV haelt UND Boden haelt UND Exploitability steigt nicht.");
}