Repository navigation
fix(swe): stop the harness eating instances the 27B never got to attempt (#380/#382) - #2338
Merged
Merged
Conversation
…become curriculum, not just graded cards (#319) `ExperienceRecord::from_lived_turn` had ZERO production callers tree-wide. The only live producer was `from_kanban_grade` (benchmark.rs:1989), so the experience stream — "the SPINE the salience→curriculum seam was missing", in `experience_stream_path`'s own words — was fed EXCLUSIVELY BY GRADES. A citizen could hold a thousand real conversations and her stream stayed empty. Nothing could learn from work nobody had scored. Everything needed already existed and was correct: the record shape, the two magic-number-free lived-salience signals (infra fault, non-convergence), `ErrorSalience` reading them with no new detector, and a doc block naming "the lived-turn settle site" as a producer. The CALL was missing. Same shape as #341 (boot called the unbounded sink; the rotating one had zero callers) and #362 (ProbeRouterLayer installed with its handle discarded) — a built component with a dead wire, which is why [[an-absence-is-an-unfinished-measurement]] keeps earning its place. WIRED at `service_loop.rs`'s live settle site, BEFORE `SettleStep::from_settled` consumes the outcome — the only point where a lived turn's settle verdict exists. The driver stays a driver per PERSONA-COGNITION-PIPELINE §3: one call, no policy. The behaviour lives in `experience::record_lived_turn` so it is unit-testable without booting a loop. BEST-EFFORT, and that is NOT a fallback ([[no-fallbacks-ever]] holds): nothing is substituted and no result is fabricated. Learning is a SIDE channel to being — a full disk must not make a citizen mute mid-sentence. The failure is WARNED with the path and the honest consequence ("this episode will not become curriculum"). COMPRESSION, because the new writer would otherwise have been the FIFTH hand-rolled spelling of the citizen storage layout. `citizens/peers/<uuid>` was written as `join("citizens/peers")` in modules/work.rs, `join("citizens").join("peers")` in commands/benchmark.rs, and in prose in persona_workspace.rs + persona_roster.rs. Now ONE resolver, `identity::citizen_peer_dir(root, peer)`, in the module whose own doc says "the whole crate imports identity from ONE home" and warns against exactly this re-invention. Keyed by `PeerId`, never a String — the directory name IS her identity. Pure path arithmetic, so a read-only caller never mints an empty citizen dir, which its test pins. Tests: 11/11 cognition::experience (the lived-turn test now asserts the PRODUCER — empty stream → record lands at the canonical path → a second turn appends rather than overwrites, i.e. the wire, not just the record's shape) + identity's one-spelling test. `cargo check -p continuum-core --features metal,accelerate` clean. LIVE PROOF OWED and NOT claimed: no live turn has run on this build. The falsifiable prediction is that a citizen's `citizens/peers/<her>/experience.jsonl` gains a `LivedTurn` record on her next real room turn, where today it holds only kanban grades or nothing. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… not at one call site (#319) MEASURED, and it retracts my own claim from 200dab9. I wrote that the #319 producer was wired and that a LivedTurn record was owed on the next real turn. The wire was wrong, so the record could never come: 180 experience records across 5 citizens on this box, 100% `source: "Eval"`, ZERO `LivedTurn` — while the same core showed 47 persona.upstart.bind, 97 presence rows and 4 delib.context.render, i.e. citizens alive and deliberating. ROOT CAUSE. `record_lived_turn` was called from ONE of the THREE `drive_to_settle` sites in service_loop — the directed-message path (:1087). The self-tick path (:2628) and the held-work path (:1207) settle turns through the same driver and recorded nothing. Three callers, one remembering: a missing constraint expressed as three sites, not a bug at one ([[the-same-bug-at-two-sites-is-a-missing-constraint]]). FIX. The record moves INTO `drive_to_settle`, which is the one place a `SettleOutcome` is born. `drive_to_settle` is now a thin wrapper over a private `settle_to_outcome`, so the write happens ONCE around the driver rather than at its four return paths — a fifth return path added later inherits learning instead of silently opting out, and no call site carries learning policy. Gated on `WorkspaceCycle::acting()`, because that is where a citizen's identity lives: a cycle with no `ActingBody` is pure cognition (a faculty test, a replay) and is nobody's lived experience. Structural absence, not a skipped write. SECOND FIX, applying Joel's rule that a required thing should not be re-expressible: dropped the `stimulus: &str` parameter. It was a second, independent expression of "what she was responding to", free to disagree with what the turn actually perceived — and it already did, since the old call site passed only `msg.text` while the mind had settled over the whole rendered burst. The stimulus is now read off `SettleOutcome.world_state` (set on every return path), so the disagreement is unrepresentable rather than merely discouraged. The test asserts `task.prompt == settled.world_state` instead of a literal. GUARD, positive-controlled (not merely green): a source-walking test asserts `record_lived_turn` has EXACTLY ONE production caller and that it is settle.rs. Verified failing — injected a second call into service_loop and it reported `found 2: [settle.rs, service_loop.rs]` with the remediation in the message. Reverted. Comment-stripped so prose naming the function cannot read as a call (registry.rs's module-wiring audit is the house precedent). cargo check clean; cognition::experience 12/12, cognition::act_observe 38/38. LIVE PROOF STILL OWED and NOT claimed: no turn has run on this build yet. Baseline for falsifiability is recorded above — 180 records, 100% Eval, 0 LivedTurn. The prediction is that a hosted citizen's `citizens/peers/<her>/experience.jsonl` gains a LivedTurn record on her next settled turn from ANY of the three paths, where today it holds only kanban grades. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…t pinned the whole roster at the 240s cap Measured live 2026-08-17, 24 hosted citizens: ONE self-tick across the entire roster in 40 minutes, on a serving lane that was healthy and decoding at ~17 tok/s the whole time. The lane was never the problem. The cadence rule was. The self-tick gates on a single ambient-turn permit (AMBIENT_TURN_CONCURRENCY = 1). When a peer holds it, the citizen yields — she never ran, never looked at the room, learned nothing. The yield branch nonetheless charged her the SAME 1.5×-toward-the-cap backoff as a citizen who ran a full cycle and found nothing new. With 24 citizens, ~23 yield on every beat. Eight yields carries 15s past the 240s rest cap — a 16× slowdown — and she STAYS there, because the only two things that reset the beat are a successful cycle (which the backoff itself now denies her) and an inbound message. Transient contention compounds into permanent slowness, and it gets strictly worse as the roster grows. That is a ratchet, not a rest. Fix: a yield leaves the beat exactly where it was. The earned backoff after a real, fruitless cycle is untouched — that one is honest. Extracted the rule into a pure `next_beat_after(BeatOutcome, ..)` (the `core_bind_guard::decide` shape) because the three outcomes — Engaged / NothingNew / YieldedNoSlot — are trivially confusable inline, and confusing two of them cost the roster 16×. Both call sites now derive from the one function; there is no second expression of the cadence. Regression test pins the invariant in both directions: 50 yields must not cost a single millisecond; a fruitless cycle must still back off and must saturate at the cap. Positive-controlled — restoring the old compounding fails the assertion by name. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…rom the live lane budget, like its own doc always claimed
The self-tick gate in service_loop.rs has documented this permit as "sized to the LIVE
served lane count (LaneAdmission ← set_served_lane_count)" for as long as it has existed.
It never was. It was `const AMBIENT_TURN_CONCURRENCY: usize = 1`, and that constant was the
roster's starvation ceiling: on this box, 4 served lanes and 24 hosted citizens, so 3
non-directed lanes sat permanently idle while 23 citizens yielded every beat against a pool
of one.
Two things kept it invisible. The comment described the intended design, so reading the
call site told you the opposite of the truth. And a hard 1 is indistinguishable from a
quiet room at n≈1 citizen — which is exactly how it was reasoned about ("under light load
ambient turns are naturally serial, so this never throttles a quiet room"). It doesn't
throttle a quiet room. It throttles a POPULATED one, and the roster only grew.
Fix: the pool is `nondirected_budget()` — the same live (lanes − 1, floored at 1) budget
the per-call lane reservation already uses. One machine, one answer to "how much
non-directed concurrency is there", derived from live capacity instead of declared twice
and then contradicted.
Why loosening this bound is safe: the directed-turn guarantee never came from this permit.
It comes from `acquire_serving_lane`, which caps non-directed CALLS at lanes−1 so a
directed call always finds a lane — untouched here, and it is the layer that actually owns
lane priority. This permit's job (#171) is anti-STAMPEDE: bound the fan-out when N peers
wake on one beat and all read inflight=0. A bound of lanes−1 does that job exactly as well
as a bound of 1 — still fixed, still non-blocking, still held across the turn — while no
longer throttling below the hardware.
Also wired the pool into `set_served_lane_count` alongside its two siblings. It is lazy for
the same load-bearing reason they are (capture the real count at first use, never the boot
ceiling), which makes "first use beat serving's first publish" a live possibility — and
without the grow wiring the whole roster would stay pinned at the boot budget for the life
of the process. That has its own regression test.
Tests: the existing ambient test now pins a real 4-lane machine and asserts against the
derived budget — a PREMISE CHANGE, stated as such, because at a hardcoded 1 it could not
tell "correctly bounded" from "throttled below the hardware". Two new rows cover the halves
that could silently hurt: a 1- and 2-lane box still admits exactly one ambient turn
(byte-identical to before on the weakest supported hardware), and a cold-boot pool grows
when serving publishes its real width. 8/8 green.
Corrected two stale comments while here: `resource_admission.rs` claimed "an idle self-tick
is not ambient-permit-gated at all", contradicted by the self-tick gate's own comment block
in the same tree; and the service_loop references to the now-deleted constant.
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…stale core that steals the socket mid-build MEASURED 2026-08-17. `continuum reboot` shipped 6229b37 and deploy-verify reported the core running a87f7c8. The installed image on disk was confirmed to contain the NEW sha, so the build and the install were both correct. The core that answered simply was not the one the deploy launched. The mechanism is not subtle: 1. `reboot` stops the old core and runs start-server.sh, which BUILDS (292s and 530s measured here; 772s on BIGMAMA per #422) and only near the END copies the fresh artifact over ~/.continuum/bin/continuum-core-server. 2. For that whole multi-minute window, no core answers the socket AND the installed path still holds the PREVIOUS build. 3. Every `continuum <verb>` calls `ensure_core_running`, whose entire job is to autostart when nothing answers. In that window it launches the STALE image. 4. That stale core binds the socket and answers. The freshly-built binary loses, and deploy-verify correctly reports the old sha. Any client can do this — a UI poll, `npm start`, a cron, a persona, or an operator typing `continuum ping` to see whether the reboot finished. In the observed incident the trigger was my own 120-second monitor calling `persona/roster`. That also settles the open question on #421, which has sat un-run for days: "something respawns a core within seconds of every kill — external supervisor, or me?" It was the CLI's own autostart. There is no mystery daemon. #421 can close on this. WHY THE EXISTING GUARD COULD NOT SEE IT. `core_bind_guard::decide` is a function of (ping answered, core pids running). Mid-build BOTH are false, and the honest reading of that state really is "no core is running, and starting one is safe" — true in general, wrong during a deploy. "A deploy is in flight" is a fact that lives in another process, so this is not a stricter bind guard; it is the missing observation, published by the only party that knows it. THE FIX. `runtime::deploy_claim` — reboot publishes {pid, started_ms, target_sha} for the length of its build+swap; implicit autostart and the launch arm of explicit `start` consult it and refuse with a message that names the deploying pid, the build it is shipping, and how long it has been going. `--force` overrides, consistent with the Occupied arm beside it. The claim is RAII: released on Ok, Err, `?`, and panic-unwind, because a claim that leaked past its deploy would block autostarts until its owner died. AND THE FAILURE MODE IT MUST NOT BECOME. A claim that outlives its owner would wedge the machine — exactly airc's "start GIVES UP on a contended lock" defect (#355). So the claim is advisory and self-healing: it blocks only while its owner is demonstrably alive AND younger than a 1-hour cap (far above any measured build, still bounded). A killed reboot, a hung build, and a recycled pid all decay back to Clear on their own, and the decision returns `Abandoned{why}` so the caller SWEEPS AND SAYS SO rather than silently obeying a dead file. Writing the claim is best-effort for the same reason: an unwritable advisory file must not turn a hint into an outage. The decision is pure — `decide(claim, owner_alive, now_ms)` — so the `--lib` CI gate covers every row without a filesystem or a process, the same split as `core_bind_guard` and for the same reason. Four rows, each a real case: a live deploy blocks for the whole build; a dead owner and an expired claim both decay to launchable; a future-stamped claim (clock skew) reads as new rather than underflowing to "ancient", which would have silently disabled the guard on any box with a skewed clock; and the on-disk round-trip covers idempotent clear and a corrupt file degrading to absent. 8/8 green with core_bind_guard. NOT YET POSITIVE-CONTROLLED END-TO-END, and stated plainly rather than implied: an isolated control is not reachable while a real core runs, because `running_core_pids()` is global (pgrep) and returns Occupied before the gate. The honest control is the incident itself — a `continuum` verb firing mid-build must now print the refusal instead of autostarting. The monitor that caused the incident still runs every 120s, so the next reboot exercises it. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ext was false `reboot` rebuilds AND reinstalls the CLI (#422 / PR #2293). But the invocation doing the reinstall is by construction the one it REPLACES — a running image cannot be the artifact it just installed. So `cli_staleness_note`, which compares the RUNNING `continuum` against git HEAD, diverged on every healthy deploy and printed ⚠ STALE CLI. Observed three times in a row today on deploys that were otherwise perfect, including one whose core verdict was a clean ✅. Its text then said: "`reboot` rebuilds the CORE and never the CLI." That has been false since #2293 — verified on this box today, where the installed CLI advanced a87f7c8 → 6229b37 → 5d62bf3 across three reboots, each time by reboot's own install step. A warning that fires on every success is not a warning. It is noise that trains the operator to skip the exact line where a REAL stale CLI would appear — the same class of defect as #422's own "⚠ …Please report this" that nobody reported, and as airc's `doctor --fix` reporting ok while delivery was 100% down (#348). Fix: `cli_staleness_note` takes `rebuilt_this_run`, so the two situations stop sharing a message. • self-replacing run (reboot on a machine where `cli_self_build` says Rebuild) → "↻ CLI updated: this invocation is build X, the NEXT one runs Y." Information, not a fault, and it still says the useful part out loud: CLI-side behaviour in THIS run is the old build, so re-run a lifecycle verb whose fix lives in the CLI. • nothing replaced it (a bare `deploy-verify`, or a platform where the self-build skips) → the ⚠, with the false "never rebuilds the CLI" sentence replaced by what is actually true: reboot does rebuild it, except where cli_self_build skips the platform. `reboot` computes the flag from the two terms that actually decide it — a start script exists (the same condition `plan_launch` uses to choose Script for a FromSource launch) AND `cli_self_build(OS) == Rebuild`. Both matter: an installed node with no checkout rebuilt nothing, and Windows deliberately skips. Getting either wrong re-creates the noise or, worse, hides a genuinely stale CLI behind a reassuring handoff line. Test pins both readings apart, and that a MATCHING CLI stays silent in both modes so the flag cannot invent a note. It also asserts the corrected wording no longer contains "never" — the specific false claim. 6/6 green. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… the two install defects, and what is NOT yet measured Standing instruction (Joel, 2026-08-17): a new well-labeled dated observation file after every run, and stop reading the old ones. Written from this session's probes and deploy receipts only; no prior cards consulted. Records the honest state including the gaps: the ambient-pool fix has had no uninterrupted window yet (three reboots for the install fixes), and the deploy claim is unit-green but not positive-controlled end-to-end. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…, and the ambient-pool fix is inert at lanes=1 Re-measured instead of trusting my 18:07 snapshot. active_model IS Qwen3.8-27B on the persona lane; #440's bring-up landed. And nondirected_budget() = lanes-1 floored at 1, so at lanes=1 the new pool equals the old hardcoded constant — the fix is correct but buys nothing in this configuration. The remaining ceiling is the LANE count, and serving.plan says why: a 27B at a 16,384 per-slot floor fits one warm slot (resident_personas=4, warm_slots=1, without_warm_slot=3). That is an allocation policy question, not a bug. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ad identically to a healthy one Measured today at lanes=1: a 10-minute window showed zero `persona.selftick.*` rows. That is ambiguous, and dangerously so. It reads the same whether ONE citizen is mid-turn holding the only lane (healthy, just serialized) or the roster is dead. Resolving it required a manual `curl /slots`, which showed slot 0 processing with 3,727 tokens decoded — fine all along. The cause is structural: the yield branch emits nothing. That was the right call for volume — at 24 citizens on a 15s beat, a row per yield is ~92/min and would drown the stream exactly as `serving.plan` did at 2.6 rows/s (#399) — but the absence of a signal is not the same as a signal of absence ([[an-absence-is-an-unfinished-measurement]], the error class that produced the retracted premises on #211 and #390). Fix: count every yield (one relaxed increment on the permit miss, where the yield actually happens), and emit at most ONE probe per minute for the whole process carrying the delta. `persona.selftick.starved` names it as contention, not a fault — because at lanes=1 with 24 citizens it IS the expected shape, and a probe that cries fault at normal operation is the #348 / #422 defect again. Rate-limit rule is pure and table-tested. Four rows, each a real failure mode: the FIRST starvation always reports (a naive `now - last >= gap` swallows it on a box whose clock starts near zero — and the first one is the one that matters); a second report inside the gap is silent (the firehose); after the gap it reports the WINDOW delta, not the cumulative total (a cumulative count cannot show a rate); and a quiet roster emits nothing at all. Concurrent yielders race a compare-exchange so only one reports per window. 9/9 admission + 41/41 service_loop green. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ield named per-window Caught within the hour of shipping it, by reading the live rows instead of trusting the commit message: 19:44:02Z yields_this_window=135 cumulative=135 19:45:03Z yields_this_window=197 cumulative=197 19:46:03Z yields_this_window=263 cumulative=263 Identical on every row, while consecutive rows differ by ~65. The field named `yields_since_last_report` was reporting the running total. Cause: `take_ambient_yield_report` passed a literal 0 for `yields_at_last_report`, with a comment justifying it — "the report resets the clock, so total-at-report is implicit." That is false. Resetting the TIMESTAMP does not reset the COUNT, so `fresh = total - 0 = total` forever. The galling part, and worth stating plainly: the pure rule was RIGHT and its table test asserted the delta correctly (`ambient_yield_report_due(1_000, 23, 70_000, 9_000) == Some(977)`). The defect lived entirely in the impure wrapper feeding it a wrong argument — which is exactly the seam the pure/impure split exists to protect and exactly the gap a table test over the pure half cannot close. I wrote a commit an hour earlier about fields that promise one thing and deliver another, then shipped one. Fix: a second watermark, `AMBIENT_YIELDS_AT_LAST_REPORT`, advanced by the same winner of the timestamp compare-exchange so a losing yielder's counts roll into the NEXT window rather than being dropped. New test pins the argument boundary the old one couldn't reach: the second window must read 62 (197−135), not 197. The mislabel did NOT cost the measurement — consecutive cumulative rows still give the rate by subtraction, and that rate is the finding: ~65 ambient yields per minute across 24 citizens with ZERO self-cycles completing. First time that contention has had a number instead of a silence. 10/10 green. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…render, order by relevance
READ OUT OF A LIVE AMBIENT TURN (capture 762a806b, 2026-08-17), not inferred:
system prompt 18,697 chars
[board] 9,284 chars 49.7% ← 38 distinct cards, full titles
(preamble) 7,863 chars 42.1%
workspace-map 1,478 chars 7.9%
observed prefill 12,286 tokens for a turn that decoded 41
Half of every citizen's system prompt was the kanban board, re-sent on every self-tick, and
it was ~25% of total prefill. The per-card loop was `for card in &board.cards` bounded only
by remaining budget.
Two things make that a defect rather than a cost:
1. IT IS REDUNDANT. The `[board]` headline and the `[your work]` / `[available work]` leads
directly above already carry the counts and the top titles — and those leads were ADDED
precisely because this dump is unreliable under budget (the Asha 2026-08-06 note in this
file). So the same facts are paid for twice and the expensive copy is the one truncated.
2. IT SCALES BACKWARDS. Bounded by budget, the board grows to fill the prompt, so every
citizen thinks SLOWER as the backlog grows. A team that accumulates work becomes
progressively less able to do it. That is the opposite of what a work board is for, and
it gets worse every time we file a card.
FIX: order by what she can act on — her own holds first, then newest claimable (the same
recency argument the available-work lead already makes) — and take at most
MAX_RENDERED_CARDS. Counts in the headline stay the TRUE totals; the board is not made
smaller than it is, only shorter than it was. `work/list` remains the full read and is
verified working (#337).
The cap is sized from what it MUST cover, not picked: both leads name up to 5, so the detail
must carry 10 or the summary would promise cards the detail omits — a citizen seeing "you
hold 5" above a list of 3 would rightly read the substrate as inconsistent. Two spare keeps a
just-created card visible in the turn it arrives. Ten is the floor; it cannot drop below
without re-deriving the lead caps with it.
Also fixed: cap-truncation now counts into `dropped` alongside budget-truncation, so the
debug line does not report dropped=0 on a shortened board and hide the shortening in the one
place an operator looks.
Test pins all three halves — the cap holds, her OWN card survives the cut even when it is
the OLDEST on the board (under the old board-order loop a cap would have cut exactly the
worst card), and the headline still reports the true 40. Positive-controlled: with the cap
removed it fails "board must be capped at 12, rendered 41 of 41". 13/13 green.
NOT YET MEASURED LIVE: the prompt-size delta. Deploying next; the number goes on the
observation card, not in this message.
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ike -e . already did (#380/#383) `ensure_env` had TWO sites that install under the instance's date pin, and only ONE of them could heal when the pin itself created an unresolvable hole: - the editable `-e .` install carried a bounded retry loop that reads uv's own `exclude-newer-package` hint and retries with the minimum per-package override; - the dependency-sdist build-dep pre-install (#383 cause 2) applied `--exclude-newer` and failed hard. Same decision, two expressions, one of them healed. Measured 2026-08-17 dispatching swe-bench-lite's head: every astropy instance died at the unhealed site with could not pre-install astropy__astropy-6938's dependency-sdist build deps ["jinja2"] × Failed to download and build `markupsafe==1.0` ╰─▶ Because only setuptools<=38.2.4 is available and you require setuptools>=40.8.0 which is the pin working exactly as designed — jinja2 2.10 pulls markupsafe 1.0, whose setup.py build wants setuptools>=40.8.0, and the 2017 cutoff caps setuptools at 38.2.4. Unsatisfiable by construction. uv's stderr named the package and suggested `exclude-newer-package`; the loop 30 lines below knew how to parse exactly that hint and never saw it. Extracted `era_pinned_uv_install(uv, py, as_of, tail, cwd, envs)` holding the whole bounded loop, all three heal arms, and the importlib-metadata upgrade remedy (general to any --no-build-isolation build, not just `-e .`). Both sites now call it; a third site inherits the behaviour by construction rather than by remembering. MAX_ERA_OVERRIDES replaces the bare 8. No behaviour change at the `-e .` site — same flags, same arms, same bound. The change is that the other site now has them. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… one she was bound to (#443) The board source was made turn-parametric weeks ago. Roster and doctrine were not, so a citizen taking a turn in a per-run bench room got the cards and NEITHER the peers nor the rules. Measured live 2026-08-17 over 90 minutes on this box: source bound → turn room n roster academy swe-bench 23 room-doctrine academy swe-bench 19 roster academy hard-rs 3 room-doctrine academy hard-rs 3 That is 42 + 39 `rag.room_gate.abstain` rows: every bench turn ran with no roster and no operating doctrine. She was handed the work with none of the room's rules and no idea who else was there. THE CAPABILITY ALREADY EXISTED AND WAS NEVER WIRED. `airc_lib` has `room_roster_in`, `room_roster_cards_in` and `room_doctrine_in`, and `room_doctrine_in`'s own doc names this exact defect verbatim: "A citizen who belongs to several rooms answers a turn in the room it arrived in; reading doctrine from her default instead grounds that answer in another room's rules" Continuum called the roomless variants everywhere. This is the wire, not a new mechanism — the same shape as the astropy env fix earlier today (cabecb9): one decision expressed at several call sites, correct at one of them. - `AircRosterReader::room_roster` / `room_roster_cards` and `AircDoctrineReader::room_doctrine` take `room: Option<Uuid>`; the real impls delegate to airc's `*_in`. - Both sources resolve `turn_room.or(bound)` exactly as RoomBoardSource does. `None` (an UNSTAMPED context — background consolidation) keeps pre-#443 behaviour. - The exam-bleed pin SURVIVES and is now pinned by a test: a synthetic nil room gets nothing AND never falls back to the bound room; the reader is not consulted at all. Tests: `the_turn_room_wins_over_the_bound_room` asserts the reader is asked for the TURN room (the stub records what it was asked — a stub that ignores the argument would let this regress invisibly), and `a_nil_room_gets_nothing_and_never_falls_back` holds the exam pin. 8/8 green in room_doctrine_source. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… them blind Dated post-run card per the standing instruction. Records what was dispatched, the fan-out measurement (24 turn rows = 2 events), the #443 abstain table, the operator's inability to cancel a round it can create (#27/#371), the third unwired instance (wall_source, blocked on an airc-side RoomId seam), and the four method errors I made. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…isfiable at every heal rung (astropy)
Reproduced in isolation 2026-08-17 (uv 0.11, py3.11/arm64) — the astropy sdist build-dep
pre-install is unsatisfiable BY CONSTRUCTION under its 2017 era pin, at every rung the
heal loop can reach:
1. era markupsafe 1.0 has no wheel for this interpreter/arch → sdist build mandatory →
needs setuptools>=40.8.0, which the pin caps at 38.2.4. uv hints
`exclude-newer-package`; the heal lifts setuptools — VERIFIED FIRING, correct move.
2. retry: the 2017 sdist now builds against MODERN setuptools →
`ImportError: cannot import name 'Feature' from 'setuptools'` (removed in
setuptools 46). No hint in that error; the loop correctly stops.
3. the other lift is no better: modern markupsafe (>=2.1) removes `soft_unicode`,
which era jinja2 2.10 imports — dies at import time.
The only installable combination is modern jinja2 + modern markupsafe (verified
importing clean). So: when the healed era-pinned install still fails, retry ONCE with
no date pin, loudly.
Scope-safe by construction: `era_sdist_build_deps` lists BUILD TOOLS for dependency-sdist
code generators (astropy → pyerfa → jinja2), never subject requirements. A repo where
jinja2 IS subject code (flask) has no entry in that table, and the subject graph is
resolved by the still-date-pinned `-e .` step.
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
roster half, #412) A dispatch fired inside the post-boot resume window found an EMPTY roster and refused instantly, so the operator hand-rolled a sleep-loop around dispatch — run by hand twice on 2026-08-17, which per the foolproof doctrine is a design defect, not a procedure. The serving half of #442 already parks (`await_ready_serving`). The roster half now parks the same way: dispatch waits (bounded, 180s, 5s poll) ONLY while the roster is empty — citizens being re-hosted after a boot. An unknown NAME against a LIVE roster still fails fast: that error means a typo, never a resume in progress. All existing `resolve_dispatch_roster` semantics (whole-roster default, loud unknown-name listing who is online, Denied on a genuinely empty machine) are unchanged — the loop only delays WHEN the resolver runs, never what it decides. With this, the runbook's manual sequence (ping → serving/status → roster wait → dispatch) collapses into `benchmark/dispatch` itself: serving gate + roster gate are both inside the ONE command. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… emits in-process (#450 tail, #434) MEASURED 2026-08-17, the night two solved SWE cards graded as nothing. Atlas ran the full loop on astropy-14182 and astropy-14995 — work/get → shell → read → work/claim → searches → code/write (wrote=true) → shell/test → work/state. Both cards read `Closed owner=Atlas` on the bench room board. Grade receipts under ~/.continuum/progress: frozen at 92, unchanged. Zero `work.card.state_changed.bridged` rows for either. Root cause is the SPINE of the tail, not the grader. `work/state` deliberately emitted NOTHING, on the reasoning that the transition's own transcript echo returns through a persona subscribe stream and `bridge_wire_work_event` (its single caller) publishes exactly once. That is correct when delivery works. Under #434 — post-reboot durable delivery to citizen scopes down — the echo never comes back: `persona.inbound.raw_event` counted 2 rows in 80 minutes against 83 in a comparable earlier window the same day. The bridge never fires, the grader never hears, and finished work grades as nothing. A grade tail whose only feeder is a subsystem with a known-open delivery bug is a grade tail that is down whenever that bug is. So the verb now emits DIRECTLY. It just wrote the transition — it does not need the wire to tell it what it did. The bridge stays for every writer that is NOT this core's work/state (operator CLI, remote peers over the grid), which is exactly why it was added. ONE emitter, not two code paths that each know how to publish: both feeders route through `emit_card_state_changed(payload, via)`, and the (card_id, state) ring inside it makes a transition publish once no matter which feeder sees it first. The wire-event-id ring cannot cover this — the verb path has no wire event — so the dedup key had to move up to the fact itself. `via` is on the probe, so which feeder won is answerable per transition. room_id is the CARD's own room, resolved by walking the subscribed rooms' boards (`card_room_of`, the read-only sibling of `claim_following_card_room`) — NEVER `current_room()`, which is only where the persona happens to be standing. That is the #345 wrong-room trap, and `grade_card`'s own doc names it; I wrote it into this fix first and caught it before commit. An unresolvable room emits empty, so the grader fails loud rather than grading against a guessed board. Regression test pins the cross-feeder dedup (same transition once, different state publishes). cargo check green with metal,accelerate. Not deployed — a round is live on this box; this ships with the next reboot alongside 4178d50 (astropy build-dep fallback) and a37ac70 (dispatch roster wait). Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…void a score (#380 family) MEASURED 2026-08-17. A re-grade of astropy-14995 died with: clone of astropy/astropy from its local mirror failed: fatal: destination path '…/benchmarks/swe/work/astropy__astropy-14995/repo' already exists and is not an empty directory `clone_at` removes that directory immediately before cloning, so the message reads like a harness bug. It is not. The directory's ONLY content was a `.DS_Store`, stamped AFTER the remove — Finder/Spotlight noticed the parent and repopulated it inside the window between `remove_dir_all` and `git clone`. `git clone` refuses any non-empty destination, so an OS indexer can void a grade, on any repo, at random, and the receipt cannot tell you that is what happened. Fix: clone into a pid-suffixed STAGING path and move it into place. The window closes because the destination is only touched at the rename, and anything that reappeared there meanwhile loses to the tree we just built. Bonus property from the same shape: a half-fetched tree is never visible at `repo_dir` — the move is the commit point. Also stop swallowing the pre-clone removal error (`let _ = remove_dir_all`). If the stale grade tree cannot be cleared, that is a filesystem fault and it now says so by name, instead of surfacing three lines later as git's confusing "already exists" — the same absence-vs-fault confusion this whole grade tail keeps producing. No test: the failure is a filesystem race with a macOS daemon, and the honest reproduction needs a network mirror + Finder. The staging shape is the fix; the comment carries the measurement. Found while grading two closed astropy cards after the grade-tail fix (185816b). Second finding from that same pass, NOT fixed here and bigger: astropy-14182 grades UNGRADEABLE — PASS_TO_PASS scores 0 of 9 on the PRISTINE tree, so the harness correctly refuses to report (gateOk:false). That is #380 (gold-gate every env class): no astropy instance can score at all until its env builds, and a citizen's patch there is unmeasurable, not wrong. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…LECT scores 0/N (#380) MEASURED end-to-end 2026-08-17. The gold gate said astropy-14182 was UNGRADEABLE: "PASS_TO_PASS passes 0 of 9 on the PRISTINE tree". Not the citizen's patch — the DATASET'S OWN GOLD PATCH could not be scored. Running the suite by hand gave the reason in one line: ImportError while loading conftest '…/repo/conftest.py'. conftest.py:9: in <module> import hypothesis E ModuleNotFoundError: No module named 'hypothesis' The env installs `-e .`, which resolves RUNTIME dependencies. `hypothesis` is a TEST dependency, and astropy's conftest imports it at module scope — so pytest dies loading conftest, before collecting a single test. An instance whose env is missing its suite's deps scores 0/N on a PRISTINE tree, the gate correctly refuses to report, and nothing that instance's solver writes can matter. The repo declares exactly what its suite needs in `[project.optional-dependencies]`; we simply never asked for it. POSITIVE CONTROL, run before writing the fix — same env, same pristine tree, after installing `.[test]` with the era pin and the same ERA_CFLAGS the code passes: 1 failed, 9 passed FAILED …test_rst.py::test_rst_with_header_rows — TypeError: RST.__init__() got an unexpected keyword argument 'header_rows' 9/9 PASS_TO_PASS green and the ONE failure is the instance's FAIL_TO_PASS test — the bug the instance exists to fix. That is the gold-gate condition exactly. SCOPE, measured rather than assumed (a `pytest --collect-only` sweep across all 40 envs with a staged tree): every one of them collects today, so this is NOT a whole-suite outage. Per-env it is luck: of four astropy envs, 12907 HAS hypothesis and 14182 did not, and 14365/14995 still do not. Nothing designed that difference — an era resolve happened to pull it for one instance and not another. The fix's value is turning that coincidence into a guarantee, and the honest claim is "an env missing its suite's deps is unscoreable", not "astropy is broken by construction". An earlier draft of this message overstated it as every astropy instance; the sweep disproved that before it shipped. `test_extra_name` picks the group the repo declares, preferring test > tests > testing > dev. The order is load-bearing: a repo declaring both `dev` and `test` must get `test`, or we install a kitchen-sink group and inherit its resolution failures. No pyproject, no optional-dependencies, or no test-shaped group all mean "install as before" — never "install something plausible". `ensure_test_extra` is NON-FATAL by design and runs LAST. Everything before it decides whether the env can BUILD and RUN a harness; this decides whether the suite can COLLECT. A repo whose suite already collects does not need it, and a resolve failure must not delete an env that grades fine today — so a failure probes (`swe.env.test_extra`, installed=false) and leaves the env standing. It also runs on the CACHED path, marker-guarded, because every env on this box was built before this existed; without the heal, an env that happens to lack its suite's deps stays that way forever and the operator has to know which ones. The marker makes it once-only, including the "this repo declares nothing" answer. Extracted `era_cutoff` while here: the cached path needs the same "what era is this instance" answer the build path computed inline, and two copies is how they drift. Deploys with 185816b (grade tail) and 99c59fe (clone staging) on the next reboot. #380 stays open until the gold gate passes per env CLASS — that is the instrument, and one instance passing is not a class passing. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…and stop caching a negative (#380) I shipped b0141e8 claiming astropy would now gold-gate. The live run said no, and it was right. Correcting my own fix, with the receipt: gold gate astropy-14995 → "UNGRADEABLE — PASS_TO_PASS passes 0 of 40 on the PRISTINE tree"; swe.env.test_extra probe rows: 0; env marker `.test-extra` = "none-declared"; `python -c "import hypothesis"` → ModuleNotFoundError. TWO defects, both mine. 1. THE PARSER READ ONE FILE. astropy 5.3 has NO `[project.optional-dependencies]` — its suite deps are setuptools declarative config: [options.extras_require] test = # Required to run the astropy test suite. pytest>=7.0 pytest-astropy>=0.10 So `test_extra_name` returned None for the exact repo the fix was written for. Both files are ordinary in the ecosystem; reading one is reading half. `declared_extras` now reads both, hand-scanning the INI section for KEYS (an ini crate would be more surface than six lines, and we need group names, not requirement lists — note the flush-left check, since ` pytest>=7.0` is a continuation, not a group). My earlier positive control was real but proved the wrong thing: I ran `uv pip install -e ".[test]"` by hand, and uv resolves that extra THROUGH setuptools — so it worked while our own parser could never have named it. A manual command succeeding is not evidence that the code takes the same path. 2. THE MARKER CACHED A NEGATIVE, which is worse than no cache. On the first run the half-blind parser wrote "none-declared" — permanently. Fixing the parser would not have helped: the marker suppresses the heal forever, and only a human who knew which files to delete could recover it. Caching a negative caches the limits of today's code. Now only a SUCCESS is recorded, and a marker is authoritative only when it NAMES an extra, so the poisoned markers the first version wrote self-heal. Re-reading two small files per grade costs nothing next to cloning a repo and running its suite — the cost I was "optimising" was never real. Test extended with the astropy shape: no pyproject at all, extras in setup.cfg, and `test_all` present — which sorts before `test` alphabetically and is a superset, so it must not win. That case is the one that shipped broken. LESSON, and it is the same one twice today: a fix is not verified by the command I ran by hand, only by the code path the system takes. I had a green unit test, a green compile, and a green manual install, and the feature was still dead on the one repo it existed for. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
#380 instrument) `let (pristine_p2p, _) = run_tests(...)` — the report went into `_`. That verdict is the ONLY artifact of the pristine run, so "the suite does not run in this environment" shipped as a conclusion with its evidence deleted, leaving the reader to reproduce the run by hand and guess at the difference. MEASURED TODAY, and it is why this is worth its own commit: astropy-14365 graded `PASS_TO_PASS 0 of 8` here, while the SAME invocation — `-m pytest <file> -v -p no:cacheprovider`, same venv, same tree — run by hand gave 8 passed and the instance's own bug failing (`ValueError: Unrecognized QDP line: read terr 1`), which is exactly the gate condition. So the environment was fine and the divergence was somewhere inside the gate. I proposed three mechanisms and could settle none of them, because the one artifact that names the divergence was thrown away on this line. Hours, on a guessing loop, next to a variable holding the answer. Now the tail rides the error (via the existing `report_tail`, so it is bounded the same way the retry excerpt is). And an EMPTY report gets its own sentence rather than an empty section: no output at all means the harness never executed — a missing interpreter, a refused invocation, a run that died before writing a byte — which is a different fault from a suite that ran and failed, and the two must not read alike. This is the same defect class as the rest of today's session: the instrument had the answer and did not surface it. #380 stays open; this is what makes the next attempt at it a measurement instead of a hypothesis. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ED by her — the round-killer THE DEFECT, measured live 2026-08-17 and deterministic: A citizen's inbound stream skips messages she is recorded as having said (airc_persona_conversation, `message.peer_id == self.own_peer_id`). Correct — nobody answers their own speech. But the operator has no self-peer in-core (#27), so `curator_airc` falls back to `registry.any_live_citizen()`, which picks the LEXICOGRAPHICALLY-LOWEST agent_name. With the roster culled to Atlas + Benchy that is ALWAYS Atlas — the assignee. So `benchmark/dispatch --assignees='["Atlas"]'` authored every `@Atlas (to you)` kickoff THROUGH Atlas. All three died at the self-skip: no error, no probe, no turn. The command reported `kickoffs: 3, kickoff_errors: []` and was telling the literal truth — three messages were sent. Zero were hearable. The round then ran for hours on the DETACHED solver (`dispatch_staged_swe_solve` → `agent/solve`), which produced 18 acts, 0 turns, 0 room visibility and 0 curriculum input (#425) — maximum effort, nothing that reaches the flywheel. Joel: "its supposed to be persona that run. you dont wire in loopers." Why it read as intermittent (#417 "kickoffs DO actuate"): with ~20 citizens online the alphabetical pick usually was NOT the assignee, so kickoffs landed. Culling the roster to two made it a coin flip, and the coin is not random — it is `min_by(name)`. THE FIX (this commit — the delivery half): - `any_live_citizen_other_than(exclude)` — the same deterministic pick, minus one peer. `any_live_citizen()` becomes `…other_than(None)`, so there is ONE selection rule, not two that can drift. - dispatch voices each kickoff through a citizen who is NOT the addressee. - When the addressee is the ONLY live citizen, REFUSE and say why, naming `persona/spawn` as the fix — never send a message that cannot be heard ([[fallbacks-are-illegal-fail-loud]]). - The self-skip now emits `persona.inbound.skipped_self_authored`. The skip stays; its SILENCE was the real cost. A message vanishing without a trace is how a substrate failure reads as "the citizen chose not to work" ([[an-absence-is-an-unfinished-measurement]]). NOT in this commit, deliberately, and next: retiring the detached solver so the persona's own turn does the work (Joel's actual point). Order matters — prove a real `persona.turn.start` fires from a kickoff FIRST, or removing the looper just yields nothing at all. Tracked on #453. Also lands the shutdown lane sweep held from earlier tonight (#454): `lane_registry::sweep_all()` + `SweepMode{Boot,Shutdown}`, called from `stop`. `stop` reaped cores and owned orphans but touched NO llama-server, so lanes leaked across shutdown by design and `reboot` (= stop + start) inherited the wreck — measured as a 19 GB ephemeral 27B resident beside the live 14B, which starved the planner into serving a 2,816-token window (smaller than the tool surface) and made every citizen structurally mute. Role-blind on purpose: the live/ephemeral split decides ADOPTION, and nothing is adoptable by a core that is exiting. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
A citizen is REGISTERED the moment her identity is minted or resumed. She is RESIDENT only once the supervisor attaches a service loop — which is what primes her perception stream and gives her a turn. Every readiness surface reported the former and called it the latter. Measured 2026-08-18: for ~15 minutes after a reboot `persona/roster` listed Atlas and Benchy while `persona.inbound.subscribe_opened` was 0. Hosting was correctly parked waiting for the serving lane to prove it could decode (#363). A round was dispatched into that window on the strength of that roster: 2 cards posted, `kickoffs: 2`, `kickoff_errors: []`, and ZERO turns. Nobody was home and every surface said otherwise. - `PersonaAircRuntimeRegistry::is_resident` / `resident_snapshot` — residency asked per citizen, never inferred from presence in the registry. The truth table is a pure fn (`resident_from_loop_state`) so the three rows are unit- pinned; a live `PersonaAircRuntime` needs a real airc daemon and cannot be built in a test. - `persona/roster` gains `resident` per row + `resident_count`. `count > 0 && resident_count == 0` is exactly the state above, and it is now legible. - `benchmark/dispatch` resolves assignees against the RESIDENT snapshot, and its post-boot wait keys on residency too — the old wait cleared on a non-empty roster, which released it ~10 minutes early (#412). Refusals distinguish the two states because they have opposite fixes: registered-but-not-resident is a WAIT, unregistered is `persona/spawn`. A named assignee who is merely unhosted is no longer reported as a typo. This is honesty at the seam, not the cure. The cure is boot owning the process tree (#452) so the resident window never exists to dispatch into. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…, spawn missing (#452) Joel, 2026-08-16: "start = enumerate → health-check → reap-or-ADOPT → spawn missing, for EVERY service — cores, llama lanes, airc daemon." The operative word was ADOPT, and boot did exactly two things to a service it found running: nothing, or kill it. Neither is ownership. ROW: llama lanes — was `pkill -f llama-server`, unconditionally, every boot. This made real code dead: `inference::lane_registry::sweep_in` already encodes the adopt rule — `(LaneRole::Live, SweepMode::Boot) => false` deliberately leaves a live lane alone at boot and reaps it only at shutdown. The shell killed that lane seconds before the core could adopt it, so that arm never once fired in production. Cost: a cold model load on EVERY reboot, during which the lane cannot prove it can decode, hosting correctly parks (#363), and every citizen is registered-but-not-resident — measured at ~15 minutes on 2026-08-18, the window a benchmark round was staged into for zero turns (#455). Now: enumerate by pid, read each lane's port from its own cmdline, /health it, adopt or reap per lane. Verified live on this box before the change landed: pids 1166 (:58057) and 95258 (:58091) both healthy — both would have been killed, and now are kept. /health is LIVENESS, not decode — a wedged server can pass it, which is exactly why the core verifies generation before seating citizens (#363). That division is deliberate: the shell adopts a plausibly-live lane, the core remains the authority that refuses a lane that cannot decode and relaunches it. Adopting can only cost a relaunch the core already knows how to do; reaping costs a cold load every time. ROW: airc daemon — this row did not exist. Boot printed "⚠ airc daemon not running. Start it with: airc daemon" and carried on: a runbook line where ownership belongs, for the one service whose absence makes everything else inert. With no transport there are no rooms, so citizens have nothing to be resident IN. Now: ping → adopt; wedged (holds the socket, answers nothing — worse than absent, since a fresh spawn loses the bind, #355) → `airc stop` then reap → spawn → bounded wait → FAIL LOUD and exit nonzero. Binary absent is a DIFFERENT state (warn, continue): a box without airc installed is not a broken one, and refusing to boot would strand CI and fresh clones. ROW: cores — already correct and left alone. #420's `core_bind_guard::decide` adopts on `start` (AlreadyServing → no-op, Occupied → refuse), and reaping on `reboot` is right because reboot replaces the binary. `bounded_run` is the shared primitive. macOS ships no coreutils `timeout`, and — the lesson that made #420's guard reachable at all — an unbounded probe against a wedged service does not fail, it HANGS: the kernel completes connect() into the listen backlog whether or not the process is ever scheduled. A health check that can hang is not a health check, it is a boot that stops. Truth table verified live: exit0→0, exit1→1, hang→124 in 1s not 5s. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ink on?" (#126/#369/#438) Joel asked where the base model is governed. The honest answer was FOUR places, in one function, each silently handing off to the next: 0. override_model — runtime per-persona assignment 1. model_preferences — tiered ladder, "best that fits" 2. model_id — explicit per-persona model, labelled "Legacy" 3. default_local_model — system-wide default Four expressions of one decision, and rows 1→2→3 walk DOWN without anyone deciding to. That is the #438 incident shape: one bogus usable_gb=0 sample walked the ladder to the bottom and served citizens a 0.5B that emitted template-token garbage into the room. The sibling module already forbade this in prose (inference_profile.rs: "substrate HARD ERRORS instead of silently degrading") — the prose was right, the code never implemented it. This is a COMPRESSION, 4 → 1, and both modes fall out of it: - Pegged{model, reason} — subsumes override_model (Measurement peg w/ lease) and model_id (Operator). This base or she does not serve. - Adaptive{ladder, floor, rungs} — the governor moves her, bounded below by a NAMED floor member (not "last entry wins", which is how a reordered ladder silently moves its own floor). No system-wide-default arm exists. That arm WAS the bug. THE GENOME IS WHAT MAKES A BASE REACHABLE (Joel, this session): a LoRA adapter is a per-base derivative. The corpus — transcripts, tool traces, solved instances — is the durable, base-independent asset; an adapter is forged FROM it ONTO a specific base and is invalid on any other (#369). So she can scale up or down freely, PROVIDED her genome was forged for the destination. Hence GenomeCoverage as an input: RequireGenome (default) skips rungs she has no adapter for and refuses with the FORGE work-list; AllowBare takes them but reports genome_backed=false so a measurement records WHICH citizen it scored. The paired obligation is the forge's, not this module's: one corpus fans out to N adapters, one per targeted base, each trained independently against that base. A ladder is only as walkable as the forge made it, and RequireGenome turns a declared-but-unforged ladder from a silent capability cliff into a visible one. Why benchmarks need this: genome lift is only measurable against a fixed base. Round 1 on a known base → corpus accrues → forge onto that same base → round 2, same base + adapter → the delta is attributable to the genome. Float the base and the number means nothing AND round 1's adapters are garbage. Worse, a silent re-base corrupts the EXPERIENCE, not just the score: turns taken on an unintended base still land in the corpus, poisoning the next adapter forged from it. So refusing to serve is the cheap failure; serving on an unintended base is the expensive one, and it is the one that used to happen by default. Pure over (host_vram_gb, coverage) — 15 tests, no GPU, no forge, no registry. Every refusal names its own remedy and is asserted on. NOT YET WIRED: allocator/inference_profile still use the 4-way resolver. This is the type + its truth table landing first so the cut-over is mechanical. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ng the forge Correcting my own framing from an hour ago: I called the peg "only for measurement". Too narrow, and Joel's point is the load-bearing one. Continuous learning never stops. The flywheel runs turns → corpus → forge → adapter → page-in continuously, and the adapter coming out the far end is a derivative of whatever base it was trained against. If her base floats between the corpus accruing and the forge finishing, the adapter lands for a base she has already left — forged for nobody, and page-in must then refuse it (#369). The corpus survives that; the training compute does not. So a training run holds a peg for its duration, exactly as a measurement round does, and for the same underlying reason: a process is in flight whose output is only valid against the base it started on. Measurement is episodic; training is always running, which makes THIS the peg held most of the time. GenomeBound is now documented as what it actually is — the standing consequence of past Training runs, derived from the adapters she holds. Also worth stating plainly, since it corrects a second drift in my framing: the LADDER is the mechanism for daily use, not the peg. A citizen on a 64GB box resolves to the top rung automatically — no peg, no special case — and a smaller box steps down the same ladder. The peg exists for the three cases where something in flight depends on the base staying put. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…e genome (#456) Joel: "learning and score are both the objective. We should outcompete the base model." The learning half was structurally impossible. This is why. MEASURED FROM SOURCE: `training_producer::produce` — the L2 step that turns a turn into a (context, completion) training example and submits it to the forge — had exactly ONE call site tree-wide: the message-REPLY path. Its own comment explains the exclusion: "It lives ONLY on this live `Spoke` path, which eval forks (`drive_to_settle`) never run, so the training set can never be contaminated by a measurement simulation." Correct for eval (#59). But it means: - `agent/solve` (which IS `drive_to_settle`) produces zero training examples, so a dispatched bench card can never reach the genome no matter that dispatch sets `learn: LearnFromThisWork` — the gate is PATH-based, the policy is never consulted, the policy loses. - AND the WORK TURN — the separate drive at the heart of "working is not speaking" (#154), the turn where she actually works her CLAIMED CARD — also never fed the producer. Chat produced training data; real work did not. That second one is the sharper defect and it is fixed here, in the live loop, without touching the eval guard. TWO CHANGES, both in the held-work turn: 1. HANDS FOLLOW THE CARD. A held card may be a staged benchmark checkout — a real git repo under `workspace/swe/<instance>`. Without rooting her hands there she "works" it by writing into her OWN workspace and the grader's `git diff` on the sandbox scores a false ZERO — exactly the defect glass-boxed on agent/solve 2026-07-22 (two real acts, correct file written, empty patch). Now the work turn roots at the card's workspace and RESTORES on every exit path (#312: after a flask solve, Anwen's live self was still reading the exam repo hours later). A root failure is LOUD and she works in her own dir anyway — an unexplained empty diff is worse than a diagnosed one. 2. THE PRODUCER FIRES. context = the card burst she was handed, completion = the report she wrote after doing the work. Same shape, same best-effort spawn, same quality bar as the reply path. Still the LIVE path — an eval fork does not reach this call site — so the contamination guard is unchanged. NEW: `persona/staged_workspace.rs` — ONE answer to "which workspace does this card point at", replacing the walk that `persona/roster` and `dispatch_staged_swe_solve` each did inline. The layout knowledge that makes a citizen able to act in the repo previously lived only inside a benchmark dispatcher, so the live path could not reuse it without importing the very bypass it should replace. Matching is by title containment (dispatch writes the title from the instance, so it is by construction); MORE than one match refuses with a probe rather than guessing, because rooting at the wrong repo silently scores a false zero for the other card. WHAT THIS DOES NOT DO: retire the `agent/solve` inbound bypass. That is still #456 and still the right end state. But this makes the in-loop path actually work — hands in the repo, experience into the genome — which is the precondition for retiring the bypass rather than a consequence of it. CORRECTION TO MY OWN CLAIM this session: I first said "zero production callers of training_trigger/submit — the trigger is dead." Wrong. `training_producer.rs` is the producer and dispatches correctly; `memory/consolidate.rs:196` is a second legitimate caller. The wire was never dead; it was never REACHED from work. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…efend Joel: "the learning and score are both the objective. We should outcompete the base model." One falsifiable claim: a citizen on base X with her genome beats bare base X on the same benchmark. Four threads with the non-obvious ordering constraint written down: D (the score ceiling) GATES C (the measurement), because a delta between two zeros is noise. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…achedSolve|Citizen} (#456, A2 unblock) A2 (live-prove the work-turn fix, 18ecef7) failed 3 of 4 gates, and the cause was structural rather than a defect in the fix. Measured on a real dispatch: gate 1 persona.work.hands_rooted — never fired (546 probe rows, class absent) gate 2 acts inside the repo — YES, but by the BYPASS: workspace.rooted names the "forked persona's file engine", i.e. agent/solve gate 3 training submit — no jobs, no genome rows gate 4 hands restored — n/a, the work turn never ran work/claim fires dispatch_staged_swe_solve synchronously in the claim handler (modules/work.rs), so the detached fork takes the card and works it in a forked persona. Her own service loop never sees a held-card work turn on it. A1's code is UNREACHABLE by construction on the default path — the fork always wins the claim. So A2 and A3 are one step, and the resolution is a switch, not a deletion (retiring the bypass onto an unproven path would be strictly worse than today): WorkDriver::DetachedSolve default, today's behaviour, the path that produced #366 WorkDriver::Citizen nothing detached fires; she works it in her own loop The driver lives on the ROUND because that is the only thing that knows: the decision is made once at dispatch and read later at claim time, in a different verb, on a different task, with nothing threaded between them. Round lifecycle becomes open → add_card → seal, replacing register_round-at-the-end. That ordering is load-bearing, not tidiness: dispatch sends kickoffs INSIDE its card loop, so a citizen can claim card 1 while card 2 is still being posted. Registering after the loop left that window answering with the default — a Citizen round would have fired the solver on its own first card and defeated itself with no error anywhere. Pinned by the_driver_is_readable_the_instant_a_card_can_be_claimed. A citizen-driven SWE card also takes the gym pre-claim cut, and for the reason that one was written: nothing detached will fire, so the only thing between the card and her work turn is the kickoff→claim hop that stalls rounds. The pre-claim goes through airc directly, not the work/claim verb, so it cannot re-enter the dispatcher. Defaults are conservative in both directions: a card in no live round (human-claimed, undirected, or claimed after its round ended) answers DetachedSolve. 8 tests green. Behaviour unchanged unless --drive=citizen is passed. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…it already claimed to be Its module doc has said since 18ecef7 that three callers share one answer to "which on-disk workspace does this card point at", and named `dispatch_staged_swe_solve` as one of them. That was aspirational: the dispatcher still walked `citizens/peers/<her>/workspace/swe` itself. A doc making a claim the code does not keep is worse than no doc — the next reader trusts it. They had already drifted in KIND, not just in duplication: the inline walk accepted any directory, the module requires a `.git`. So an interrupted clone read as a staged instance on the claim path and did not on the work-turn path — the same card resolving differently depending on who asked. `Option<PathBuf>` was why the copy survived: it erased both distinctions the dispatcher needed (no-staging vs ambiguous, and the instance NAME its era venv is keyed by). So the resolver now returns `CardWorkspace{One{instance,path}|None|Ambiguous{candidates}}` and `workspace_for_held_cards` becomes the projection the WORK TURN wants — "root here or leave her hands alone" — keeping the ambiguity probe at the caller that would otherwise score a false zero. The dispatcher matches the enum and reports ambiguity in its own vocabulary, as it did before. Also splits the matching rule into a pure `select()`. The existing test restated the containment check in its own body instead of calling it — it could not fail if the real rule changed. It now exercises the production function, and the ambiguity arm (which both callers depend on staying distinguishable from "nothing staged") gets its first test. 4 tests green. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…d attribution (#438) MEASURED AFTER the high-water fix, which did NOT cover this. Cold boot, live board: serving= 0.00G phys=29.90G UNOWNED=29.90G avail=25.76G ready=False model=None serving= 0.00G phys=36.88G UNOWNED=36.88G avail=18.79G ready=False model=None Physical climbing as the 27B loads; zero attributed the whole way. The high-water needs a prior residency and a verification stamp, and a first boot has neither — Joel's exact worry about option (a), landing on option (b) in a different form. THE CAUSE WAS UPSTREAM AND IS THE SAME SHAPE AS EVERYTHING ELSE TODAY: `ServingSnapshot` was BINARY — ready with a model, or not-ready with `active_model: None`. The loading arm of `snapshot_from_outcome` returned `ServingSnapshot::empty()` and DISCARDED `desired`, which it had been handed. So for the whole load window the state pipe FORGOT what it was bringing up, and the consumer could not attribute those bytes because the information was not in the pipe. A state machine that cannot express an honest intermediate degrades its answer to zero. Readiness is a claim about SERVICE. Residency is a fact about MEMORY. They do not start together: weights are mmap'd from spawn, `/props` answers much later. Reporting residency from readiness is a category error, and it costs a third of the box during every load. THE FIX: `loading_model: Option<String>` on the snapshot, set by the loading arm from the `desired` it already receives, and charged by `footprint()` at a MINIMUM shape — one lane at the floor window. That under-states the eventual KV and names the dominant term (weights) immediately, growing to the true figure the moment readiness lands. Conservative in the safe direction, and never zero while a process holds memory. 12/12 green in serving_consumer including the new cold-load case, which sets up exactly the measured condition: never ready, no prior residency, NO verification stamp. THE CHAIN, now honest at every link: capacity source absent → zero-capacity row is not a reading 85024f2 no board reading → last-known, then device prior, never 0 6338cd3 derived arithmetic → inherits its weakest ancestor + reason f1e7b67 a holder that cannot be sized→ declines instead of contributing 0 67a6edb a reshaping lane → reports what it holds, decays on proof 163c926 a LOADING lane → is named and charged from spawn this commit NEXT, and Joel named the likely mechanism (2026-08-19): "startups can destroy the evidence like pid files that they'd need to know which process to kill." That reframes the orphan `sweep_all` missed — it is probably not the wrong call site but an ORDERING bug: if boot recreates the pidfile/registry before reading the previous generation's, the evidence of what to kill is destroyed by the act of starting. The sweep then finds nothing, reports clean, and the orphan survives. Read-and-reconcile the old generation BEFORE writing the new one. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…obe the lane's own slot count (#452) The adopt-or-relaunch decision had two operands and they asked different authorities. `window_ok` probed the running server's `/props`. `lanes_ok` read `current_serving().lanes` — our own process-local snapshot. For a lane THIS core spawned those agree, so the asymmetry was invisible. For a lane it did NOT spawn it is fatal. MEASURED LIVE 2026-08-19, by crashing a core with SIGKILL while its lane was healthy: custody survived exactly as designed — llama-lane.pid still named pid 64372, the registry record still described it ({"pid":64372,"port":58057,"role":"live", "model":"…Qwen3.8-27B…"}), and the process was still serving. Drop is ownership-gated and a SIGKILL skips it on purpose, so the evidence a successor needs is all there. boot then declined it. `serving.grow` fired with target_window=22616 — which is 90464/4, EXACTLY the per-slot window the surviving lane was already serving — and `serving.adopt_rejected` had zero rows, so the lane was never even decode-probed. It was reaped (`serving.lane_reclaim → Reclaimed { pid: 64372 }`), and rebuilt over ~110s across three pids, returning at 3 lanes / 21,504 against the 4 lanes / 22,784 that had been running before the crash. The planner targeted precisely what already existed on the box and threw it away to make it again, worse. FIX: `LlamaServerControl::served_lanes()` reads `/props total_slots` — the LANE sibling of `served_context_window`, same shape, same error policy (a probe failure is "lanes OK" so a transient hiccup can never spuriously relaunch a healthy lane; a missing field is Err/UNKNOWN, never a guessed 0). Both operands now ask the process. The stale comment claiming `served_lanes` was "the process's own truth (ServingSnapshot .lanes)" is corrected — a snapshot is our memory of a process, not the process. The `serving.grow` probe now reports what the LANE said and says "unreadable (…)" when it could not be asked; a probe that silently substitutes a number is how this hid. Tests: two added, both to the existing mod. - a_past_form_of_ourself_serving_enough_lanes_is_adopted_not_reaped — the defect itself (not-owned + healthy + already at target shape ⇒ AlreadyServing, zero relaunches). - a_lane_serving_fewer_slots_than_planned_still_relaunches_to_grow — the guard that "adopt more eagerly" must not disable lane grow-back (#214's sibling). Every pre-existing adoption/grow test passes UNMODIFIED, which is the evidence this moves only the intended seam. 35/35 llama_server, 40/40 serving_daemon. Joel's ruling this is built on: we need to know OUR footprint, the total system with us removed, and ANY PAST FORMS OF OURSELF — and we are free to control our own processes, fully. Boot could already see the first two. This is the third. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…carries the shape (#452/#438) The upstream half of 6c12965. That commit made the adopt gate ask the lane how many slots it serves; this one makes the GOVERNOR know the lane is ours at all. MEASURED LIVE 2026-08-19, on the boot right after deploying the adopt fix: serving.plan t-381s qwen2.5-coder-3b lanes=1 win=3271 usable_gb=2 ← boot serving.plan t-380s qwen3.5-4b-forged lanes=1 win=16384 usable_gb=2 serving.plan t-374s Qwen3.8-27B lanes=1 win=16384 usable_gb=31 ← recovers serving.plan t-299s qwen2.5-coder-7b lanes=1 win=16384 usable_gb=7 ← collapses AGAIN serving.plan t-290s Qwen3.8-27B lanes=3 usable_gb=25 `usable_gb = 2` on a 64 GB machine. The predecessor's healthy 27B was still running and holding ~50 GB, but a fresh core's ServingSnapshot is empty for a lane it did not spawn, so the consumer reported ZERO and the governor filed those bytes under `external` — someone ELSE'S. The box looked full, the planner chose a 3B, and the 27B was reaped as the "wrong model" to make room for it. Twice in one boot (serving.lane_reclaim: Reclaimed{3459}, Reclaimed{62615}). The self-eviction ratchet could not rescue it either: the ratchet adds back our OWN measured residency, and the lane was not ours yet. And the adopt gate from 6c12965 never even ran — zero serving.grow rows — because the decline happened upstream at model identity. One misfiling, both symptoms. FIX, in Joel's own frame ("know OUR footprint, the total system with us removed, and any PAST FORMS OF OURSELF — then work within that; we are free to control our own processes, fully"). Boot could already see the first two quantities. This is the third: 1. `LaneRecord` carries the SHAPE (`context_window`, `lanes`), not just the identity. Residency is weights + KV(window, lanes), so a record naming only the model cannot answer "how many bytes does my past form hold?". Written at spawn from ServingTarget. 2. `lane_registry::live_lane()` — the LIVE-role record whose pid is genuinely alive. A stale file cannot conjure residency. 3. `serving_consumer::inherited_footprint(rec, sizer)` — pure over (record, sizer), so both arms are testable with no filesystem, process, or governor. Wired as the third fallback after active_ready and loading_model. THE REFUSAL IS THE LOAD-BEARING HALF. A record predating the shape fields carries 0, which means UNKNOWN, not "a zero-byte lane". `inherited_footprint` returns None there. Returning Some(0) would hand the governor a QUANTITY where it should get an absence — the same fabricated-zero class as #438's usable_gb=0 and the sidecar's two-zeros bug, and this fix would have re-created the very defect it exists to remove. Tests (2 added to the existing mod, both confirmed by name): - a_lane_inherited_from_a_previous_generation_is_counted_as_ours — sized from the record's own shape, reason names the pid it came from. - an_old_record_without_a_shape_is_unknown_and_never_a_zero_byte_lane — all three partial-shape rows refuse. 22/22 serving_consumer + lane_registry green; the registry fixture gained a real shape. STILL OWED: live proof. Both fixes are green and deployed-pending; the repro that produced the evidence above must be re-run and show usable_gb NOT collapsing at boot. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…rity, identity-verify the pid (#452) Caught by measuring the previous commit instead of trusting it. Polling the board DURING a boot, with the 27B (pid 97530, 19414 ctx × 4 lanes) as the live lane: serving = 0.81G "continuum-ai/qwen2.5-0.5b-instruct-GGUF inherited from a previous generation" We attributed 0.81 GB where ~50 GB was resident. Two defects in the `live_lane()` I wrote in 5f7ecce, compounding: 1. `read_dir` order is ARBITRARY. A crashed generation leaves several `Live` records and the loop returned whichever the filesystem listed first — a stale 0.5B. 2. `is_alive(pid)` is NOT identity. A dead lane's pid gets REUSED and the stale record reads live forever. `lane_pidfile::reclaim` has always been "identity-verified (never a reused pid)" and `lane_process::is_llama_server` exists for exactly this; I simply did not call it. The hazard is even named in lane_process.rs:11. FIX — one authority per question, which is why they cannot drift: - the PIDFILE answers *which* lane is live (it holds exactly one canonical pid); new `lane_pidfile::read()` exposes it, doc'd as NOT a liveness claim. - `is_llama_server(pid)` proves the number still belongs to a lane. - the REGISTRY RECORD supplies that lane's shape. SECOND DEFECT, mine, found by the tests immediately: calling `lane_registry::live_lane()` from `footprint()` reaches a process-wide FILESYSTEM singleton, and three unit tests began reporting the operator's real live 27B. A unit that reads the developer's machine is not a unit test (#72's smell), and it would pass or fail depending on whether a lane happened to be up. `inherited_lane` is now an INJECTED field beside `footprint_of` — which was the precedent sitting right there, already injected for the same reason. Production wires the real lookup; tests hand it `|| None` via `with_inherited_lane`, gated `#[cfg(any(test, feature = "test-fixtures"))]`. 22/22 serving_consumer + lane_registry green. STILL OWED: the live re-measure. The two prior commits moved usable_gb's floor 2 → 5 and cut the collapse from two cycles to one, but the attribution was sizing a 0.5B the whole time — so that improvement came from something else and the real effect of counting a 27B as ours has never actually been observed. Not claiming it until the board shows ~50 GB under `serving` at boot. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ips with its Rust) The `loading_model` field added to ServingSnapshot in this branch never had its generated TS committed. Repo rule is both halves land together — a Rust wire type whose binding lags is #457's drift, caught here by hand because CI has no guard for it yet. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
work.rs conflicted twice, both on #425: canary's b4fad49 and this branch each grew a room-lookup helper for the same job. Taking canary's file wholesale COMPILED CLEAN and would have silently deleted 206 of this branch's lines to gain 154 — a green build proving nothing. Caught before shipping; resolved by hand instead. RESOLUTION, keeping both sides: - canary's `room_holding_card` WINS over this branch's `card_room_of` — returns the full `Room` (superset of the uuid) and is the explicit consolidation of two callers that "used to derive it separately — badly". One resolver, not three. - this branch's work/state direct-emit caller is KEPT, rewired onto it (`.map(|r| r.channel.as_uuid().to_string())`) rather than deleted. - hunk 2 takes canary's fuller #425 treatment (solve runs IN THE CARD'S ROOM). - type seam: canary's dispatch carries a typed `PeerId`, `resolve_for_titles` wants a raw `&Uuid` — bridged at the call site with `&claimer.as_uuid()`. 36/36 green across work:: + serving_consumer:: + lane_registry::. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… as the incumbent (#438) Measured from the probe ledger, 2026-08-19 — and it retracts my last two diagnoses of this defect, both of which were wrong. WHAT THE LEDGER SHOWS. A core crashed with a healthy Qwen3.8-27B serving 4 lanes at a 25,075 window (`serving.grow served_lanes=4 target_window=25075`). Its successor booted while that lane was STILL ALIVE holding ~45 GB, and the first plan read: +32246.3s Qwen2.5-Coder-7B lanes=1 win=4689 usable_gb=6 bound_by=host-fit +32246.9s qwen2.5-coder-14b lanes=1 win=2048 bound_by=host-fit +32247.5s serving.lane_reclaim outcome=Reclaimed { pid: 11341 } <-- 1.2s TOO LATE +32256.3s Qwen3.8-27B lanes=2 win=16384 usable_gb=29 +32306.3s Qwen3.8-27B lanes=4 win=27481 usable_gb=47 `usable_gb=6` is not a bogus sample and not a fabricated window — it is an HONEST reading of free VRAM on a box whose own predecessor holds 45 GB of it. The planner spent that budget on a 14B at MIN_SERVE_CTX; 1.2 seconds later the reclaim freed all 45 GB, and by the time the plan wanted the 27B back it could not have it — a model swap needs the relaunch already spent. WHY BOTH DEFENCES WERE OFF. `plan_serving_stable`'s at-rest credit exists precisely so "a model's OWN load/residency can never flap it out", and `downshift_gate`'s sustained-ticks debounce (#368) exists precisely to reject a transient squeeze. BOTH key on an incumbent, and `publish_plan`'s own comment declared boot has none: "Boot's first plan has no incumbent (plan_tx holds None) -> plain selection." So the one moment a squeeze is GUARANTEED — the successor overlapping its predecessor — is the one moment every guard against transients is disabled by construction. THE FIX, in Joel's framing of the governor: know our footprint, the system with us removed, and ANY PAST FORMS OF OURSELF — then work within that. An inherited lane is that third category. It is ours, its bytes are ours to reclaim, so it is the incumbent the first plan reasons against, not an external squeeze to flee. `incumbent_for_plan(published, inherited)`: a published plan always wins (a stale .lane file must never pin the model forever); the registry record speaks only in the window where `plan_tx` is empty. `InheritedLaneSource` is an injected seam, not a direct `live_lane()` call, for the same reason `DecodeAgeSource` is one — the production default reads a filesystem singleton, so under `cargo test` (one process, shared HOME) it would hand every planning test the OPERATOR's real 27B as an undeclared incumbent. `daemon_with` pins it to None. That exact leak was already caught by measurement in `serving_consumer`; this is the same lesson applied before it could bite. TESTS (43/43 green in this module), with a real negative control: - the inherited 27B is defended at a 6 GB sample - WITHOUT it, the same 6 GB genuinely downshifts — so the test above is not vacuous - a published plan outranks a stale inherited record, and cold boot still has no incumbent RETRACTED by this commit, both mine: (1) the handoff note's "the reap happens BEFORE attribution can matter" — it happens 1.2s AFTER the plan it invalidates; (2) "a transient in a settled system, not a boot defect" — it is a boot defect, and the ordering is the mechanism. The three VRAM-provenance fixes from earlier today are correct and remain, but they were not the binding constraint on this path. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…anner may tick (#438) Joel, 2026-08-19: *"unacceptable to not consider the removal of the last system as negated."* He is right, and the honest form of the defect is narrower than it first looked. THE NEGATION ALREADY EXISTS. `governed_vram_ceiling` budgets serving through `budget_for_replacing(SERVING_CONSUMER_ID, Vram)` — available PLUS serving's own resident bytes, because a consumer choosing its successor releases what it holds. Live board, right now, with the 27B up: `externalBytes: 0`, `measured 55.59 GB` attributed to `serving`. Our predecessor's memory is filed as OURS, not as an external squeeze. A second credit was drafted for `host_budget()` and DISCARDED before commit — it would have added the same 55.59 GB twice and over-committed the GPU, which fails as an OOM rather than a small window. That is the parallel-allocator move this codebase forbids. WHAT WAS ACTUALLY BROKEN IS THE WIRING ORDER, read in-file at `ipc/mod.rs:1322`: serving_daemon.register_planner_on_authority_tick(); // planner attached HERE runtime.register(serving_daemon.clone()); // initialize() → register_as_consumer LATER The add-back is keyed on serving being a REGISTERED CONSUMER. The planner was attached to the authority's tick at wiring time, while registration lived in `initialize`, which the runtime calls afterwards. The authority could therefore tick a plan in the gap — and did. Measured on the crash-repro boot: `usable_gb = 0` on a 53 GiB board for ~0.6 s, because our own 44 GB were filed under nobody yet. Nothing was actuated (the #438 downshift debounce held the plan, and `serving.lane_reclaim` never fired — the inherited 27B was ADOPTED, same pid across the crash). But a guard covering for a budget that is momentarily lying is not the same as the budget being honest, which is exactly Joel's objection. FIX: `declare_to_memory_authority()` — seed the device VRAM prior + register as a consumer — called at wiring time immediately BEFORE the planner is attached. Both operations are idempotent (set-once prior; `add_consumer` clears stale quarantine for the id), so this is an ordering constraint, not a duplication hazard. The device's total VRAM is a static hardware fact available immediately; there was never a reason to learn it later than the first tick that plans against it. The two call sites carry a do-not-swap note naming the measurement. ACCEPTANCE (Joel's, verbatim): "letting us have and keep our 27b for benchmarks and project development activities." Verified live across a hard SIGKILL of the core with the lane held: 27B kept, ADOPTED not reaped (pid 42506 identical before and after), ready, 4 lanes, 26,880 window — vs. the pre-fix ledger where the same crash produced a 14B at a 2,048 window. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…mpt (#380/#382) Measured on a live 10-instance Lite round, 2026-08-20, Qwen3.8-27B: 2 resolved / 16 gradeable. Three of the losses were never the model's — the harness spent them before or after the citizen's work. Two are fixed here. **1. astropy dies at env build — numpy is a BUILD dep, not just a runtime one.** File ".../astropy/__init__.py", line 116, in <module> _check_numpy() ImportError: Numpy version 1.10.0 or later must be installed to use Astropy astropy's `setup.py` imports its own package, and the `-e .` install runs `--no-build-isolation` — so the backend resolves against the venv as it stands, with no PEP-517 scratch env to pull numpy into. numpy can therefore only be satisfied in the `era_sdist_build_deps` pre-install, and it wasn't there. Both astropy instances in the round (6938, 7746) died before a citizen saw them; every astropy instance in Lite dies this way. Added, still era-pinned, so it widens what BUILDS without smuggling a modern numpy into a date-pinned subject graph. **2. The tests are not the solver's to touch.** `pallets__flask-4992`: Atlas produced a real 1,192-byte patch and grading died with "could not apply test patch — the tree is not what the patch expects" → UNGRADEABLE. The grade order is reset → model patch → test patch, so a model patch touching a file the test patch also touches breaks the apply. The existing four-arm ladder (exact → ignore-whitespace → -C1 → --3way) is a FUZZ ladder: it rescues only overlaps it can still merge, and `--3way` additionally needs the patch's pre-image blobs present. Fuzzing harder was never the fix. `restore_paths_to_base` now restores exactly the paths the test patch targets to their committed state, immediately before applying it. The ungradeable is the smaller half of what this buys. The larger half: before this, a candidate patch that edited a test file EITHER broke the apply (visible) or — where the edits merged — silently graded the solver's OWN tests. A clean-looking pass was reachable by editing the test. It no longer is. Source edits are untouched and remain exactly what gets scored; only the test patch's own paths are reverted. Creating-a-new-file is handled by construction (no HEAD entry → the per-path checkout no-ops). Tests: `diff_target_paths` pinned on the cases that would silently under-read — a `/dev/null` post-image (deletion, must NOT be restored), a tab-separated timestamp, and a quoted path with a space. An under-read here is the invisible-failure mode, which is why it is parsed strictly rather than best-effort. NOT FIXED HERE, named so it is not mistaken for done: `astropy__astropy-14995` sat `quiet` for 4,784s with `stalled=true` on the same round. The stall is DETECTED and nothing acts on it. That is its own fix. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ree out from under her Joel, on the previous cut of this fix: "Paths should remain throughout the whole recipe not off/on come on now." He was right and the objection is architectural, not stylistic. `grade()` was HANDED the solver's working tree and mutated it in place: reset_worktree → apply model patch → apply test patch. One path meaning different things at different instants. The citizen's workspace gets reset out from under her, ends up carrying a patch she didn't write, and finishes in a state neither the solving phase nor the grading phase asked for. My previous attempt (restore_paths_to_base) made that WORSE — it added a second toggle on top of the first to undo a specific overlap, which is the shape of a hack. Now: `ensure_grade_checkout(instance)` gives the grading phase its own directory, one stable path per instance, and grade() builds its state there from the base commit every time. `clone_at` already clears and re-stages, so the checkout is pristine BY CONSTRUCTION rather than by a reset someone has to remember to call. The solver's path stays the solver's for the whole recipe. `repo_dir` leaves both signatures. grade() and gold_gate() do not take a tree — they take an instance and a patch, and the path is theirs. A caller now CANNOT hand grading a tree to mutate; the invariant is enforced by the type, not by a comment. The test-file invariant restore_paths_to_base was buying still holds, and now holds inside the grade's own tree where mutation is legitimate: a model patch that edits a test file gets restored to base before the real test patch applies, so a solver can never grade against her own edited tests. Nearly every historical confusion in this file has the shared-path shape: `-e .` pinned to whichever tree built the venv first, pristine p2p reading 0/N off a dirty workspace, the "already passes on the pristine tree" gate firing against a tree that was not pristine. Separate paths per phase removes the class, not the instance. 23/23 swe_bench tests green. Follow-up #382 (pre-warm the grade clone during the attempt) gets easier from here — the clone is now a named, owned thing with a lifetime. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…r .eggs debris
Measured on the 10-instance round dispatched 2026-08-20: astropy-6938 and astropy-7746 both
died at env build, 2 of 10 gone before a citizen ever saw them. Reproduced by hand and the
cause is not a compiler error, not a missing dep, and not era pinning:
FileExistsError: [Errno 17] File exists:
.../astropy__astropy-6938/.eggs/markupsafe-3.0.3-py3.9-macosx-10.9-universal2.egg
Pre-PEP-517 setup.py declares `setup_requires`, and setuptools satisfies it by downloading
eggs into `.eggs/` INSIDE THE CHECKOUT. Next run, `setuptools.wheel._convert_metadata` calls
a bare `os.mkdir` on that existing path and raises. So the first failure — from any cause —
makes every later attempt fail forever, on a completely unrelated error.
We already knew this shape and had already fixed half of it: the teardown deletes `env_dir`
because "a cached broken env would poison every later run". The build writes to TWO places
and only one was being cleared. Same bug, second location — and the same class as the grade
path in the previous commit: state written into a path, never cleaned, rigging the next phase.
Why it took a manual repro to see: astropy's __init__.py catches the build failure and
re-raises `ImportError: astropy` with "try rerunning this command manually to see what the
issue was". The harness faithfully printed all of it; the real FileExistsError was four frames
down in a message nobody read. Positive control, same tree, same command:
.eggs present -> build_ext --inplace exits 1
rm -rf .eggs -> identical command exits 0
Fix: clear the checkout's build debris before the `-e .` install (it may predate this process)
and again on failure (so a failing instance never hands the next attempt a rigged tree).
`build/` goes with it — a stale `build/temp.<plat>-<pyver>/` reuses objects compiled against a
different interpreter or numpy ABI and fails much later as an unrelated import error.
NOT deployed by this commit; the 2 astropy instances need a reboot before they can rebuild.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… — and adopt same-line unwrap justification
MEASURED LIVE 2026-08-20, post-reboot: the plan served 16,384 with `bound_by=demand` while
`usable_gb=33` and `fits_on_gpu=true`. Read plainly that says "the minds asked for exactly
16,384 and got it" — with 33 GB free. No mind had asked for anything. No turn had been
measured yet, so `WorkingSetRegistry::ceiling()` returned None and `ServingDemand::new`
substituted BOOTSTRAP_WORKING_SET.
The prior is FINE. Laundering it into a measurement is not. `bound_by` exists precisely so a
window that fails to grow is falsifiable — its own doc says it separates "the host could not
fit more" from "the measured demand did not ask for more". A cold-start prior wearing the
`demand` label defeats the one question the field was added to answer, which is why the 16,384
rows looked like a settled system rather than an un-measured one.
Fix: `ServingDemand` carries `measured: bool`, set from the Option BEFORE `unwrap_or` discards
it, and `bound_by` gains a third state `bootstrap`, ordered first — with no measurement there
is no demand bound to be within, so "demand-bound" is vacuous, not merely imprecise. The probe
also emits `demand_measured`, so the provenance rides the receipt and not only the label.
Test pins the case that makes the flag load-bearing rather than cosmetic: a REAL measurement
that happens to equal BOOTSTRAP_WORKING_SET is still measured, so the two states can never be
distinguished by comparing the number alone. 30/30 serving_plan tests green.
UNWRAP DISCIPLINE (Joel, this session): every unwrap is suspect; legitimate ones carry a
SAME-LINE justification, and CI will eventually require it. Adopted on the two this change
touches. Measured surface for the sweep ahead, continuum-core/src only, 1,203 files:
unwrap() 3,866 total 323 outside tests
expect( 2,169 total 171 outside tests
unwrap_or* 2,738 total 1,712 outside tests
Two distinct hazards, worth separating when the ratchet gets built: `unwrap()`/`expect()`
outside tests (~494) CRASH; `unwrap_or*` (~1,712) are the class this commit is about — they
never crash, they quietly convert UNKNOWN into a quantity, and every downstream reader
inherits a number with no way to ask where it came from.
NOT FIXED HERE, and the more valuable half: 224 `working-set.json` files sit on disk, one with
peak_tokens=31,834 over 18 turns, and the planner cannot see any of them. `rehydrate` is
per-persona at spawn while `ceiling()` is host-level, so with no resident persona the host
serves the bootstrap prior indefinitely. Loading all 224 at boot would change lane-sizing
semantics from "resident minds" to "every mind that ever ran here" — a VRAM tradeoff, and
Joel's call rather than something to change silently.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…nd personas stop being an ungoverned disk class TWO defects, one root: durable state the system already had, that nothing read. 1. THE 27B WAS SERVING A QUARTER OF ITS EARNED WINDOW. `ceiling()` is a HOST question, but the only thing populating it was `rehydrate`, called per-persona AT SPAWN. Between boot and first spawn (~10 min, #412) the host had no demand; with nothing resident it had none at all. So the plan fell to BOOTSTRAP_WORKING_SET and served 16,384 while 224 working-set.json files sat on disk — one recording a peak of 31,834 tokens over 18 turns. The box had already proven what it needs and could not see it. Fix: `rehydrate_all()` at boot, called from `declare_to_memory_authority` — the same ordering law as the two lines above it, which make our own footprint visible to the authority before a plan may tick. This makes the host's earned DEMAND visible in the same window. This is NOT a VRAM risk, and I said it was, wrongly, an hour ago. Demand is a REQUEST, not an allocation. `plan_serving_stable` clamps it against what the host can fit — a `bound_by=host-fit` plan is literally that clamp firing — under CO_CONSUMER_HEADROOM and the governor's own `budget_for_replacing`. Raising demand raises the ASK; the governor still decides. The failure mode of asking too little is the one we MEASURED. The failure mode of asking too much is a plan that says host-fit. I invented a hazard the architecture already handles and handed it back as a question instead of doing the diligence. Why it matters for benchmarks specifically: `completion_budget_for(window) = window/4`, so a 16,384 window caps generation at 4,096 — and a reasoning model spends that inside `<think>` and never reaches the tool call. Window is upstream of the empty-turn round-killer. 2. `~/.continuum/personas` WAS AN UNGOVERNED DISK CLASS. Untracked, so invisible to BOTH halves of the contract: no size report, and the eviction guard could not flag a missing decision because that guard iterates `standard_tracked_dirs`. Exactly the silent-class shape the 2026-07-13 incident was about. Found at 295 dirs / 18 MB, 286 under 100 KB — spawn ghosts (#437), not minds. Registered as a TrackedDir + given an eviction decision inheriting `citizens`' rule: a LIVE mind's longterm.db and working-set.json are MEMORY, never blind-LRU'd. The evictable sub-class is GHOST dirs only — no roster entry AND no recorded turn — which needs a pool that can ask the roster, not a size heuristic. Named that way so the owner is unambiguous. Also: `personas_root()` extracted so the path has one spelling, with a same-line JUSTIFIED comment on its `unwrap_or` per the unwrap discipline adopted this session. 79 tests green (43 working_set, 36 disk_*). Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ies of `/4` collapsed to a derived constant Pure refactor, zero behaviour change: the split stays 1/4 and all 21 prompt_shaping tests stay green. The point is that changing it is now a ONE-LINE edit instead of a six-site hunt. The fraction was re-spelled as a bare `/ 4` in five places: `completion_budget_for`, the `div_ceil(3).saturating_mul(4)` in `min_window_for_agentic_surface` (that same algebra solved for D=4 and frozen), and three test mirrors. That is the dangerous kind of duplication — the mirrors RE-DERIVE the old fraction from scratch, so on any change they keep passing while no longer measuring the invariant they exist for. A guard that can only pass is worse than none. Now: `COMPLETION_SHARE_DENOM` is the single source; the agentic-surface bound derives `ceil(fixed * D / (D-1))` from it; the three mirrors call `completion_budget_for`. PROVEN by flipping D to 2 and running the suite: FIVE tests failed immediately and by name — `prompt_plus_completion_cap_never_exceeds_the_served_window`, `prompt_view_stays_within_the_ served_window`, `a_held_work_card_survives_budget_pressure...`, `catalog_fits_the_minimum_ serving_window`, `tool_surface_is_a_category_index_plus_discovery_pair`. Before this commit the mirrors would have absorbed the change silently. Reverted to 4: green again. So the flip is NOT free, and the failures say exactly why: a bigger reserve leaves less than the mandatory floor (framing + tool surface + newest message + held card). The correct shape is `reserve = min(desired_share, window - mandatory_floor)` — the reserve YIELDS to the floor — which needs the floor pre-computed. That is real work, not a constant edit, and it is next. WHAT ALREADY MOVED THE NUMBER, measured live on build 9068466 minutes ago: the window itself. `rehydrate_all` put the host's earned demand in front of the first plan, and the probe now reads `demand_measured=true demand_window=71492 bound_by=host-fit` where it read `demand_window=16384 bound_by=demand` an hour ago. Served window 16,384 -> 22,528 on 4 lanes, so the completion cap went 4,096 -> 5,632 with no change to this fraction at all. The governor is now the thing deciding the window, which is what host-fit means. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…cript — bring them into the ts(optional) pattern
Found by reading the 194 compiler warnings I had been scrolling past all session. 50 of them
were one class — "failed to parse serde attribute … ts-rs failed to parse this attribute. It
will be ignored." — and that is not cosmetic.
#[serde(default, skip_serializing_if = "Option::is_none")]
serde OMITS such a field from the JSON. ts-rs cannot parse that attribute, ignores it, and
emits the field as REQUIRED. So the wire and the type disagreed, and the generated TS was
worse than merely imprecise — it was confidently wrong in a way that reads as safe:
-export type StepResult = { …, output: string | null, error: string | null, … }
+export type StepResult = { …, output?: string, error?: string, … }
TS said "present, possibly null". The field is ABSENT. Every `x.output === null` guard written
against that type was comparing against `undefined` and silently taking the wrong branch.
This was never an unknown pattern — 324 fields already carry `#[ts(optional)]` beside the
serde attribute, exactly as ARCHITECTURE-RULES prescribes. 131 had drifted out of it. Scoped
precisely: only fields INSIDE a `#[derive(..., TS, ...)]` item can drift, so the 50
serde-only fields (no TS derive, no generated type, nothing to disagree with) were left alone
rather than blanket-edited.
VERIFIED, not asserted: regenerated the bindings (1,210 export tests green) and the diff is
61 changed lines across 19 files in protocol/typescript — every one a field flipping from
required-nullable to optional. If the drift had been imaginary the diff would have been empty.
The 50 warnings themselves REMAIN, and honestly so: ts-rs still cannot parse that serde
attribute: that is ts-rs's limitation, and it is precisely why the explicit `#[ts(optional)]`
has to be there. The warning is now a true statement about a tool, not a symptom of a lie in
our output. The remaining `alias =` parse failures are deserialize-side only and do not change
the emitted shape.
Joel, this session: "refine everything into the patterns and reduce smell everywhere you see
it at all — do not ever ignore or just stick it in a card." This is that, and the smell was
one I had personally read past in every build today.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… not unwrap_or(0)
Swept the whole tree for the shape that broke memory allocation — an Option meaning "we could
not measure" collapsed into a number. Scoped the search to a FAILED ACQUIRE (poisoned lock,
dead guard) becoming a quantity, since that is the specific family, not every unwrap_or.
Tree-wide, outside tests, that search returns exactly ONE site:
self.entries.lock().map(|m| m.len()).unwrap_or(0) // gpu/eviction_registry.rs:182
That is a better answer than I expected and worth stating plainly rather than implying a
plague. But the one site is in the worst possible place: the structure that tells the
allocator what is resident on the GPU. A poisoned lock — another thread panicked mid-mutation
— reported "0 entries", which reads as "nothing is registered, nothing to evict". Believing
VRAM is free when it is full is the most dangerous wrong answer this type can give.
`len() -> Option<usize>` and `is_empty() -> Option<bool>` now say what is true: `Some(n)` is a
count, `None` is "could not read", and the caller decides. Identical law to the serving demand
fixed earlier today, where a bootstrap prior spent an hour posing as measured demand — same
failure mode, different units.
HONEST SCOPE, because the compiler settled it: production compiled CLEAN against the new
signature, so `len()`/`is_empty()` had ZERO production callers. This was a latent hazard in
public API, not an active bug. Only test call sites needed updating.
Also corrected my own over-reach mid-fix: a regex rewrote `candidates.len()` — a plain `Vec`,
never an Option — into `Some(3)`. Caught by the compiler, reverted to the scoped form. Worth
recording because it is the same class of error as the bug: applying a rule by NAME match
rather than by what the thing actually is.
102 gpu tests green.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…or — and the share-only form is DELETED, not kept as a fallback
ONE form now decides the reply's room: `completion_reserve_within(&self, window)`.
reserve = min(window / D, window - (tool_schemas + bare_framing)).max(FLOOR)
The reserve yields. It was a bare share of the window and nothing else, so raising it took
room the prompt has no choice but to use — the packer admits framing and the tool surface
whether or not the budget covers them. The overshoot was never the packer misbehaving; it is
the floor correctly refusing to compress, and holding the reserve fixed against it was the
actual error.
Both floor terms are pure over `&self`, which is what makes this work at all: `prompt_view_
within` and `build_request_within` compute the SAME number without threading a workspace
through. That agreement is load-bearing — the prompt is sized to leave exactly this and
generation is capped at exactly this, so `prompt + completion` cannot reach `n_ctx`. Reuses
the identical `fixed` term as `min_window_for_agentic_surface`, so the bound that WARNS about
a too-small window and the reserve that LIVES within one cannot disagree about "mandatory".
DELETED `completion_budget_for` outright — 0 references remain, verified. Joel, this session:
"No fallbacks ever. Delete the wrong form." It was exactly that: a share-only reserve, still
callable, still correct-looking, that any future edit could reach for and silently reintroduce
the overshoot. Keeping it as "the simple one" is how two forms of one decision persist. Its
doc's real promises (one source of truth, no fixed ceiling, never a const we picked) moved
onto the surviving form, which is where they were always true.
WHAT THE /2 EXPERIMENT ACTUALLY MEASURED, kept at /4 deliberately and NOT bumped to fit:
flipping D to 2 now fails on genuinely NEW information, not on the stale mirrors it failed on
before (those are repointed at the live reserve, so they can no longer pass while measuring a
dead formula):
- `catalog_fits_the_minimum_serving_window`: at window 2,048 framing alone is 1,506. The
reserve yields correctly to 542 — and that leaves ZERO for any message. The floor is
incomplete: "mandatory" must include a minimum burst, or MIN_SERVE_CTX cannot host a turn
at D=2 by arithmetic, not by policy.
- `tool_surface_is_a_category_index_plus_discovery_pair`: needed 16,864 vs ceiling 11,300.
`needed = fixed * D/(D-1)`, so changing the RESERVE POLICY moved a guard whose own comment
says it exists to catch SURFACE growth ("framing/tools grew again. Shrink the surface").
Two concerns in one assertion. The guard belongs on `fixed`, not on `needed`.
Neither is a reason to bump a number. Both are named with measured values so the next pass
fixes causes. Stopping at /4 with the mechanism shipped and green is the honest boundary —
landing /2 against a floor I know to be incomplete would be the quick fix.
21/21 prompt_shaping green.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…s fixed at the cause, neither number bumped to fit `COMPLETION_SHARE_DENOM: 4 → 2`. On the live 22,528 window the reply goes 5,632 → 11,264. This is the cap that was truncating turns inside `<think>` before they reached a tool call. The flip only lands because the two things blocking it were defects, and both are fixed as defects rather than as thresholds: BLOCKER 1 — THE FLOOR WAS INCOMPLETE (`mandatory_prompt_floor`). The floor was `tools + framing`, which stopped the reserve eating framing and still produced a citizen who could not converse. Measured at MIN_SERVE_CTX (2,048): framing alone is 1,506, the reserve yields correctly to 542, and what remains for the message she is ANSWERING is zero. The reserve was behaving perfectly; the floor simply did not describe the whole obligation. A prompt with no room for the turn's own message is not a prompt. The burst allowance is `COMPLETION_FLOOR_TOKENS` — deliberately the SAME term as the smallest usable reply, because a turn needs at least as much room for what she answers as for the answer. BLOCKER 2 — A GUARD WITH TWO CONCERNS (`AGENTIC_SURFACE_CEILING`). It asserted on `min_window_for_agentic_surface()` = `fixed * D/(D-1)` — the surface AND the reserve policy, multiplied. So changing the split tripped a ceiling whose own message reads "framing/tools grew again. Shrink the surface", at 16,864, with the surface untouched. It now asserts on `fixed` (tools + bare framing) and moves if and only if the surface actually grows. AND THE ONE I CAUSED, caught by the full suite and worth recording plainly: `COMPLETION_FLOOR_TOKENS: u32 = 256` — a bare literal in a TOKENS-named constant, which is precisely what `no_new_hardcoded_context_or_prompt_size_constant_anywhere_in_the_crate` exists to catch. It shipped hours ago and every prompt-shaping run stayed GREEN, because that guard lives in another module. Now derived: `MIN_SERVE_CTX / 8`. Not exempted — derived, so it tracks the substrate floor instead of being a second opinion about how small a window gets. WASTED MOTION, owned: three attempts at this one flip (try→revert, collapse→try→revert, delete→fix→land). All of it was derivable in ONE pass by reading the three call sites and the two guards first. I went empirical where the structure was already legible. VERIFIED: full `--lib` suite run (7,343 tests) is what surfaced the de-hardcode violation that every narrower filter missed; cognition tree 1,028/1,028 green at /2 after the fix. ALSO: killed a false parity claim in `dream_consolidation` that named `completion_budget_for` (deleted) and "= window/4" (no longer true). The code never called it — it derives from `ContextBudget::latest_action_chars`. Both were a quarter, so the prose agreed with the arithmetic by coincidence for as long as it existed. Deliberately NOT "fixed" by wiring the two together: a distiller's reply is not a citizen's turn, and inventing a dependency to make a sentence true would couple things with no reason to move together. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… adapter contract for Metal/CUDA/Vulkan/MLX
The Metal monitor answered a failed Mach syscall with `total_bytes` — "the sensor
broke, so assume every byte is free" — and handed that straight to the
ResourceGovernor. Its constructor did the same thing unconditionally, seeding
`free_bytes = total_bytes`, so EVERY boot told the governor the pool was entirely
free until the first tick. The NVIDIA backend, sampling at construction, never had
the hole.
One backend lying and the other not is not two facts about two backends. It is one
missing constraint. Each impl wrote `GpuMonitor` WHOLE — its own atomics, its own
last-good retention, its own sensor sentinel encoding, its own pressure derivation,
its own tick — four copies of one concern, each free to express it differently. A
Vulkan or MLX adapter written against that trait would have been free to invent the
same lie a third time, and `monitor.rs`'s own Vulkan TODO names that exact hazard:
"a stale `free` that never drops is the exact bug this whole live-monitor layer
exists to kill."
So the split is by NATURE, not convenience. New `gpu/device_probe.rs`:
GpuSample — one sampling ATTEMPT. Every term Option; None means "the platform
did not report it", identically on every backend. Never zero,
never a substitute.
GpuDeviceProbe — what a BACKEND supplies and all it supplies: platform/name/total,
memory_mode, cadence, and `sample()`. How to ask THIS device.
MonitoredGpu<P> — the common half, written once: last-good retention, the
unknown-until-first-sample state, the tick + panic isolation, the
milli-unit sensor encoding, pressure derivation, and the whole
GpuMonitor impl.
A backend now cannot express the substitution bug, because a backend never touches
the stored value. MetalProbe holds the device handle and the Mach calls; NvidiaProbe
holds the nvidia-smi CSV shape. `derive_pressure`, `to_milli`/`from_milli` and the
NO_SENSOR sentinel are DELETED from nvidia_monitor.rs — they were logic, and logic
lives in one place. `MetalMonitor`/`NvidiaMonitor` remain as type aliases with their
`new()` intact, so no caller's contract changed.
The trait's free_bytes is now `Option<u64>` — same law, same wording as the host-RAM
sibling one trait below it in capacity.rs, which already said "`None` is 'unknown',
NEVER 'zero'". GPU was the sibling that never got it. Degradation policy for an
unknown reading belongs to the CAPACITY SOURCE, not the monitor:
VramCapacitySource::used_bytes now returns 0 on unknown, matching
HostRamCapacitySource's documented choice and its recorded reasoning.
GpuSnapshot.free_bytes is Option + #[ts(optional)]; the positron metrics emitter
omits the GPU series entirely when there is no reading, because `total - 0` paints a
full bar that reads as "saturated" — the opposite of "we don't know yet".
Five tests in the base pin the rule for every backend at once, driven by a scripted
probe that can fail on demand — the failure no real device produces when you want it:
unknown-until-first-sample, a failed read leaves the last measured value standing,
absent sensors stay None not 0, pressure clamps when free briefly exceeds total,
zero total yields no pressure. 105 gpu tests green including the live-Metal ones on
this M5.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…pass the base silently The module header says "implement GpuDeviceProbe, never GpuMonitor directly". Prose in a header stops nobody: a Vulkan/MLX/ROCm author who writes `impl GpuMonitor for VulkanMonitor` gets a compiling, plausible adapter that re-owns retention and the unknown state — free to re-invent the `unwrap_or(total)` lie a third time. The rule has to be a guard. `every_gpu_backend_goes_through_the_shared_base` scans src/ for `impl GpuMonitor for` against a SANCTIONED table where each row carries its REASON — comment-stripped first, so prose can neither satisfy nor trip it (same predicate discipline as the module-wiring audit in registry.rs). It found a real bypass on its first run: a third impl in cognition/host_capability_probe.rs — a #[cfg(test)] fake device, so it is sanctioned as a test double, with the note that it is a second fixture beside MockMonitor and should collapse into it (CLAUDE.md: one fixture per concern). Sanctioned as a test, NOT as a backend — which is the distinction the table exists to force someone to make out loud. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…not a line in CLAUDE.md
The law has been in CLAUDE.md for months — "Consider all unwraps suspect and if legit
mark in comments why… We will eventually force CI to require justification" — and has
been re-broken continuously, because prose enforces nothing. Today it produced the
Metal free-VRAM lie: `read_system_free_bytes().unwrap_or(total)` told the
ResourceGovernor the whole pool was free on every failed Mach syscall, silently.
`source_hygiene/` — a SEAM, because there were already two hand-rolled source
scanners in tree (the de-hardcode guard in context_budget.rs, the module-wiring audit
in registry.rs) and a third copy is the duplication this codebase forbids everywhere
else. `SourceRule` supplies a predicate over one file; `scan` owns the walking, the
production/test split, and the string-literal-aware comment parsing that every rule
needs identically. The two older scanners should migrate onto it.
`unwrap_justification` is the first rule, and it is a RATCHET, not a wall: there are
2,267 unjustified occurrences in production today, and a guard demanding they all be
fixed now would fail forever, get #[ignore]d in a week, and enforce nothing — the
exact fate of the prose it replaces. It enforces the thing that matters: THE COUNT MAY
NEVER RISE. Every new unwrap carries its reason; every old one anybody touches
ratchets the number down. `// ok` does not count (MIN_JUSTIFICATION_CHARS) — a rule
a token satisfies reports zero forever while the codebase rots.
POSITIVE-CONTROLLED, and it earned its keep immediately: the first control run PASSED
when it should have failed. Cause was a bug in MY OWN scanner, the same class this
whole day was about — `src.find("#[cfg(test)]")` matched the string anywhere,
INCLUDING inside a doc comment. This module's own header mentions `#[cfg(test)]`, so
the split fired at line 36 and excluded nearly the entire file from its own scan.
Every file whose docs merely MENTION test-gating was silently under-scanned. Fixed to
split on the first line whose CODE (comment-stripped) contains it — match by nature,
never by name — which revealed 14 more occurrences the first measurement had hidden
(2253 → 2267, the honest number). Re-controlled after the fix: green at 2267, inject
one unjustified unwrap → FAILS naming it at 2268, revert → green.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
… GPU/hygiene branch
Four conflicts, all the same shape and none semantic: my additions against canary's
absence, flagged on adjacent context. Taking ours in each:
gpu/metal_monitor/mod.rs canary still carried `impl GpuMonitor for MetalMonitor`
with `free_bytes() -> u64`; that impl moved to
`MonitoredGpu` in 5cd393e, so the block is dead code.
modules/serving_daemon.rs `working_set.rehydrate_all()` + its ordering comment.
cognition/swe_bench.rs `clear_setuptools_build_debris` before the `-e .` install,
and the two `diff_target_paths` tests.
THE ONE THAT WOULD HAVE SHIPPED BROKEN: `resources/capacity.rs` auto-merged with NO
conflict markers and produced 306 duplicated lines — `HostMemoryReader`,
`LiveHostMemory`, `HostRamCapacitySource`, `default_ram_reserve_for` each defined
twice (E0428 ×4). Git concatenated both sides of a moved block and reported success.
A textually-clean auto-merge is not a correct one; only the compiler caught it.
Duplicate span removed, one definition of each remains.
`cargo check --all-targets --features metal,accelerate` clean. Full suite + CI are
the gate for the canary merge itself — NOT merging canary until they report.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ilt but never wired" disease (#27 root) Five times in ONE session the same defect was found by accident, each after hours debugging a symptom that looked unrelated: ProbeRouterLayer installed, handle discarded (#362, dead probe stream) CLI install ran every deploy, BUILD gated off (#422, stale binary) BenchViewState impl complete, never bound (#426, blind citizen) GeneratorModule never registered with the runtime (#325, orphan command) AgentContext constructed ONLY in its own tests (#27, operator w/ no identity) Every one compiled. Every one had passing unit tests. Five in one day is not bad luck, it is a missing constraint. The module-wiring audit (#344) asks about MODULES; four of the five were not modules. This asks the general question: does anything in the workspace actually use this? AgentContext is why it matters commercially, not just aesthetically: because the operator has no in-core airc identity, benchmark/dispatch authors its cards through `any_live_citizen` — so a round's cards are attributed on the board to a citizen who did not post them, and no operator/agent can hold a claim, which is what makes collaborating on a round impossible. THE RULE: a `pub struct`/`pub enum` in this crate, with an inherent impl AND a stand-up constructor (new/bootstrap/spawn/install/connect/start), referenced nowhere in the workspace outside its own file. Condition 2 keeps it from degenerating into a dead-code lint over wire DTOs and ts-rs payloads. FOUR false-positive classes closed, each of which would have got the guard deleted: 1. a `use`/`pub use` re-export is NOT a use — this is exactly how AgentContext would have hidden from its own guard; 2. a doc-comment mention is not code (match by nature, never by name — same discipline `scan` already needed for #[cfg(test)]); 3. reference corpus includes TEST halves: a type wired to another file's test harness IS wired (GridSimulator, RecordingGridCapture). Production-only scored 205; the honest number is 107; 4. a type surfaced via `pub type Alias = ...` is reached through the alias — this would have fired on MetalProbe/NvidiaProbe, i.e. on the exact backend-adapter shape gpu::device_probe was refactored INTO today. A guard that punishes the pattern it protects gets weakened until it says nothing. SEAM, not a fourth hand-rolled scanner: source_hygiene gains CrateRule/scan_crate for rules that are irreducibly cross-file, alongside the per-file SourceRule. Violations come only from continuum-core/src; references are searched across every workspace src root, because this crate is a LIBRARY and apps/cli may be the legitimate caller. Widening the corpus can only ever remove findings. A BUG IN THIS GUARD, found and fixed before it shipped: own-mentions were counted over the production half while the corpus was raw, so a type constructed in its OWN test mod scored corpus>own and read as externally referenced — AgentContext went unreported. Symmetry between the two sides IS the arithmetic. The first fix re-read the file with `unwrap_or_else(|_| production.clone())`; that fallback silently swapped the text shape and reintroduced the very miscount, so SourceFile now carries `raw` from the single read and there is no fallback at all (Joel: don't leave fallbacks or other refuse in there). Ratchet at a MEASURED 107, not a wall — a wall gets #[ignore]d in a week. Positive control is hermetic: a synthetic type with a bootstrap ctor, constructed only in its own test mod, re-exported by a parent and named in that parent's prose, must still be reported. If that test ever passes vacuously the guard is decoration. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ported on every target (CI E0432)
`#[cfg(target_os = "macos")]` binds to the NEXT item only. Inserting the new
`device_probe` re-export ABOVE `metal_monitor` in today's adapter refactor silently
moved the gate onto the base and left the macOS-only adapter exported everywhere:
#[cfg(target_os = "macos")]
pub use device_probe::{...}; // the PLATFORM-NEUTRAL base — wrongly gated
pub use metal_monitor::{...}; // the macOS ADAPTER — wrongly ungated
Exactly inverted from the `mod` declarations two lines up (device_probe ungated,
metal_monitor macOS-gated), and exactly inverted from the point of the refactor: the
base is what every backend shares.
Compiled clean on this Mac. E0432 `unresolved import metal_monitor` on every other
host — which is BOTH red CI jobs from one cause: `cargo test --lib` (Linux) and
`cargo check windows-msvc`. I was ready to write the Windows job off as the #404
flake; it was this.
Caught only because CI builds a different target than I do. The local check that
would have caught it does not exist on a Mac (`--no-default-features` can't build
here, #422), so the honest guard is CI itself — which is the argument for not
merging red on a "probably the flake" hunch.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…/{metal,nvidia}
Organizational fix for the class that just took down both CI jobs (e0ff670).
BEFORE: `metal_monitor/` and `nvidia_monitor.rs` sat flat beside the platform-neutral
base, each with its own `#[cfg]` at its `mod` AND another at its `pub use` in
gpu/mod.rs. One concern — which platform am I building for — decided in four places.
On 2026-08-20 one drifted: `#[cfg]` binds to the NEXT item only, so inserting the new
`device_probe` re-export ABOVE `metal_monitor` slid the gate onto the base and left the
macOS-only adapter exported on every target. Compiled here, E0432 on Linux AND Windows.
AFTER:
gpu/device_probe.rs the contract (platform-neutral, ungated, always exported)
gpu/backends/mod.rs THE single cfg site — selects the platform adapter
gpu/backends/metal/ macOS (Mach FFI — genuinely cannot build elsewhere)
gpu/backends/nvidia.rs every platform (subprocess nvidia-smi, no FFI) — deliberately
ungated, documented so nobody "tidies" a cfg onto it
`gpu/mod.rs` now re-exports with no cfg reasoning of its own: by the time it runs, the
platform question is already answered. There is no second gate to put on the wrong
line. Adding Vulkan/ROCm/MLX is a local edit — one file, one mod+use pair, nothing else
in the tree changes.
Not vigilance, a STRUCTURE — and then a guard on top, because structure alone still
lets the two lines inside backends/mod.rs disagree:
`every_backend_export_carries_the_same_gate_as_its_module` reads this file's own source
and requires each `pub mod NAME` and its `pub use NAME::` to carry the same gate.
Source-reading is the only way to assert it from ONE target: the missing gate is one
macOS satisfies, so no compile-time check on this box could ever see it.
POSITIVE-CONTROLLED both directions: re-introducing the exact CI bug (dropping the cfg
from the metal export) fails on this Mac naming the backend and the asymmetry; reverting
passes. 107 gpu tests green.
Move was pure `git mv` — all 4 remaining `metal_monitor`/`nvidia_monitor` mentions in
the tree are prose in comments, zero code depended on the deep paths, and the crate
compiles unchanged.
Joel, 2026-08-20: "I'd organize the platforms like you did cuda/mlx/vulkan. Fix
organizational problems. They haunt you later."
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…rd — it bounds a COMMENT, not a window CI red, and the guard was right to be suspicious. `no_new_hardcoded_context_or_prompt_ size_constant_anywhere_in_the_crate` matches `const NAME: usize = <literal>` when NAME contains WINDOW|CONTEXT|CTX|TOKEN|PROMPT|CHARS. My `MIN_JUSTIFICATION_CHARS = 12` hit on the CHARS suffix alone. It is genuinely not a size bound on anything served: it is the minimum length of the inline `//` comment a human writes to justify an unwrap. It never scales with the context window and a fraction of the window would be meaningless. So this takes the guard's own sanctioned escape — `context-budget-exempt:` with the reason — rather than renaming the constant to dodge the pattern, which would be gaming the guard. Second time one of my own PRs has been caught by this guard (#411 was FLOOR_TOKENS). That is the guard working, not the guard being noisy: it errs toward flagging and makes you say why, which is exactly the trade its header argues for. HOW THIS REACHED CI, which is the real lesson: I validated with `cargo test --lib source_hygiene` — a FILTER. The de-hardcode guard lives in cognition::context_budget, so it was never in the filtered set. A filtered pass is not a pass; CI runs the whole lib. Running the full suite locally before push is the fix, and it is what I am doing now. Windows-msvc went green on this same run (was FAILURE), independently confirming the E0432 cfg diagnosis in e0ff670 was correct rather than lucky. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ary has been unmergeable for 4 days Every PR into canary has sat permanently BLOCKED with all real gates green. Not a quality problem — a stale config line. WHAT HAPPENED: on 2026-08-16 the binding-drift gate was folded from its own workflow into a STEP inside `cargo test -p continuum-core --lib`, and that consolidation was correct — the check is a `git diff` against bindings the test run already regenerated, so a standalone job had to re-compile continuum-core (~9 min) to diff what the previous job just produced. The workflow's own comment argues this well and the duplicate build should not come back. WHAT WAS MISSED: canary's branch protection still requires a status CONTEXT named `ts-rs binding drift detector`. After the fold, no job published that name. A required check that never reports can never be satisfied, so mergeStateStatus stays BLOCKED forever regardless of results. Found while merging #2338 with lib tests, windows-msvc, and label-pr all green. THE FIX, and why it is this one rather than the obvious one: re-splitting the detector into its own job would restore the name at the cost of reintroducing the 9-minute duplicate compile someone deliberately deleted — undoing a correct optimization to satisfy a config line. Instead this job makes the required name real without the waste: `needs:` binds it to the job that actually runs the detector, so drift → lib job fails → this job is SKIPPED → the required check never passes → the PR stays blocked. Correct gating, ~5 seconds, no rebuild. It mirrors a verdict rather than computing one, and it SAYS SO in both the comment and its output instead of printing a "✓ no drift" it did not establish — the same lying-receipt smell killed twice today (#151/#357 class). The comment also names the maintenance hazard: if the detector moves, update `needs:`, because a mirror pointed at the wrong source is worse than no mirror. No branch-protection change required — the context is now produced by a job, so repo config stays untouched. Closes the live half of #457. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Measured on a live 10-instance SWE-bench Lite round, 2026-08-20, Qwen3.8-27B:
2 resolved / 16 gradeable. Three of the losses were never the model's — the harness spent
them before or after the citizen's work. Two are fixed here.
1. astropy dies at env build — numpy is a BUILD dep, not just a runtime one
astropy's
setup.pyimports its own package, and the-e .install runs--no-build-isolation— so the backend resolves against the venv as it stands, with noPEP-517 scratch env to pull numpy into. numpy can therefore only be satisfied in the
era_sdist_build_depspre-install, and it wasn't there. Both astropy instances in the round(6938, 7746) died before a citizen saw them; every astropy instance in Lite dies this way.
Added, still era-pinned — widens what BUILDS without smuggling a modern numpy into a
date-pinned subject graph.
2. The tests are not the solver's to touch
pallets__flask-4992: a real 1,192-byte patch, and grading died with "could not apply testpatch — the tree is not what the patch expects" → UNGRADEABLE.
Grade order is
reset → model patch → test patch, so a model patch touching a file the testpatch also touches breaks the apply. The existing four-arm ladder (exact → ignore-whitespace →
-C1→--3way) is a fuzz ladder: it rescues only overlaps it can still merge, and--3wayadditionally needs the patch's pre-image blobs present. Fuzzing harder was never thefix.
restore_paths_to_baserestores exactly the paths the test patch targets to their committedstate, immediately before applying it.
The ungradeable is the smaller half of what this buys. The larger half: before this, a
candidate patch that edited a test file either broke the apply (visible) or — where the edits
merged — silently graded the solver's own tests. A clean-looking pass was reachable by
editing the test. It no longer is.
Source edits are untouched and remain exactly what gets scored; only the test patch's own
paths revert. A path the patch creates has no HEAD entry, so the per-path checkout no-ops.
Tests
diff_target_pathspinned on the cases that would silently under-read — a/dev/nullpost-image (deletion, must NOT be restored), a tab-separated timestamp, and a quoted path with
a space. An under-read here is the invisible-failure mode, which is why it is parsed strictly
rather than best-effort. 2/2 green;
cargo check -p continuum-coreclean.Not fixed here, named so it isn't mistaken for done
astropy__astropy-14995satquietfor 4,784s withstalled=trueon the same round. Thestall is detected and nothing acts on it. That is its own fix.
Verification plan
Re-run the identical 10 instances on the fixed harness and report the delta against today's
measured 2/16 — not asserted, measured.