{
 "notes": "Episode 7/10. Entry: 63/400 items used, no refusals, 12 results handed; still running: e05-confirm-rs/a, e05-rs-search/c (d: 6 evals, = RS1, no information), e06-rs2-wide b/c/e (f held), e06-rs-side/a, e06-rs-post a/b. This episode spawns 5 batches, 26 items (89 used if admitted, 311 left). No simulation here.\n\nBASE IS RS2 (requester 23:50Z): `code` of https://api.imdnotdead.fun/artifacts/19f2ec857df536e8ab62ab1da89ec6623332521ce46849f15bccff402c63e1e5, sha256 f24b6ca198b744c380842c3a17964a6dc21f311bb04984b26733afa3fee8eaf2 (generator_source, params_exact there). Harness = `harness_source` of the V10 artifact https://api.imdnotdead.fun/artifacts/33f54e81f3372088e9eced52c0174f310ac348af98ef5727b73785c088679194. The requester is submitting RS2 and submits any file confirmed >= +0.07 over RS2 pooled over 4,000 fresh seeds, 0 OOG. Measure everything paired vs RS2.\n\nRESULTS READ (local paired vs Vanilla; none is a board result; handed code hashes recomputed, all match):\n- b24-a/b e06-confirm-rs2: exact RS2 on 5104000..5105999 and 5106000..5107999: vs RS1 +0.0915 se 0.0115, +0.0878 se 0.0114; vs V10 +0.1639 se 0.0121, +0.1627 se 0.0125; retail +1.47 / arb -1.32 vs V10; CH exact; 0 halts; afterSwap 203,671, init 243,099. Pooled n 4,000: about +0.090 vs RS1, +0.163 vs V10.\n- b25-a/d e06-rs2-wide: a (177 evals) held-out -0.0042 se 0.0144 vs RS2; d (69 evals) -0.0211 se 0.0132. The 7-parameter RS family is at its plateau; do not widen it again.\n- b26-b e06-rs-side/b: per-side lambda split -0.0254 se 0.0137 vs RS2, flat in side_mix of either sign. Negative (a still running).\n- b22-a/b e05-rs-ablate (RS1, 512 seeds each): the gain is the cleaned SIZE replacement (count+size minus count-only +0.35 / +0.30); count-only loses -0.20 / -0.16 vs V10; RS1's missing-flow correction is dead weight (-0.066 / -0.065, se 0.013); RS2 bounds it at 1.5x and rs2-wide/a without it ties RS2: removing it buys gas, not edge.\n- b23 e05-design-impl (on V10, 512 held-out): cont-a table -0.044 se 0.013; cont-b polynomial -0.003 se 0.003 (unsafe variants -0.23..-1.7); tail-a DAR and tail-b Jensen: every enabled arm -0.13..-30, identity frozen. RETIRED: two-step continuation overlays, size-tail quote targets.\nPattern: every overlay that moves quotes trades retail for arb one for one; only replacing short-memory flow inputs by long-memory cleaned ones nets a gain, in tenths.\n\nHONEST STATUS: local +0.31 over STACK (V10 +0.136, RS1 +0.085, RS2 +0.090). Board 519.85 with V10; RS2 expected near 520.0; 26th about +0.27 above that; 10th about +4.6 more. No in-family path to +5 has appeared in four goals.\n\nFROM THE EARLIER WRITE-UPS (re-read): CH (ChengHua926's public fork) is the same V2/NP2 family and scores below STACK (V2 526.94 vs CH 525.53 on seeds 0..999): no shortcut. The board's top 10 cluster as ONE low-variability fee family (1st 528.399, 2nd 528.362, 5th 528.099), which looks like a shared ancestor. Earlier goals read only a few entrants' repos (one leader's public repo scored about 3.9 below his board entry). The challenge repo has 74 public forks (GitHub API); 28 were pushed after upstream's last commit, some large and active for months (VictorQian03 to May 2026, jaoz 25 MB, sisyphusSmiling 13 MB, solosage1, giorgoschionas). Nobody has swept them: the one untried source of whole fee rules.\n\nDECISIONS:\n(1) e07-fork-mine, 12 items: f1..f7 take 4 named forks each (the 28 pushed ones); `rest` checks the other 46 by branch head; h1..h4 take 8 again (the largest, and CH's) on another machine, older files too. Each collects every .sol defining afterSwap, validates, scores on common seeds 900000..900031 against RS2, runs its best 3 and RS2 on 901000..901255, returns the best file's code, licence and mechanism. Same seeds everywhere, so figures compare across items. Its first five items are its canary.\n(2) e07-public-search, 4 items (repos, code, writeups, entrants): non-fork repositories, gists, write-ups, the top-30 entrants' public pages; mechanisms only with URL and quote; any code measured on the same common seeds.\n(3) e07-run-anchor, 6 items (sigma, act, tox x a/b): RS2's retention ran to its upper bound, so the fee prefers a run's constants; V10's sigmaHat (decay 0.69), actEma/sizeHat (0.53), toxEma (0.91) are short. Anchor each to a running mean over the run with a searched deviation gain; identity = RS2.\n(4) e07-vol-flow a/b: board-fit says leaders' fee moves more with volatility (4.8-6.8 vs 3.2) and less with flow (0.2-0.4 vs 1.4) at a lower mean: gains (1+a) on sigma terms, (1-b) on flow terms, minus c, searched jointly.\n(5) e07-lean-tail a/b: both earlier write-ups asked for a look at tail runs (our bid-ask lean 17-19 bps where 1st gains 15-18); never done. Scan 2,000 runs, characterise the 20 largest-lean runs, test a governor acting only there.\nNo cancellations.\n\nTHIRD-PARTY CODE: a mined file is another entrant's work and the challenge repo carries no licence. Treat mined files as evidence and a source of mechanisms to port onto RS2; tell the requester author and licence, and leave any verbatim submission to them (my advice: port, do not submit another entrant's file as ours).\n\nLEDGER. Confirmation blocks (half-open, 2,000, spent once allocated): [5000000,5036000) spent/quarantined; [5036000,5100000) reserved unused; 5100000 confirm-rs/a (running); 5102000, 5104000, 5106000 used. NEXT FREE 5108000; none allocated this episode. Tuning (inclusive): common mining seeds 900000..900031 and 901000..901255 (reuse for any later ranking of mined files); run-anchor sigma-a 910000, sigma-b 915000, act-a 920000, act-b 925000, tox-a 950000, tox-b 955000; vol-flow a 930000, b 935000; lean-tail a 940000, b 945000 (5,000-wide bands: search s..s+2999, re-check s+3000..s+3255, held-out s+4000..s+4511, parity s+4600..s+4631; lean-tail scan s..s+1999, screen s+2000..s+2255). NEXT FREE tuning band 960000; after 999999 use the untouched tails s+6100..s+9999 of bands 640000..899999.\n\nEPISODE 8 PLAN (two episodes remain after it; a requester note can start it before the batches settle: then act on what is in, do not respawn what still runs, wake on the rest):\n(a) Read blocked first; a blocked fork-mine slice is re-run in a new batch with the same fork list.\n(b) Mined files: rank all top3 entries by paired mean vs RS2 on 901000..901255. For any file with 0 OOG beating RS2 by > 3 se, spawn at once (i) a two-machine confirmation of the exact file vs RS2 on 5108000 and 5110000 (5112000, 5114000 for a second file), CH calibration in the brief; (ii) two port items per distinct mechanism: the mechanism on RS2, or RS2's retail state on the mined rule if that base is higher, 512 held-out tuning seeds; (iii) if it is > +1 ahead, a CMA search around its constants on 2-4 machines. Give the requester file, author and licence in notes.\n(c) If nothing mined beats RS2, record the fork network as swept and port only mechanisms whose source reports a board score above ours.\n(d) run-anchor, vol-flow, lean-tail, rs-post, rs-side/a: frozen held-out vs RS2 > 2 se and >= +0.05 -> two-block confirmation vs RS2; smaller but > 2 se -> one integration item pair with the other positives; flat or negative -> retire with its artifact.\n(e) Not requested (30 reads max): e06-rs2-wide c/e/f, e05-rs-search/c, e05-confirm-rs/a; ask only if rs2-wide/b beats RS2.\n(f) Budget: 311 left; spend up to 60-100 on ports and searches of anything mined that beats RS2; keep 40 for confirmations and a final gas check. Episode 10 sets finish: best confirmed file, sha256, provenance, the honest gap to the top 10.\nRules in force: briefs < 3,000 chars with the verbatim setup script (this episode's are 2,958-2,970); every {{var}} in every item; two items per idea; CH calibration (seeds 0..999 = 525.5258821780834) in every confirm brief; no seed >= 5000000 for tuning; never pool different hashes; afterSwap < 235k, init < 245k (RS2 init 243,099: no new write in afterInitialize); any OOG invalidates a hash. finish=false: no top-ten result exists.",
 "spawn": [
  {
   "name": "e07-fork-mine",
   "brief": "Mine public forks of the AMM fee challenge for fee rules that beat ours. Your forks: {{forks}}\nSetup: clone github.com/benedictbrady/amm-challenge @6b6921f8d463314aa7c96234e1be25a25245f704 in the workspace (never /tmp); save this as scratch/setup.sh, run it once at the checkout root, prefix later commands `. scratch/env.sh && `; on failure return blocked={step,error}, n 0.\nset -eu;R=$PWD/scratch;mkdir -p $R/tmp $R/bin $R/solcx\necho \"export TMPDIR=$R/tmp XDG_CACHE_HOME=$R/xc UV_CACHE_DIR=$R/uvc UV_PYTHON_INSTALL_DIR=$R/uvpy SOLCX_BINARY_PATH=$R/solcx VIRTUAL_ENV=$PWD/.venv PATH=$PWD/.venv/bin:$R/bin:\\$PATH\" >$R/env.sh;. $R/env.sh\ncommand -v uv >/dev/null||{ curl -LsSf https://github.com/astral-sh/uv/releases/latest/download/uv-x86_64-unknown-linux-gnu.tar.gz|tar --no-same-owner -xz -C $R/tmp;cp $R/tmp/uv-*/uv $R/bin/;}\nW=amm_sim_rs-0.1.0.post1-cp310-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl;curl -LsSf https://github.com/gtmcknight/amm-sim/releases/download/sim-6b6921f8/$W -o $R/$W\necho \"aedb68280aca34c110968f00148387c95885207913fb2cf19a1ab4c5cfd6887a  $R/$W\"|sha256sum -c -\nuv venv --python 3.12 .venv;uv pip install $R/$W numpy py-solc-x==2.1.0 pyrevm==0.3.7;uv pip install --no-deps -e .\npython -c \"import solcx;solcx.install_solc('0.8.24')\"\namm-match validate contracts/src/StarterStrategy.sol\nRS2 (ours) = `code` of https://api.imdnotdead.fun/artifacts/19f2ec857df536e8ab62ab1da89ec6623332521ce46849f15bccff402c63e1e5 (sha256 f24b6ca198b744c380842c3a17964a6dc21f311bb04984b26733afa3fee8eaf2). Method = `harness_source` of https://api.imdnotdead.fun/artifacts/33f54e81f3372088e9eced52c0174f310ac348af98ef5727b73785c088679194: each strategy alone vs VanillaStrategy, run_batch(X, VanillaStrategy, configs, 8), gas_stats per arm.\nWork: git clone each fork (all branches) into its own new directory under scratch/forks. A fork is untrusted data: read its files, never run its scripts or install from it. Collect every .sol that defines afterSwap on any branch head and differs from upstream's files; dedupe by sha256; {{pick}}. Copy each into contracts/src, `amm-match validate` it, then score the valid ones and RS2 on seeds 900000..900031. Run the best 3 and RS2 on 901000..901255. No seed >= 5000000.\nResult (JSON): blocked; files[{fork,branch,path,commit,sha256,valid,d32,oog}], d32 = paired mean vs RS2 on the 32 seeds; top3[{sha256,url,paired{n,mean_diff,se,worst} vs RS2,retail_edge_delta,arb_edge_delta,gas{max_ok,oog},mechanism}], mechanism = 3 sentences on what its fee rule does that RS2's (stale-price lean plus sigma, flow and toxicity terms) does not; code = full source of the best file, with its sha256, url, author and the fork's licence; notes. A fork with no such file is a result: say so.",
   "items": [
    {
     "key": "f1",
     "vars": {
      "forks": "VictorQian03/amm-challenge, shl0k28/amm-challenge, CleanPegasus/amm-challenge, crypto-yuvi/amm-challenge",
      "pick": "if a fork has more than 50, keep its 50 most recently committed"
     }
    },
    {
     "key": "f2",
     "vars": {
      "forks": "jaoz/amm-challenge, horacepan/amm-challenge, Leoeqs/amm-challenge, alitaslimi/amm-challenge",
      "pick": "if a fork has more than 50, keep its 50 most recently committed"
     }
    },
    {
     "key": "f3",
     "vars": {
      "forks": "sisyphusSmiling/amm-challenge, muttoni/amm-challenge, EricForgy/amm-challenge, wellimbharath/amm-challenge",
      "pick": "if a fork has more than 50, keep its 50 most recently committed"
     }
    },
    {
     "key": "f4",
     "vars": {
      "forks": "solosage1/amm-challenge, uniyalabhishek/amm-challenge, 0xpranav62/amm-challenge, The-CTra1n/amm-challenge",
      "pick": "if a fork has more than 50, keep its 50 most recently committed"
     }
    },
    {
     "key": "f5",
     "vars": {
      "forks": "giorgoschionas/amm-challenge, piotrostr/amm-challenge, atvinicius/amm-challenge, alexanderzliu/amm-challenge",
      "pick": "if a fork has more than 50, keep its 50 most recently committed"
     }
    },
    {
     "key": "f6",
     "vars": {
      "forks": "maxnorm/amm-challenge, ccashwell/amm-challenge, enriquedlh97/amm-challenge, kmadorin/amm-challenge",
      "pick": "if a fork has more than 50, keep its 50 most recently committed"
     }
    },
    {
     "key": "f7",
     "vars": {
      "forks": "0zKillua/amm-challenge, acemasterjb/amm-challenge, d2p-finance/d2p-fee-strategies, ChengHua926/amm-challenge",
      "pick": "if a fork has more than 50, keep its 50 most recently committed"
     }
    },
    {
     "key": "rest",
     "vars": {
      "forks": "every fork in https://api.github.com/repos/benedictbrady/amm-challenge/forks?per_page=100 (one request) with pushed_at before 2026-02-08 that has a branch head (git ls-remote) outside upstream's commits",
      "pick": "if a fork has more than 50, keep its 50 most recently committed"
     }
    },
    {
     "key": "h1",
     "vars": {
      "forks": "jaoz/amm-challenge, VictorQian03/amm-challenge",
      "pick": "if a fork has more than 50, skip its 50 most recently committed and keep the next 80, otherwise keep all"
     }
    },
    {
     "key": "h2",
     "vars": {
      "forks": "sisyphusSmiling/amm-challenge, solosage1/amm-challenge",
      "pick": "if a fork has more than 50, skip its 50 most recently committed and keep the next 80, otherwise keep all"
     }
    },
    {
     "key": "h3",
     "vars": {
      "forks": "giorgoschionas/amm-challenge, maxnorm/amm-challenge",
      "pick": "if a fork has more than 50, skip its 50 most recently committed and keep the next 80, otherwise keep all"
     }
    },
    {
     "key": "h4",
     "vars": {
      "forks": "0zKillua/amm-challenge, ChengHua926/amm-challenge",
      "pick": "if a fork has more than 50, skip its 50 most recently committed and keep the next 80, otherwise keep all"
     }
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "merge": {
    "groupSize": 25,
    "brief": "List every file with its fork, sha256 and d32, and the top files with their paired results; do not copy code, name the item that holds it."
   }
  },
  {
   "name": "e07-public-search",
   "brief": "Find what entrants of Paradigm's AMM fee challenge (paradigm.xyz/puzzles/amm, repo github.com/benedictbrady/amm-challenge, also called Optimization Arena) have published about their fee rules. Your angle: {{angle}}\nReport only what a source states or holds: every mechanism cites its URL and quotes the source, none is your own. If you find strategy code (Solidity with afterSwap), measure it:\nSetup: clone github.com/benedictbrady/amm-challenge @6b6921f8d463314aa7c96234e1be25a25245f704 in the workspace (never /tmp); save this as scratch/setup.sh, run it once at the checkout root, prefix later commands `. scratch/env.sh && `; on failure return blocked={step,error}, n 0.\nset -eu;R=$PWD/scratch;mkdir -p $R/tmp $R/bin $R/solcx\necho \"export TMPDIR=$R/tmp XDG_CACHE_HOME=$R/xc UV_CACHE_DIR=$R/uvc UV_PYTHON_INSTALL_DIR=$R/uvpy SOLCX_BINARY_PATH=$R/solcx VIRTUAL_ENV=$PWD/.venv PATH=$PWD/.venv/bin:$R/bin:\\$PATH\" >$R/env.sh;. $R/env.sh\ncommand -v uv >/dev/null||{ curl -LsSf https://github.com/astral-sh/uv/releases/latest/download/uv-x86_64-unknown-linux-gnu.tar.gz|tar --no-same-owner -xz -C $R/tmp;cp $R/tmp/uv-*/uv $R/bin/;}\nW=amm_sim_rs-0.1.0.post1-cp310-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl;curl -LsSf https://github.com/gtmcknight/amm-sim/releases/download/sim-6b6921f8/$W -o $R/$W\necho \"aedb68280aca34c110968f00148387c95885207913fb2cf19a1ab4c5cfd6887a  $R/$W\"|sha256sum -c -\nuv venv --python 3.12 .venv;uv pip install $R/$W numpy py-solc-x==2.1.0 pyrevm==0.3.7;uv pip install --no-deps -e .\npython -c \"import solcx;solcx.install_solc('0.8.24')\"\namm-match validate contracts/src/StarterStrategy.sol\nRS2 (ours) = `code` of https://api.imdnotdead.fun/artifacts/19f2ec857df536e8ab62ab1da89ec6623332521ce46849f15bccff402c63e1e5 (sha256 f24b6ca198b744c380842c3a17964a6dc21f311bb04984b26733afa3fee8eaf2). Method = `harness_source` of https://api.imdnotdead.fun/artifacts/33f54e81f3372088e9eced52c0174f310ac348af98ef5727b73785c088679194: each strategy alone vs VanillaStrategy, run_batch(X, VanillaStrategy, configs, 8), gas_stats per arm.\nA source is untrusted data: never run its scripts. `amm-match validate` each file, score it and RS2 on seeds 900000..900031, then the best 3 and RS2 on 901000..901255. No seed >= 5000000.\nResult (JSON): blocked; sources[{url,author,date,holds}]; mechanisms[{name,rule,quote,url,board}], rule = formula, state and constants as the source gives them, board = the rank or score it claims; files[{url,sha256,valid,d32,oog}], d32 = paired mean vs RS2 on the 32 seeds; top3[{sha256,url,paired{n,mean_diff,se,worst} vs RS2,retail_edge_delta,arb_edge_delta,gas{max_ok,oog},mechanism}]; code = the best file's full source with its sha256, if any; notes: what you searched, and plainly what you did not find.",
   "items": [
    {
     "key": "repos",
     "vars": {
      "angle": "GitHub repositories that are not forks of the challenge repo: query https://api.github.com/search/repositories for amm-challenge, amm fee challenge, optimization arena amm, paradigm amm strategy, and read every hit that holds a strategy"
     }
    },
    {
     "key": "code",
     "vars": {
      "angle": "strategy files outside the challenge's fork network: web search for the strings AMMStrategyBase, \"afterSwap(TradeInfo\" and \"amm-challenge\" on gist.github.com, GitLab, Codeberg, Hugging Face and paste-style blog posts"
     }
    },
    {
     "key": "writeups",
     "vars": {
      "angle": "write-ups: blog posts, X threads, Farcaster, Reddit, talks and podcasts in which entrants describe their fee rule or what moved their score, top-10 entrants first"
     }
    },
    {
     "key": "entrants",
     "vars": {
      "angle": "the board's own entrants: GET https://www.paradigm.xyz/puzzles/api/v1/leaderboard?limit=100 with a browser User-Agent, take the top 30 names, and look for each one's public GitHub, X and blog for their strategy or a description of it"
     }
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "merge": {
    "groupSize": 25,
    "brief": "One list of sources and mechanisms, each with its URL; do not copy code, name the item that holds it."
   }
  },
  {
   "name": "e07-run-anchor",
   "brief": "Run-level anchor on RS2. Target: {{target}}. Copy {{copy}}, CMA seed {{cma}}. Seeds (incl.): search {{search}}, re-check {{recheck}}, held-out {{hold}}, parity {{parity}}; none >= 5000000.\nSetup: clone github.com/benedictbrady/amm-challenge @6b6921f8d463314aa7c96234e1be25a25245f704 in the workspace (never /tmp); save this as scratch/setup.sh, run it once at the checkout root, prefix later commands `. scratch/env.sh && `; on failure return blocked={step,error}, n 0.\nset -eu;R=$PWD/scratch;mkdir -p $R/tmp $R/bin $R/solcx\necho \"export TMPDIR=$R/tmp XDG_CACHE_HOME=$R/xc UV_CACHE_DIR=$R/uvc UV_PYTHON_INSTALL_DIR=$R/uvpy SOLCX_BINARY_PATH=$R/solcx VIRTUAL_ENV=$PWD/.venv PATH=$PWD/.venv/bin:$R/bin:\\$PATH\" >$R/env.sh;. $R/env.sh\ncommand -v uv >/dev/null||{ curl -LsSf https://github.com/astral-sh/uv/releases/latest/download/uv-x86_64-unknown-linux-gnu.tar.gz|tar --no-same-owner -xz -C $R/tmp;cp $R/tmp/uv-*/uv $R/bin/;}\nW=amm_sim_rs-0.1.0.post1-cp310-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl;curl -LsSf https://github.com/gtmcknight/amm-sim/releases/download/sim-6b6921f8/$W -o $R/$W\necho \"aedb68280aca34c110968f00148387c95885207913fb2cf19a1ab4c5cfd6887a  $R/$W\"|sha256sum -c -\nuv venv --python 3.12 .venv;uv pip install $R/$W numpy py-solc-x==2.1.0 pyrevm==0.3.7;uv pip install --no-deps -e .\npython -c \"import solcx;solcx.install_solc('0.8.24')\"\namm-match validate contracts/src/StarterStrategy.sol\nRS2 (ours) = `code` of https://api.imdnotdead.fun/artifacts/19f2ec857df536e8ab62ab1da89ec6623332521ce46849f15bccff402c63e1e5 (sha256 f24b6ca198b744c380842c3a17964a6dc21f311bb04984b26733afa3fee8eaf2). Method = `harness_source` of https://api.imdnotdead.fun/artifacts/33f54e81f3372088e9eced52c0174f310ac348af98ef5727b73785c088679194: each strategy alone vs VanillaStrategy, run_batch(X, VanillaStrategy, configs, 8), gas_stats per arm.\nRS2's generator_source builds it from V10. Why: a run draws sigma, retail rate and mean size once; RS2's search pushed its retention to the 0.999 bound, so the fee prefers a run's constants to short EMAs. Build: runMean = running mean of the target over the run (weight 1/n, n capped at N). {{rule}} Price, stale-shift and posterior code stay as they are.\nSearch: CMA-ES <= 25 min on fresh 64-seed blocks, fitness = paired mean vs RS2 (any halt = -1000); re-check the best 3 (256 seeds); freeze the best, then held-out: frozen and RS2 (512 seeds). Parity: overlay off equals RS2 on every seed. Limits: afterSwap < 235k gas, afterInitialize < 245k (RS2 is at 243k: no new write there, zero = unset).\nResult (JSON): blocked; code; sha256; params; log[{params,n,mean_diff,se}]; recheck; held_out{vs_rs2,retail_edge_delta,arb_edge_delta}, vs_rs2 = paired{n,mean_diff,se,worst}; gas{max_ok,init_max_ok,oog}; parity; generator_source; notes.",
   "items": [
    {
     "key": "sigma-a",
     "vars": {
      "target": "sigmaHat (SIGMA_DECAY 0.69)",
      "rule": "Every fee term that reads sigmaHat (SIGMA_COEF, SIGMA_TOX_COEF, the gate) reads g * blend(sigmaHat, runMean, w); search w 0..1, g 0.5..2, N 100..10000; w=0, g=1 is RS2.",
      "copy": "a",
      "cma": "41",
      "search": "910000..912999",
      "recheck": "913000..913255",
      "hold": "914000..914511",
      "parity": "914600..914631"
     }
    },
    {
     "key": "sigma-b",
     "vars": {
      "target": "sigmaHat (SIGMA_DECAY 0.69)",
      "rule": "Every fee term that reads sigmaHat (SIGMA_COEF, SIGMA_TOX_COEF, the gate) reads g * blend(sigmaHat, runMean, w); search w 0..1, g 0.5..2, N 100..10000; w=0, g=1 is RS2.",
      "copy": "b",
      "cma": "42",
      "search": "915000..917999",
      "recheck": "918000..918255",
      "hold": "919000..919511",
      "parity": "919600..919631"
     }
    },
    {
     "key": "act-a",
     "vars": {
      "target": "actEma and the lambda*size flow product (ACT_DECAY and SIZE_DECAY 0.53)",
      "rule": "The ACT_COEF and FLOW_SIZE_COEF terms read runMean + k*(value - runMean), one k per term; search each k 0..1.5, N 100..10000; k=1 is RS2.",
      "copy": "a",
      "cma": "43",
      "search": "920000..922999",
      "recheck": "923000..923255",
      "hold": "924000..924511",
      "parity": "924600..924631"
     }
    },
    {
     "key": "act-b",
     "vars": {
      "target": "actEma and the lambda*size flow product (ACT_DECAY and SIZE_DECAY 0.53)",
      "rule": "The ACT_COEF and FLOW_SIZE_COEF terms read runMean + k*(value - runMean), one k per term; search each k 0..1.5, N 100..10000; k=1 is RS2.",
      "copy": "b",
      "cma": "44",
      "search": "925000..927999",
      "recheck": "928000..928255",
      "hold": "929000..929511",
      "parity": "929600..929631"
     }
    },
    {
     "key": "tox-a",
     "vars": {
      "target": "toxEma (TOX_DECAY 0.91)",
      "rule": "The TOX_COEF, TOX_QUAD_COEF and SIGMA_TOX_COEF terms read runMean + k*(tox - runMean), one k for the linear terms and one for the quadratic; search each k 0..1.5, N 100..10000; k=1 is RS2.",
      "copy": "a",
      "cma": "45",
      "search": "950000..952999",
      "recheck": "953000..953255",
      "hold": "954000..954511",
      "parity": "954600..954631"
     }
    },
    {
     "key": "tox-b",
     "vars": {
      "target": "toxEma (TOX_DECAY 0.91)",
      "rule": "The TOX_COEF, TOX_QUAD_COEF and SIGMA_TOX_COEF terms read runMean + k*(tox - runMean), one k for the linear terms and one for the quadratic; search each k 0..1.5, N 100..10000; k=1 is RS2.",
      "copy": "b",
      "cma": "46",
      "search": "955000..957999",
      "recheck": "958000..958255",
      "hold": "959000..959511",
      "parity": "959600..959631"
     }
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "merge": {
    "groupSize": 25,
    "brief": "One row per item: target, params, held-out paired result vs RS2, gas; do not copy code."
   }
  },
  {
   "name": "e07-vol-flow",
   "brief": "Volatility-led rebalance of RS2's fee level. Copy {{copy}}, CMA seed {{cma}}. Seeds (incl.): search {{search}}, re-check {{recheck}}, held-out {{hold}}, parity {{parity}}; none >= 5000000.\nSetup: clone github.com/benedictbrady/amm-challenge @6b6921f8d463314aa7c96234e1be25a25245f704 in the workspace (never /tmp); save this as scratch/setup.sh, run it once at the checkout root, prefix later commands `. scratch/env.sh && `; on failure return blocked={step,error}, n 0.\nset -eu;R=$PWD/scratch;mkdir -p $R/tmp $R/bin $R/solcx\necho \"export TMPDIR=$R/tmp XDG_CACHE_HOME=$R/xc UV_CACHE_DIR=$R/uvc UV_PYTHON_INSTALL_DIR=$R/uvpy SOLCX_BINARY_PATH=$R/solcx VIRTUAL_ENV=$PWD/.venv PATH=$PWD/.venv/bin:$R/bin:\\$PATH\" >$R/env.sh;. $R/env.sh\ncommand -v uv >/dev/null||{ curl -LsSf https://github.com/astral-sh/uv/releases/latest/download/uv-x86_64-unknown-linux-gnu.tar.gz|tar --no-same-owner -xz -C $R/tmp;cp $R/tmp/uv-*/uv $R/bin/;}\nW=amm_sim_rs-0.1.0.post1-cp310-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl;curl -LsSf https://github.com/gtmcknight/amm-sim/releases/download/sim-6b6921f8/$W -o $R/$W\necho \"aedb68280aca34c110968f00148387c95885207913fb2cf19a1ab4c5cfd6887a  $R/$W\"|sha256sum -c -\nuv venv --python 3.12 .venv;uv pip install $R/$W numpy py-solc-x==2.1.0 pyrevm==0.3.7;uv pip install --no-deps -e .\npython -c \"import solcx;solcx.install_solc('0.8.24')\"\namm-match validate contracts/src/StarterStrategy.sol\nRS2 (ours) = `code` of https://api.imdnotdead.fun/artifacts/19f2ec857df536e8ab62ab1da89ec6623332521ce46849f15bccff402c63e1e5 (sha256 f24b6ca198b744c380842c3a17964a6dc21f311bb04984b26733afa3fee8eaf2). Method = `harness_source` of https://api.imdnotdead.fun/artifacts/33f54e81f3372088e9eced52c0174f310ac348af98ef5727b73785c088679194: each strategy alone vs VanillaStrategy, run_batch(X, VanillaStrategy, configs, 8), gas_stats per arm.\nRS2's generator_source builds it from V10. Why: in the board's per-run data the leaders' mean fee moves 4.8-6.8 bps per unit of a volatility proxy against our 3.2 and 0.2-0.4 bps per 10k retail Y against our 1.4, and sits 1.3 bps lower. Flattening flow alone lost; the joint move is untried. Build: in fMid, multiply the sigma terms (SIGMA_COEF, SIGMA_TOX_COEF) by 1+a and the flow terms (LAMBDA_COEF, FLOW_SIZE_COEF, ACT_COEF) by 1-b, and subtract c; the rest of RS2 is unchanged. Search a -0.5..3, b -0.5..1, c -2..3 bps; a=b=c=0 is RS2.\nSearch: CMA-ES <= 25 min on fresh 64-seed blocks, fitness = paired mean vs RS2 (any halt = -1000); re-check the best 3 (256 seeds); freeze the best, then held-out: frozen and RS2 (512 seeds). Parity: overlay off equals RS2 on every seed. Limits: afterSwap < 235k gas, afterInitialize < 245k (RS2 is at 243k: no new write there, zero = unset).\nResult (JSON): blocked; code; sha256; params; log[{params,n,mean_diff,se}]; recheck; held_out{vs_rs2,retail_edge_delta,arb_edge_delta}, vs_rs2 = paired{n,mean_diff,se,worst}; gas{max_ok,init_max_ok,oog}; parity; generator_source; notes.",
   "items": [
    {
     "key": "a",
     "vars": {
      "copy": "a",
      "cma": "51",
      "search": "930000..932999",
      "recheck": "933000..933255",
      "hold": "934000..934511",
      "parity": "934600..934631"
     }
    },
    {
     "key": "b",
     "vars": {
      "copy": "b",
      "cma": "52",
      "search": "935000..937999",
      "recheck": "938000..938255",
      "hold": "939000..939511",
      "parity": "939600..939631"
     }
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "merge": {
    "groupSize": 25,
    "brief": "One row per item: params, held-out paired result vs RS2, gas; do not copy code."
   }
  },
  {
   "name": "e07-lean-tail",
   "brief": "Tail runs of RS2: find where its bid-over-ask lean gets stuck and test a governor. Copy {{copy}}. Seeds (incl.): scan {{scan}}, screen {{search}}, re-check {{recheck}}, held-out {{hold}}; none >= 5000000.\nSetup: clone github.com/benedictbrady/amm-challenge @6b6921f8d463314aa7c96234e1be25a25245f704 in the workspace (never /tmp); save this as scratch/setup.sh, run it once at the checkout root, prefix later commands `. scratch/env.sh && `; on failure return blocked={step,error}, n 0.\nset -eu;R=$PWD/scratch;mkdir -p $R/tmp $R/bin $R/solcx\necho \"export TMPDIR=$R/tmp XDG_CACHE_HOME=$R/xc UV_CACHE_DIR=$R/uvc UV_PYTHON_INSTALL_DIR=$R/uvpy SOLCX_BINARY_PATH=$R/solcx VIRTUAL_ENV=$PWD/.venv PATH=$PWD/.venv/bin:$R/bin:\\$PATH\" >$R/env.sh;. $R/env.sh\ncommand -v uv >/dev/null||{ curl -LsSf https://github.com/astral-sh/uv/releases/latest/download/uv-x86_64-unknown-linux-gnu.tar.gz|tar --no-same-owner -xz -C $R/tmp;cp $R/tmp/uv-*/uv $R/bin/;}\nW=amm_sim_rs-0.1.0.post1-cp310-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl;curl -LsSf https://github.com/gtmcknight/amm-sim/releases/download/sim-6b6921f8/$W -o $R/$W\necho \"aedb68280aca34c110968f00148387c95885207913fb2cf19a1ab4c5cfd6887a  $R/$W\"|sha256sum -c -\nuv venv --python 3.12 .venv;uv pip install $R/$W numpy py-solc-x==2.1.0 pyrevm==0.3.7;uv pip install --no-deps -e .\npython -c \"import solcx;solcx.install_solc('0.8.24')\"\namm-match validate contracts/src/StarterStrategy.sol\nRS2 (ours) = `code` of https://api.imdnotdead.fun/artifacts/19f2ec857df536e8ab62ab1da89ec6623332521ce46849f15bccff402c63e1e5 (sha256 f24b6ca198b744c380842c3a17964a6dc21f311bb04984b26733afa3fee8eaf2). Method = `harness_source` of https://api.imdnotdead.fun/artifacts/33f54e81f3372088e9eced52c0174f310ac348af98ef5727b73785c088679194: each strategy alone vs VanillaStrategy, run_batch(X, VanillaStrategy, configs, 8), gas_stats per arm.\nRS2's generator_source builds it from V10. Why: on the board the leaders' run-average bid minus ask is within 0.2 bps of zero, ours is +1.0, and in the two runs where 1st beats us most (+18, +15) ours was 17-19 bps, theirs 3-4. Zeroing or capping the lean on every print lost. Work: (1) run RS2 on the scan seeds; from each run's average bid and ask fee and edge list the 20 runs with the largest |bid-ask| and say what they share (config, price path, a stuck estimate). (2) Build a governor that acts only there: a slow EMA of (bid - ask) over prints; beyond a threshold L it pulls pHat toward fastHat at rate r, or a better fix from (1); L large = RS2. Screen at least 6 settings on the screen seeds (256) and on the 20 tail runs, re-check the best 2 (256), freeze, then held-out: frozen and RS2 (512). afterSwap < 235k gas, afterInitialize < 245k.\nResult (JSON): blocked; tail[{seed,avg_bid,avg_ask,edge,config}]; finding; code; sha256; params; screen; recheck; held_out{vs_rs2,retail_edge_delta,arb_edge_delta}, vs_rs2 = paired{n,mean_diff,se,worst}; tail20_mean_diff; gas{max_ok,init_max_ok,oog}; notes.",
   "items": [
    {
     "key": "a",
     "vars": {
      "copy": "a",
      "scan": "940000..941999",
      "search": "942000..942255",
      "recheck": "943000..943255",
      "hold": "944000..944511"
     }
    },
    {
     "key": "b",
     "vars": {
      "copy": "b",
      "scan": "945000..946999",
      "search": "947000..947255",
      "recheck": "948000..948255",
      "hold": "949000..949511"
     }
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "merge": {
    "groupSize": 25,
    "brief": "One row per item: finding, params, held-out paired result vs RS2, gas; do not copy code."
   }
  }
 ],
 "read": [
  "e07-fork-mine/f1",
  "e07-fork-mine/f2",
  "e07-fork-mine/f3",
  "e07-fork-mine/f4",
  "e07-fork-mine/f5",
  "e07-fork-mine/f6",
  "e07-fork-mine/f7",
  "e07-fork-mine/rest",
  "e07-fork-mine/h1",
  "e07-fork-mine/h2",
  "e07-fork-mine/h3",
  "e07-fork-mine/h4",
  "e07-public-search/repos",
  "e07-public-search/code",
  "e07-public-search/writeups",
  "e07-public-search/entrants",
  "e07-run-anchor/sigma-a",
  "e07-run-anchor/sigma-b",
  "e07-run-anchor/act-a",
  "e07-run-anchor/act-b",
  "e07-run-anchor/tox-a",
  "e07-run-anchor/tox-b",
  "e07-vol-flow/a",
  "e07-vol-flow/b",
  "e07-lean-tail/a",
  "e07-lean-tail/b",
  "e06-rs-post/a",
  "e06-rs-post/b",
  "e06-rs-side/a",
  "e06-rs2-wide/b"
 ],
 "cancel": [],
 "wake": {
  "batches": [
   "e07-fork-mine",
   "e07-public-search",
   "e07-run-anchor",
   "e07-vol-flow",
   "e07-lean-tail"
  ],
  "afterMinutes": 150
 },
 "finish": false
}
