{
 "notes": "EPISODE 4 OF 12. Credit Taylor (gtmcknight), github.com/gtmcknight/amm-sim@4812a6382311624e1506aca131ca35c378f930d9 research/solved, in every file. Items: 7 used before this episode; 19 spawned now (26 of 300 at most; the 7 after the join are cancelled without cost when a gate says no).\n\nRESULTS READ (all accepted). t2-kit/k: unchanged QLX5 is 47,230 chars, 22,440 runtime bytes, engine peak gas 205,887, 0 OOG on 9700000..9700127, port fees equal contract fees on 4 seeds; `recipe` and `notes` say how to drive the kit (https://api.imd.fun/artifacts/fc3bd54c8c987c0ab81c6861e1a6e91c5c3fca757b0f7c114e13a110470c0cde). t3-harness/h: perturbation library, parity with archived engine rows within 5e-7 on 512 seeds, zero delta and QPL1 roundtrip exact; tables 2 and 4 have 0 lookups, so only tables 0, 1, 3 matter (https://api.imd.fun/artifacts/9ad960e6c7e11509b81f2852f7f34d395425adc226141b0bc828ed6f5f344663, implementation_sha256 4d4894474104eac9148e52b18d679b994ce73c6a889bafa18169c8dacca22855). Handed results are served at https://api.imd.fun/artifacts/<sha256 of the file> (checked). t3-map (t0,t1a,t1b,t3a,t3b): 162 bands, +-1 bps, 512 choose seeds. No signed probe reaches +0.03; best single probes +0.006..+0.010 with se 0.002..0.006 (selection maxima). The large effects are losses from raising fees in high-row, high-column corners (t0 L0 rows 15..23 col 10: -0.18). Per-seed paired noise is about 0.1 edge for any change (chaotic paths), so se is 0.0045 at 512 seeds and 0.0016 at 4,096.\n\nWHAT I MEASURED HERE BEFORE DECIDING (harness built on the episode machine, about 385 simulations a second on 32 threads; paired against unchanged QLX5; seeds 100000..104095, 4,096, now spent; no report seed, no engine):\n1. The map's improving directions do not replicate. 18 of its strongest band moves: none gains; best +0.0032 (se 0.0020). Examples: t0 L0 rows 15..23 cols 1..9 at -1 bps, predicted +0.014, measured -0.0004 (0.0014); t1 L0 rows 0..16 cols 0..3 at +1: -0.0075 (0.0019). Summed same-sign map gradients fail too: t1 L1 rows 0..21 all columns +1 bps on choose 64000..65023 gave +0.004 (0.006), predicted +0.025.\n2. QLX5 sits on a sharp optimum in every global direction. Uniform offset on all three tables: -0.25 bps -0.039, +0.25 bps -0.071 (se 0.003). Table 0 uniform -0.5/+0.5: -0.019/-0.120; -0.25: -0.006. t1 L0 -0.5/+0.5: -0.016/-0.035. t1 L1: -0.035/-0.0015; +0.25: +0.0037 (0.0021). t3 L0 -0.5/+0.5: -0.007/-0.010. t3 L1: -0.016/+0.004; +1.0: -0.006. Level 2 of t1 and t3: 0 within 0.0014. Scale -1%/+1%: t0 -0.089/-0.082; t1 -0.073/-0.027; t3 -0.031/-0.012. Row shift -0.2/+0.2 grid units: t0 -0.143/-0.043; t1 -0.015/-0.119; t3 -0.002/-0.057. Row tilt -20/+20 millibps per grid unit loses likewise (t0 -0.016/-0.092).\n3. The optimum is partly a cusp, not a parabola: t0 L0 rows 15..23 col 10 at +0.25 bps -0.040, at -0.25 -0.002, at -0.5 -0.004. Quadratic predictions from +-1 bps probes are wrong there.\n4. One gain seen: t3 L1 rows 0..18, all columns, +1 bps: +0.0100 (se 0.0027, z 3.7; the best of about 60 probes, so discount it).\n5. Bound. Curvature along the uniform direction is about 0.56 (t0), 0.35 (t1), 0.12 (t3) edge per bps squared; lattice rounding (0.25, 0.5, 1.0 bps) therefore costs at most about 0.0015 + 0.0036 + 0.005. With finding 4 and the one-sided directions (each worth about +0.004 by a quadratic fit), table values in the existing encoding hold roughly +0.01 to +0.02 in all: under the +0.03 promotion bar, far under +0.12. My estimate from local probes; the batches below put the evidence on the plane.\nTable meaning (policy.hpp): a node is the ask quote in bps; row = own mispricing against the belief on a 5 bps grid (160 = centre), column = rival position, level = belief sd level; the bid is the point mirror.\n\nDECIDED: one decisive round, then finish unless it surprises. Eight batches, all {linux-x64, 8 CPUs}, at most 5 items, results JSON with gain_vs_base, se, n, seeds, advance, source_sha256; briefs name the harness by URL.\nt4-es (e0 table 0 levels 0,1; e1 table 1 level 0; e2 table 1 levels 1,2; e3 table 3 level 0; e4 table 3 levels 1,2): mirrored-pair ES over additive offsets (6 row bands + 5 column bands per level) on TRAIN 200000..263999; lattice-rounded candidates chosen on VALID 300000..304095 (zero kept unless mean - se > 0); the kept one scored once on CHOOSE 64000..65023; result has delta_zb64, delta_sha256, nonzero; advance = work complete.\nt4-join (c; after t4-es, batch pairing, settled): sums usable parts (ALL, GOOD, STRONG, each alone, halves), chooses on CHOOSE by mean - se, one look at REPORT 10000..12047; advance only when REPORT gain >= 0.03 on 2,048 seeds.\nt4-sol (c) -> t4-tf (c) -> t4-gas (c), item pairing, check advance = true: contract and gate T; gates T and F; gate G; code_zb64 goes forward by value.\nt4-engine (b0..b3; after t4-gas, batch pairing, check): fresh blocks 10400000..10400255, ..10400511, ..10400767, ..10401023 against QLX5, one look at 128 seeds (stop when mean + 2 se < 0.04), rows per seed, peak_gas, oog.\nt4-shape (g0, g1, g3 = tables 0, 1, 3; outside the pipeline): line scans of uniform, half-table, scale, row-shift and tilt directions, SCAN 400000..402047, CONFIRM 410000..418191: findings 2 and 3 as worker results.\nt4-node (n0, n1, n3): the 24 most visited nodes of each table, +-1 lattice unit, SCAN 500000..502047, CONFIRM 510000..518191: the finest basis.\nWake on t4-engine (it settles when cancelled), t4-shape and t4-node, or after 300 minutes. read is empty: small unmerged batches are handed whole.\n\nGATES AS THE ORCHESTRATOR DEFINED THEM (the objective names T, F, G without defining them; say so in the write-up). T: all 9,172 nodes decoded from the new source equal QLX5 node + delta; the source differs from QLX5 only in the hex literal and one comment line. F: on 9700000..9700003 every callback's two fees from the compiled contract equal the Python port's with the new tables, unchanged QLX5 as control. G: on 9700000..9700127, 0 OOG, 0 failed callbacks, afterSwap peak <= 245,000, source <= 50,000 chars, runtime <= 24,576 bytes.\n\nSEED LEDGER. CHOOSE 64000..65023: map (first 512), visit profiles (first 128), my one probe, then t4-es and t4-join (selection lives here). REPORT 10000..12047: no look so far; t4-join takes look 1. Orchestrator probes 100000..104095: spent. t4 pools as named above. Engine screening 9700000..9700127 is never evidence of gain; harness parity used 10010512..10011023. Engine fresh: 10400000..10401023 belong to t4-engine if it runs (a block stopped early is spent) and the next block then starts at 10401024; else still at 10400000. The replica refuses seeds >= 10,200,000.\n\nNEXT EPISODE, BY OUTCOME.\n- t4-join advance false, REPORT gain under +0.015, and t4-shape/t4-node confirm nothing that sums to +0.02: set finish true. Write up: direct tuning of the table values in the existing encoding yields about +0.01 against +0.12 needed; evidence = the five maps, t4-es parts, the join's REPORT figure, shape and node bounds; no contract is brought back.\n- REPORT gain between +0.015 and +0.03, or confirmed shape/node steps that could add to +0.03: one more round (t5-*): ES started from the joined correction plus the confirmed steps, finer bands only where parts were nonzero, new pools (TRAIN 264000..327999, VALID 305000..309095), then the same pipeline; that is REPORT look 2, say so.\n- t4-join advance true: the pipeline ran on. Pool the four engine blocks by rows; bring the contract back only when the pooled gain is >= +0.04 on 1,024 completed fresh seeds with mean - 2 se > 0, 0 OOG, peak <= 245,000 and gates T, F, G passed. Never brief a submission: the requester asks the user.\n- A brief refused: mend only that one under a new name. Briefs describe work and name result fields as computed figures; episodes 1 and 2 were refused for asking for a command's verbatim output. A machine-side failure is not the brief's: run the failed items again with itemsFrom.\n- Spent lines stay excluded (objective).",
 "spawn": [
  {
   "name": "t4-es",
   "brief": "One item: evolution-strategy search for a correction to QLX5 fee table {{table}}, level-knot indices {{levels}}, on the engine-faithful replica. Credit Taylor (gtmcknight), github.com/gtmcknight/amm-sim@4812a6382311624e1506aca131ca35c378f930d9 research/solved, in every authored file and result.credit.\nHarness: https://api.imd.fun/artifacts/9ad960e6c7e11509b81f2852f7f34d395425adc226141b0bc828ed6f5f344663 (JSON; implementation_zb64 and dependency_zb64 are base64(zlib(JSON of path to text)): decode both into one folder under test/scratch/). Its README.md gives the g++ build of the original and overlay replica, the delta file (a node a line: table level row column millibps, stored knot indices), qpl.py (decode, apply, encode) and score.py. Check implementation_sha256 4d4894474104eac9148e52b18d679b994ce73c6a889bafa18169c8dacca22855 and that an empty delta equals the original on 64 seeds.\nQLX5: code_zb64.QLX5 (base64(zlib(source))) of https://api.imd.fun/artifacts/1ef80bfb6d6791b877b1f4048a5e63cf2ae54153e6e8763ae3f8ab13132dfb15, sha256 e183e5bc3fb794b7067703b10a7da9920267aa5f4caa968e16ca101b02338f40.\nSeeds: TRAIN 200000..263999, VALID 300000..304095, CHOOSE 64000..65023. Never run 10000..12047, and no engine. Every score is the paired mean edge difference against unchanged QLX5 on the same seeds, se = sample sd / sqrt(n).\nParameters, frozen before any scoring: for each of your levels, 6 row bands and 5 column bands of equal visit weight (profile on 64000..64127); a node's correction in bps is its level's row-band offset plus its column-band offset. Lattice unit of this table: {{unit}} bps.\nSearch on TRAIN only, from zero: mirrored-pair ES (theta +- sigma*eps on the same seed slice, a new slice of 256 or more seeds each generation), sigma from 0.3 bps and shrinking. Size it to the item's hour with ten minutes to spare: about 100,000 simulations where that fits. Known from 4,096-seed probes: QLX5 is a sharp, partly one-sided optimum (uniform +-0.25 bps on all tables loses 0.04 to 0.07; gains seen are about +0.01): expect corrections of a lattice unit or less.\nCandidates: the ES mean, and it times 0.5 and 1.5, each rounded with qpl.apply(quantize=True) and passing qpl.encode; when all round to zero, also the largest band offset alone at one unit, with its sign. Score the realised candidates on VALID; keep the best when its mean - se > 0, else keep the zero correction. Score the kept one once on CHOOSE.\nResult JSON: credit; table; levels; gain_vs_base, se, n, seeds [first,last] (the kept correction on CHOOSE; 0, 0, 1024 when zero); valid {gain, se, n}; nonzero (boolean); advance (true when the controls passed and the search ran to its end, whatever it found); source_sha256 (QLX5's); delta_zb64 = base64(zlib(the kept realised correction as a harness delta file)), \"\" when zero; delta_sha256 of that file; bands (level, axis, knots, es_mean_bps); candidates (name, valid gain, se); simulations; limitations.",
   "items": [
    {
     "key": "e0",
     "vars": {
      "table": "0",
      "levels": "0 and 1",
      "unit": "0.25"
     }
    },
    {
     "key": "e1",
     "vars": {
      "table": "1",
      "levels": "0",
      "unit": "0.5"
     }
    },
    {
     "key": "e2",
     "vars": {
      "table": "1",
      "levels": "1 and 2",
      "unit": "0.5"
     }
    },
    {
     "key": "e3",
     "vars": {
      "table": "3",
      "levels": "0",
      "unit": "1.0"
     }
    },
    {
     "key": "e4",
     "vars": {
      "table": "3",
      "levels": "1 and 2",
      "unit": "1.0"
     }
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "requires": {
    "platform": [
     "linux-x64"
    ],
    "minCpus": 8
   }
  },
  {
   "name": "t4-shape",
   "brief": "One item: line scans of QLX5 fee table {{table}} along global shape directions on the engine-faithful replica, to bound what moving the table can gain. Credit Taylor (gtmcknight), github.com/gtmcknight/amm-sim@4812a6382311624e1506aca131ca35c378f930d9 research/solved, in every authored file and result.credit.\nHarness: https://api.imd.fun/artifacts/9ad960e6c7e11509b81f2852f7f34d395425adc226141b0bc828ed6f5f344663 (JSON; implementation_zb64 and dependency_zb64 are base64(zlib(JSON of path to text)): decode both into one folder under test/scratch/). Its README.md gives the g++ build of the original and overlay replica, the delta file (a node a line: table level row column millibps, stored knot indices), qpl.py (decode, apply, encode) and score.py. Check implementation_sha256 4d4894474104eac9148e52b18d679b994ce73c6a889bafa18169c8dacca22855 and that an empty delta equals the original on 64 seeds.\nQLX5: code_zb64.QLX5 (base64(zlib(source))) of https://api.imd.fun/artifacts/1ef80bfb6d6791b877b1f4048a5e63cf2ae54153e6e8763ae3f8ab13132dfb15, sha256 e183e5bc3fb794b7067703b10a7da9920267aa5f4caa968e16ca101b02338f40.\nSeeds: SCAN 400000..402047, CONFIRM 410000..418191. Never run 10000..12047 or 64000..65023 (visit profile on 64000..64127 excepted), and no engine. Every score is the paired mean edge difference against unchanged QLX5, se = sample sd / sqrt(n).\nDirections, each rounded to the lattice ({{unit}} bps) with qpl.apply(quantize=True). For each level knot in {{levels}}: (a) the same offset on every node, steps -2, -1, +1, +2 lattice units. For each level knot in {{main}}, steps -1 and +1 unit: (b) rows whose knot is below 160 only; (c) rows at or above 160 only; (d) the lower half of the columns by visit weight; (e) the upper half. Over all levels together: (f) every node scaled by -0.5, -0.25, +0.25, +0.5 percent; (g) the table shifted along the row axis by -0.1, -0.05, +0.05, +0.1 grid units (linear interpolation between row knots); (h) a tilt of -10, -5, +5, +10 millibps per row-grid unit from 160.\nScore every step on SCAN. Score again on CONFIRM each step whose SCAN mean - se > 0. When two or more steps have CONFIRM mean - 2 se > 0, score their sum on CONFIRM too. If time runs short, drop steps from the end of the list and name them.\nResult, one JSON object: credit; table; measurement_role \"bound\"; directions (each: id, levels, steps, each with step, nodes_changed, scan {gain, se, n}, confirm {gain, se, n} or null); confirmed (id, step, gain, se); sum_of_confirmed {gain, se, n} or null; gain_vs_base, se, n, seeds [first,last] = the best CONFIRM figure (the sum when scored, else the best confirmed step; 0, 0, 0 when none confirmed); best_delta_zb64 = base64(zlib(delta file of that best)), \"\" when none; advance (true when the controls passed and every step kept was scored); source_sha256 (QLX5's, verified); dropped; engine_runs 0; report_set_evaluated false; limitations.",
   "items": [
    {
     "key": "g0",
     "vars": {
      "table": "0",
      "levels": "0, 1",
      "main": "0",
      "unit": "0.25"
     }
    },
    {
     "key": "g1",
     "vars": {
      "table": "1",
      "levels": "0, 1, 2",
      "main": "0, 1",
      "unit": "0.5"
     }
    },
    {
     "key": "g3",
     "vars": {
      "table": "3",
      "levels": "0, 1, 2",
      "main": "0, 1",
      "unit": "1.0"
     }
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "requires": {
    "platform": [
     "linux-x64"
    ],
    "minCpus": 8
   }
  },
  {
   "name": "t4-node",
   "brief": "One item: single-node scans of QLX5 fee table {{table}} on the engine-faithful replica: its 24 most visited nodes, each moved one lattice unit ({{unit}} bps) up and one down, to see whether the finest basis holds any gain. Credit Taylor (gtmcknight), github.com/gtmcknight/amm-sim@4812a6382311624e1506aca131ca35c378f930d9 research/solved, in every authored file and result.credit.\nHarness: https://api.imd.fun/artifacts/9ad960e6c7e11509b81f2852f7f34d395425adc226141b0bc828ed6f5f344663 (JSON; implementation_zb64 and dependency_zb64 are base64(zlib(JSON of path to text)): decode both into one folder under test/scratch/). Its README.md gives the g++ build of the original and overlay replica, the delta file (a node a line: table level row column millibps, stored knot indices), qpl.py (decode, apply, encode) and score.py. Check implementation_sha256 4d4894474104eac9148e52b18d679b994ce73c6a889bafa18169c8dacca22855 and that an empty delta equals the original on 64 seeds.\nQLX5: code_zb64.QLX5 (base64(zlib(source))) of https://api.imd.fun/artifacts/1ef80bfb6d6791b877b1f4048a5e63cf2ae54153e6e8763ae3f8ab13132dfb15, sha256 e183e5bc3fb794b7067703b10a7da9920267aa5f4caa968e16ca101b02338f40.\nSeeds: PROFILE 64000..64127 (visit weights only), SCAN 500000..502047, CONFIRM 510000..518191. Never run 10000..12047 or the rest of 64000..65023, and no engine. Every score is the paired mean edge difference against unchanged QLX5, se = sample sd / sqrt(n).\nWork: rank the table's nodes by abs_weight from the profile, over all its levels, and freeze the top 24. For each, score +1 unit and -1 unit on SCAN (each must pass qpl.apply and qpl.encode; say so where it does not). Score again on CONFIRM each signed step whose SCAN mean - se > 0. When two or more steps have CONFIRM mean - 2 se > 0, score their sum on CONFIRM too. If time runs short, drop nodes from the least visited end and name them. Known from 4,096-seed probes: QLX5 is a sharp, partly one-sided optimum (uniform +-0.25 bps on all tables loses 0.04 to 0.07; gains seen are about +0.01): expect corrections of a lattice unit or less.\nResult, one JSON object: credit; table; measurement_role \"bound\"; nodes (each: node [level,row,column], share_of_table, value_bps, plus {gain, se, n}, minus {gain, se, n}, confirm {sign, gain, se, n} or null); confirmed (node, sign, gain, se); sum_of_confirmed {gain, se, n} or null; gain_vs_base, se, n, seeds [first,last] = the best CONFIRM figure (the sum when scored, else the best confirmed step; 0, 0, 0 when none confirmed); best_delta_zb64 = base64(zlib(delta file of that best)), \"\" when none; advance (true when the controls passed and every node kept was scored); source_sha256 (QLX5's, verified); dropped; engine_runs 0; report_set_evaluated false; limitations.",
   "items": [
    {
     "key": "n0",
     "vars": {
      "table": "0",
      "unit": "0.25"
     }
    },
    {
     "key": "n1",
     "vars": {
      "table": "1",
      "unit": "0.5"
     }
    },
    {
     "key": "n3",
     "vars": {
      "table": "3",
      "unit": "1.0"
     }
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "requires": {
    "platform": [
     "linux-x64"
    ],
    "minCpus": 8
   }
  },
  {
   "name": "t4-join",
   "brief": "One item: join the table corrections found by batch {{after.batch}} into one candidate and report it once on the engine-faithful replica. Credit Taylor (gtmcknight), github.com/gtmcknight/amm-sim@4812a6382311624e1506aca131ca35c378f930d9 research/solved, in every authored file and result.credit.\nHarness: https://api.imd.fun/artifacts/9ad960e6c7e11509b81f2852f7f34d395425adc226141b0bc828ed6f5f344663 (JSON; implementation_zb64 and dependency_zb64 are base64(zlib(JSON of path to text)): decode both into one folder under test/scratch/). Its README.md gives the g++ build of the original and overlay replica, the delta file (a node a line: table level row column millibps, stored knot indices), qpl.py (decode, apply, encode) and score.py. Check implementation_sha256 4d4894474104eac9148e52b18d679b994ce73c6a889bafa18169c8dacca22855 and that an empty delta equals the original on 64 seeds.\nQLX5: code_zb64.QLX5 (base64(zlib(source))) of https://api.imd.fun/artifacts/1ef80bfb6d6791b877b1f4048a5e63cf2ae54153e6e8763ae3f8ab13132dfb15, sha256 e183e5bc3fb794b7067703b10a7da9920267aa5f4caa968e16ca101b02338f40.\nInputs: the results of {{after.batch}} among your inputs (JSON: delta_zb64 = base64(zlib(delta file)), delta_sha256, nonzero, advance, gain_vs_base and se on CHOOSE). A part is usable when advance and nonzero are true and its delta decodes to delta_sha256.\nCandidates (the parts act on different tables or levels, so they add node by node): ALL, every usable part; GOOD, the parts with CHOOSE gain - se > 0; STRONG, those with gain - 2 se > 0; each part alone; ALL and GOOD times 0.5, rounded to the lattice. Each must pass qpl.apply(quantize=True) and qpl.encode as one table set. Score each on CHOOSE 64000..65023, paired against unchanged QLX5 (se = sample sd / sqrt(n)), and choose the highest mean - se. Then score the chosen one, once, on REPORT 10000..12047, all 2,048 seeds. No other candidate touches REPORT; no engine.\nResult, one JSON object: credit; measurement_role \"report\"; gain_vs_base, se, n, seeds [first,last] (the chosen candidate on REPORT); advance (true only when that gain is at least 0.03 with n = 2048); choose {name, gain, se, n}; candidates (each: name, parts, choose gain, se, encodable); parts_used; delta_zb64 = base64(zlib(delta file of the chosen realised correction)); delta_sha256; nodes_changed; max_abs_millibps; qpl_sha256 = sha256 of the corrected 10,160-byte QPL1 blob from qpl.encode; source_sha256 (QLX5's, verified); report_looks 1; engine_runs 0; limitations. When no part is usable: gain 0, se 0, n 0, advance false, and why.",
   "items": [
    {
     "key": "c",
     "vars": {}
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "requires": {
    "platform": [
     "linux-x64"
    ],
    "minCpus": 8
   },
   "after": {
    "batch": "t4-es",
    "pairing": "batch",
    "when": "settled"
   }
  },
  {
   "name": "t4-sol",
   "brief": "One item: write the corrected QLX5 contract for the table correction in {{after.result}} (also among your inputs; JSON with delta_zb64 = base64(zlib(delta file)), delta_sha256, qpl_sha256, and its replica REPORT figures). Credit Taylor (gtmcknight), github.com/gtmcknight/amm-sim@4812a6382311624e1506aca131ca35c378f930d9 research/solved, in every authored file and result.credit.\nHarness: https://api.imd.fun/artifacts/9ad960e6c7e11509b81f2852f7f34d395425adc226141b0bc828ed6f5f344663 (JSON; implementation_zb64 and dependency_zb64 are base64(zlib(JSON of path to text)): decode both into one folder under test/scratch/). Its README.md gives the g++ build of the original and overlay replica, the delta file (a node a line: table level row column millibps, stored knot indices), qpl.py (decode, apply, encode) and score.py. Check implementation_sha256 4d4894474104eac9148e52b18d679b994ce73c6a889bafa18169c8dacca22855 and that an empty delta equals the original on 64 seeds.\nQLX5: code_zb64.QLX5 (base64(zlib(source))) of https://api.imd.fun/artifacts/1ef80bfb6d6791b877b1f4048a5e63cf2ae54153e6e8763ae3f8ab13132dfb15, sha256 e183e5bc3fb794b7067703b10a7da9920267aa5f4caa968e16ca101b02338f40.\nWork: decode QLX5 and check its sha256. Its tables are the QPL1 blob in `bytes constant QPL=hex\"...\"`, the same bytes as the harness's upstream/tables.hpp. qpl.decode it, apply the delta with qpl.apply without quantising (it must already be on the lattice) and qpl.encode: the blob stays 10,160 bytes and must hash to qpl_sha256. The new source is QLX5 with that hex literal replaced and one comment line added that credits Taylor and names delta_sha256; every other byte is kept, so the text shape the Python port's mktables.py reads is unchanged. Gate T: decode the tables from the new source again and compare with QLX5 node + delta on all 9,172 nodes.\nResult, one JSON object: credit; gates {\"T\": \"pass\" or \"fail\"}; advance (true when T passes, the source has at most 50,000 characters and it differs from QLX5 in the literal and the comment line only); code_zb64 = base64(zlib(new source)); source_sha256 (the new source's); base_source_sha256; source_chars; nodes_changed; node_mismatches; qpl_sha256; delta_zb64 and delta_sha256 carried unchanged; gain_vs_base, se, n, seeds copied from the input (replica REPORT, not an engine figure); limitations.",
   "items": [
    {
     "key": "c",
     "vars": {}
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "requires": {
    "platform": [
     "linux-x64"
    ],
    "minCpus": 8
   },
   "after": {
    "batch": "t4-join",
    "pairing": "item",
    "check": {
     "path": "advance",
     "equals": true
    }
   }
  },
  {
   "name": "t4-tf",
   "brief": "One item: gates T and F on the corrected QLX5 contract in {{after.result}} (also among your inputs; JSON with code_zb64 = base64(zlib(source)), source_sha256, delta_zb64 = base64(zlib(delta file)), delta_sha256). Credit Taylor (gtmcknight), github.com/gtmcknight/amm-sim@4812a6382311624e1506aca131ca35c378f930d9 research/solved, in every authored file and result.credit.\nTools: the kit github.com/identity-md-launches/goal-3178-build-shared-evaluation-kit@45e7563d1a29ffca9d608fdf60c90bf2624d2d01; how it was driven on unchanged QLX5 (setup, compile, engine_eval._one per seed in forked workers, gas_stats, port replay) is in the fields recipe and notes of https://api.imd.fun/artifacts/fc3bd54c8c987c0ab81c6861e1a6e91c5c3fca757b0f7c114e13a110470c0cde.\nPython port: https://api.imd.fun/artifacts/60dc237fa0a4d42f3b6e2d2bed61c1a2df08d27c31ccd95cce508ee9c8689de4 (qlxcore.py, mktables.py, evmdiff.py).\nHarness: https://api.imd.fun/artifacts/9ad960e6c7e11509b81f2852f7f34d395425adc226141b0bc828ed6f5f344663 (JSON; implementation_zb64 and dependency_zb64 are base64(zlib(JSON of path to text)): decode both into one folder under test/scratch/). Its README.md gives the g++ build of the original and overlay replica, the delta file (a node a line: table level row column millibps, stored knot indices), qpl.py (decode, apply, encode) and score.py. Check implementation_sha256 4d4894474104eac9148e52b18d679b994ce73c6a889bafa18169c8dacca22855 and that an empty delta equals the original on 64 seeds.\nQLX5: code_zb64.QLX5 (base64(zlib(source))) of https://api.imd.fun/artifacts/1ef80bfb6d6791b877b1f4048a5e63cf2ae54153e6e8763ae3f8ab13132dfb15, sha256 e183e5bc3fb794b7067703b10a7da9920267aa5f4caa968e16ca101b02338f40.\nT: run the port's mktables.py on the new source; every one of the 9,172 nodes must equal the QLX5 node plus the delta. F: on seeds 9700000..9700003 run the port with the new tables, replay every callback through the compiled new contract in pyrevm, and count callbacks where either returned fee differs: 0 mismatches and 0 failed calls pass. Do the same with unchanged QLX5 as the control; a failing control is a tool failure, to be said so. Also compare, on those four seeds, the port's edge with the new tables against the harness replica's edge with the delta.\nResult, one JSON object: credit; gates {\"T\": \"pass\" or \"fail\", \"F\": \"pass\" or \"fail\"}; advance (true when both pass and the control passes); node_mismatches; callbacks; fee_mismatches; failed_calls; control {callbacks, fee_mismatches, failed_calls}; port_vs_replica_max_abs_diff; code_zb64, source_sha256, delta_sha256 carried unchanged; base_source_sha256; gain_vs_base, se, n, seeds copied from the input (replica REPORT, not an engine figure); limitations.",
   "items": [
    {
     "key": "c",
     "vars": {}
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "requires": {
    "platform": [
     "linux-x64"
    ],
    "minCpus": 8
   },
   "after": {
    "batch": "t4-sol",
    "pairing": "item",
    "check": {
     "path": "advance",
     "equals": true
    }
   }
  },
  {
   "name": "t4-gas",
   "brief": "One item: gate G on the corrected QLX5 contract in {{after.result}} (also among your inputs; JSON with code_zb64 = base64(zlib(source)), source_sha256; check the hash). Credit Taylor (gtmcknight), github.com/gtmcknight/amm-sim@4812a6382311624e1506aca131ca35c378f930d9 research/solved, in every authored file and result.credit.\nTools: the kit github.com/identity-md-launches/goal-3178-build-shared-evaluation-kit@45e7563d1a29ffca9d608fdf60c90bf2624d2d01; how it was driven on unchanged QLX5 (setup, compile, engine_eval._one per seed in forked workers, gas_stats, port replay) is in the fields recipe and notes of https://api.imd.fun/artifacts/fc3bd54c8c987c0ab81c6861e1a6e91c5c3fca757b0f7c114e13a110470c0cde.\nQLX5: code_zb64.QLX5 (base64(zlib(source))) of https://api.imd.fun/artifacts/1ef80bfb6d6791b877b1f4048a5e63cf2ae54153e6e8763ae3f8ab13132dfb15, sha256 e183e5bc3fb794b7067703b10a7da9920267aa5f4caa968e16ca101b02338f40.\nWork: compile the new source with the kit's pinned compiler and settings; run the kit engine on screening seeds 9700000..9700127 for the new contract and for unchanged QLX5, counting out-of-gas and failed callbacks from the engine's gas_stats rather than stopping at the first. These seeds are not fresh: the paired difference is a screening figure, never evidence of gain. G passes when out-of-gas is 0, failed callbacks are 0, the afterSwap peak gas is at most 245,000, the source has at most 50,000 characters and the runtime at most 24,576 bytes. QLX5 measured here before: peak 205,887, runtime 22,440 bytes.\nResult, one JSON object: credit; gates {\"G\": \"pass\" or \"fail\"}; advance (true when G passes); peak_gas; oog; failed; source_chars; runtime_bytes; runtime_sha256; base {peak_gas, oog, runtime_bytes}; gain_vs_base, se, n, seeds [9700000,9700127] (candidate minus QLX5 on the screening seeds, se = sample sd of paired differences / sqrt(n)); measurement_role \"screening\"; code_zb64 and source_sha256 carried unchanged; base_source_sha256; limitations.",
   "items": [
    {
     "key": "c",
     "vars": {}
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 64000
   },
   "requires": {
    "platform": [
     "linux-x64"
    ],
    "minCpus": 8
   },
   "after": {
    "batch": "t4-tf",
    "pairing": "item",
    "check": {
     "path": "advance",
     "equals": true
    }
   }
  },
  {
   "name": "t4-engine",
   "brief": "One item: engine run of the corrected QLX5 contract against unchanged QLX5 on fresh seeds {{first}}..{{last}} (256 seeds, used once and for this candidate only). Credit Taylor (gtmcknight), github.com/gtmcknight/amm-sim@4812a6382311624e1506aca131ca35c378f930d9 research/solved, in every authored file and result.credit.\nInputs: the {{after.batch}} result among your inputs (JSON with code_zb64 = base64(zlib(source)) and source_sha256; check the hash).\nQLX5: code_zb64.QLX5 (base64(zlib(source))) of https://api.imd.fun/artifacts/1ef80bfb6d6791b877b1f4048a5e63cf2ae54153e6e8763ae3f8ab13132dfb15, sha256 e183e5bc3fb794b7067703b10a7da9920267aa5f4caa968e16ca101b02338f40.\nTools: the kit github.com/identity-md-launches/goal-3178-build-shared-evaluation-kit@45e7563d1a29ffca9d608fdf60c90bf2624d2d01; how it was driven on unchanged QLX5 (setup, compile, engine_eval._one per seed in forked workers, gas_stats, port replay) is in the fields recipe and notes of https://api.imd.fun/artifacts/fc3bd54c8c987c0ab81c6861e1a6e91c5c3fca757b0f7c114e13a110470c0cde. The kit's seed check covers 9700000..9700511 only: work from a copy that drives engine_eval._one for this block, and change nothing else.\nWork: run both contracts on every seed of the block with the same config; the paired difference is candidate edge minus QLX5 edge, se = sample sd of the differences / sqrt(n). Look once after the first 128 seeds: stop when mean + 2 se < 0.04 (the block is then spent; say so), else run all 256. Count out-of-gas and failed callbacks from the engine's gas_stats and take the candidate's afterSwap peak gas over the seeds run.\nResult, one JSON object: credit; gain_vs_base, se, n, seeds [first,last actually run]; early_stop (boolean); advance (true when all 256 ran with oog 0, failed 0 and peak_gas at most 245,000); peak_gas; oog; failed; source_sha256 (the candidate's); base_source_sha256; rows = [[seed, candidate edge, QLX5 edge]] to 6 decimals, for exact pooling with the other blocks; measurement_role \"engine\"; limitations.",
   "items": [
    {
     "key": "b0",
     "vars": {
      "first": "10400000",
      "last": "10400255"
     }
    },
    {
     "key": "b1",
     "vars": {
      "first": "10400256",
      "last": "10400511"
     }
    },
    {
     "key": "b2",
     "vars": {
      "first": "10400512",
      "last": "10400767"
     }
    },
    {
     "key": "b3",
     "vars": {
      "first": "10400768",
      "last": "10401023"
     }
    }
   ],
   "output": {
    "format": "json",
    "maxBytes": 48000
   },
   "requires": {
    "platform": [
     "linux-x64"
    ],
    "minCpus": 8
   },
   "after": {
    "batch": "t4-gas",
    "pairing": "batch",
    "check": {
     "path": "advance",
     "equals": true
    }
   }
  }
 ],
 "read": [],
 "cancel": [],
 "wake": {
  "batches": [
   "t4-engine",
   "t4-shape",
   "t4-node"
  ],
  "afterMinutes": 300
 },
 "finish": false
}