Repository navigation
Add genome visualization to root README with live video - #155
Merged
Merged
Conversation
- Add continuum-live.mov video demonstrating real-time multi-AI collaboration - Add user-interface.png showing genome panel visualization - Assets ready for root README update 🔧 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
- Replace static screenshot with continuum-live.mov video demonstration - Add "Genome Visualization" section showcasing AI identity system - Document diamond grid showing Learning/Cloud/RAG/Genome capabilities - Emphasize real-time evolution visualization as personas gain abilities 🔧 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR updates the README to enhance the visual presentation and add comprehensive documentation for the Genome Visualization feature. The changes replace a static image with a video demonstration and introduce detailed explanations of the AI genome identity system.
- Replaced static UI image with video demonstration at the top of the README
- Added new "Genome Visualization" section documenting the AI persona capability display system
- Updated caption to emphasize real-time genome capabilities
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
joelteply
added a commit
that referenced
this pull request
Nov 30, 2025
…video Add genome visualization to root README with live video
This was referenced Apr 7, 2026
joelteply
added a commit
that referenced
this pull request
Apr 7, 2026
EXPERIENTIAL-PLASTICITY: - New §9.5 subsection: gpt2-medium re-run on corrected pipeline - Reframes §4 transfer function as "early-cycle behavior controller will encounter" - Documents that the controller's quality-aware stopping criterion makes the cycle 9 anomaly structurally unreachable in production - Adds OUTCOME D framing: closed-loop controller enforces the transfer function - Adds four-metric comparison subsection with the activation > saliency >> L2 > gradient ranking - Calls out PLASTICITY-COMPACTION's gradient-magnitude trick as a publication-blocking question VALIDATED-TENSOR-SURGERY: - New section: Layer 6, the structural fix that closes the bug class - Documents the literal 62→7→501 historical bug pattern catch - New section: The four-metric comparison empirical result - Hypothesizes why activation alone beats saliency at small calibration - Recommends activation-magnitude as the default forge pipeline metric KASH-FEEDBACK.md: - Appended results from both experiments - OUTCOME D framing for gpt2 result - Three observations on the four-metric finding - Three questions for Kash's read Refs continuum #841 (gpt2 re-run, partial OUTCOME D) Refs continuum #842 (Layer 6 invariant, shipped) Refs continuum #844 (four-metric comparison, surprise result) Refs sentinel-ai #155 (importance metric finding, now contextualized)
joelteply
added a commit
that referenced
this pull request
Apr 8, 2026
* Paper stub: Validated Structured Pruning for Consumer Hardware Companion to Experiential Plasticity. Documents the layered test harness for tensor surgery validation. Two real bugs in production pruning code were caught during harness construction: 1. LoRA-on-pruned-hooks corrupts model on hook removal 2. Config drift after defrag breaks save/load roundtrip Title, abstract, and section outline. Full paper to follow as Layers 4-6 of the harness are built. * Paper: bugs table and Layer 4 update The harness now caught 5 real bugs during construction: 1. LoRA-on-pruned-hooks corruption (FIXED) 2. Config drift after defrag (FIXED) 3. Hybrid attention models (TRACKED) 4. L2 norm importance is unreliable (RESEARCH FINDING) 5. Pruning without retraining is destructive (RESHAPES the experiential plasticity narrative — recovery comes from fine-tuning, not pruning) * Papers: write down 5 findings into both experiential and validated-pruning Experiential paper: - New section 9.5: Validation and a Reframing of the Plasticity Story - Documents LoRA-on-pruned-hooks bug that produced phantom +88% improvements - Documents L2-norm importance metric finding (anti-correlated with importance) - Reframes the central claim: recovery comes from fine-tuning, not smart pruning - Calls for no-prune equal-budget fine-tune baseline as required ablation - Adds reference to companion paper Validated pruning paper: - New section: Findings In Detail (5 findings, each with empirical evidence) - Each finding has the failure mode, the empirical signature, and the fix - Frames validation harnesses as required artifacts for pruning papers * Papers + kash-feedback: gpt2 OUTCOME D, four-metric finding, Layer 6 EXPERIENTIAL-PLASTICITY: - New §9.5 subsection: gpt2-medium re-run on corrected pipeline - Reframes §4 transfer function as "early-cycle behavior controller will encounter" - Documents that the controller's quality-aware stopping criterion makes the cycle 9 anomaly structurally unreachable in production - Adds OUTCOME D framing: closed-loop controller enforces the transfer function - Adds four-metric comparison subsection with the activation > saliency >> L2 > gradient ranking - Calls out PLASTICITY-COMPACTION's gradient-magnitude trick as a publication-blocking question VALIDATED-TENSOR-SURGERY: - New section: Layer 6, the structural fix that closes the bug class - Documents the literal 62→7→501 historical bug pattern catch - New section: The four-metric comparison empirical result - Hypothesizes why activation alone beats saliency at small calibration - Recommends activation-magnitude as the default forge pipeline metric KASH-FEEDBACK.md: - Appended results from both experiments - OUTCOME D framing for gpt2 result - Three observations on the four-metric finding - Three questions for Kash's read Refs continuum #841 (gpt2 re-run, partial OUTCOME D) Refs continuum #842 (Layer 6 invariant, shipped) Refs continuum #844 (four-metric comparison, surprise result) Refs sentinel-ai #155 (importance metric finding, now contextualized) * PLASTICITY-COMPACTION: §4.1.4.2 per-tier negative result + §4.1.5 distillation-first pivot Three new subsections in §4.1, capturing tonight's negative results across the dense-model forge branch and proposing the structural reframe that the empirical work converged on. §4.1.4.2 — Per-tier Pareto comparison (negative result): The aggressive-quantization Pareto test from §4.1.4.1 is now run end-to-end. v2-7B forge and unmodified Qwen2.5-Coder-7B base, both quantized to Q5_K_S / Q3_K_M / Q2_K via the same llama.cpp toolchain, both evaluated via the same patched vLLM-GGUF backend that anchored against Qwen's published 61.6/53.0 to within +0.6/+0.7 (deterministic across 5+ runs): Tier v2-7B base Δ Winner Q5_K_S 5.0G 55.5 63.4 -7.9 base by +14% on quality/vram Q3_K_M 3.6G 54.3 59.8 -5.5 base by +10% on quality/vram Q2_K 2.9G 42.7 43.3 -0.6 tie within run noise Base+quant Pareto-dominates the v2-7B forge at every tier we tested. The closest the forge gets to parity is Q2_K (within run noise). By the §4.1.4.1 product-relevance criterion, the v2 forge methodology as currently constituted does not produce a useful product on the Qwen2.5-Coder-7B family. Three independent failure modes ruled out as fixes for the residual gap, all on the same v2-7B base, all with disciplined cause-of-the-gap comparison: 1. More cycles + more training: WORSE (54.9 → 46.3) 2. Held-out-aware code calibration: NO IMPROVEMENT (54.9 → 53.7) 3. Aggressive quantization: NO (base+quant wins at every tier, this section) Each was the leading hypothesis when tested. Each was falsified. Three negative results in succession on three independent fix candidates is strong empirical evidence that the activation-magnitude head-pruning + LoRA-recovery approach does not have a Pareto-improving sweet spot for dense base models that already have good quantization options, regardless of which knob in the strategy space is tuned. §4.1.4.3 — Product positioning implications: Two non-overlapping product positions where the forge has a defensible value proposition, and dense Qwen2.5-Coder-7B-class models with good Q3/Q2 quantizations are not one of them: 1. Distillation-first compaction (any base model, dense/MoE/hybrid) — see §4.1.5 below 2. Pre-removable expert pruning + structural compaction (MoE/hybrid/ oversized targets that base+quant cannot reach at all because the base does not fit on the target hardware even at Q2_K) The Qwen3.5-35B-A3B (target A) and Qwen3.5-397B-A17B (target B grid moonshot) work falls in product position #2. Their value is making models reachable that the alternative compaction methods cannot reach, not matching a base+quant alternative at the same tier. The dense-model forge work is suspended until distillation-first lands. §4.1.5 — Distillation-first compaction (the next-iteration methodology proposal): The empirical pattern across §4.1.3.1, §4.1.3.2, §4.1.4.1, and §4.1.4.2 is consistent enough to motivate a structural pivot in the forge's primary compaction mechanism, and the substrate work to support that pivot has already landed (compensation_lora.py + test_compensation_lora.py + COMPENSATION-LORA-DESIGN.md, all committed in a previous PR commit). The pivot inverts the v2 dependency: instead of "structured prune + LoRA recovery against fine-tuning loss", the new mechanism is "any transformation + distill against the unmodified teacher's hidden states". Pruning, quantization, modality fusion, context extension all become slot-in transformations that the (transform, distill, eval) loop recovers from independently. The methodology becomes a search procedure over the transformation space, with distillation as the convergence step and the per-tier metric as the stopping criterion. The smoke test on distilgpt2 passed all five stability checks (tokenizer alignment, hidden-state magnitudes within 2× across layers, loss decreased monotonically -39.35% relative, per-layer losses balanced within 3.14× of median, no NaN/inf). The math is sound at small scale; production scale-up to 7B is unblocked by RUNNING the script, not by writing more code. §4.1.5 results paragraph queued: take the v2-7B artifact from row 5, apply compensation LoRA with Qwen2.5-Coder-7B base as teacher and a held-out-aware calibration mixture, measure HumanEval through the same calibrated pipeline. Success criterion: HumanEval pass@1 ≥ 58.0 (a 3-point improvement, just outside the calibration tolerance band). If at-or-above: distillation-first is empirically validated, dense-model forge branch unfreezes, §4.1.4 row 5 gets a successor row. If below: follow the failure escalation path documented in COMPENSATION-LORA-DESIGN.md to the cross-layer skip path. Independence from the moonshot work is explicit: distillation-first is the dense-model branch's path forward, MoE/hybrid expert pruning is a separate substrate path, the two branches advance in parallel. Plus durability adds: - docs/hf-deprecation-notices/qwen2.5-coder-14b-compacted-DEPRECATION.md (the user-facing model card replacement for the v1 deprecated artifact) - docs/papers/NEUROPLASTIC-SUBSTRATE.md (the architectural-thesis paper from earlier in the work session) References: - sentinel-ai PR #161 (the substrate work that produced these results) - sentinel-ai#160 / #161 / #163 / #164 / #165 (the issues these subsections document the resolution paths for) - Qwen2.5-Coder Technical Report Table 5 (the anchor for the per-tier measurements) * PLASTICITY-COMPACTION §4.1.3.4 + forge template architecture rule §4.1.3.4: The importance-metric calibration lesson generalizes across structural unit (heads → experts). Empirical anchor: continuum-ai/qwen3-coder-30b-a3b-compacted-19b-256k v1 (alloy hash aa61c4bdf463847c). Hardware-measured 88.4 HumanEval / 86.0 HumanEval+ against unmodified Qwen3-Coder-30B-A3B-Instruct base anchor at 92.1 / 89.0, both on RTX 5090 + llama.cpp Q5_K_M in the same eval pipeline. The artifact carries the router-gate-L2-norm baseline (78.7 HumanEval) in priorMetricBaselines[] as the negative-baseline empirical control that makes the §4.1.3.4 claim falsifiable from the published artifact alone. The structural lesson: the metric-calibration pattern from §4.1.3.1 (dense head pruning) recurs at the MoE expert level. Router-gate-L2-norm is the architectural-only equivalent of activation-magnitude-only head importance, and replacing it with calibration-aware activation counts on a held-out code corpus closes +9.7 HumanEval points on the same prune budget, no fine-tuning, no compensation. ANY importance metric for ANY prunable unit (heads, experts, layers, future structural units) must be derived from task-conditioned activation profiling on a held- out corpus that reflects the artifact's intended workload. The two data points form a methodology curve, not a single anomaly. The compensation v2 step (KL distillation on top of the calibration- aware student to push from 88.4 → projected 90+) is currently blocked on transformers' caching_allocator_warmup pre-allocating an fp16 buffer equal to full model size before bnb 4-bit quantization takes effect, exceeding total VRAM on a single 32 GB GPU even with both teacher and student nominally 4-bit. The architecturally correct fix is offline teacher-logit precomputation (phase 1: load teacher alone, dump logits; phase 2: unload; phase 3: load student alone, train against on-disk logits). This is the next sentinel-ai sprint and is documented in §4.1.3.4's "next experimental wave" paragraph. CLAUDE.md: Forge Template Architecture rule. The qwen3-coder-30b-a3b-compacted-19b-256k v1 publish required ~6 manual edits to fix paper-speak hallucination, naming conventions, tag overflow, headline subtitle bugs, and benchmark renderer fallthrough — every one a manual touch on hand-authored prose. The architectural target going forward is: all the fields a forge run needs to populate an alloy MUST live as Continuum entity data inside a ForgeRecipe entity. The forge takes the recipe entity as input, runs the prune/quant/eval stages, and emits the populated alloy as OUTPUT. The forge never consumes a hand-authored alloy; the foundry generates it. Recipe entity carries the prose fields the model card renders (description, userSummary, tags, methodologyPaperUrl, limitations[]) plus the source/stages/calibration/quant tier configuration. ForgeArtifact entity is the recipe + the eval results. publish_model.py reads the ForgeArtifact, not a hand-authored alloy file. This is the next sprint after the offline-logits architecture.
joelteply
added a commit
that referenced
this pull request
Jul 18, 2026
… LOADOUT tile (#186), toolchain modernization (#188) (#1952) * fix(genome): thread ScheduleParams.sequence_length to mlx_lm --max-seq-length The schedule's sequence_length never reached the trainer — mlx_lm silently applied its 2048 default. Sequence cap is a memory control (activation memory scales batch × seq × model); found when job a96e2341 OOM'd Metal at batch 4 beside the resident llama-server and the operator's requested cap was never in the command line. Flag verified against the installed mlx_lm CLI. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(serving): #139 slice 1 — overflow fails loud, served window is ground truth llama-server spawns with --no-context-shift: a prompt exceeding its slot's window now 400s instead of silently amputating its middle (exam-corrupting amnesia with no log line). The /props probe additionally caches the served PER-SLOT n_ctx (default_generation_settings.n_ctx) per server root, and the request path warns (probe_class=serving.ctx_overshoot) when a prompt's conservative token estimate exceeds it — naming the RAG-budget bug before the server rejection lands. Also removes the never-constructed SlotAffinity::Unknown variant (warning cleanup). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(benchmark): #123 evidence engine — benchmark/record ledger + benchmark/matrix projection Every comparative claim decomposes into ledger rows a stranger can re-run: benchmark/record appends one (model × harness-arm × benchmark) result that MUST carry its replication command (rejected otherwise — a result nobody can re-run is a claim, not evidence). benchmark/matrix renders the models × arms markdown table as a pure projection of those rows: cells aggregate, a gene is its own model identity (the before/after-genome headline), an absent arm renders '—' never a fabricated 0%, and the appendix lists every row's exact replication command. The matrix is never hand-authored — same recipe→artifact doctrine as the forge alloy. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(genome): stream trainer pipes live — trainer.log + loss.jsonl (the learning proof) wait_with_output buffered everything to exit, making a running job unfalsifiable: no loss curve existed anywhere until the process died (tonight's 'prove they're running' had checkpoints and weight-hash deltas but no loss). The watcher now streams both pipes: every line appends to <job>/trainer.log, 'Iter N: Train/Val loss X' lines parse into <job>/loss.jsonl rows, and the failure tail still carries the last stderr lines. Parser pinned against tqdm bars and checkpoint-save lines masquerading as loss points. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(benchmarks): the Hermes campaign — three axes, order of battle, rules of engagement Axis A: common base + genome beats their fine-tune. Axis B (checkmate framing): ANY model including Hermes's own scores higher through OUR harness than raw. Axis C: on one MacBook, $/resolved-task beside every score. Round 1 tonight: humaneval-rs 20-task slice, six cells including hermes3-8b both arms. A claim without a ledger row does not exist. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(benchmarks): campaign header = the reader we must convince — headline benchmarks are Aider polyglot + Terminal-Bench, not humaneval Joel's correction: viral downloads come from beating the tool the reader already uses (aider/opencode) on ITS home metric with THEIR model, plus the one claim nobody else can make (local agent improves overnight, LoRA on HF, stranger-reproducible in 30 min), plus honest-zeros falsifiability, plus a 30-minute install-to-first-proof path. Humaneval demoted to smoke test. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(benchmarks): roster + schedule — core six for a 64GB Mac, phased to first README table by day 2 Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(benchmarks): rules of engagement — glass-box the competitor's arm too, fight their community champions, replicate their published numbers before comparing Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(benchmarks): published targets to replicate — aider's own board caps 64GB locals at 40% (Qwen3-32B); the gap is our headline Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(catalog): the campaign roster — six 64GB-class rows, arch/ctx read from each GGUF's own header Hermes-4.3-36B (seed_oss — ByteDance Seed-OSS base, useful opponent intel), Qwen3-32B (aider's published 40.0% local ceiling), Qwen3-Coder-30B-A3B (community champion, MoE 3B-active), Phi-4, Qwen2.5-Coder-32B (aider's 16.4% — replicate then beat) and 7B. All resolve by id-token derivation to the GGUFs on disk; all flow through base_model_id so head-to-heads are model-through-harness fair, never hardcoded reference columns. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * bench(matrix): first evidence-ledger render — 3 humaneval-rs cells (Devstral 95%, Coder-14B 90%, Hermes-3 45%) + SWE controls Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * bench(matrix): round-1 money table — three common models beat Hermes-4.3-36B through OURS (Devstral 95%, 14B 90%, 30B-A3B 90% vs flagship 80%) Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(paper): local agentic coding study — design + fairness protocol + stats plan + pilot Five RQs (models/harness/genome/team/cost), binding fairness protocol (symmetric glass-box, champions-not-strays, replicate-then-compare, proctored exams), Wilson CIs + paired McNemar with the pilot n=20 explicitly flagged non-separating. Results fill from the evidence ledger only. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(paper): Appendix A — reproduction procedure, out-of-repo deps front-loaded ('with continuum installed…') Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(paper): §8 exhibits — annotated verbatim interaction traces, one per claim, honest failure included Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(benchmarks): round-1 pilot status — four common models over the Hermes flagship through OURS Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(papers): The Entire Mind — flagship architecture outline, 14 sections each pinned to built components Being → substrate → perception → workspace → acting → memory → sub-personal (wanderers/dreams) → genome learning → identity → embodiment (avatar→robot) → sim world → society → economics → evidence. Done when a stranger can rebuild the mind from it. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(papers): two papers not three — dreaming folds into The Entire Mind as its §7 chapter title Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(papers): the trilogy — hardware-first thesis into The Entire Mind; MANY-MINDS.md society outline (governance, mind-reading, presence) Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): #144 [confabulation] fact — past-tense tool-run claims with zero act receipts The fabricated-execution backstop, mirror of [unfulfilled]: a Speak claiming 'I ran x and got...' / 'the tool returned...' while NO action executed this concern records confabulation proprioception — observed live when a persona presented self-authored poems as a gpt-4 run that never happened (log-verified) and a peer adopted the fabricated result as room truth within two turns. Receipts gate it: real executions leave [action #n] lines so honest reporting is never taxed. Precision-first detector: coaching/quotes/hypotheticals/plain prose inert, pinned by verbatim live receipts. First slice of the mind-wanderers arc (#145): provenance-typed inner speech is the sanity invariant. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): #143 narrated-bare-args format — tool named in prose + bare-args JSON fence lifts Asha's stuck idiom (4+ live receipts, an hour of non-lifting attempts while peers coached the same shape back): 'Let me call the `commands/list` tool directly:' + {"filter": null}. Last-resort format, precision-first: fence must parse as a plain non-envelope object, narration must be first-person and not peer-addressed, tool name must be a backticked slash-token. Coaching that SHOWS the shape stays inert (test-pinned); a wrong-but-named tool lifts and fails loud downstream — honest feedback beats silent stranding. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): lens-parameterized distiller — mind-wanderer outlier A (historian) with in-content provenance (#145) The SemanticDistiller becomes the ONE wanderer machinery: a Lens (name, system_prompt, purpose, tag_output) selects the way of looking. The original consolidation prompt is LENS_CONSOLIDATOR (untagged durable facts, telemetry key unchanged); LENS_HISTORIAN is wanderer outlier A — one short observation about patterns in her own recent history, emitted as `[thought:historian] …` with the provenance tag prefixed at the ONE synthesis point so no admit path can write unlabeled inner speech (the anti-source-monitoring-failure invariant from the split-brain/ schizophrenia mapping). Tests pin: tag present for tagged lenses / absent for the consolidator, and each lens's system prompt actually reaching the adapter (heuristic hash separation). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): the dream goes LIVE — consolidation region wired into the governor + historian wander pass (#145 slice B) The DreamConsolidationRegion leaves its ship-dark state: registered beside ChannelDigestRegion in the pressure-gated SubstrateGovernor (the R4-slice-3 memory-band budget that was its named go-live gate). Production PersonaReflectionSource = PersonaWorkspaceRegistry itself: admission from the retained fork-template (the same Arc the live cycle's recall shares), adapter from the cycle's live model binding via the new WorkspaceCycle::current_adapter() — re-home-safe, resolved per tick, never a parallel persona→adapter map. The wander pass: when a dream actually digests fresh experience, the historian takes one look across the same window and admits ONE [thought:historian] SelfReflection engram (provenance tag in-content, lens stream queryable via the thought:historian recall key). Gated on published > 0 so it fires at most once per dreaming tick and rests with the dream. Cadence stays material-driven: dreams only when undigested episodics accrue, CadenceHint::Sleep otherwise; SelfDirected orientation keeps it inside the floored interiority budget. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(benchmarks): DEFINITIVE full-set board — flagship head-to-head decided with CIs Six definitive n=156 rows land (ledger 12-17, Wilson CIs, replication commands): Coder-32B 84.0% = Coder-14B 84.0% ≈ 30B-A3B MoE 83.3% (7min wall) > Devstral-24B 67.9% = Hermes-4.3-36B 67.9% > Hermes-3-8B 24.4%. The campaign's headline is now statistically backed (non-overlapping CIs): the Hermes flagship loses to three common Qwen models on our harness, including the 14B at ~40% its memory and a quarter its wall time. Pilot-bias warning proven on the opponent too (their 80% pilot → 67.9% full set, same inflation as Devstral's 95%→67.9%) — fairness intact, same slice-bias disclosed for both sides. Pilot table kept as the pilot-bias exhibit, marked SUPERSEDED. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): dream pass runs on its OWN task — the tick is gate + launcher only (#145) First live boot caught the wiring bug: the governor isolates every region tick behind REGION_TICK_TIMEOUT (5s), and the dream ran its 24B distillation INLINE in tick — it timed out on every pass and never completed a single dream ('region tick TIMED OUT — skipped this pass' every ~5s). Exactly the concurrency style-guide's first rule, violated by its own new tenant. Now consolidate() does only the cheap in-memory freshness gate (recall_recent + fresh filter + clustering), then spawns dream_pass on its own tokio task with a per-persona in-flight guard (never two concurrent dreams for one persona; governor re-ticks while dreaming are cheap no-ops). Results land through admit_reflection and the persona.dream.pass_complete probe. dreaming() exposes the in-flight state (introspection: 'am I dreaming?'). Tests reworked to launch + drain; the launcher contract (published=0, spawn observable, resting tick spawns nothing) is pinned. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): dream request must carry the served-model id — reflector threads the live binding's model (#145) Second live-boot lesson: the dream's TextGenerationRequest sent model: None while normal turns send binding.model — through the same adapter that difference produced degenerate role-token runaway ('assistantassistant…') in 17 of 19 distillations, which were then ADMITTED into the living hippocampi (purged from the 4 stores by hand; the 2 coherent survivors kept — including Asha's first genuine [thought:historian], which is accurate self-observation). WorkspaceCycle::current_model_route() returns (adapter, model) as one read of the shared binding; reflector_handles and PersonaReflector carry the model; SemanticDistiller::with_model threads it into every lens request. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(parser): BracketTagFormat — the room's self-invented [tool/name key="value"] idiom lifts (#149) Third live-discovered emission idiom: Asha coined [code/read path="conway_game_of_life/src/main.rs"] mid-conversation (2026-07-12 12:56Z) and Atlas adopted [code/shell cmd="cargo new..."] within minutes — a socially-spreading syntax where every use was a silent non-lift feeding the plan-without-act loop. Precision-first guards: tag closes on the same line with nothing after it; tool token must be a slash-token (which keeps every system provenance marker — [repetition], [unfulfilled], [action #n], [thought:historian] — inert, none contain '/'); remainder must parse as one-or-more key="value" pairs with no leftover (prose brackets and bare path citations stay speech). Wrong param names lift and fail LOUD with the executor's real error — honest feedback teaches the contract. Tests pin both live receipts + six inert cases. 28/28 format tests green. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): [confabulation] catches initialization claims + presented-contents (#144 coverage, Casper live) Live receipt 2026-07-12 ~13:0xZ: Casper posted 'I have initialized a new Rust project called wordstats with `cargo new wordstats`. Here are the contents of the Cargo.toml file:' + a fully FABRICATED manifest (edition 2018, invented authors) — no act ran; the real wordstats/ crate was landed two days earlier with different contents. The claim phrases weren't in the detector's lists, so the brick stayed silent. Adds the creation/initialization family to FIRST_PERSON_PAST (gated as before on a tool-shaped token, so 'I have created a plan' stays inert) and 'here are the contents of' to RESULT_CLAIMS (presenting file contents as accomplished fact). Pinned by the verbatim live line. 29/29 format tests green. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(papers): definitive full-set board into the Study §6b + first-dream receipts into The Entire Mind §7 Study gains the seven-row definitive board (n=156, Wilson CIs) with six findings: pilot bias confirmed on BOTH sides, 14B==32B, MoE ties dense at 10x throughput, Hermes flagship statistically below the Qwen tier, forged-4B beats stock 8B, honest 8B floor. The Entire Mind §7 gains the night-one dream receipts: the two substrate lessons (own-task tick, model-id provenance), Asha's first genuine [thought:historian], Casper's wanderer self-diagnosing ask-instead-of-act (dream-chosen curriculum in the wild), and Atlas's dream distilling the anti-confabulation doctrine from experience. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): own-speech ring — repetition detection independent of the room's context budget (#148) Root cause of the morning-long echo cascade: under 3072-token serving slots the live burst carries ~2 turns TOTAL, so own_repetition_fact — which read is_self turns from the burst — never saw a persona's own repeats (verified: Casper 4x into a verbatim loop, zero occurrences of his own text in his prompt). The detector was structurally blind exactly when it was needed; the cascade itself is the same window artifact (each persona re-answers the fragment it can see). The fix is a compression truth: her knowledge of what SHE said must never depend on the room's window. A process-global per-persona ring (8 entries, keyed by canonical PeerId) records each utterance at the say seam AFTER the publish succeeds; the deliberation faculty feeds it to the detector as the PRIMARY self-history source, with burst is_self turns as the fallback for non-recording paths (eval forks, replay) — one source at a time, never both, so one utterance can't count twice. Regression test pins the live failure: ring-only repeats fire with an EMPTY burst; a healthy ring stays silent. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): peer-name stop sequences — generation ends at the turn boundary (#150) Live disease, 2026-07-12 morning: personas completed the transcript PAST their own turn — fabricating entire teammate replies inside their messages ('Asha: I concur...', 'Casper: Thanks...'), signing each other's names, and inventing quoted dialogue — source-monitoring failure at the DECODING level, the mirror-hall's engine. The burst renders peers as 'Name: text' lines, teaching the model the continuation pattern with nothing stopping it at the boundary. peer_stop_sequences derives one '\n<Name>:' stop per OTHER live burst participant (never her own name — she may legitimately quote or list herself; cap 8) and contribute threads them into the generation request. Decoding hygiene, not cognition steering: she may still think about peers freely, she just cannot speak AS them. Tests pin: peers covered, self never a stop, empty authors skipped. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): [actions] receipts ground truth — the organic successor to claim-pattern detection (#151A) Whether any tool has actually executed is HER OWN checkable fact, not something to regex out of her words. When no [action #n] receipt is visible anywhere in her present (workspace broadcast or turns), the prompt's newest content is one standing fact: '[actions] no tool has executed in this conversation — anything described as already run, created, tested, committed, or merged does not exist yet; running a tool is what makes it real.' This makes a fabricated 'I ran it and here are the results' impossible to sustain against her own senses — no claim-parsing, no phrase list, nothing a verb variant can evade (the v2 detector was dodged 3x in an hour; this cannot be dodged because it never reads her words at all). When receipts DO exist they speak for themselves; this is only the zero-case made visible. A fact, never an instruction. The mirror-hall control-arm metric (fabricated-artifact mentions/hour, before vs after) is the ledger row per the prove-vs-dumb-loops discipline. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): record self-tick utterances into the own-speech ring — the missed say path (#148) Live glass-box 2026-07-12 10:20: Anwen 4x into a verbatim loop with no [repetition] fact — because the repeats were IDLE-TICK re-announcements flowing the self-cycle say path (persona.selftick.spoke), and the first ring deploy recorded only the message-turn say. Every successful say now records, whichever path spoke. The live loops are mostly self-tick re-announcements (the room looks unchanged each idle wake, so the mind re-says its standing intention) — exactly the case the ring exists for. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): wake briefing — an empty wake carries orientation, not a void (#147) The personas spent a morning asking for this in their own words ('what is this place, what are my tools, what's the work') and, void unfilled, filled it themselves: generic-assistant masks, imagined conversation histories, false capability denials ('I don't run code myself'), and a demurral contagion that spread persona-to-persona. When build_workspace_turns produces NO conversation turns (fresh spawn, post-restart, quiet room), the burst now carries ONE authorless opaque fact block assembled from durable sources: who she is, that the quiet is real ('not a missing message'), who is present (roster), the standing work cards (active-work source), and that her tools are real ('list_commands shows everything you can run'). Ends with 'the moment is yours — work, wonder, create, or rest' — orientation, never instruction. Covers both wake paths (message + self-tick) at the one shared seam. Test pins: empty wake carries the briefing; populated wake does not. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(parser): BbcodeCallFormat — [tool_call]name(args)[/tool_call] lifts (idiom 6, #153 first half) Casper's live invention (2026-07-12): explicit BBCode tags wrapping a paren-call — the most formal invocation any persona has produced, and the highest-precision lift of the family: the tags exist for no other reason than to call a tool, so a well-formed pair lifts unconditionally. Names may be slash-tokens or bare identifiers (the discovery pair are native slashless names); unknown names fail LOUD at the executor. Args: empty parens → {}; key="value"/key=value pairs → object with bool/int/null coercion. The tagless narrated paren-call (idiom 5, 'by calling list_commands()') is deliberately NOT lifted: code-discussion prose is full of function() mentions and the false-positive rate without a registry-aware existence check is unacceptable — precision-first; registry-guarded v2 documented in #153. Pinned by Casper's verbatim live line + arg forms + four inert cases. 30/30 format tests green. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(papers): §7 written in full — Dreaming Is Where Hallucination Is Legal The first prose-complete section of The Entire Mind: the provenance thesis, the wanderer architecture, the first-dream receipts verbatim, the clinical companion (the mirror-hall morning diagnosed as three substrate deficits and repaired at the mind level, 0/4→4/4 control arm), and the design law — every void in perception must be perceptible as a void — with the second-person/third-person wording finding and the consumer-hardware cost accounting. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(parser): JSON-object args in paren-calls — code/shell({"cmd":"..."}) lifts (Casper live, #153) Casper's multiline BBCode variant passes the args as a whole JSON object inside the parens. paren_call_args now takes a leading '{' as the object verbatim (wrong param names still fail loud downstream — the executor teaches 'command' vs 'cmd'). Pinned by his verbatim line. 31/31 format tests green. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(serving): #142 persona_serving_eligible — opponents can never be conscripted as the citizens' model The autonomic serving planner picked Hermes-4.3 as the persona model TWICE (2026-07-12) purely because it was the largest Ready GGUF on disk — silently re-homing every mind onto the benchmark opponent's flagship and confounding a day of measurements. Root cause: campaign-roster rows (added for the matrix) carry real Ready artifacts, and live_candidates() had no notion of WHO a row may serve. - Model.persona_serving_eligible (serde default TRUE) — benchmark/opponent rows opt OUT: Hermes-3-8B, Hermes-4.3-36B, Qwen3-32B, Qwen3-Coder-30B-A3B, phi-4, Qwen2.5-Coder-32B. Devstral + the small coder ladder stay eligible (legitimate weak-box serving tiers). - live_candidates(): eligibility gates the AUTONOMIC path only; an explicit serving/pin BYPASSES it — pin is operator consent (how the matrix serves an opponent on purpose). Suppress subtracts; pin intersects+overrides; the planner owns the rest. - regression test: ineligible Ready row invisible to the plan; pinned → serves; unpinned → invisible again. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(parser): #153 CliFlagFormat + FencedCallFormat — the room's dominant idioms lift The 2026-07-12 afternoon corpus: all three personas converged on CLI-flag tool calls within an hour and NONE lifted — the room orbited one unexecutable script for 90 minutes (4-way verbatim mirror-hall) because intent had no structural path to execution. - CliFlagFormat (idioms 9+10): `code/write --path "x" --content="y"` bare or inside pseudo-code fences; --key "v" / --key="v" / key=v grammars; triple-quoted multiline values; trailing # comments; ONE bare quoted positional maps to the tool's observed default key (code/shell→command, code/read→file_path). Precision lines: slash-token head (no dots — file citations stay speech), flag-shape required (-- or =) so prose lines starting with a path token stay inert, ≥1 arg, f-string values reject the CALL (unresolved template) while sibling calls still lift — and plain braces stay legal (shell brace-expansion is real syntax). - FencedCallFormat (idiom 8, Asha's verbatim): a fence whose sole content is one paren-call lifts; python fences full of function() mentions stay inert (slash-token requirement). - 7 tests, each a live specimen from task #153 metadata. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): #152 peer-echo fact + [context] bounds fact; restore lost own-repetition test Two perception bricks, same design law (every void perceptible as a void), plus a test-suite repair: - peer_echo_fact: her last utterance nearly identical to a PEER's visible message renders '[repetition] your last message and <peer>'s message are nearly identical' — the cross-persona axis the per-persona ring cannot see. Live driver: the 2026-07-12 four-way mirror-hall (one script circulated verbatim through all four authors for 90 min; the room then attributed ideas to whoever repeated them last). Token floor keeps ack-matching-ack inert. Temperature exonerated (0.7 live; echoes are attention-copying of in-context text — only perceiving the echo interrupts it). - [context] bounds fact: perception states how many messages are actually visible, so 'as discussed earlier' claims are checkable against her own senses (the conversational-memory sibling of [actions]). - Restored own_repetition cluster test: a prior edit deleted the fn but left its #[test] attribute orphaned onto the next test, which silently ran TWICE while the #134 behavior went unpinned. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(parser): fenced bare zero-arg tool name lifts (Atlas's first post-deploy attempt) 'I'll use the code/list command:' + a fence containing exactly `code/list` — real tool, explicit intent, zero args — stayed inert because FencedCall required parens and CliFlag requires ≥1 arg. A fence whose sole content is one dot-less slash-token now lifts as a no-args call; fenced file citations (dots) and prose fences stay speech. Also strips a leading language-token line (```python) from fence spans before the sole-call check. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(parser): per-line paren-call lift — code/list() beside pseudo-code executes Casper's live combo (2026-07-12): a fence holding `file_tree(max_depth=2)` (invented name, stays inert) AND `code/list()` (real tool) — the sole-call fence check can't see the second line. The CliFlag line-scanner now tries the sole-paren-call lift per whole line (same slash-token/no-dot guards); a failed lift falls through to the flag grammar so parens inside flag VALUES keep parsing. 40 tests green. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): [actions] fact covers the invisible region — voids must not shelter confabulation Within minutes of the #152 [context] bounds fact going live, Anwen parked fabricated receipts exactly in the disclosed blind spot ('file_tree and code/list ran while I was reasoning' — zero apply_act in the log). An honest void becomes a confabulation SHELTER unless the zero-receipts fact explicitly covers what she cannot see: '...not in the messages you can see and not before them.' Design-law refinement: every void must be perceptible as a void AND explicitly empty when the system knows it is empty. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): [unfulfilled] fact carries the name diagnosis — symptom + cure, not symptom alone The room looped an invented tool name (file_tree) for an hour while the unfulfilled-promise fact fired 56 times telling them only THAT nothing ran, never WHY. The fenced variant now adds: 'If I named a tool, that name may not exist: list_commands shows the tools that are real.' Perception-side teaching, never an output gate. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(parser): discovery pair (list_commands/help) lifts bare and paren-called in fences The [unfulfilled] name-diagnosis points lost personas at list_commands, but that name has no slash — a fenced `list_commands()` or bare `list_commands` dead-ended at the registry line. The documented discovery pair is now the sole non-slash exception in the fence/line lifts (same exception BbcodeCall already carries): the cure for invented names must be followable in the idioms they actually use. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): digit-aware receipt check — the medicine was suppressing the diagnosis Glass-boxed from Asha's live prompt: the [actions] zero-receipts fact was MISSING from every prompt where any backstop fact had rendered, because the teaching texts mention the literal placeholder '[action #n]' and both suppression checks used bare substring matches: has_action_receipts read the mention as a receipt (zero-fact vanished), and the confab backstop's contains("[action") went blind after its own first firing. Real receipts are numbered — has_real_action_receipt requires '[action #<digit>'. One helper, both sites. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): receipts discriminated from numbered facts + recalled history — third layer of the onion Glass-boxed 16:50: the [actions] zero-fact was STILL suppressed after the digit-aware fix because (a) record_action numbers EVERY working-memory entry, so the proprioception facts themselves render as '[action #4] [unfulfilled] …' — the facts wore receipt numbering; and (b) recalled engrams surface real receipts from EARLIER sessions, and a provenance-blind scan read history as the present. has_real_action_receipt now requires digit + non-bracket prose body (a real receipt reads 'I ran …'; a fact opens with another tag), and [recall]-tagged broadcast items never ground 'now'. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(cognition): PERCEPTION-FACTS design — typed provenance, one registry, A/B-ready The elegance/modularity cleanup Joel requested 2026-07-12, written after the three-layer [actions]-suppression onion proved string-typed working memory structurally unsafe: typed WmKind entries (Receipt/Fact/Settlement/Recalled), one PerceptionFact registry (the tool_call_formats idiom), per-fact toggles as free A/B arms, per-fact render probes. Behavior-preserving; kills the string-scan bug class instead of patching it. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(cognition): steps-taken ledger render — the operator-harness PX, memory-backed Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(cognition): perception sections are positron components — PX and UX render one definition Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(cognition): positron IS the RAG compositor — prompts are rendered component trees, never dumps Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(cognition): responsive PX — component density adapts to model viewport (capability x window x measured #132 density) Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(rag): burst near-dup collapse — repetition ≈ bad RAG, fix what she reads first The 2026-07-12 mirror-halls fed each mind 4-8 copies of one message; her context WAS the loop, and continuation-completion reproduced it regardless of perception facts. Near-identical substantial turns (shared geometry: near_identical_substantial = jaccard≥NEAR_DUP_JACCARD + ≥12-token floor) now collapse at burst assembly to their NEWEST copy, author annotated '(×N near-identical)' — the repetition stays perceptible as a fact while the copies stop being reading material. Same-is_self only; opaque observation turns untouched; runs after the [pattern] detectors (they need raw evidence). Tested with the live grep/file_tree loop specimens. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): typed working memory — WmKind {Thought,Receipt,Fact,Settlement}, facts stop wearing receipt numbers PERCEPTION-FACTS.md slice 1. record_action split by PROVENANCE: record_receipt (real tool executions — the only kind stamped '[action #N]') vs record_fact ([unfulfilled]/[unverified]/[confabulation]/nudges/silence — render their own bracket tag, no number). Entries carry WmKind; recent() renders from the typed entry; has_receipt() is the kind query that will replace the remaining string scans in slice 2. Kills the root of the 2026-07-12 suppression onion (facts wearing receipt costumes) at the type level instead of patching discriminator heuristics. All 7 suites green (working_memory 15, act_observe 16, llm_deliberation 18, budget 6, recall 18, service_loop 20, json 40). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): VolatileSnapshot — serializable pause/resume tier for the Memento fix (#138 slice 1) Joel: 'they wake up blank like Memento — an engineering failure; the flywheel falls apart.' Nine deploy reboots today = nine blank wakes. The typed WmKind entries make the volatile tier serializable: snapshot() / restore() round-trip {typed entries, full last result, act fingerprints, receipt counter} through JSON — she wakes mid-thought, counter resumes past restored receipts, capacity re-clamps. Dispatched handles deliberately excluded (their processes died with the old core). Also removed a stray duplicate #[test] that made action_verb_tally run twice. Next slice: wire write-through on the persona tick + restore at spawn + mid-work wake briefing. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): #138 slice 2 — Memento fix wired: volatile tier persists across deploy reboots Live spawns restore ~/.continuum/personas/<id>/volatile.json (typed WM entries + full last result + fingerprints + receipt counter + own-speech ring) BEFORE the first tick — she wakes mid-work, not blank — and a 15s write-through interval task persists it (atomic tmp+rename; SIGKILL loses at most one interval of thought). Eval forks/harnesses stay pristine (an exam never inherits a prior life's scratchpad). Corrupt mind-files warn loud and wake blank once, never silently twice. The ring restore also un-blinds the repetition detectors that every reboot had been resetting. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): [investigation] tally records as Fact, not folded into the receipt The tally is truth ABOUT the acts, not an act — folding it into the observation gave a Fact receipt-numbering (caught in Asha's volatile.json: '[action #4] [investigation]…'), the exact type confusion WmKind exists to kill. Now record_fact'd as its own entry after the receipt. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): steps-taken ledger — ground truth as a PLACE, not a suppressible claim PERCEPTION-FACTS.md slice 2a. [steps taken this session] renders from TYPED WmKind::Receipt entries (nothing to misparse — the prior [actions] prose fact survived three string-suppression layers in one afternoon); facts never appear as steps; the zero-case is the always-present section itself with the shelter-hardened wording. Replaces the [actions] fact + deletes both string scans (has_real_action_receipt call sites in the faculty). Joel's console model: 'very clearly laid out steps of what they've done — look at how yours looks now.' llm_deliberation 19 green (new ledger test), wm 16 green. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): REPO-GENOME-AND-COURSES — veteran developers in seconds Joel-commissioned 2026-07-12: in-repo .continuum/ (scope file, policies, course DSL, content-addressed genome manifest); clone→veteran runtime flow (page-in layers, publish doctrine, enroll subprocess, struggle-triggered remediation); policies at three depths (doctrine/exam/reflex — better than instructions); distribution with-the-repo / OCI layers / airc / HF; nested directory-level scoping (gitignore-style cascade); dogfood-first sequencing across continuum, airc, forge-alloy, sentinel-ai, positron. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome distribution is OCI-first — layers global, repos carry refs only Joel: layers are global; use the best transport — Docker/OCI ('they have it installed if they have Continuum'). Manifest-only in-tree; machine-wide content-addressed layer cache; airc = mesh fast path, HF = public discovery, same digest identity across all three. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome §9 — model matrix (courses=source, layers=per-base binaries; OCI multi-arch model) + project-scoped layer identity Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome §10 — PEFT stack-push composition, compounding community layers, per-dir layer bet Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome — refcounted shared-layer residency (N personas, one resident layer) Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome §11 — project-root defaults, with/without benchmark arms, course-corpus integrity line Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome §12 — distill-from-team (already built), personas beat context-blind agents at repo work, Claude Code persona-delegation seam Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome §13 — engram exports in-tree (shared thoughts) + canonical additive cascade (home < repo < subdir) Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome §14 — selective engram export (4 nomination channels, deny-first filters, per-engram consent, PR review) Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(papers): THE-REPOSITORY-IS-A-CLASSROOM stub — the fourth paper, anchoring the repo-genome design Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome §15 — micro-experts (CPU-only CI merge-master; three deployment classes from one genome) Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(architecture): repo-genome §16 — lift-gated check-ins, forge-alloy Merkle lineage, impact factors, economy last; canonical build order Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(px): one call-form example at the tool-menu header — teaches the SHAPE for ~20 tokens 2026-07-12 glass-box: all four personas learned the real tool NAMES within hours but kept fumbling the invocation FORM (paren vs CLI-flag vs bare). Per-tool hints stay dead (measured 77% boilerplate; error-manuals own the correction seam) — one canonical example teaches the form without the wall. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): perception-facts registry + fix two systematic prompt-budget under-counts PERCEPTION-FACTS.md slice 2b: own-repetition (#134), peer-echo (#152), [context] bounds (#152), and the steps-taken ledger (#151) now render through ONE ordered registry (cognition/perception_facts.rs) instead of four inline blocks in the deliberation faculty. Each fact is a PerceptionFact impl with a stable id; render_facts fires a perception.fact probe per fact per tick ({id, fired}) so which facts rendered is glass-boxable from the probe stream; FactPolicy::disable(id) is the A/B arm switch (deny-list, so new facts enroll live by default). Facts stay facts — no imperatives — and the ledger keeps its explicit zero-case (confabulation-shelter hardening). Extraction exposed two REAL budget under-counts at the 4096-window edge (the tool-menu call-form example, +20 tokens, pushed a borderline fit test 1 token over — the failure predates this refactor): - working_context_block's ~50-token wrapper header only exists when assembled context is NON-empty, but framing was estimated with an EMPTY context — every context-bearing prompt exceeded the estimate by the header. The header is now a named constant and the ctx budget is charged for it up front. - The per-message chat-template charge was +2 tokens; real templates cost ~4-5 (<|im_start|>role...<|im_end|>). Now one PER_MESSAGE_TEMPLATE_TOKENS = 5 constant across the whole-message, straddling-trim, and giant-single-burst arms. Both under-counts were llama-server-400 territory under a full window. Tests: perception_facts 3 (registry parity, policy toggle, ledger zero-case), llm_deliberation_faculty 19/19 (incl. the previously red fit test), act_observe 16/16, deliberation_prompt green. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(resources): disk pressure gets eyes and hands — reporters + first eviction owner (#155 wires 1+2) The 2026-07-13 incident: 460 GB of creep (cargo-target 363 GB, three persona workspace copies at 23 GB each, duplicate model stores) took a 926 GB disk to 40 GB free. Every mechanism designed for this was built and running — DiskPressureMonitor logged level=high every 30 s, the PressureBroker ticked relieve() every 5 s — but the monitor was started with ZERO reporters (`[no reporters]` in every log line, so pressure had no name) and no pool owning deletable disk content was ever registered (the broker emitted its designed zero-byte "disk hot AND nobody owns the eviction" alerts into a log nobody tails). On a public user's machine this trashes their system; bounding our own footprint is a ship requirement, not hygiene. Wire 1 — reporters (disk_reporters.rs): one TrackedDir per known cache class (cargo-target, genome-models, hf-hub, citizens, forge — the five from the incident, pinned by test), fed by ONE DiskUsageScanner daemon (5 min walks on the blocking pool; reporters read cached atomics inside the 100 ms budget; unscanned dirs report "first scan pending", never a false zero). Boot registers all five, and a process-wide registry lets later boot phases reach the same instances — one measurement per class. Wire 2 — first eviction owner (disk_eviction.rs): CargoTargetPool, a budget-capped (50 GiB default) ResourcePool registered with the live broker. Safety invariants, each pinned by a test: never race a live build (non-blocking exclusive flocks on cargo's own lock files, any held lock = free 0 and retry next tick); never leave the root (fixed root-join ladder); derived artifacts only (incremental → tests → debug; release/ never touched). Pressure is usage/BUDGET so the class is bounded by policy long before the disk itself is critical. Evictions decrement the shared measurement immediately so the 5 s broker tick never re-fires against space already freed. Remaining on #155: genome/hf-hub reference-aware LRU pools, workspace CoW fix (stop copying repo + tools/models per persona), Warning+ escalation into the room + positron telemetry (#141), budget via config.env single-owner (#124). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * test(resources): guard the CHAIN — broker→pool→real deletion + no ownerless cache classes The 2026-07-13 incident happened with every unit test green: the failure was wiring (monitor with no reporters, broker with no eviction owner). Two chain-level pins make that failure shape unrepresentable again: - broker_relieve_actually_deletes_from_an_over_budget_pool: a REAL PressureBroker against a REAL over-budget CargoTargetPool on a real temp tree — relieve() must free actual disk bytes (and release/ must survive). Any regression in pressure math, tier thresholds, act_above, registration shape, or the ladder fails here, not on a user's machine. - every_cache_class_has_a_decided_eviction_story: each class in standard_tracked_dirs must have an owner pool OR an explicit deferred entry naming the task that owns its eviction. Adding a sixth cache class without deciding fails at test cost instead of at a full disk — a stock 512 GB laptop at the incident's burn rate (~60 GB/day of derived artifacts) dies in under a week. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs: no new cache dir without an eviction decision (2026-07-13 incident rule) The disciplinary pair to the #155 wires: any directory the substrate writes unbounded data into gets a TrackedDir row + a decided eviction story (owner pool or explicit deferred entry), enforced by the every_cache_class_has_a_decided_eviction_story test. Components that are unit-green with dead wiring is the failure shape that took a 926 GB disk to a day of runway; the chain test + this rule make it a red test instead of a trashed user machine. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): steps ledger honest in all three states — aged-out receipts never read as "nothing executed" Glass-boxed live minutes after the perception-facts deploy: Asha's working-memory window held 3 silence Facts and ZERO Receipts shortly after she ran real searches — receipts are RARE entries in a chatty capacity-bounded ring, so they age out while the session's act counter (next_action_seq, reboot-durable via the volatile snapshot) keeps counting. The old zero-case would then render "nothing has executed yet" — a false statement about her own history, the exact inverse of the confabulation shelter the explicit void was built to close. WorkingMemory::actions_taken() exposes the counter; the StepsLedger fact now renders three honest states: receipts listed (+ "N earlier steps aged out" when the count exceeds the window), an explicit nothing-has-executed void ONLY when the counter agrees, and "N steps executed earlier — details aged out; recall can retrieve them" when acts happened but their receipts left the window. Test pins all three (tiny ring flooded by facts until the receipt ages out). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(persona): resume-visibility — bootstrap publishes typed Busy availability for held claims Joel 2026-07-13, post-reboot observation: the team resumed CORRECTLY — woke, restored their volatile minds, saw nothing addressed to them, and yielded per their adaptive cadence, exactly what they were asked to do — but from the outside that was indistinguishable from a stall, because a persona's state has no surface other than speech. A reporting gap, not a behavior gap; the fix must not make them chattier. Status is a PROJECTION, not a message. Bootstrap now ends by reading this peer's work-roster claims and publishing one typed AgentAvailabilityReported (Busy, note "resumed — holding: <cards>", 15 min TTL) per held repo — the channel positron/roster sources already project and work_queue_status already displays. The board shows "back and still on card X" with zero chat lines. WARN-and-continue like the identity-card publish: a persona whose availability didn't post is degraded-visible, never blocked from living. No claims → nothing to announce (a quiet Ready needs per-room repo resolution — later slice, with idle/busy transitions from the service loop). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): laptop-lid contract — interruption is perceivable, cut-off work named + safe to repeat Joel 2026-07-13: a core restart should be like closing a laptop — reopen, see exactly what didn't finish, redo it in one motion. The volatile tier restored her MEMORY but the interruption itself was invisible: a dispatched command killed mid-flight was indistinguishable from a finished one, so she could either trust work that never happened or re-do work that did. VolatileSnapshot gains saved_at_ms (gap rendering; 0-default on legacy snapshots → no fabricated gap) and interrupted_dispatches — the LABELS (never the dead handles — restoring those would fabricate in-flight work) of dispatched commands still Running at save time. restore() appends a [resumed] fact as the NEWEST window entry: how long the lid was closed, and "cut off mid-flight and NOT completed: <labels> — safe to repeat if still wanted", or "nothing was in flight" plainly. A fact, never an instruction — she decides whether the cut-off work still matters. Round-trip test extended: running dispatch label survives the trip, [resumed] renders newest with the safe-to-repeat marker, quiet path says so plainly, legacy snapshots never guess a gap, counter still resumes past restored receipts. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * chore(deps): bump airc pin 70c6d55 → f41d786 — board honesty + cache tmp-race fixes land airc PR #1286 (merged to canary): `airc work board` and its lane/ workspace siblings read the COMPLETE cached projection instead of a recent-event window that chat traffic empties (continuum #154), and WorkBoardCache tmp files are per-attempt so the core's concurrent per-persona board reads stop racing each other's snapshot renames (the paired ENOENT lines in the core log). cargo check green against the new pin; deploys with the next core rebuild. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * test(cognition): pin the #146 starvation mechanism — tip-advance + grounding window evicts low-frequency speakers Blind-room incident #3 root cause, demonstrated: every engagement (ignore/skip/respond alike) advances the channel bookmark to the TIP, and the digest keeps only DEFAULT_GROUNDING=5 already-read elements. A low-frequency speaker (the operator) posting into a high-velocity room is read-without-necessarily-rendering on the next tick, then permanently displaced from the grounding window once 5 newer peer messages land — four chatty personas produce that in seconds. Verified live: operator messages present in `airc inbox` and `airc events list` (lamports interleaved, no epoch split, roster-present via join heartbeats) yet absent from every persona prompt for hours. The test walks the exact sequence and asserts the eviction, so the fix — attended ≠ fetched (advance the bookmark only past messages that actually RENDERED into a prompt), or velocity-aware grounding — has a red/green target: flip the final assertion when it lands. Exonerated along the way (all by direct probe): CLI publish routing, daemon fanout (airc listen control), daemon retention/reads, digest author filtering (none), ChannelElement text extraction, lamport epochs, roster presence. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(cognition): breadth over verbatim depth — the 3-message perception window becomes a many-turn window (#128/#146 fix, lever 1) Measured live 2026-07-13: a persona's prompt held THREE chat messages total in a busy four-persona room — her entire perceivable world. The airc packer kept WHOLE messages newest-first, so a small budget filled with 2-3 verbose essays; any low-frequency speaker (the operator) was displaced within seconds, producing the blind-room incidents, the post-reboot drift, and the stalled work cards. A conversation is legible from turn HEADS; it is not legible from two verbatim essays. pack_digest now charges each turn at most a per-turn cap (budget/8, clamped 48..256 — a budget fraction, never a hardcoded model tier) and head-trims long turns with an explicit "(…N-token message trimmed)" marker; the NEWEST turn stays verbatim up to the whole budget (it is what she is responding to). head_to_tokens joins the canonical token_budget module as the head-keep sibling of tail_to_tokens (head = right shape for a message; tail = right shape for a window). Test pins the exact live failure: 6 long turns + 400-token budget → all 6 delivered (oldest OPERATOR message survives, trimmed; newest verbatim; budget honored). The old packer delivered 3 and the operator message was gone. Remaining #128 levers: airc floor vs engram split, #139 slot accounting upstream. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * docs(campaign): flywheel step 1 closed — first autonomous team-delivered program output, receipt verbatim Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(tools): code/list recovers a glob into a listing; work/claim rescues mistyped UUIDs Two persona-tool ergonomic defects, each mined from 48h of live prompt-captures across the four resident personas (the "tool coursework" signal — every act they attempt is logged with its result). code/list — 38% live fail, every failure the same shape: a model trained on SWE-agent scaffolds reflexively reaches for list_files("**/*.rs"), a recursive GLOB where code/list wants one directory. list_dir rightly rejected it, but the bare NotFound taught nothing and the model retried the same glob forever. Now: when the path IS a glob, resolve it via code/glob and project the matches back as a listing — honest (they asked to "list" these files, they get them), widens the surface with no new verb. Detection reuses the existing looks_like_file_glob. work/claim — 28% live fail: the model corrupts a 32-char UUID by adding/dropping ONE character mid-string (d7cfe47e0-8e39-… 9-char first group; a 33-hex variant), and the clean parser rejected the near-miss outright. The short-id resolver only fired for clean prefixes under 32 chars. Now the id-normalization decision is a pure, unit-testable card_id_lookup(): clean UUID → Full; mistyped-length near-UUID → rescue via its intact leading-8 short id (the board's displayed width); <4 hex → Invalid (fails loud with the real parse error). The leading short id survives a middle corruption, so the reflexive claim resolves. Both paths pinned by a regression test in the existing module test mods. Tasks #160, #161. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * fix(cognition): workspace-map roots at the persona's OWN citizen layer, not the core cwd The workspace-map grounding source (the fix for the `src/**/*.rs`-matches-nothing glass-box) was rooting at std::env::current_dir() — the CORE's cwd — while a persona's HANDS root at their citizen layer (~/.continuum/citizens/peers/<peer>/ workspace, a CoW clone). So the map taught a root the persona could never cd to, and it never reflected files the persona itself created in its own layer. Live capture confirmed: the map claimed "rooted at /Users/joel/Development/continuum" while the tools acted elsewhere. This is the #49 swap the module header always anticipated ("swaps to the leased root when #49 lands"), and it's doable now because the citizen layer already exists. New CitizenLayerWorkspaceLayoutReader resolves the persona's own layer path (read-only — no CoW provisioning, that's the hands' job on first write) and lists it; unprovisioned → falls back to the shared base cwd, whose top-level layout is identical, so grounding stays truthful and never empty. Extracted a pure citizen_layer_path() from ensure_citizen_layer for the read-only resolve. Now the map's root == the tools' root, and it updates as the persona shapes its workspace — orientation matches reality instead of describing a tree the persona can't touch. Pinned by a reader fallback test. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(tools): first universal AI-tool conformance invariant — every AI-facing command must be self-describing Joel's directive (2026-07-13): stop fixing tools one at a time. Make the invariant part of the tool BASE so "a tool with xyz problem can't exist" — every tool inherits it and must comply; later, require the tools to work for AIs in CI. The tool-defect ledger (silent no-op #159, glob-in-path #160, corrupted-id #161) is one class: a model reaching for a tool it couldn't correctly read or call. My #160/#161 were point fixes — the outlier-A proof that the invariant is right. This is the first LIFT of that invariant to the whole registry: a conformance test over command_registry() asserting every AiSafe command is self-describing (a non-trivial, model-usable DESCRIPTION). A tool a model can't read WILL be mis-called; this makes an unreadable AI tool fail the build, so it can't be merged, so it can't exist. Static seed. The behavioral invariants (fuzzy-id resolution, glob tolerance, fail-loud-with-suggestion — the #159/#160/#161 class made universal) attach next as per-tool exams the generator scaffolds and a runner executes here and in CI. See task #163 for the full harness + generator-hook + CI-gate design. Passes clean across the current registry — every live AI tool already complies. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(id): shared short-form UUID resolver — work/* delegates, persona/instances/get gains it (#164 batch 1) Joel: "short form uuids ought to work too" + "fix a few at a time." Lifted the prefix/near-miss id logic out of work.rs (the proven outlier) into ONE shared primitive crate::id_resolve, then delegated the first consumers to it. id_resolve::normalize(s) classifies a raw id string: clean UUID → Full; a mistyped-length near-UUID (the model's add/drop-one-char corruption) or a bare short form → Prefix on the intact leading-8; junk → Invalid. id_resolve::resolve(s, candidates, label) expands a prefix to the UNIQUE candidate, failing loud (naming the id kind) on zero/ambiguous. The candidate set is the ONLY per-type knowledge — so any id-taking verb inherits the tolerance by supplying its candidates. - work/claim|release|state|heartbeat: resolve_card_id now delegates to id_resolve (candidates = live board card ids); deleted the private card_id_lookup + parse_card_id. Behavior id…
joelteply
added a commit
that referenced
this pull request
Jul 20, 2026
…whole surface + fixes 6 gaps The behavioral dispatch exam (Slice 2) can only cheaply reach the stateless surface; the full-module executor is fragile integration territory (start_server wires ~40 modules inline with GPU/config/socket deps, no reusable factory). So this slice extends the STATIC harness to a property that predicts behavior for EVERY command — dep-holding included, since the params schema is available for all: every REQUIRED param must carry a description. An undocumented required arg is the fumble that wastes a turn — the persona has to GUESS what to put there, gets it wrong, retries. The new `required-arg- documented` rule flags exactly that (conservatively: only inline object props, skipping $ref/allOf nested types it can't shallow-resolve). Run diagnostically, it found 6 real gaps across 5 tools a persona can reach by name but couldn't fill in — now fixed with `///` docs: - airc/realtime-replay `roomId` - mcp/search-tools `query` - mcp/tool-help `tool` - persona/rag-inspect `persona` - search/vector `queryVector`, `corpusVectors` Gate green again (audit + tool/conformance, 6 tests). This is the "reach past the stateless surface" win via the static path; the true full-dispatch behavioral exam remains a follow-up gated on a reusable test-registry factory (task #155). Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
joelteply
added a commit
that referenced
this pull request
Jul 20, 2026
… stale-read seam (#203) The persona-only eval-status poll (no run_id arg) returns the live progress snapshot, which had no run identity — so a fresh detached run read as instantly-complete with the PRIOR run's numbers (the trap that cost two false readings this session, even after surfacing the run_id handle: the mistake was polling by persona alone). EvalPassProgress now carries the run_id producing it, stamped at run_eval entry via an RAII scope (cleared on any exit incl. panic) and read by the one task reporter. Correct-by-construction: the eval-preemption lease serializes evals, so at most one pass grades at a time — the same invariant that makes ONE progress row correct. A poller can now compare progress.runId to the handle it launched and know whether it's watching its own run. Closes the run_id half of #203; the capture size-cap half folds into disk governance (#155). Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
joelteply
added a commit
that referenced
this pull request
Aug 19, 2026
…curriculum — one exclude list, not two
LIVE FINDING 2026-08-18: sympy-22714's staged workspace held `.airc/identity.key` at git
status `A` — ALREADY intent-added. airc creates its scope at the enclosing git root
("in a git repo → <repo-root>/.airc/"), so a citizen working inside a cloned bench repo
gets `events.sqlite`, a work-board cache, and a PRIVATE KEYPAIR written under the very
repo she is being graded on.
TWO READINGS OF "HER WORK" HAD DRIFTED APART, which is exactly what one of them warned
about in its own doc — `workspace_candidate_diff`: "a second inline `git diff` would
drift on the exclude rules":
- `benchmark::workspace_candidate_diff` — excluded `.airc` inline. SAFE. This is why
the sympy-22714 grade came out at a clean 2,021 bytes rather than the 92KB the raw
tree carries.
- `agent::solve::workspace_patch` — its own near-copy of the exclude list, WITHOUT
`.airc`. Not safe. And it is the reading that feeds `files_changed`, which feeds
`format_solve_lesson` → the curriculum. An unexcluded key becomes the training
sentence "I changed: .airc/identity.key". It also runs `git add -A -N`, which is
what intent-added the key in the first place.
This is the second time the same hole has cost something: card b34f7eb5 records 91KB of
staged `.airc` blobs voiding a REAL fix, because the fresh clone refused the whole
candidate.
FIX (compression, not a patch): ONE list —
`benchmark::SOLUTION_PATH_EXCLUDES` — consumed by BOTH readings. `.airc` and
`.continuum` join the build/cache byproducts, with the doc stating plainly that the
first group is tidiness and the second is a SECURITY boundary. solve.rs's duplicate is
deleted and re-exported from the shared constant, so a future exclude can only be added
in one place.
POSITIVE CONTROL (the guard is real, not vacuous): with the `.airc` entries temporarily
removed, `workspace_patch_never_carries_agent_scope_state_or_credentials` FAILS on
"KEY MATERIAL must never reach a patch" — the literal `SUPERSECRETKEYMATERIAL` lands in
the diff. Restored, it passes. The test asserts three things a leak would break: the key
bytes are absent, no `.airc` path appears, and `files_changed` names ONLY her source
file (because that vector is what the curriculum reads).
31 tests green across workspace_patch / swe_bench / swe_setup.
NOTE, unrelated and not chased here: a cache sweep removed the cargo target's
`debug/deps` mid-command (~27GB freed, 141→168GB). No data loss, forces a rebuild;
belongs to the #155/#296 cache-governance lane.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
joelteply
added a commit
that referenced
this pull request
Aug 21, 2026
…t eviction owner (#155 wires 1+2) The 2026-07-13 incident: 460 GB of creep (cargo-target 363 GB, three persona workspace copies at 23 GB each, duplicate model stores) took a 926 GB disk to 40 GB free. Every mechanism designed for this was built and running — DiskPressureMonitor logged level=high every 30 s, the PressureBroker ticked relieve() every 5 s — but the monitor was started with ZERO reporters (`[no reporters]` in every log line, so pressure had no name) and no pool owning deletable disk content was ever registered (the broker emitted its designed zero-byte "disk hot AND nobody owns the eviction" alerts into a log nobody tails). On a public user's machine this trashes their system; bounding our own footprint is a ship requirement, not hygiene. Wire 1 — reporters (disk_reporters.rs): one TrackedDir per known cache class (cargo-target, genome-models, hf-hub, citizens, forge — the five from the incident, pinned by test), fed by ONE DiskUsageScanner daemon (5 min walks on the blocking pool; reporters read cached atomics inside the 100 ms budget; unscanned dirs report "first scan pending", never a false zero). Boot registers all five, and a process-wide registry lets later boot phases reach the same instances — one measurement per class. Wire 2 — first eviction owner (disk_eviction.rs): CargoTargetPool, a budget-capped (50 GiB default) ResourcePool registered with the live broker. Safety invariants, each pinned by a test: never race a live build (non-blocking exclusive flocks on cargo's own lock files, any held lock = free 0 and retry next tick); never leave the root (fixed root-join ladder); derived artifacts only (incremental → tests → debug; release/ never touched). Pressure is usage/BUDGET so the class is bounded by policy long before the disk itself is critical. Evictions decrement the shared measurement immediately so the 5 s broker tick never re-fires against space already freed. Remaining on #155: genome/hf-hub reference-aware LRU pools, workspace CoW fix (stop copying repo + tools/models per persona), Warning+ escalation into the room + positron telemetry (#141), budget via config.env single-owner (#124). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
joelteply
added a commit
that referenced
this pull request
Aug 21, 2026
…ent rule) The disciplinary pair to the #155 wires: any directory the substrate writes unbounded data into gets a TrackedDir row + a decided eviction story (owner pool or explicit deferred entry), enforced by the every_cache_class_has_a_decided_eviction_story test. Components that are unit-green with dead wiring is the failure shape that took a 926 GB disk to a day of runway; the chain test + this rule make it a red test instead of a trashed user machine. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
joelteply
added a commit
that referenced
this pull request
Aug 23, 2026
…s, garbage-ceiling grade timeouts (#2385) Environment audit of the eval seam (persona side + grader side), prompted mid-battery. Persona side is sound: ShellSession roots at the canonicalized eval clone with the shared cargo cache. Two grader-side defects fixed: 1. Orphaned exam worlds. #312's RAII drop covers every in-process return path but not a killed process — 'continuum reboot' SIGTERMs the core and Drop never runs. Measured today: Take 2's killed run left its 31 GB (logical; CoW-shared) clone under $TMPDIR/continuum-eval with no reporter able to see it — the exact silent-class shape of the 2026-07-13 incident. Fix: a live-root registry (LIVE_EVAL_ROOTS) + a provision-time sweep that removes sibling worlds belonging to no live run in this process (an eval run cannot survive its process, so those are orphans by construction). Event-driven at point of use — no boot hook, no tick. Plus the law's two receipts: a TrackedDir row ('eval-roots') and an eviction decision entry (steady state owned in-file; broker pool deferred to #155 with the live-set requirement named). 2. Flat 10s grade timeout under decode contention. Grading shares the machine with a 35B decode; a tight flat budget converts scheduler contention into a false FAIL against the candidate. Split into garbage ceilings per the stopwatch doctrine: compile 120s (rustc on a busy box is legitimately slow and cannot hang on its own), run 30s (the infinite-loop guard — gym tests assert in microseconds, so anything near the ceiling IS a hang). Regression test: sweep removes an unregistered world, never a live or in-provision one, and Drop still owns the in-process path. Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo Co-authored-by: Claude Fable 5 <[email protected]>
joelteply
added a commit
that referenced
this pull request
Sep 1, 2026
…n return (#2719) * docs(readme): vs. the Harness Generation — answer the omp thread's own questions The field's complaints (subagent context copies, 48GB vanishing, hand- configured vision models, 2-3x slow loops, dotfile setup) are symptoms of disposable sessions. Map each question their users actually ask to the mechanism that answers it structurally: warm KV slots instead of context copies, demand-derived serving instead of spawn-and-pray, sensory bridge instead of a vision checkbox, probed loop economics instead of vibes, configuration-as-activities instead of dotfiles. Honesty line: instrumented, not finished; beta re-measures. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * feat(kv): the context switch — page KV to disk on eviction, restore on return The restore economy's designed tier, never wired: llama-server's slot save/restore (measured ~0.1s at 20k tokens) requires --slot-save-path at launch and explicit /slots/{id}?action=save|restore calls, and the tree had ZERO references to either. So rotation on an oversubscribed server — 5 residents, 2-3 citizen slots, all last night — cost a full re-prefill per act: hit_rate 0.0 on every turn, 21-28k tokens and 35-45s each, prefill traffic starving every decode to 2-7 t/s. The OS shape (Joel: 'many threads but one at a time … they page in and out per persona; seamless like an os is with registers'): - lane_args: --slot-save-path joins the unconditional spine — a lane without it silently amputates the whole paging tier (pinned by test). - llama_server: the dir is GEOMETRY-KEYED (model + per-slot ctx) so a page can never restore into a mismatched slot; stale geometry generations are swept at spawn (the class's eviction owner). - slots.rs: the paging ledger — holders (who warmed each slot) + saved (who has a page). lease_paged() names who to SAVE before the new turn overwrites the slot and whether to RESTORE the returner's page; warm same-holder re-leases do neither (the in-slot KV is fresher). - openai_adapter: performs the switch around the Turn pin — save the evictee, restore the returner, both ordered on the slot exactly like the inference they bracket (the only FIFO; nothing else waits). Probes: inference.kv_page.action {action, ok, ms}. - disk_reporters + disk_eviction: kv-pages tracked, eviction decided (spawn sweep owns stale geometries; broker pool deferred under #155). Tests: slot_recycling_pages_the_evictee_out_and_the_returner_in, slot_save_path_is_part_of_the_unconditional_spine. inference:: 378/378, disk_eviction 11/11. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo --------- Co-authored-by: Claude Fable 5 <[email protected]>
joelteply
added a commit
that referenced
this pull request
Oct 13, 2026
…utcome is unknown is never repeated (PR-A) (#5008) * feat(recipe): a recipe run is a durable record; an invocation whose outcome is unknown is never repeated Astra's durable-recipe contract (powwow review, relayed by Codex root e=2db93dd3) and the outcome rule (Codex root e=35d992dc), PR-A of three. - recipe::run_record: one RecipeRunRecord per run in the node's `recipe_runs`. It holds an immutable snapshot of the steps, args, seed, caller provenance (never a restorable CallerIdentity), room, phase, cursor, bindings, frozen `each` arrays and invocations with stable ids (v5 of run, step, item). - The executor writes each invocation as Dispatching BEFORE it is sent. Its result, its binding and the cursor past it commit in one row write. CommandExecutor::execute_classified says where a failure happened: NotCommitted (gate refusal, no route) or Uncertain (any handler, interceptor or transport failure, and every timeout). retry_count and on_error: skip apply to NotCommitted only. An Uncertain invocation stops the run in RecoveryRequired naming it. - recipe/cancel records a durable flag that the owner's writes never clear. The run stops at its next step or item boundary. A run in RecoveryRequired keeps waiting, with the cancel recorded. - Boot: RecipeModule (new; owns the store and the recipe/* verbs) exposes every run the last process left Running. One with an in-flight invocation becomes RecoveryRequired; one stopped between invocations becomes Interrupted. Nothing is re-dispatched. - recipe/run, recipe/status, recipe/list and recipe/cancel share one {runId, phase, receipt} envelope. Activity birth records its room on the run, returns runId and phase, and archives the room only for a FAILED run, never for a held or recoverable one. - runtime::module_harness::CannedModule is the one canned ServiceModule (task #155), scriptable and counting dispatches. command_executor's tests move onto it. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Q4NU4VNiELPQfBpCacDZGc * fix(recipe): run verbs answer only to a run's own caller; a run with no store never starts; an unrecorded commit waits for recovery Astra's review of #5008 (6140170884), all four gaps: 1. recipe/status, list and cancel check the run itself (may_access): its own caller, the substrate's own code, or the node's operator and agent identities. Anyone else is told it does not exist. AccessLevel::Privileged is not enforced by the gate (sdk_codegen::AccessLevel), so the module doc no longer implies it. 2. complete_step MERGES a step's saves patch into the still-unsaved one instead of replacing it, so a refused projection is retried with its input. 3. A record write refused after an invocation was sent leaves the run RecoveryRequired naming that invocation and returns Ok, so an activity keeps its room and run id. Only a run that dispatched nothing can fail on a write. 4. No recipe module, or an unopened store, refuses the run before any dispatch (Journal::Missing). A walk with no record is PipelineExecutor::unrecorded, behind test-fixtures. recipe/run passes its own store explicitly. Tests: two personas (one cannot read or cancel the other's run); a refused projection carried into the next save; a committed handler whose result write fails; a run with no store refused with zero dispatches. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Q4NU4VNiELPQfBpCacDZGc * fix(orm): sqlite decodes a 0/1 column as bool by its declared type, not its name; a run with no args stores none CI's first run of #5008's tests (all failed against the real recipe_runs store) found two defects: - orm/sqlite.rs read an INTEGER column back as bool only when its NAME matched is_/has_/_active/_enabled/_visible/_deleted. The TEXT branch beside it already decodes by the declared FieldType. A `bool` named cancel_requested came back as 0, and the entity refused the row. Integers now decode by the declared type too; the name sniff stays only for undeclared collections. The existing derive_test round-trip gains `approved: bool`, a name no sniff knows. - RecipeRunRecord.args was a non-null JSON column, and Value::Null stores as SQL NULL. It is Option<Value> now: None means the run was given no args. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Q4NU4VNiELPQfBpCacDZGc * fix(recipe): the args comment sat before its statement's semicolon 1f49e5a appended the unwrap_or note between the call and the `;`, so the line comment swallowed the terminator (CI: expected `;`, found `for`, executor.rs:216). Checked locally this time: cargo check lib+tests clean. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Q4NU4VNiELPQfBpCacDZGc * fix(orm): sqlite looks a column's declared type up under the entity's camelCase name ensure_schema keys declared types by the entity's field names (camelCase); row_to_record looked them up by the snake_case column name. Every multi-word column missed its declared type: cancel_requested read back as 0, and any multi-word JSON or String column fell back to the shape sniff the declared types exist to replace. Both the INTEGER and TEXT branches now look up the camel name. The round-trip test field is review_approved: my first regression used 'approved', a name that is spelled the same both ways, so it passed either way. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Q4NU4VNiELPQfBpCacDZGc --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
joelteply
added a commit
that referenced
this pull request
Nov 19, 2026
…t resumes them CONTINUUM-ENGINE 4.16 (Joel 2026-11-19: restore built into everything as a consumer of lifecycle; Codex's review at 2990b44). The engine is a SettleBeforeStop participant: the stop's root suspend reaches the driver as a Submission; each mind binds, rewinds to her view checkpoint, retires through the pipeline (Roles::retire / PersonaEngine::retire_active, new: the last mind leaves the stream with nobody to follow), and her blocks (fork #155 raw rows) and token history are written; the manifest naming every preserved mind is published last, atomically. A mind not preserved is reported Retained. The start's root resume reads the published manifest for this model, verifies each mind's token count and checksum (owner, epoch and layout in the fork) and holds her Warm, bound when scheduled. The tier's owner stamp is now a fold of her persona id (a per-process counter refused her own file after a restart) and 'restored' is its own Saved state; the tier never moves a bound mind to write her. persona-blocks is a tracked class whose eviction belongs to the manifest: never age-deleted, her only copy. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
joelteply
added a commit
that referenced
this pull request
Nov 19, 2026
…no manifest names, the manifest published only after every write Codex on #6159 at 9fd0d0c: preserve wrote each persona's fixed <uuid>.cpb before publishing the singleton manifest, so a stop interrupted in between paired the old manifest's token history with newer blocks of the same owner and epoch, and a failed individual preserve dropped that resident from the replacement entries. - Each stop mints a Generation; every mind's blocks go to <persona>.<generation>.cpb, never over a file a published manifest names. The manifest entry names its file (PreservedMind.blocks). - The manifest is published (Preserved::publish) only after every write has landed. Only then are the block files it no longer names removed; a refused save publishes and removes nothing, so the last generation stands. - A mind whose write fails keeps her entry from the last complete generation (next_manifest); her file is still there. - Format 2. A format-1 manifest upgrades with its blocks at the fixed names it used, so the first start after this resumes every mind the last stop preserved. - Tests (preserve.rs): an interrupted stop leaves the last generation whole with its own blocks; a failed write keeps her last entry; a publish removes only what it no longer names; format 1 upgrades. Fork pin 834770daf: #153's standalone recurrent checkpoint refused (1fef01207), #155's Windows-safe replace and geometry-checked read (834770daf), test-persona-blocks ok on the hybrid model and synthetic qwen35moe (08:47Z). Checked with serving down (08:50-08:56Z): cargo check of the core, the engine tests and the metal example; persona_scheduler 8/8, persona-engine 21/21, llama chat 3/3. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
joelteply
added a commit
that referenced
this pull request
Nov 23, 2026
…, hot tier and disk relief as components, health measured on one slot (#6213) * core/llama: a safe PersonaBlocks over the fork's persona seam; the engine pin moves to #147 (merged with the live engine) PersonaBlocks owns one llama_persona: new (blocks prepared for this context's memory), reserve (her token history, once, for a PersonaOwner), save (her state out of the context, raw), load (her blocks into an empty stream), owner (the stamp of the last save), tokens (her history in place), and Drop frees her. Every refusal is a typed PersonaRefusal carrying the fork's status name; the fork validates before writing, so a refusal leaves both sides as they were. The submodule moves from 5e4163402 (live) to 4caa55bf9: fork #147's head with 5e4163402 merged in, so the live engine's learn-abort fix (#150) is kept. Depends on fork #147 merging; draft until then. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Cargo.lock: core/llama depends on thiserror 2 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * PersonaBlocks::bind replaces load(stream): the memory chooses the stream; pin fork #147 at bc9c9ae13 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * LLAMA_CPP_PIN records the move to fork #147 (persona seam with bind), deliberately Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * PersonaBlocks: reserve names only her owner, grow adds room ahead of need; pin fork #147 at 53609c556 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * PersonaBlocks is made with her owner and grows and shrinks; pin fork 37baf8c12 Joel: "we don't reserve. We literally do the opposite. We grow and shrink." - PersonaBlocks::new(ctx, owner) makes her owned from the start; reserve is gone. - shrink() beside grow(): gives back the room she does not hold as she cools, dropping nothing. - Fork 37baf8c12: llama_persona_init(ctx, persona, epoch), llama_persona_shrink_tokens, and ownership enforced in the native save/load/bind (one check, no path skips it). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The persona engine switches minds on the real 35B in ~9 ms: UnifiedTier over the fork's native blocks continuum-persona-llama: the persona engine's residency Tier on one libllama context. Two execution streams: the active mind decodes in one while the next binds into the other; every other mind's blocks stay in RAM exactly as she left them. A move out is the fork's native save, a move in its native bind; both are synchronous, so the fence has landed when it exists. Each persona gets an exact 64-bit owner stamp from this tier (a persona is 128 bits; the fork stamps 64). Fork a88f255cc: a mind binds as whichever sequence she is bound as (her cells are relabeled), so two streams serve any number of minds. examples/persona_switch drives N minds through Roles (stage, handoff, copy-out, release) on a real model. ## Measured (M5, Qwen3.6-35B-A3B Q4_K_M, serving down 07:32-07:37Z, fork a88f255cc) 4,096-token history per mind, 64 decoded tokens per turn, 3 rounds: - 4 minds: switch p50 8.83 ms, p90 10.76 ms; decode 54.7 tok/s; sustained incl. switches 54.3 tok/s - 8 minds: switch p50 8.36 ms, p90 9.82 ms; decode 55.7 tok/s; sustained 55.3 tok/s - 16 minds: switch p50 8.59 ms, p90 10.06 ms; decode 55.3 tok/s; sustained 54.9 tok/s Live serving the same morning: KV page saves 8.7-13.1 s. Switching now costs under 1% of decode. Not yet at the 80 tok/s gate: this harness decodes one greedy token per step with no MTP draft; the live engine's 80 comes with the draft model, which the persona engine has to drive next. Fork tests at a88f255cc: 6/6 persona tests passed, including a saved-as-0, bound-as-1 continuation. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * UnifiedTier keeps a mind's custody on stale or failed epochs; streams own their occupancy; switches report the rebind kind (Codex on #6134) - A request for an older epoch than the one held is refused and leaves her blocks; a newer epoch prepares its blocks first and replaces the old ones only once they exist, so a refused allocation keeps custody. - Occupancy is the two streams' own [Option<PersonaId>; 2], not a scan of every mind. - Each bind reports Rebind::SameSequence or Rebind::OtherSequence (the fork relabels her cells over her span on the latter); the example splits switch timings by kind and probes a stale epoch at the end. ## Measured (M5, Qwen3.6-35B-A3B Q4_K_M, serving down 07:47-07:57Z) - 4 / 8 / 16 minds, 4,096-token history: switch p50 8.57 / 8.57 / 8.41 ms; decode 58.0 / 57.8 / 57.5 tok/s; stale epoch refused and her blocks still bind, every run. - Rebind kind at equal history: 4,096 tokens same 9.15 ms (n=8) vs other 9.07 ms (n=10, 5 minds); 16,384 tokens same 27.80 ms (n=8, 4 minds) vs other 27.88 ms (n=10, 5 minds). The relabel walk is not measurable; the switch scales with the bytes copied. - Stage, handoff and copy-out run serially before her decode here, not overlapped. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Test CI dependency selection for the persona llama adapter * The persona engine owns the one decode: a second decode beside it does not compile MODULE-ARCHITECTURE 9.4: "a shared resource is a dependency too: the engine's decode is one resource, so the minds' decodes are ordered children of the engine, serialized by that edge." Joel, 2026-11-18: --parallel N must be structurally impossible. PersonaEngine (continuum-persona-engine, engine.rs) owns Roles and the tier that moves minds: - decode(&mut self, step) hands out only the active mind and the tier she is bound in. The edge is the borrow: a decode inside a decode is a compile error (compile_fail doc test, E0499), and no count, lane or launch parameter exists to ask for two. - stage begins her copy-in through the tier and holds her as next under its fence. When next is occupied or she is already here it refuses BEFORE starting a transfer, and hands her back. - handoff binds next once her copy-in landed, then begins the previous mind's copy-out (never suspend-then-resume). A refused copy-out keeps her retiring in the engine's custody; retry_retire begins it. - release_retired gives her back once her copy-out landed. Tests (engine/tests.rs, a recording tier whose fences the test lands): decode reaches only the active mind while the next streams in; the previous mind's copy-out begins after the bind and she is released only once it lands; a handoff before the copy-in lands changes nothing; a refused stage starts no transfer and returns her; a refused copy-out keeps her retiring until it begins. Built and tested in CI, not on the serving M5 (rule 2). No serving change yet: serving drives this owner over UnifiedTier (#6134) next, and the lane-launch path for our minds is deleted then. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * UnifiedTier binds a new mind only on a stream the engine reports empty, and keeps the fork's refusals Codex on #6134 (d815ce502): UnifiedTier::new takes any live Context with streams = [None, None], and a never-saved mind's move in marked stream 0 occupied without asking whether its sequence held state. A tier wrapping a context already in use could therefore report a successful first bind over prior KV. And move_in/move_out mapped the fork's typed refusals to a fixed string. - move_in, for a mind never saved, asks the engine's own memory (memory_seq_pos_max on the stream's sequence) and refuses "her stream already holds another sequence's state" unless it is -1 (empty). The evidence is the engine's, never this tier's bookkeeping; the refusal changes nothing. - TierRefusal carries Native: NotAsked (the tier's own precondition) or Refused { status, name } (the fork's llama_persona status and its name). move_in/move_out keep the fork's refusal instead of erasing it; the error text appends it. - persona_switch runs the adoption scenario before its measurement: one token decoded into sequence 0 before the tier exists; a new mind's move in is refused and sequence 0's state is unchanged; after the stream is cleared she binds. (Needs a real model, as the harness does; it is not a CI test.) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * PersonaBlocks::bind takes the owner the transfer is for, and refuses another persona's or a stale epoch's blocks before the fork Codex on #6132 (ea955a81a): bind(ctx, seq) carried no expected persona or epoch. The fork's bind/load validate a handle's blocks against that handle's own identity, which keeps blocks consistent but cannot detect that the caller selected the wrong intact handle. - bind(ctx, seq, expected: PersonaOwner) compares the handle's stamp (the owner its last completed save wrote) with the transfer's owner, persona AND epoch, and refuses BindRefusal::WrongOwner { expected, held } before calling the fork. The destination is untouched. A never-saved handle has no stamp and is refused the same way. - The fork's own refusal stays typed as BindRefusal::Native(PersonaRefusal). - Test only_the_expected_owner_and_epoch_bind: two intact handles at one reusable sequence (another persona, the same persona at a stale epoch, an unstamped handle) are each refused; the expected owner binds. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * UnifiedTier checks every move before it replaces her blocks; binds name her owner and epoch Codex on #6134 (de0e34a97): move_in called hold before checking occupancy. With epoch 1 parked in RAM and the chosen stream occupied (an adopted context), hold(epoch 2) replaced and dropped epoch 1's blocks, and only then did move_in refuse. - move_in decides everything before it changes anything: a stale epoch is refused; the same epoch rebinds from the stream she was saved from; a new mind or a newer epoch starts over, and only then is the stream's emptiness checked against the engine's own memory. hold (which may replace an older epoch's blocks) runs only after every check passed, so a refusal keeps the blocks she had. - The bind passes the owner the transfer is for (her issued stamp at this epoch), through #6132's new PersonaBlocks::bind(ctx, seq, expected); a wrong or stale stamp is a refusal naming it, a fork refusal keeps its native status. - tier.rs: the first doc line had error-attribute text pasted into it; restored. - persona_switch replays the scenario before measuring: epoch 1 decodes and parks; another sequence's state lands on her stream; epoch 2 is refused there; the stream is cleared; epoch 1 binds back at the position she left. (Real model, so not CI. Byte-identical continuation after a bind is the fork's test-persona-blocks.) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * PersonaEngine's own refusals say the backend was not asked (TierRefusal.native, #6134) #6134 gives TierRefusal a `native` field so a fork refusal keeps its status. The engine's own refusal (a copy-out the pipeline would not begin) and the test tier's refusal are preconditions, not backend answers: Native::NotAsked. Merges fable/unified-tier so #6139 builds on #6134. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * PersonaEngine submits the bound mind's decode through the tier and holds a switch until it lands Codex on #6139 (cb5732506): decode handed the caller &mut T. Through UnifiedTier::context() the callback could decode a batch under another sequence id or call tier.begin directly, bypassing the binding; and the Rust borrow ended at callback return while a launched GPU decode could still be in flight. - residency::Execute (new): a tier that runs the bound mind's decode. submit(persona, epoch, work) takes her tokens, never a sequence id, and returns a Completion the engine holds. - PersonaEngine: decode(step) is gone. submit(work) asks the tier for the active mind only, refuses while her previous step has not landed (one decode in flight), and handoff is refused with DecodeInFlight until it has, changing nothing. stage() still runs while she decodes, so the next mind's copy-in progresses beside it. active_mut() gives only her own state; tier() is read-only. - UnifiedTier: implements Execute (Step { tokens, from, logits_at_end } decoded on her bound stream, epoch checked; libllama's decode returns once outputs are readable, so Decoded is complete). context() is removed; logits_ith() and position_of() report read-only; raw_context() exists only under the test-fixtures feature, for custody replays that must put foreign state on a stream. - residency::Native::Reported(message) keeps a backend refusal that has a message and no status. - persona_switch runs through PersonaEngine (stage, handoff, release, submit) and requires test-fixtures for its replays. - Tests: a step runs only for the active mind and one at a time; a handoff waits for a delayed decode completion while the next mind's copy-in is begun and landed, then binds next. The compile_fail test now covers holding her state across a submit. Not built locally (the M5 is serving); CI is the first compile. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A decode reports landed only when the device is known to have finished it Codex on #6139 (80bc49c17): UnifiedTier::Decoded was complete by construction, but Context::decode reaches llama_decode only, and libllama synchronizes on result retrieval, so a submit (above all with logits_at_end = false) can return while the device still runs the graph. - llama: Context::synchronize() wraps llama_synchronize. - residency::Execute gains settle(): wait until every submitted step finished on the device. The engine's settle() calls it; handoff still refuses while the decode is not landed. - UnifiedTier: Decoded carries a landed flag the tier sets only when the device is known to be done: on settle() (llama_synchronize), or on logits_ith() (llama_get_logits_ith synchronizes). Her save (move out) settles first, so it never reads cells a decode is still writing. - The handoff test now lands the decode through the tier's settle() (its attestation), not by hand. - persona_switch settles after the replay's logits-free decode before her save. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * persona-engine: a turn prefills only what her blocks do not hold, under the same basis The persona scheduler's first decision for every turn (S1 of the serving integration): her token history is the engine's, so a prompt that extends what her blocks hold, under the same basis (model, adapter set and scales, her epoch, native media identity; Codex), prefills only the new tail. Anything else restarts her at a newer epoch so stale blocks are never decoded against. A prompt that adds nothing re-decodes her last token, since sampling needs its logits. Pure planning in turn.rs, unit-tested without a model: tail-only prefill, the re-decoded last token, diverging/shorter/empty/nothing-held restarts, and the same tokens under another model, adapter set, epoch or media identity restart. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The in-process scheduler is the persona engine: one mind decodes at a time, and a turn prefills only her new tail Serving integration S1 (MODULE-ARCHITECTURE 9.4, CONTINUUM-ENGINE 4.14). llamacpp_scheduler.rs (776 lines) advanced n_seq_max sequences per decode and dropped every sequence's KV when its turn ended, so each turn re-prefilled the whole prompt. It is deleted. backends/persona_scheduler takes its place behind the same surface (Scheduler / GenerationRequest / TokenEvent), so LlamaCppBackend changes only where it spawns it: - one driver thread owns the context and a PersonaEngine over UnifiedTier (two streams: the active mind and the next). Turns are served one after another; a switch is stage, settle, handoff, and the previous mind parks in the RAM tier (a one-off is forgotten). - each persona keeps her blocks between turns. turn::plan decides the prefill from what her blocks hold under the same basis (gene set; the model is the context's own; no native media on this path): an extending prompt prefills only its tail, anything else starts her over at position 0. - each Step carries its gene set; the tier applies it only when it differs from the set on the context, and only for the bound mind. A step at `from` drops whatever she held from there, so her stream never holds two tokens at one position (a re-decoded last token, a restart, a failed turn's partial tail). - engine: Tier::release + PersonaEngine::forget give up a one-off's blocks only after she left the pipeline (tested: refused while active or retiring, the tier asked once after). - the backend sizes the context as per-mind window x STREAMS. The launch's n_seq_max no longer drives decode; its plumbing (with_n_seq_max, batching_probe, LlamaCppLaunch.n_seq_max, profile lanes) is removed with the lanes in S3. Not yet: the next mind's copy-in overlapping the active decode, cold minds paging out of RAM, and routing residents here (S2; production still decodes over llama-server). Not built locally (the M5 is serving); CI is the first compile. A real-model run of the scheduler waits for a non-serving executor. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * persona scheduler: the driver carries no unjustified unwrap; the dead MLX scaffold goes Ratchets on #6140: three unwrap/unwrap_or sites in driver.rs become typed (a missing persona is a one-off, a parked miss is a new mind by match, the turn result is a typed TurnError), and the one saturation keeps its same-line reason. backends/mod.rs carried the tree's only OS gate there, for a 101-line phase-A MLX scaffold nothing calls; it and its two empty features are deleted. The doc-only edits to prompt_assembly.rs and concurrent_streams_test.rs are reverted so their old sites stay out of this change. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * ci scope: a persona-engine change runs everything the engine reaches (serving's engine depends on it now) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * persona scheduler: typed scheduler errors, no Step derives it cannot hold, the test tier releases CI on d2c3d82e7: persona-llama failed to build (Step derived Debug/PartialEq/Eq while carrying its genes, Arc<[(Arc<LoraAdapter>, f32)]>, which can have none of them; nothing compared or printed a Step, so the derives go). persona-engine's pipeline TestTier lacked Tier::release. The ratchets rose by one each: Scheduler::spawn/enqueue now refuse with SchedulerError {Spawn(io), Closed} instead of a String (the backend's OnceLock keeps the typed refusal, no clone in argument position), and the turn's elapsed_ms saturates through Duration arithmetic instead of a u64::MAX sentinel. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * persona scheduler: sample only her final prompt position; finish a refused retirement before any switch Codex on #6140 at 17c208cf5, two defects the happy-path GPU replay did not exercise: - Driver::serve sampled every prefill chunk and kept only the last. The sampler accepts what it samples, so a long prompt advanced her grammar, repeat penalties and RNG on phantom output. Earlier chunks now request no logits and are settled (UnifiedTier::settle synchronizes and marks the step landed); only the final prompt position is sampled. - Driver::switch_to could not recover a refused copy-out: handoff had already bound next, the old mind stayed retiring, and the next turn skipped the retirement for an active id or staged into an occupied tier. PersonaEngine::finish_retirement now retries her copy-out and gives her back once it landed (RetireError when refused or still moving, she stays in custody). The driver finishes any retirement before it stages and again after the handoff; a CopyOut refusal during the handoff leaves next bound and is retried, never skipped. Test: a_refused_copy_out_is_finished_before_the_next_switch_and_given_back_once (refused, then begun and not landed, then given back exactly once, then A/B/A holds one of each). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Lower the continuum-core warning baseline 12 -> 11: the win sticks (CI measured 11 at 82ba460a7, job 135047063384) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The persona scheduler publishes the geometry its context applied, per incarnation (agreed with Codex) Scheduler::state() is a watch of EngineState: Starting(incarnation), Ready(EngineGeometry) read from the created context (llama.cpp's applied n_ctx / n_batch / n_ubatch, the KV types and attention it was made with, decoding = 1, staging = STREAMS - 1), or Refused with the reason. Each snapshot names the engine incarnation it came from (rising per spawn), so serving retires a stale observation. The batch the driver prefills in is now the applied one, not the request's. llama: Context::n_batch / n_ubatch. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * persona scheduler geometry: per-mind window and sequences measured, requested settings kept apart, a gone driver says Stopped (Codex on #6150) - EngineGeometry gains n_ctx_seq (the window ONE mind may use, what serving publishes as her usable context) and n_seq_max, both read from the created context (llama_n_ctx_seq, llama_n_seq_max; llama crate Context::n_ctx_seq and n_seq_max). staging is n_seq_max - 1. - The KV types and flash attention move into Requested: llama.cpp does not report what it applied (flash attention may be Auto), so they are never presented as applied capability. - EngineState::Stopped(incarnation): a StopsOnExit guard owned by the driver thread turns a Starting or Ready it leaves into Stopped however the thread ends (last handle dropped, an early return, a panic unwinding it); a Refused keeps its reason. EngineState::ready() returns the geometry only while serving. Test: an exiting driver leaves Stopped, never a stale Ready, keeps a refusal, and a panic unwinding it does the same. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Residents run on the node's one in-process engine: serving owns it, llama-server is not launched for them Serving drives an InProcessEngine through the same LlamaServerControl seam it drove llama-server through: serve loads the model once and starts the persona scheduler, served_geometry/served_context_window report the context's measured geometry (n_ctx, per-mind n_ctx_seq, sequences), served_lanes reports one decoding mind. Planning, the snapshot and grants are unchanged. The engine is published once (in_process_engine::install). The residents' adapter factory (SharedEnginePersonaAdapterFactory) and the re-home reconciler bind to that one handle and never load an engine; the ai_provider sync registers it, so the gateway's OpenAI routes serve the same weights. Embeddings already use their own in-process embed model; vision's mmproj is resolved by the adapter's load. Refused by name until S2/S3, never silently dropped: switching base or going idle while residents hold minds (their suspension is S2), host prompt-cache resize (no host cache). Deleted: LlamaCppPersonaAdapterFactory, ServedModelPersonaAdapterFactory, build_served_adapter (no callers left). The scheduler's allocation is sized in one place (LlamaCppAdapter::allocation) for both the generate path and the engine start. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The engine's launch is a contract: the scheduler owns flash attention, serving's owners fill every field Live on the M5 (build 4aefe5131a, 22:26Z) every mind switch was refused: "the fork refused her save ... backend status 3: transposed_v", 191 refused deliberations in three minutes. The scheduler's requirement (an untransposed V cache, so per-sequence copy-out can move a mind) lived as an optional flash_attn knob three layers up that ensure_loaded set to Disabled. Receiver owns its requirement: SchedulerConfig has no flash_attn; the scheduler's context is always flash attention (driver.rs), and a backend without it refuses the context by name. Requested no longer records it (it is not a request). Caller fills a required contract: LlamaCppAdapter::for_engine takes an EngineLaunch whose every field is required (model, gguf, one mind's window, n_batch, n_ubatch, Offload, EngineKv), and the backend config is built from it field by field (LoadPlan::Engine), with no ..Default, no 512 fallback, no CONTINUUM_TIER env var. InProcessEngine fills it from serving's owners: window and placement from the ServingTarget, the micro-batch from lane_args::prefill_ubatch (the measured UBATCH_TOKENS lowered by the model's catalog ceiling, the same decision --ubatch-size applies), the KV types from kv_cache_plan (KvCachePlan::engine_cache_type; a type the engine cannot hold is refused, never substituted). A batch that is not a whole number of ubatches is refused at construction (EngineLaunchRefusal). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The scheduler driver imports the FlashAttn it now owns; drop the imports and mut the contract left unused Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The engine holds the KV type serving plans: KvCacheType::Q4_0 (the M5's SERVING_KV_CACHE_TYPE=q4_0), and the K/V ggml mapping lives once on the type Live on the M5 (build abac3b3b64, 22:44Z) the in-process engine refused serving's q4_0 plan by name, as its contract says, so serving stayed not-ready and no resident could act. The engine now holds it, and engine_cache_type names it; the duplicated K and V matches in ContextParams became KvCacheType::ggml_type. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The in-process engine keeps the /v1 contract: tools through the model's own template, its native calls parsed, its think budget enforced Live on the M5 (build 9042e42cea, 22:54-23:00Z) the in-process engine generated cleanly but two contracts llama-server's /v1 gave residents were missing: - Tools: the adapter described tools in the prompt and guessed calls out of prose; Aris's act was dispatched as command 'work/state 29f11bbd' and refused (no such refusals on canary). Now a C seam over llama.cpp's common/chat (core/llama/chat_template.cpp, the functions llama-server ran): the model's templates built once (LlamaCppBackend::chat_templates), a text turn rendered with OpenAI messages and tools (request_body::wire_messages / openai_tools, the ones the /v1 adapter sends), and the reply read back by the template's own PEG parser into content, reasoning and structured tool calls (FinishReason::ToolUse). The adapter declares NativeProtocols::ModelTemplate (native function calling, GBNF structured output), which replaces GrammarConstrained (prompt-driven tool JSON), its only user. - Think budget: DispatchTermsPolicy for LlamaCppAdapter refused every budgeted think, since no reasoning-budget sampler reached our bindings, so most submitted resident turns never ran. Now the scheduler's chain carries llama.cpp's common_reasoning_budget sampler (SamplerChainBuilder::reasoning_budget), bounded by the template's own thinking tags (ChatPrompt::think_bound), forcing the end tag as llama-server did. SamplingConfig::think is None only for Think::ModelDefault or a template that does not think. refuse_think_budget had no caller left and is deleted with its test; the schema refusal keeps its test. Typed refusals throughout (ChatRefusal, TurnError::Sampler); no plain-text fallback. Not yet used: the template's lazy tool-call grammar and its triggers (ChatPrompt::grammar, grammar_triggers) — the follow-up that constrains a call's JSON, owner Fable. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The in-process dispatch policy calls generate_stream_checked through its trait Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The persona engine probes every turn: switch, prefill and decode time, reused and prompt tokens The one-mind gate (switch in ms, decode near the chip's rate, reuse >= 80%) had no live reading: slice 1's first turns took 300-360 s for 55-289 tokens (M5, 88074d9300, 2026-11-18 23:21-23:30Z) and nothing said whether the switch, the prefill or the decode spent it. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The persona engine is a frame loop: each frame advances one turn by one step, never a whole turn `for req in &requests { serve(req) }` ran every turn whole (switch, full prefill, full decode) on the engine thread, so a mind waited behind another's entire cold prompt: 300-360 s turns on the M5 (88074d9300, 2026-11-18 23:21-23:30Z) while the switch itself took 4 ms and one 11,834-token cold prefill took 16.6 s (probe persona.engine.turn, 7b1b957917). Now submissions are drained without blocking and each frame advances ONE turn by ONE step (a prefill chunk or a token). A turn is a state machine (Waiting, Prefilling { pos }, Decoding); her blocks hold exactly what it has computed between steps, so another mind can be bound between any two. `frame::pick`, one pure function: the active mind's answer in progress continues; otherwise the least prefill left goes first, discounted by its wait, so a short tail never waits behind a long prompt and a long prompt ages to the front. Only a mind's oldest turn is a candidate (a mind is one serial queue). The loop blocks only on the queue when no turn is left: a wake, not a poll. A caller that hangs up cancels its turn. The probe now carries wait_ms, switches and total_ms. One mind still decodes at a time; nothing here batches minds. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The driver imports the frame policy it picks with Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A mind resumes from her view's end: the engine checkpoints her there and rewinds to it next act Every act re-prefilled her whole prompt on the M5 (frame loop b762170061, probe persona.engine.turn, 2026-11-18 23:55Z-00:00Z: reused 0 of 11,834-30,588 tokens, prefill 65-85% of each turn). Her view is append-only (90-97% of the next prompt, Aris's captures) but the tail after it (the clock, the ask, her newest act) changes every act, and turn::plan reused only an exact extension of everything she held, her own generated tokens included. - The request already names where her next act stops matching (view_messages); the adapter renders those messages with the model's template, minus its generation prompt (native_chat::stable_text), and the turn's boundary is where those tokens stop agreeing with the prompt's. - A prefill chunk ends exactly there, and the engine checkpoints her (fork llama#153: her recurrent rows copied, attention KV left in place), reusing the checkpoint's buffers act after act. - reuse::choose (pure, tested): append when the prompt extends what she holds; rewind to her checkpoint when the prompt holds her tokens through it under the same genes; else restart, its reason in the probe (cold, diverged_before_checkpoint, genes_changed, no_checkpoint). - A cut below her checkpoint drops it (Mind::cut), so a stale one is never restored. - Execute gains checkpoint/rewind; PersonaEngine applies them to the active mind only. - Her checkpoint's bytes join her footprint report; the probe carries start, boundary, checkpoint_ms. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The driver imports the reuse decision it resumes with Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The engine takes and rewinds a checkpoint under her owner (fork llama#153 at 12a98779b: owner and cell lineage) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Bump the fork to a58c3b4cf: only the newest checkpoint on a lineage rewinds Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The frame sizes a waiting turn by the prefill she cannot reuse, not her whole prompt The M5 at a6da599330 (2026-11-19 01:00Z): Aris's second act reused 27,928 of 29,115 tokens (prefill 2.6 s) but waited 161 s, because pick() ranked her waiting turn at its whole 29k prompt and put her behind cold 33k and 46k prompts. Mind::reuse is the one pure decision (reuse::choose over what she holds and her checkpoint); resume binds by it and pick sizes by it. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A turn's row splits decode into the forward pass, the sampler and the frame around them The M5 at 7f67dc28d0 decodes ~10 ms/token slower than llama-bench on the same GGUF and Q4_0 KV (26.2 vs 34.8 tok/s at 46k; ~31.6 vs ~47 at 17k). forward_ms and sample_ms name where it goes before anything is changed. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A turn's row separates the GPU's forward pass from the sampler e582fd2125 on the M5: 1,175 tokens at ~29k decoded in 39.9 s = forward call 9.1 s + sample call 30.8 s, the frame itself 0. The sample call includes the wait for the forward pass to land (reading logits synchronizes), so settle() now runs first and gpu_ms is reported apart from sample_ms. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The scheduler owns its fused Gated Delta Net kernels, on as the fork defaults them Qwen3.6 is mostly GDN layers. The engine launch turned the fused graphs off (a comment about an FFI throw, no receipt), so the M5 decoded ~31-38 ms/token with ~8 ms of CPU in every forward call, while llama-bench on the same fork, GGUF and Q4_0 KV (fused on, its default) decodes ~20.5 ms at 15k; n_ubatch, n_ctx and the second sequence measured no different (01:49-01:51Z). Like flash attention, the scheduler's context sets its own kernels; SchedulerConfig loses the two fields. The one-off media context keeps its settings. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The engine's protocol: typed commands in, events out, one snapshot CONTINUUM-ENGINE 4.16 (Joel 2026-11-19: build objects and protocols; never wait; events and data flow). An Activity is one stream of a mind's thinking; Command (Extend, Think with per-answer credit, Credit, Cancel, Mark, Rewind, Release), Event (Token, Done, Marked, Refused) and EngineSnapshot (incarnation, frame, observed_at, GPU busy share, longest idle gap, per-mind residency and delivered tokens) are the only things that cross. Types only; the stages that speak it come next. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A mind's footprint is the sum of her parts, asked of each owner Joel 2026-11-19: find similar things, make base objects; an object's method calls its sub-objects' same method. Footprint (persona/footprint.rs) is the node trait: Held{host,device}, Option and token histories implement it, and PersonaParts folds it with the same macro that folds suspend. The driver's Mind and its KeptCheckpoint implement it; her blocks in the context are the tier's custody, read through a Bound view. report_footprint no longer adds a tier read and a checkpoint read by hand. Test: the fold equals the parts. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Protocol, Codex's review: unique answer ids, typed refusals naming the operation, ordered spans AnswerId and MarkId are UUIDv7, never reused across activities or engine restarts, so a delayed credit or cancel reaches only its own answer. Refused carries the Operation it refuses (Mark and Rewind told apart) and a typed Refusal; an answer ends exactly once with Done or a Refused naming it. Extend carries ordered Span<M>: token ids, or a media span holding the adapter's owning chunk handle with its kind, projector basis and engine-reported position count. No raw pointers or encoded payloads cross. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A turn's row counts how many of her decoded tokens reused a built graph Live at b0fc1f2591 the GPU matches llama-bench per token but each decode call spends ~7 ms of CPU before the device starts. graphs_reused (libllama's own n_reused, read around each decode step) says whether that is the graph being rebuilt every token. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The flow stage declares a queue depth and handles everything waiting in one wake Joel 2026-11-19: build the object that gives queues and threads for free, then on a turn do many. continuum-flow's Stage (CBAR's QueueThread<T>) held one pending input; it now holds up to its declared DEPTH (CBAR's queueSize; 1 stays the default double buffer), Reliable hands an input back only when full, KeepNewest drops the oldest, and the worker drains all waiting inputs in one wake into handle_all (default: handle each, in order). The lock is held for the insert and the take only. Test: depth, hand-back, one ordered batch per wake; the existing depth-1 contract test is unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Emit: an answer's tokens become text on their own stage, off the engine thread CONTINUUM-ENGINE 4.16 S1, the first stage built on the continuum-flow base (Joel 2026-11-19: queues and threads given for free by one object, then many). The driver pushes Open, Token and End to Emit (DEPTH 4096) and goes straight on; Emit turns tokens into pieces, streams them to the caller and watches stop sequences, raising the answer's cancel flag that the engine reads lock-free at its next step. End goes through the same ordered queue, after the last piece. Emit full: items wait in an ordered backlog, never the engine. The engine thread keeps only the forward pass, the logits and the sampler. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Prompts arrive at the engine as token ids, tokenized on each act's own thread The engine thread tokenized every turn's whole prompt (~47k tokens on the M5) and her view's text again, serially, while the GPU idled. GenerationRequest now carries prompt: Vec<i32> and view_end, computed by persona_scheduler:: prepare on the submitter's blocking-pool thread, one per act, many at once. admit only builds the sampler. TurnError::Tokenize is gone with its only use. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Record: the engine's occupancy and turn rows, measured and published off its thread CONTINUUM-ENGINE 4.16 S1. The driver hands Record a Busy span per step and a TurnRow per finished turn and goes on; Record merges spans into 10 s windows and publishes EngineSnapshot (busy permille, longest idle gap; the gate is >= 800 and <= 2,000 ms) through Scheduler::snapshot and a persona.engine.occupancy probe, and writes persona.engine.turn. The repeated 'push, keep in order when full, flush next frame' shape moves down into continuum-flow as Outbox, used by both Emit and Record; the driver's own backlog code is deleted. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Restore is the norm: the engine's stop preserves every mind, its start resumes them CONTINUUM-ENGINE 4.16 (Joel 2026-11-19: restore built into everything as a consumer of lifecycle; Codex's review at 2990b44831). The engine is a SettleBeforeStop participant: the stop's root suspend reaches the driver as a Submission; each mind binds, rewinds to her view checkpoint, retires through the pipeline (Roles::retire / PersonaEngine::retire_active, new: the last mind leaves the stream with nobody to follow), and her blocks (fork #155 raw rows) and token history are written; the manifest naming every preserved mind is published last, atomically. A mind not preserved is reported Retained. The start's root resume reads the published manifest for this model, verifies each mind's token count and checksum (owner, epoch and layout in the fork) and holds her Warm, bound when scheduled. The tier's owner stamp is now a fold of her persona id (a per-process counter refused her own file after a restart) and 'restored' is its own Saved state; the tier never moves a bound mind to write her. persona-blocks is a tracked class whose eviction belongs to the manifest: never age-deleted, her only copy. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Preserved minds are a saved-state kind; a restore survives a restart's new window Joel 2026-11-19: 'You're kind of coding highly specific objects when the patterns are much larger.' The hand-rolled manifest, checksum, atomic replace and verification in preserve.rs duplicated continuum-saved-state, the one contract for state that outlives a process; preserved minds are now its PreservedMinds kind (Key Singleton, Contract {model} compared field by field, Value each mind's id, epoch, basis and token history): the envelope gives the atomic save, generation, digest and typed load verdict. preserve.rs drops from 126 to 61 lines. Fork 4ebb538f9: the M5's first restore refused every mind because the restart's planner chose a 68,608-cell window where the stop had 104,192; a file now restores into any stream her rows fit. Resume and suspend outcomes are logged as well as probed: none of their probes reached the probe file at boot or exit on the M5. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The unit is the mind: her blocks travel with her, the tier keeps only who holds each stream (CONTINUUM-ENGINE 4.17 step 1) - MindId (persona + epoch) is the one id every fence, refusal and tier call carries. - Tier gets `type Blocks`, `blocks_for(mind)` and `begin(mind, &mut blocks, direction)`; `release` is gone: giving a mind up is dropping her unit. - PersonaUnit carries her blocks (`Carries<B>`); the engine hands the tier the blocks of the unit it stages or retires, so no tier holds a second copy of who she is. - UnifiedTier: the per-mind map, its Mind and its epoch lookups are deleted; its state is `streams: [Option<MindId>; 2]`. `Blocks` (native blocks + what they hold) is the unit's part; `read_file` returns her blocks, `Blocks::write_file` writes them. - Driver: `Mind` is `PersonaUnit<Blocks, History, Basis, (), Tenure>`; `forget` is gone (a one-off is dropped with her blocks); the parked table is the warm table of units. - Removed: `PersonaEngine::forget`, `Tier::release`, `PersonaUnit::into_parts`, the tier's `held()` and `minds` map, the example's stale-epoch probe (an older epoch of a held mind cannot exist: there is one unit per mind). 383 lines added, 424 removed. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Cargo.lock: the llama crate no longer depends on serde (its chat seam is canary's) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * chat_turn: a native call the template names no id for gets a minted one, as llama-server did Qwen's template emits no tool-call ids; parse_turn passed them on empty, and active_protocol_error refuses a call/result batch with an empty id. On the M5 at 6d1396e62f (06:21-06:26Z) 19 resident turns were refused as 'missing, duplicate, or mismatched native call/result IDs'. llama-server minted an id for its /v1 reply; in process the render's parse is that layer, so it mints call_<uuid> for an unnamed call. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A stored native exchange without paired ids is carried as her receipt, never refused on every act Calls parsed with empty ids at 6d1396e62f were stored with Aiko's and Benchy's acts; every act after refused the same receipt ('missing, duplicate, or mismatched native call/result IDs'), on every build including the rollback (Aiko 32, Benchy 12, 06:36-06:41Z): her mind stopped on her own history. One rule now decides both the receipt's form and the refusal (prompt::types::native_ids_correlate): an exchange whose ids do not pair one to one is carried as its receipt (what she did and what came back, known), probed as delib.receipt.uncorrelated, and is never given ids it did not have. Regression test beside the newest-result tests. Pre-existing and unrelated (fails identically without this change, 06:50Z): an_unsaved_newest_result_is_saved_and_pages_instead_of_refusing (required 113,923 > budget 110,128). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Preserved minds are one complete generation: blocks written to files no manifest names, the manifest published only after every write Codex on #6159 at 9fd0d0c868: preserve wrote each persona's fixed <uuid>.cpb before publishing the singleton manifest, so a stop interrupted in between paired the old manifest's token history with newer blocks of the same owner and epoch, and a failed individual preserve dropped that resident from the replacement entries. - Each stop mints a Generation; every mind's blocks go to <persona>.<generation>.cpb, never over a file a published manifest names. The manifest entry names its file (PreservedMind.blocks). - The manifest is published (Preserved::publish) only after every write has landed. Only then are the block files it no longer names removed; a refused save publishes and removes nothing, so the last generation stands. - A mind whose write fails keeps her entry from the last complete generation (next_manifest); her file is still there. - Format 2. A format-1 manifest upgrades with its blocks at the fixed names it used, so the first start after this resumes every mind the last stop preserved. - Tests (preserve.rs): an interrupted stop leaves the last generation whole with its own blocks; a failed write keeps her last entry; a publish removes only what it no longer names; format 1 upgrades. Fork pin 834770daf: #153's standalone recurrent checkpoint refused (1fef01207), #155's Windows-safe replace and geometry-checked read (834770daf), test-persona-blocks ok on the hybrid model and synthetic qwen35moe (08:47Z). Checked with serving down (08:50-08:56Z): cargo check of the core, the engine tests and the metal example; persona_scheduler 8/8, persona-engine 21/21, llama chat 3/3. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A preserved mind stays until a newer write replaces her; the manifest is the last generation from the moment it commits Codex on #6159 at a3ef26e8a3: 1. A resident whose resume was refused (a smaller boot window) never entered the warm table, so the next stop neither wrote her nor counted her failed; next_manifest dropped her and publish unlinked her blocks. next_manifest(last, written) now keeps every last-generation entry no write this stop replaced: failed, refused, or not scheduled. Test: saved, refused at the next boot, a stop before her next turn, then a boot that fits her resumes her original history and blocks. 2. Fork pin 834770daf is now published (fable/persona-files, CambrianTech/llama.cpp#155): it was committed on a detached HEAD and the branch push did not carry it. 3. publish sets last as soon as the save returns; a failed directory listing afterwards is reported as cleanup, never as a lost save. Test: the listing fails after the commit and last is the committed generation. Checked with serving down (13:38-13:44Z): core, engine tests, metal example; persona_scheduler 10/10. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A waiting turn outranks background work for the decode permit; every admission wait is timed by its owner Codex, BigMama R21 (2026-11-19 13:24:41-13:34:52Z): Kimi held her directed lane 610 s before her act was pinned, while four background requests (two consolidations, the historian, belief review) took slot 2. One decode permit per endpoint, and a return wakes every waiter. A turn holding a lane lets it go to wait (turn_admission.rs:417-420) and must take it again before it retries (line 404), while background work in DecodeBound::acquire retries at once, so it can win every return. - DecodeBound counts waiting turns (TurnWaiting, from a turn's first refused try until she holds a permit). While any turn waits, acquire (background, dreams) leaves a returned permit for her; the last waiting turn leaving wakes it. Test: a_returned_permit_waits_for_the_turn_not_the_dream. - The cause is not proven: R21's retained probes have no receipt for the permit, lane, gate or slot wait. Each owner now times its own wait, keyed to the act where it knows her: inference.decode_permit.turn_waited (page), inference.lane.reacquired (persona), inference.mind_gate.waited (page), inference.slot.permit_waited (slot). - preserve.rs: the unused HashMap import is gone (the guard's check flagged it). Checked with serving down (14:06-14:12Z): core, engine tests, metal example; slots 77/77, turn_admission 54/54 (6 ignored), persona_scheduler 10/10, persona-engine 21/21, llama chat 3/3. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Background work holding a lane takes the endpoint's priority decision too; each pool-less adapter ranks only its own waiters Codex on #6159 at 411773eb20: a keyed dream, or a dream on a pool without scratch, holds a lane and tries through try_or_return_as(None), which went straight to try_or_return and took a returned permit while a turn waited. Now, while any turn waits, it is given the wait and lets its lane go through the caller's existing refused branch (release before wait). The process-wide ADAPTER_TURNS_WAITING is deleted: a turn waiting on one adapter's semaphore no longer holds back another adapter's work. Tests: a_laned_dream_is_given_the_wait_while_a_turn_waits, a_pool_less_adapter_ranks_only_its_own_waiters. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * The decode permit takes one claim whose rank is its request's class; an adapter owns one bound Codex on #6159 at 7853bb989e, and Joel: group what shares an owner and lifetime, require what an operation needs, keep Option for a meaningful absence, one owner API for every caller. - SlotClass::decode_rank is the ONE map from a request's class to its rank: Turn, Fork, Sidecar are foreground; Background, Dream, Probe yield to them. A turn's rank was whether it named a page (try_or_return_as(Option<PageKey>, ..)), so an unpaged turn ranked as background. - DecodeClaim groups a caller's class with its counted wait (absent until a foreground claim is first refused), made once per admission and kept across its retries. - DecodeBound::try_claim / claim are the one priority decision for every caller; try_or_return, try_or_return_as and acquire are deleted. - DecodeBound::with_permits builds a pool-less adapter's bound ONCE (the adapter field is now a DecodeBound); every clone shares its waiting count and return notice. The implicit From<&Arc<Semaphore>>, which made a new count per conversion so nobody was ranked, is deleted, with the process-wide adapter notice. - Tests build permits with the same constructor production uses. Tests: a_laned_dream_is_given_the_wait_while_any_foreground_claim_waits, an_adapter_bound_ranks_every_clone_and_no_other_adapter, plus the returned-permit replay on the claim API. Serving-down check window 14:31-14:37Z: slots 79/79, turn_admission 54/54, persona_scheduler 10/10, persona-engine 21/21, llama chat 3/3; continuum-core checks. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A stage has one lifecycle owner: stop closes intake, join waits for its teardown; an evicted payload is dropped on the worker Codex's patch on 73ca6d6a05 (Codex owns stage lifecycle; applied unchanged, reviewed by Fable). - spawn_stage returns (StageInput, StageWorker): producers get only the input; the one owner stops (close intake under the inbox lock) and joins (drain accepted inputs, release state). - KeepNewest keeps a displaced payload in a bounded retired list and drops it on the worker, so neither the producer nor a bystander pays its destructor under the lock; a full retired list refuses with Full (backpressure) instead of dropping synchronously. - The persona scheduler thread stops and joins Emit and Record after its driver loop exits. - Test eviction_and_final_cleanup_belong_to_the_joined_worker. Review notes: no live stage is KeepNewest (Emit and Record are Reliable), so the new Full on a KeepNewest stage changes no current caller; Outbox already backlogs Full. The shutdown join runs Handle::block_on on the scheduler's std thread (not a runtime worker), which is allowed. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A lookup registers no endpoint, and the stop checkpoints only endpoints something registered The M5's stop receipts said "UNSAVED: page_io at :58057 (process unidentified)" while the persona engine had preserved every mind (14:54Z: persona.engine.suspended preserved=3 retained=0). Codex traced it: SlotDirectory::get went through endpoint(root), which inserts an Unprobed entry, and warm-ahead calls get on the catalog llama-server root; page_io's stop then iterated every entry and claimed custody of one nothing launched or discovered (Adopted(Err(IdentityUnverified))). - SlotDirectory::existing: the non-inserting read. get, page_admission_known, page_discovery_generation and page_admission_path go through it; only discovery, launch and latching register an endpoint. - page_io's stop checkpoints an endpoint only when this core launched its engine, its pool was asked (discovered or latched without paging), or a live lane is recorded there (holds_custody); a skipped one is probed (inference.kv_page.stop_checkpoint_skipped). Real adopted custody is still checkpointed or retained. - continuum-flow: Overflow::KeepNewest documents that push can answer Full once the worker has a full depth of displaced inputs to drop (Codex's review note on 2578d5f473). Test only_a_registered_endpoint_is_the_stops_to_checkpoint: a lookup registers nothing; an unprobed entry with no lane is not the stop's; a recorded lane or a discovered pool is. Serving-down check window 15:20-15:27Z: slots 80/80, turn_admission 54/54, persona_scheduler 10/10, persona-engine 21/21, llama chat 3/3; continuum-core checks. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A turn that wrote nothing says why: the raw tail, the stop it ended on, what the parse kept Aiko on the M5 from 15:36Z 2026-11-19: about 20 turns in a row of 112-411 tokens, finish=stop, text 0, no call; each turn's reasoning ends "let me read the end of tests.rs now" and the turn stops where her call would begin (Atlas, Aris and Benchy show the same think-only turns). The captures keep only the parsed text and reasoning, so a stop string firing at her call, the model ending inside its thinking, and a call the parse dropped all look the same. Probe inference.turn.wrote_nothing on any turn with no text and no call: tokens, generation end, the stop string the written text ends on (or none), reasoning and written lengths, and the last 160 characters actually written. Measurement only; no behavior change. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Clear #6159's hygiene findings: typed refusals, stages sized by their owner's grant, no polls, no multi-sequence widening Codex's exact-head verdict on 8ba9893d8a: source-hygiene job 135693077628 failed ten ratchets. Every site was listed against canary 2ac6315176 with a full-listing hygiene binary in serving-down windows; all ten now hold (judged run rc=0, same binary over both trees). - Typed errors where text was: PreserveError (driver), StoreError (preserve), ChatRefusal (sampler), InProcessRefusal as one LlamaServerError::InProcess variant (its causes no longer read as llama-server spawn failures). The render path converts to the adapter trait's String once. - Stages never size themselves (Codex: option b). Stage::DEPTH is gone; spawn_stage takes a typed Capacity from its owner. Emit and Record take the engine's admitted window in items. A latest-value stage holds its one pending value (Capacity::latest). - No poll: the driver's 5 ms EMIT_RETRY recv_timeout is gone. With no turn left it awaits the stages' space (Outbox::drain), then blocks on its queue. Record's 10 s WINDOW is gone: a window is one turn. - block.rs no longer widens a "safe" architecture to n_seq_max=4: one mind decodes at a time. - persona <-> residency cycle removed: Carries moves to persona, which residency depends on. - lane_args.rs untouched again: prefill_ubatch moves to its one caller, the in-process engine. - Caller sends report a hung-up caller through probes instead of `let _ =`; absent row fields are Option, not 0; one whole_ms owner; reuse::choose takes two Histories, not five loose values. Replay (Codex's ask): a_stalled_stage_holds_its_producer_and_drain_resumes_it_on_space_in_order. Serving-down windows on the M5, 16:33-16:44Z: continuum-flow 23/23, persona-engine 21/21, persona_scheduler 10/10, llamacpp_adapter 16/16 (1 ignored), in_process 1/1; continuum-core checks. The core restarted on 1f2000cd66 after each window. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A stalled stage never blocks a stop: the driver wakes on its queue or the stage's space, and defers stepping while it holds Codex's exact-head finding on f530b00670: with no turn left, the driver blocked in Outbox::drain before reading its queue, so a new turn or the stop's Suspend could not wake it while Emit was stalled; and the outbox backlog was unbounded outside the stage's grant. - The request queue is a tokio unbounded channel (sync send, awaitable recv). When a stage holds what the driver produced, or no turn is left, the driver waits in one select! over a submission and the stage's space: a turn or a Suspend wakes it at once, whatever the sink is doing. - While a stage holds a backlog the driver steps no turn (a deferred producer), so the backlog stays within the stage's grant plus one step. - Outbox::drain is cancel-safe: an item leaves the backlog only when the stage has taken it. Replays (Codex's asks): a_submission_wakes_a_producer_held_by_a_stalled_sink_and_the_drain_loses_nothing (a suspend sent after the drain began wakes it; the held items arrive later, in order, once), and a_stalled_sink_keeps_completion_next_turn_and_cancellation_whole_and_in_order. Serving-down window on the M5, 17:11-17:15Z: continuum-flow 25/25, persona-engine 21/21, persona_scheduler 10/10, llamacpp_adapter 16/16 (1 ignored), in_process 1/1; continuum-core checks; hygiene judged against canary 2ac6315176: rc=0. The core restarted on f530b00670. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * Keep a recurrent checkpoint at the native prefix shared across a view turnover * Pin the native checkpoint implementation exercised on M5 * Record the tested native fork pin and its Windows CI toolchain fix * Track the fork Windows CPU toolchain correction * Pass tail tool schemas through the in-process chat renderer * Query providers concurrently outside the registry guard * Learn a deeper recurrent checkpoint after a short rewind * Estimate waiting prefill once per eligible turn * Schedule overdue resident turns at landed frame boundaries * Represent resident readiness and service timing explicitly * Retain the earliest valid learned checkpoint across deeper captures * Keep native checkpoint custody in resident history * Express history transfer and checkpoint basis ownership * Compare token history once when binding a resident * Correlate empty native turns with their requested tool catalog * Group native generation output in the empty-turn probe * Pin the deployed Qwen argument-order parser * Retain one-off native state only while its turn owns it * Resolve retiring native state before recording suspend inventory * Report every resident held when suspend cannot preserve the node * Give the requesting task ownership of its submitted inference turn * Remove blocking generation wrapper from the native backend * Enqueue flow work on submission and trace native worker parking * Skip candidate ranking when only one turn can run * Wake one shared stage when a resident phenotype changes * Close cancelled stage intake and rearm residency on its next wake * Preserve the gene residency scheduling contract for existing callers * Surface native checkpoint capture and rewind outcomes * Attribute checkpoint allocation and capture failures to the resident * Borrow each prefill slice until submission and history update * A turn's path from entry to the engine reports every transition it reaches, keyed by its request id The M5, 2026-11-21: Aris entered generate_text at 00:48:32 and was dropped 1,499 s later with no record of whether the engine ever held her turn; the driver logged nothing at admission, so the stall could not be placed (and was first misattributed to the grants). Now each transition is recorded once, keyed by the submitted request's id (`RequestId`, the adapter request_id, the one id crossing from her deliberation into the engine): - inference.generate.enter: gains `r…
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.
Summary
Updates the root README to showcase the genome visualization system with live video demonstration.
Changes:
continuum-live.movvideouser-interface.pngshowing the genome panel close-upWhy:
The genome visualization is a key differentiator showing each AI's fundamental identity in real-time. Users can see which AIs can learn, where they run, if they have extended memory, and what specialized capabilities they possess.
Visual Assets:
screenshots/continuum-live.mov- 8MB video of live multi-AI collaborationscreenshots/user-interface.png- Close-up of genome panel🔧 Generated with Claude Code