{
  "notes": "Episode 1: read goal.json and both supplied orchestration references; no prior notes, requester additions, handed results, batches, or refusals; trunk=null. Budget starts 0/60 items, 8 episodes, 30 concurrent workers. This decision launches 11 research items in five small batches: 2 independent implementations each of grid64, moment closure and small mixture; 4 clean-room restarts; 1 engine/calibration audit. Leaves 49 items and seven episodes. All groups are smaller than groupSize=5, so request individual results, avoiding lossy merges/canary delays. No cancellations; goal not achieved.\n\nSources read: https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/filter-brief.md and sibling oracle_table.json/replica.py/setup.sh; pinned engine 6b6921f8d463314aa7c96234e1be25a25245f704. Published ceilings are claims to reproduce, not this episode's measurements. Distinguish frozen table with own-arb-only price (507.61) from RETRAINED own-arb table (519.24); true-price table 532.45. No measured filter or engine result exists yet. Table has 17 ask +17 bid knots at ln(spot/p)=(-8..8)*0.003 plus 0.1463 arb offset, clamp fees [0,.1]. Correct interpolation and observable arb inference matter.\n\nDirect source checks: contracts/src/IAMMStrategy.sol exposes side, amounts, timestamp and post-reserves only; there is no arb flag, true price, rival state or sampled environment parameter. replica.init/on_trade expose all of those: filter/restart adapters must firewall them. Arb pins are conditional on latent trade type; blindly treating every first trade as arb invalidates evidence. Later same-timestamp callbacks are retail. Silent elapsed steps need diffusion then no-arb conditioning with historical fees, not one final truncation. Rival band is valid just after its arb phase, not arbitrary later retail. The replica updates the rival first whereas engine callbacks run submission first; audit information timing and do not consume oracle rival snapshots. Global config RNG index in amm_competition/competition/match.py is seed i: chunking may not reset this index or merely replace cfg.seed after sampling parameters. Pair separate submission-vs-Vanilla runs and compare submission edge.\n\nDevelopment protocol: filter A trains 0..127, B 128..255; restart training uses 20000..20127,20200..20327,20400..20527,20600..20727. Shared frozen validation 10000..10255, 10000 steps; targeted ablations only first64 validation seeds, never retune on them. CH calibration 0..999 is not model training. Callback log-price squared errors/counts permit correct pooled RMS; score gap uses paired per-seed oracle-minus-filter. Distinguish true-p+true-flag control from true-p+inferred-flag diagnostic to expose classification cost. Fresh final seeds 5148000..5151999 are quarantined from all episode-1 work. Replica differences are screening only, never board gains. Engine audit is the sole RS2-reading item; restarts receive only original brief/data/engine and their family assignment, no incumbent source.\n\nNext episode: read all 11 individual results requested here; first check blockers, runnable handoff, leakage tests and audit calibration. Compare two implementations per filter on identical seeds; disagreement is a debugging signal, not two statistical replications. Prefer a reliable observable filter with paired oracle deficit <=2 and good uncertainty/port cost; uncertainty CI and achieved sample sizes must be stated. If none qualifies, identify whether loss is censoring, latent label, router likelihood, or discretization; spend a focused repair pair before blindly optimizing a policy. Persist a numeric dead-end log from results in next-episode notes. Do not fund RS2 overlays or tiny gains.\n\nBudget roadmap, adaptable to evidence: reserve 20 seats for final confirmation, each 200 non-overlapping fresh seeds (20*200=4000; fits table maxRows=200), about 8 for policy search and 4 for Solidity port/parity/gas, leaving 17 repair/reproduction seats after these 11. Episode2 fit table/small net over posterior mean,sd, displacement and inferred arb flag using CMA-ES warm-started from oracle; engine decides winners. Episode3 port selected frozen model: afterInitialize and afterSwap each <245000 gas, zero OutOfGas/errors, Python-vs-Solidity bid/ask differences <=1e-6 on 256 NEW development seeds, exact source/bytecode/config hashes, complete offline-reproducible handoff. Episode4 onward confirm only after these gates. Use later episodes for meaningful fixes/independent checks, preserving budget. Final model must freeze before confirmation; do not reuse confirmation seeds for retuning. New model after failed confirmation requires a new untouched block and sufficient seats.\n\nConfirmation must record all 4000 per-seed candidate and exact RS2 edges/deltas, both retail/arb components and raw gas/error counters, exact configs/hashes; use table-backed numeric shards and exact reductions. Required mean paired delta >=+4.6 on REAL engine; CI reported, never substitute a replica estimate, absolute board extrapolation or rounded threshold. If no qualifying candidate, report failure rather than enter it. No public submission now. finish=true only when complete evidence supports the final deliverable or work must conclude candidly; currently false. Wake after all five batches settle (90-minute fallback accommodates scheduling/leads without spending an empty episode); this is a scheduling declaration, not a local clock wait.",
  "spawn": [
    {
      "name": "e01-filter-grid64",
      "mode": "research",
      "brief": "One item: independently build and evaluate {{variant}}, replicate {{rep}}, not an RS2 overlay. Read https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/filter-brief.md and sibling oracle_table.json and replica.py.\nSetup: clone https://github.com/benedictbrady/amm-challenge at 6b6921f8d463314aa7c96234e1be25a25245f704 into your workspace. In checkout: mkdir -p scratch && curl -LsSf https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/setup.sh -o scratch/setup.sh && sh scratch/setup.sh. Prefix later commands `. scratch/env.sh && `. On setup failure return blocked={step,error}. Finish within 1h; each command <480s, checkpoint/resume in scratch/.\nState z=ln(p/spot). Implement {{method}}. Only init reserves and afterSwap's side, amounts, timestamp, post-reserves and stored fees/history enter the strategy. Hide replica p,s2,arb and init sigma/lambda/size; oracle values are evaluation-only. Infer first-callback arb/retail as latent alternatives; later callbacks at that timestamp are retail. For an uncapped arb, pin p=spot_after/(1-oldAsk) for AMM sells X, or spot_after*(1-oldBid) for AMM buys X. Shift z for reserve moves. For every fully silent intervening step diffuse GBM then truncate z to [ln(1-bid),-ln(1-ask)] under the fees then in force; handle current-step hypotheses, t=0 and repeated timestamps correctly. Estimate sigma from inferred arb moves, with uncertainty/selection acknowledged. Add a weak router-fill likelihood marginalizing unknown total order and rival state; the rival's 30bp band holds just after its arb phase, not after arbitrary retail fills.\nUse frozen oracle_table with linear knot interpolation and endpoint clamp; feed p_hat=spot*exp(E[z]) and inferred arb flag, never truth. Train only {{train}}; freeze before 10000..10255 (256 seeds, 10000 steps). Pair closed-loop filtered and true-p table arms on identical seeds; also separate true-p/inferred-flag diagnostic from full-oracle control. Log callback RMS=1e4*sqrt(mean((ln(p_hat/p))^2)), uncertainty coverage, per-seed score gap oracle-minus-filter, mean/SE/95% CI, retail/arb edge and volume. Target gap <=2. Run one router-likelihood-off ablation on 10000..10063; do not retune. Never touch 5148000..5151999. Test hidden-input isolation, gap propagation, signs and repeated callbacks.\nReturn JSON: variant, seeds/configs, URLs+hashes, full runnable source and parameters as strings (not local paths), compact per_seed arrays with columns including seed, filtered/oracle/diagnostic edges, retail/arb edge+volume, squared-log-error sum and count; aggregate metrics, ablation, test commands/results, runtime, bounded-state/port cost estimate, dead ends with numbers and limitations. Include harness changes; preserve simulator semantics. If incomplete, report actual n and missing work. Entire result <=64000 bytes.",
      "items": [
        {
          "key": "rep-a",
          "vars": {
            "variant": "64-bucket posterior grid",
            "method": "64 bins with conservative recentering, Gaussian transition mass and normalized likelihoods; report grid/tail error",
            "rep": "A",
            "train": "0..127"
          }
        },
        {
          "key": "rep-b",
          "vars": {
            "variant": "64-bucket posterior grid",
            "method": "64 bins with conservative recentering, Gaussian transition mass and normalized likelihoods; report grid/tail error",
            "rep": "B",
            "train": "128..255"
          }
        }
      ],
      "output": {
        "format": "json",
        "maxBytes": 64000
      },
      "merge": {
        "groupSize": 5,
        "brief": "Preserve each independent result's sources, executable source, seed arrays and metrics. Compare oracle gap, RMS, coverage, leakage checks and approximation errors; do not average incompatible runs or treat replicas as independent validation seeds. Retain failures and numerical dead ends."
      }
    },
    {
      "name": "e01-filter-moments",
      "mode": "research",
      "brief": "One item: independently build and evaluate {{variant}}, replicate {{rep}}, not an RS2 overlay. Read https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/filter-brief.md and sibling oracle_table.json and replica.py.\nSetup: clone https://github.com/benedictbrady/amm-challenge at 6b6921f8d463314aa7c96234e1be25a25245f704 into your workspace. In checkout: mkdir -p scratch && curl -LsSf https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/setup.sh -o scratch/setup.sh && sh scratch/setup.sh. Prefix later commands `. scratch/env.sh && `. On setup failure return blocked={step,error}. Finish within 1h; each command <480s, checkpoint/resume in scratch/.\nState z=ln(p/spot). Implement {{method}}. Only init reserves and afterSwap's side, amounts, timestamp, post-reserves and stored fees/history enter the strategy. Hide replica p,s2,arb and init sigma/lambda/size; oracle values are evaluation-only. Infer first-callback arb/retail as latent alternatives; later callbacks at that timestamp are retail. For an uncapped arb, pin p=spot_after/(1-oldAsk) for AMM sells X, or spot_after*(1-oldBid) for AMM buys X. Shift z for reserve moves. For every fully silent intervening step diffuse GBM then truncate z to [ln(1-bid),-ln(1-ask)] under the fees then in force; handle current-step hypotheses, t=0 and repeated timestamps correctly. Estimate sigma from inferred arb moves, with uncertainty/selection acknowledged. Add a weak router-fill likelihood marginalizing unknown total order and rival state; the rival's 30bp band holds just after its arb phase, not after arbitrary retail fills.\nUse frozen oracle_table with linear knot interpolation and endpoint clamp; feed p_hat=spot*exp(E[z]) and inferred arb flag, never truth. Train only {{train}}; freeze before 10000..10255 (256 seeds, 10000 steps). Pair closed-loop filtered and true-p table arms on identical seeds; also separate true-p/inferred-flag diagnostic from full-oracle control. Log callback RMS=1e4*sqrt(mean((ln(p_hat/p))^2)), uncertainty coverage, per-seed score gap oracle-minus-filter, mean/SE/95% CI, retail/arb edge and volume. Target gap <=2. Run one router-likelihood-off ablation on 10000..10063; do not retune. Never touch 5148000..5151999. Test hidden-input isolation, gap propagation, signs and repeated callbacks.\nReturn JSON: variant, seeds/configs, URLs+hashes, full runnable source and parameters as strings (not local paths), compact per_seed arrays with columns including seed, filtered/oracle/diagnostic edges, retail/arb edge+volume, squared-log-error sum and count; aggregate metrics, ablation, test commands/results, runtime, bounded-state/port cost estimate, dead ends with numbers and limitations. Include harness changes; preserve simulator semantics. If incomplete, report actual n and missing work. Entire result <=64000 bytes.",
      "items": [
        {
          "key": "rep-a",
          "vars": {
            "variant": "mean-and-variance posterior approximation",
            "method": "truncated-Gaussian moment updates with a latent arb/retail observation mixture; report closure error",
            "rep": "A",
            "train": "0..127"
          }
        },
        {
          "key": "rep-b",
          "vars": {
            "variant": "mean-and-variance posterior approximation",
            "method": "truncated-Gaussian moment updates with a latent arb/retail observation mixture; report closure error",
            "rep": "B",
            "train": "128..255"
          }
        }
      ],
      "output": {
        "format": "json",
        "maxBytes": 64000
      },
      "merge": {
        "groupSize": 5,
        "brief": "Preserve each independent result's sources, executable source, seed arrays and metrics. Compare oracle gap, RMS, coverage, leakage checks and approximation errors; do not average incompatible runs or treat replicas as independent validation seeds. Retain failures and numerical dead ends."
      }
    },
    {
      "name": "e01-filter-mixture",
      "mode": "research",
      "brief": "One item: independently build and evaluate {{variant}}, replicate {{rep}}, not an RS2 overlay. Read https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/filter-brief.md and sibling oracle_table.json and replica.py.\nSetup: clone https://github.com/benedictbrady/amm-challenge at 6b6921f8d463314aa7c96234e1be25a25245f704 into your workspace. In checkout: mkdir -p scratch && curl -LsSf https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/setup.sh -o scratch/setup.sh && sh scratch/setup.sh. Prefix later commands `. scratch/env.sh && `. On setup failure return blocked={step,error}. Finish within 1h; each command <480s, checkpoint/resume in scratch/.\nState z=ln(p/spot). Implement {{method}}. Only init reserves and afterSwap's side, amounts, timestamp, post-reserves and stored fees/history enter the strategy. Hide replica p,s2,arb and init sigma/lambda/size; oracle values are evaluation-only. Infer first-callback arb/retail as latent alternatives; later callbacks at that timestamp are retail. For an uncapped arb, pin p=spot_after/(1-oldAsk) for AMM sells X, or spot_after*(1-oldBid) for AMM buys X. Shift z for reserve moves. For every fully silent intervening step diffuse GBM then truncate z to [ln(1-bid),-ln(1-ask)] under the fees then in force; handle current-step hypotheses, t=0 and repeated timestamps correctly. Estimate sigma from inferred arb moves, with uncertainty/selection acknowledged. Add a weak router-fill likelihood marginalizing unknown total order and rival state; the rival's 30bp band holds just after its arb phase, not after arbitrary retail fills.\nUse frozen oracle_table with linear knot interpolation and endpoint clamp; feed p_hat=spot*exp(E[z]) and inferred arb flag, never truth. Train only {{train}}; freeze before 10000..10255 (256 seeds, 10000 steps). Pair closed-loop filtered and true-p table arms on identical seeds; also separate true-p/inferred-flag diagnostic from full-oracle control. Log callback RMS=1e4*sqrt(mean((ln(p_hat/p))^2)), uncertainty coverage, per-seed score gap oracle-minus-filter, mean/SE/95% CI, retail/arb edge and volume. Target gap <=2. Run one router-likelihood-off ablation on 10000..10063; do not retune. Never touch 5148000..5151999. Test hidden-input isolation, gap propagation, signs and repeated callbacks.\nReturn JSON: variant, seeds/configs, URLs+hashes, full runnable source and parameters as strings (not local paths), compact per_seed arrays with columns including seed, filtered/oracle/diagnostic edges, retail/arb edge+volume, squared-log-error sum and count; aggregate metrics, ablation, test commands/results, runtime, bounded-state/port cost estimate, dead ends with numbers and limitations. Include harness changes; preserve simulator semantics. If incomplete, report actual n and missing work. Entire result <=64000 bytes.",
      "items": [
        {
          "key": "rep-a",
          "vars": {
            "variant": "small-mixture posterior",
            "method": "up to four Gaussian components with separate arb/retail branches and explicit merge/prune error",
            "rep": "A",
            "train": "0..127"
          }
        },
        {
          "key": "rep-b",
          "vars": {
            "variant": "small-mixture posterior",
            "method": "up to four Gaussian components with separate arb/retail branches and explicit merge/prune error",
            "rep": "B",
            "train": "128..255"
          }
        }
      ],
      "output": {
        "format": "json",
        "maxBytes": 64000
      },
      "merge": {
        "groupSize": 5,
        "brief": "Preserve each independent result's sources, executable source, seed arrays and metrics. Compare oracle gap, RMS, coverage, leakage checks and approximation errors; do not average incompatible runs or treat replicas as independent validation seeds. Retain failures and numerical dead ends."
      }
    },
    {
      "name": "e01-restarts",
      "mode": "research",
      "brief": "One item: a clean-room restart in {{family}}. Build one observable-only Python strategy testing {{hypothesis}}; deliver an executable experiment, not a proposal. Read https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/filter-brief.md and sibling oracle_table.json and replica.py. These and the pinned simulator are the only starting material. Do not fetch/read RS2, its numba port, other incumbents or other workers' results; use no RS2 overlays.\nSetup: clone https://github.com/benedictbrady/amm-challenge at 6b6921f8d463314aa7c96234e1be25a25245f704 into your workspace. In checkout: mkdir -p scratch && curl -LsSf https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/setup.sh -o scratch/setup.sh && sh scratch/setup.sh. Prefix later commands `. scratch/env.sh && `. On setup failure return blocked={step,error}. Finish within 1h; each command <480s, checkpoint/resume in scratch/.\nChoose a bounded model suitable for a later Solidity port. Only initial reserves and afterSwap's side, amounts, timestamp, post-reserves and your stored history/fees are inputs. True p, rival reserves, arb label and sampled sigma/lambda/order parameters are hidden at inference; offline simulator truth may supervise training/evaluation only. Model ambiguous first trades and repeated timestamps; do not silently equate first trade with arb. Use trade-implied price and uncertainty where helpful.\nFit only {{train}}, freeze, then evaluate 10000..10255, 10000 steps/seed. Pair against the true-p oracle_table arm and fixed 35bps; keep replica and real-engine claims distinct. Return score mean, paired oracle deficit and SE/95% CI, per-seed retail/arb edge+volume, and RMS in bps if estimating p. Include one targeted ablation on 10000..10063 without retuning. Goal requires +4.6 over RS2 on 4000 fresh real-engine seeds; this is a structural screening experiment, not qualification. Never use 5148000..5151999. Do not spend the item tweaking tenths.\nReturn JSON: family, hypothesis, source URLs+hashes, model and all constants/weights, full runnable source+harness as strings, exact seeds/configs, compact per_seed arrays with column names, metrics, leakage-test commands/results, ablation, runtime, port/state-cost estimate, limitations and dead ends with numbers. No local-path-only handoff or unrun claimed scores. Keep complete result <=64000 bytes; if time-limited return completed sample size and remaining work.",
      "items": [
        {
          "key": "analytic",
          "vars": {
            "family": "compact analytic displacement/uncertainty policy",
            "hypothesis": "robust trade-implied price with smooth asymmetric quotes that make corrective arb cheap",
            "train": "20000..20127"
          }
        },
        {
          "key": "recurrent",
          "vars": {
            "family": "tiny recurrent neural estimator and quoter",
            "hypothesis": "a small recurrent state can learn latent trade type and price from observable trade history",
            "train": "20200..20327"
          }
        },
        {
          "key": "finite-state",
          "vars": {
            "family": "finite-state Bayesian regime controller",
            "hypothesis": "a few latent price/arb regimes with posterior-weighted actions retain impact gains",
            "train": "20400..20527"
          }
        },
        {
          "key": "rival-model",
          "vars": {
            "family": "explicit rival-pool latent-state model",
            "hypothesis": "router likelihood and a 30bps rival transition model recover price information from retail fills",
            "train": "20600..20727"
          }
        }
      ],
      "output": {
        "format": "json",
        "maxBytes": 64000
      },
      "merge": {
        "groupSize": 5,
        "brief": "Keep all four clean-room models, reproducible source, coefficients, seed arrays and failures separate. Compare common-seed oracle deficits and substantive mechanisms; retain the clean-room declaration and numerical dead ends. Replica scores are screening evidence only."
      }
    },
    {
      "name": "e01-engine-audit",
      "mode": "research",
      "brief": "One item: build and verify the real-engine calibration/measurement harness for later policy decisions. Read https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/filter-brief.md and sibling oracle_table.json and replica.py.\nSetup: clone https://github.com/benedictbrady/amm-challenge at 6b6921f8d463314aa7c96234e1be25a25245f704 into your workspace. In checkout: mkdir -p scratch && curl -LsSf https://raw.githubusercontent.com/gtmcknight/amm-sim/main/research/setup.sh -o scratch/setup.sh && sh scratch/setup.sh. Prefix later commands `. scratch/env.sh && `. On setup failure return blocked={step,error}. Finish within 1h; each command <480s, checkpoint/resume in scratch/.\nUse amm_sim_rs.run_batch(X, VanillaStrategy, configs, 8); each candidate and RS2 separately occupies submission against Vanilla, never candidate vs RS2. Read submission edge, not PnL or submission-minus-normalizer. Reproduce MatchRunner._build_configs and competition defaults; variance RNG uses global seed i, not chunk-local i. Return seed-to-config code and check it against native builder on 0..999.\nFetch RS2 only from code at https://api.imd.fun/artifacts/19f2ec857df536e8ab62ab1da89ec6623332521ce46849f15bccff402c63e1e5; verify UTF-8 source sha256 f24b6ca198b744c380842c3a17964a6dc21f311bb04984b26733afa3fee8eaf2.\nLocate exact CH source in the brief's linked tool artifacts; calibrate once on 0..999: target mean 525.5258821780834, report observed value, difference and source hash. No invented/substituted CH if unavailable. Measure RS2 on 10000..10255 as reusable development baseline. Reserve 5148000..5151999 untouched.\nAudit actual TradeInfo visibility, initial step diffusion, arb side/pin equations, gap censoring and router event order against replica; report minimal counterexamples, not hidden-data shortcuts. Use the linked retail/arb split harness; cross-check split sums against unmodified engine edges on 16 seeds. Verify how raw per-callback gas and OutOfGas/errors are obtained, including swallowed failures; label missing telemetry. Exercise 256-seed fee-parity comparison infrastructure with a simple known strategy; this does not certify a future candidate.\nReturn JSON <=64000 bytes: runnable harness source, URLs/hashes, exact compiler/config/options, compact seed arrays (CH seed+edge, RS2 seed+edge+retail/arb split), calibration residual, split reconciliation, gas/error sample counters, callback observability findings, commands/timings, blockers and handoff. No local-path-only source; no strategy optimization. Missing CH/telemetry is explicit incomplete evidence, not success.",
      "items": [
        {
          "key": "calibrate",
          "vars": {}
        }
      ],
      "output": {
        "format": "json",
        "maxBytes": 64000
      },
      "merge": {
        "groupSize": 5,
        "brief": "Preserve the exact calibration, harness source, seed/config mapping, hashes, raw measurements, observable-input audit and missing evidence. Do not replace missing telemetry or CH with estimates."
      }
    }
  ],
  "read": [
    "e01-filter-grid64/rep-a",
    "e01-filter-grid64/rep-b",
    "e01-filter-moments/rep-a",
    "e01-filter-moments/rep-b",
    "e01-filter-mixture/rep-a",
    "e01-filter-mixture/rep-b",
    "e01-restarts/analytic",
    "e01-restarts/recurrent",
    "e01-restarts/finite-state",
    "e01-restarts/rival-model",
    "e01-engine-audit/calibrate"
  ],
  "cancel": [],
  "wake": {
    "batches": [
      "e01-filter-grid64",
      "e01-filter-moments",
      "e01-filter-mixture",
      "e01-restarts",
      "e01-engine-audit"
    ],
    "afterMinutes": 90
  },
  "finish": false
}
