Commit Graph

20 Commits

Author SHA1 Message Date
Drew T 4f7c3b64a3 docs(phase-33): commit-map + citations resolved to the rewritten history (C4–C7 — the tip commit)
- docs/commit-map.tsv: 4,032 rows (ordinal of the ORIGINAL main -> rewritten hash, author/committer dates, subject);
  1 pruned row of zeros (ordinal 1712, "session archive update"); 0 old hashes asserted; ordinal 1 unchanged by the
  rewrite (byte-identical)
- resolve_tokens: 1,238 commit:NNNN tokens -> shortest-unique new hashes in 98 files (docs, phase-ends, logs, tool
  docstrings, 2 C comments, the A5 evidence logs); residue left as tokens: commit:1712 x4 (the pruned commit),
  commit:orphan-24 x2, commit:orphan-26, commit:orphan-35 (cited commits that exist in no lineage)
- the rewrite (C4): filter-repo 2.47.0 on a bare clone of the C2 tip, 311 s, exactly 1 pruned, main 4,032 -> 4,031;
  the pre-rewrite history is mirrored in the private archive repo and in the local bundle
- the proof (C5): verify_rewrite 4,031 pairs / 0 failures; absent_scan 0 offenders; gate_scan 0 offenders on the clone
- adoption (C6): 100 text files differ at the tip, 0 purge paths, 0 added/deleted; leftover refs dropped; no gc yet
- resolver skips tools/public_rewrite/ (its self-test fixtures are the token grammar, not citations); repo-local
  identity is the GitHub noreply address from here on; CURRENT_PHASE: C4–C7 logged, checkpoint -> NEXT = C8
2026-09-06 23:28:39 -06:00
Drew T 194cce7570 docs(phase-31): T4 DONE — routing rule (<=50: Sonnet+DeepSeek parallel, Opus residue; 51-120: Sonnet, Opus escalation; >120: Opus; haiku retired; M-extend-tell -> wall); frontier-s61 Addendum 5; judge artifacts (P31 S62) 2026-08-26 18:32:51 -06:00
Drew T 16d1d01b56 docs(phase-31): T3 log (75 banks; six carve-lane defect classes fixed; residue named) + frontier-s61 Addendum 4 (P31 S62) 2026-08-26 15:57:18 -06:00
Drew T ab9e5770c7 feat(tools)+docs: T2 knowledge — interleave_check.py + pads_audit.py promoted (derive carve specs from the bytes; SETUP rows), cookbook §302 (the three carve-state invariants; five reds classified), frontier-s61 Addendum 3 (red list 5 -> 0, 39/40 held banks) (P31 S62) 2026-08-26 14:29:35 -06:00
Drew T 3a5caa65b1 feat(tools)+docs(phase-31): T1 — resolver declfix wiring; masked_diff/rtu_match compare internal-j targets (jrel; §195 premise refuted, cookbook §301); diff_autopsy.sh + stub_invariant_audit.py promoted; frontier-s61 Addendum 2 (step-1 falsifier fired: 54 carve-refused, 2 DIFF autopsied+banked, 1 plumbing); S62 log 2026-08-26 14:04:54 -06:00
Drew T d7bfa03d92 docs(phase-31): frontier-analysis-s61 addendum — distill cross-check folded in (4 fns to deterministic via §295; §296 contamination quantified at 11 main fns; analyst's own R40 note) 2026-08-26 12:55:57 -06:00
Drew T bd37b7eb7b docs(phase-31): frontier-analysis-s61 — the post-ox finish-plan ground truth (2,520 open instances fully classed, zero unassigned; wall = 86 fns; done-denominator reconciled; engines measured per class) 2026-08-26 12:45:16 -06:00
Drew T 07a167516d docs(s60): the Fable frontier audit + corrections it forced to my own checkpoint
The audit's headline, measured: THE WALL IS AN INTEGRATION WALL, NOT A CODEGEN WALL. Of the 292
functions the gate has refused 6+ times, 178 (61%) have ALREADY produced a closeness-0 draft —
match_one byte-equality, whole-binary gate rejection. The blocker is symbols/decls/TU plumbing,
and the fleet keeps re-drafting them: 10,049 reject rows over 574 distinct functions. Highest-EV
build is a zero-token integration-resolver lane, not more drafting.

CORRECTIONS TO MY OWN NUMBERS, verified against the tree before accepting:
* siblings are 1,334 behind 480 multi-member groups, NOT ~3,900. 1,292 groups are SINGLETONS
  carrying 57% of open instruction mass. I conflated the never-drafted stub count with the sibling
  count and overstated remap leverage ~3x, in this checkpoint and repeatedly in conversation.
* 'everything drawable is gen6+' holds only for the collapsed wave-eligible view; whole-pool
  generation is 53% gen0/1, 25% gen6+, and only 292 fns are 6+ GATE-refused.
* '30-67 min gates at 8% CPU' conflated wall_min (includes drafting/queue) with gate wall (12-31
  min healthy). Gate cost is proportional to FAILURES, not drafts: ~3 whole-binary builds per
  failing draft, so banks/gate-min fell 17.5 -> 0.10 as conversion fell.
* the 5,388 closeness<=2 rows de-dupe to ~543 open functions; my own 19:40 re-measure found 290
  still open, down from its 470 — the re-gate and grinder are draining that pool now.
* campaign_status's 'banked today' undercounts: the stub invariant says ~2,644 net, because the
  A-prop lane's 357 rode in a chore commit its regex cannot see.

One documented counterexample to 'model quality is not a bottleneck': func_80181714, where
ox-alpha plateaued at closeness 4 while Opus/GLM/DeepSeek each reached reloc-verified MATCH —
argues for a small escalation tier AFTER the resolver drains the fake walls.

Taken on trust and flagged as such: the A-prop residual split (169 STRUCT / 121 no-seed-decl /
73 IMM / 12 void) — the refusal mechanisms exist in aprop_autodraft.py but no file carries those
counts; re-derive before building the decl-inference tool.
2026-08-25 19:36:51 -06:00
Drew T 65fe4a81d4 docs(aprop-s59): final numbers — 64 banked exactly; sweep 3 honest 0/9 with the residual hypotheses named 2026-08-24 23:39:16 -06:00
Drew T 586916732c docs(aprop-s59): the measured decomposition + honest ceiling; cookbook §270-§273; lane wiring complete
docs/tool-designs/aprop-lane-s59.md: baseline (117 staged / 0 banked = 82
shape-DIFF + 19 standalone-fail + 16 near-0, none invisible), the defect
classes with byte-proofs, the fixed pipeline's end-to-end numbers (64+ banked,
zero tokens), the near-miss taxonomy (11 IMM tier-2, 8 wrong-family), the
ceiling with every refusal named and sized, and the two pre-existing RED
binaries the scoped R22 surfaced (SC07_010 fixed green; SC07_002 named for the
jtbl owner).

Cookbook: §270 the four-verdict law (instructions/symbols/TU/whole-binary —
stage on fewer and burn a build per missing layer forever), §271 ordinal
candidate pairing, §272 K&R the definition, §273 the wrong-oracle law.

maintenance.sh now runs the full recovered pipeline unattended: shape-gated
(binary,fn)-keyed staging, reloc --fix repair+recheck, rtu second chance,
fix_tu_ret_decls on fresh near-0 rejects.
2026-08-24 23:32:06 -06:00
Drew T e6bb079a2f docs(s59): the proof run — 40 drafts, 32 banked, one rebuild, SHA green (m05 = commit:2717) 2026-08-24 19:23:29 -06:00
Drew T e40fe9c116 fix(main-lane): the baseline was RED — guard every gate with a no-draft control (S59)
PROVEN: from 14:57:01 to 18:43:23 today HEAD built main to 307aa45d… against the
expected 143dbb89…, with NO draft substituted (measured under gate.main.lock, no
gate_main alive). Auto-commit commit:2693 had adopted a mid-flight gate_main
substitution — its carve-out reverted main's TUs, gate_main re-wrote them, and
`git add -A src/` swept the unverified bodies in (a TOCTOU race, 14 s after a
bisect chunk banked). Every main batch after it was doomed before its first
draft was judged: m00–m03 card cycles drafted ~737, slated 160, banked 0, and
burned ~50 clean rebuilds bisecting innocent slates. commit:2712 restored the
green content by accident (it swept this investigation's diagnostic checkout).

gate_main: on any batch failure, ONE try_batch([]) control runs first — if HEAD
itself is red it prints BASELINE RED, leaves the slate reusable, exits 3 (R40).
clean_build no longer reports a linked-but-mismatched build as "no binary" (the
build target embeds the SHA check), the compile-conflict shortcut fires only on
error-shaped lines naming a symbol some draft in the slate actually uses (the
baseline's own func_800143AC implicit-decl WARNING was matching — every m04
chunk died with "drafts declaring it: []"), reverts narrow to top-level src/*.c
(main_tus) so a main gate can never destroy overlay lanes' in-flight work, and
--assert-baseline is a first-class mode.

main_lane: every cycle opens with gate_main --assert-baseline and REFUSES to
draft or gate against a red baseline (R43) — BaselineRed parks nothing, burns
no tries, writes .run/main_lane.BASELINE_RED, re-checks every 30 min.

Adopters (ox_campaign ×3, maintenance.sh, gate_stage, gate_lane, idiom_serial):
main's TUs (top-level src/*.c) are never staged and never reverted by an
overlay/maintenance lane — one writer (gate_main), one committer (main_lane,
after the whole-EXE SHA re-checks green). Unstage-after-add is race-free where
the old revert-then-add was the losing half of the TOCTOU.

Diagnosis, evidence and the full timeline: docs/tool-designs/main-lane-fix-s59.md
2026-08-24 19:08:47 -06:00
Drew T 6ae2c55804 feat(tells): land the crib, the grep aliases and per-lane budgets
Three measured harness defects, all fixed:

1. THE CARD NAMED A WORD THE COOKBOOK DOES NOT CONTAIN. api_agent stated the lever
   as a bare label and nothing else; grep 'extend-tell' / 'swaprepeat' / 's16-div-tell'
   over the 750-section cookbook returns ZERO. 108 failure transcripts grepped
   extend-tell and 28 grepped swaprepeat against nothing while the knowledge sat at
   172a/172b under different words. Fixed both ends: a LANE ALIASES grep-bait block at
   172b, and LEVER_CRIB on the card — what the tell means, the section to grep, and
   the byte-proven C spellings.

2. ONE GLOBAL AGENT BUDGET FOR CARDS OF VERY DIFFERENT SIZE. tells cards are 2.4x the
   default lane's (median 89-95 ins vs 37-39) and stack 3-5 idioms; 98 of 270 final
   attempts ended AT the 24-turn cap. LANE_BUDGET gives tells 40 turns / /bin/bash.40, and
   logs the choice so it is auditable rather than invisible.

3. Two new SYS laws: grep the section your crib cites before drafting, and stop when
   the residual class says [permuter]; plus 263 (an invented argument changes
   scheduling — check arity before reaching for a fence the permuter cannot help with).

Cookbook 264 records the four recipes the tells agent drove to MATCH: the inline (s16)
in a call argument, the save-order/bb0 anti-dependence law (new), the opaque-bound
local assigned late (new), and 172b-1's multi-def mirror variable made concrete.
2026-08-24 12:41:41 -06:00
Drew T 9e44612c2a feat(jtbl): the carve→draft→bank pipeline is automated at the gate — byte-proven ×3, one per class (S59)
The carve stays INSIDE the byte-gate (harvest_verify._jtbl_prep_one, the §61b-proven
order); everything new routes work to it:

* jtbl_carve: island_probe (read-only classifier: tail/covered/island-end/island-blocked/
  island-pads/main-manual), --island-split (the one-line §260 insert, end-adjacent only),
  and apply() now recognizes a completed island split as a no-op success instead of the
  historical refusal.
* harvest_verify: _ISLAND_WALLS branch — on the §154-A refusal the gate isolates (body
  still spliced), inserts the split line, re-extracts, re-carves. Snapshot-restore covers it.
* jtbl_lane.py (new): probe → draft (--draft-dir or api_agent) → gate via the exact
  sweep_parallel worker call, HOLDING the campaign draw lock across gate+commit → commit
  named per-binary paths. One jtbl target per gate invocation (§61c).
* build_wave_atlas: probe filter + one-jtbl-card-per-binary cap (inert unless
  --levers jtbl-carve). idiom_serial: refuses the jtbl-carve lever (R43; its pre-carve ran
  the refuted order — S58: 8 attempts, 0 banks).

Proven end to end with the live campaign running (banks committed separately):
  commit:2661  ov_SC03_014/func_8017DCC0  tail: §8b adjacent merge + §8e pad recovery,
             jr_8017AE2C.o .rodata 0x14→0x28 TIGHT, sha d84b01a2 green
  commit:2663  md_SC03_076/func_801F218C  covered: §260 STAGE 2 — sha 9a165e36 identical
             with the table COMPILER-EMITTED; the first md_* jr bank ever
  commit:2664  md_SC03_135/func_801E5358  island-end: the FULL split done BY THE GATE on a
             virgin module (~1.1s, R40-checked), sha b901fda5, md.o 0x27c→0x268 + jr.o 0x14

Census (245/245 members probed, R32): 181 members / 26,445 ins reachable unattended;
main 47 parked (gate_main cadence), island-blocked 10 (stack order), island-pads 6
(needs §8e pads for modules.mk), no-jtbl 1 (atlas mislabel).
Design + failure semantics + campaign hook: docs/tool-designs/jtbl-automation-s59.md;
cookbook §260-A.
2026-08-24 12:31:14 -06:00
Drew T 52a9f931fa docs(S59): o0-path decision study — per-population unlocks, first-compile -O0 bank proof, cookbook §261a reload grammar 2026-08-24 12:11:59 -06:00
Drew T f574f3c80e feat(match_one): derive the opt level from the target — the -O0 oracle was never wired up
--o0 has existed since P29 and NOTHING ever passed it: api_draft.match_one(), the
oracle every wave agent iterates against, builds a fixed argv without it. Every agent
handed an -O0 target was shown an -O2 compile of its own C and a mismatch on every
instruction — feedback that cannot converge, for a reason invisible in the diff, and
it hit even the 51 functions already sitting in -O0 objects.

match_one now decides from the target (R33), with two oracles because neither alone
is sufficient (R34): the -O0 frame-pointer prologue in the target's own bytes, OR the
subseg being an object the Makefile compiles -O0. boot/start.s is built -O0 with no
ordinary prologue; an -O0 function stranded in an -O2 subseg has the prologue but
cannot bank — and match_one now says so instead of letting an agent chase it.

The prologue scan is anchored at glabel, not the top of the file: two md_MAIN_011
.s files open with a migrated jump table / .asciz blob and a naive scan read table
words as the prologue.

tools/test_o0_detect.py: 14,400 .s scanned, 167/167 signature files covered, 0 false
positives outside -O0 objects, both rodata-first files detected.

Census correction in the design doc: the handoff's refutation of md_MAIN_003/011 is
itself wrong (16 and 21 -O0 functions, byte-verified), and the 311 '$fp mentions'
figure over-counts because $fp is $s8, allocatable at -O2. True population: 167
files, of which 116 / 14,148 ins are -O0 functions the build compiles -O2 — double
the atlas estimate, with x2/x3/x4 sibling replication.
2026-08-24 11:15:33 -06:00
Drew T 7aada7c4aa fix(jtbl_carve): route asm lookups through asm_dir() — main's tree is the repo root
main is the one binary splat writes to asm/nonmatchings/800/ and asm/data/ rather
than asm/<alias>/...; the hardcoded asm/<ov>/ in nine places made every main lookup
miss a directory that does not exist and report it as 'already spliced AND no stale
copy' — a true-sounding message about the wrong tree (R43).

With the path, the base and parse_config all fixed, main now reaches the real
analysis: func_8001A114 refuses because subseg 800 would host non-contiguous
.rodata carves (0x63238 = the existing LZSS table, 0x6327c = the new one), i.e.
isolate first — the same architectural refusal an overlay gets.

The island guard also moved AHEAD of jtbl_range, so an island table no longer
reports 'not found in the raw data asm — already carved / stale asm?' (true and
useless: an island table was never in the data asm). It now prints the exact line
the review prescribes: - [0x268, .rodata, md_SC03_076_jr_801F218C].

Review doc gets an S59 addendum with the measured class facts and where the two
examples now stop.
2026-08-24 10:45:01 -06:00
Drew T 840f280020 fix(gate_main): read implicit-declaration errors; document the non-idempotent hoist loop
The main probe (8 drafts) ran 38 minutes without a verdict. Two defects, neither about the
drafts:

1. FIXED — the compile-error shortcut matched only 'previous declaration of', but gcc printed
   'previous implicit declaration of func_80017930'. So a batch whose culprit gcc had already
   named fell through to bisection, which costs a full clean EXE rebuild per step. The matcher
   now accepts the implicit and conflicting-types forms too. (resolve_conflicts is separately
   blind to this class: an implicit decl comes from a call site with no prototype.)

2. NOT FIXED, documented — the typedef-hoist repair is not idempotent. It emitted 'hoisted 2
   typedef(s)' 150 times and left a duplicated marker comment; it re-hoists, rebuilds, fails
   identically and repeats, so it cannot converge. Make it idempotent and bound the bisect
   before gating main again.

Also: ox_campaign pre-draws the next wave AFTER launching shards (doing it before left the
fleet at 8 agents while a card job ran), collect_drafts grants stragglers a grace period
instead of letting 2 of 220 shards idle the fleet for 34 minutes, and drafter bands are now
mostly full-range (the 400-2000 band drew 9 cards for a 2,000-worker fleet).
2026-08-24 02:05:16 -06:00
Drew T e390f4771a docs(tool-designs): o0/cc1 lane study + the grep that refutes half its headline
ox's study correctly found that the atlas o0-lane lever is MISCLASSIFIED on its probe
instance (func_801F0A9C @ md_SC03_076 has no frame pointer — verified, zero $fp under
asm/md_SC03_076/). Its proposed replacement population is fabricated: md_MAIN_003 and
md_MAIN_011 have zero $fp in either module. $fp does appear in 311 files across asm/,
which is the population an -O0 lane would really target.

Recorded rather than discarded: the misclassification finding is load-bearing (a lane
built on the lever label drafts the wrong functions) and the study named checkable files
for every claim, which is what made the refutation cheap.
2026-08-24 01:31:57 -06:00
Drew T de9a550edb fix(jtbl): refuse md_*/main in jtbl_carve — it corrupts those configs before erroring
Two independent reviews (ox design study + Fable validation) found parse_config does not
implement its own documented contract on md_*/main: it can DELETE the c config line and
corrupt the yaml on disk before failing. main also has no config/splat.main.yaml (it is
splat.us.exe.yaml), which is the FileNotFoundError seen on every main jtbl target.

Refuse loudly rather than corrupt quietly (R43). Lift only after parse_config is hardened
and proven on two examples.

Also: gate() stages into a per-run dir (a killed gate's 3,186 stale drafts survived into the
next gate of the same tag and poisoned every group); reloc_filter no longer treats
NOT-A-STUB as a pass (it means ALREADY BANKED — wave an staged 480 of them over source that
already byte-matches).

Designs recorded: docs/tool-designs/jtbl-island-split.md (ox) and -review.md (Fable):
14 CONFIRMED / 8 WRONG / 1 UNVERIFIABLE, verdict GO-WITH-CHANGES, and the correct fix is
SMALLER than proposed — one inserted .rodata carve line + jr_isolate_all.py --only, no _pre
piece and no ld_interleave leading mode.
2026-08-24 01:00:59 -06:00