⛰️ LifeOS — The AI-powered Life Operating System that helps you hill climb to wherever you're going.
release 6.0.5: PAI→LifeOS code rename, Harvest skill, Algorithm v6.24.0, install.sh version fix
Daniel Miesslera5bcf65a5b26
diff --git a/LifeOS/SKILL.md b/LifeOS/SKILL.mdindex c676d8ee..c9ee2ccf 100644--- a/LifeOS/SKILL.md+++ b/LifeOS/SKILL.md@@ -53,7 +53,7 @@ Default flow (`/lifeos-setup`): **Setup phase** (system integration) → transit- **No `version:` in SKILL.md.** Claude Code ignores it. Version lives in the release (tag + `LIFEOS_RELEASES/<version>/` + the `install.sh` fetch), not in the skill.- **`install.sh` is non-destructive by design.** It installs only the LifeOS skill and backs up only a prior LifeOS skill — never the user's other skills, hooks, or config. The whole point is "bolt on, don't take over."- **Hooks are installed imperatively, with permission.** A bare skill cannot auto-wire hooks; the setup workflow writes them into the user's harness explicitly, after showing what changes.-- **Config is `.toml`, never `.yaml`.** `PaiConfig.ts` reads TOML; the legacy `.yaml` template was retired 2026-06-19.+- **Config is `.toml`, never `.yaml`.** `LifeosConfig.ts` reads TOML; the legacy `.yaml` template was retired 2026-06-19.- **Cross-platform is solved at setup time, not statically.** The setup conversation detects the OS + harness and tailors hook commands and paths — don't assume macOS.## Examplesdiff --git a/LifeOS/Tools/SeedPulse.ts b/LifeOS/Tools/SeedPulse.tsindex 4b54fbfb..89395b8a 100755--- a/LifeOS/Tools/SeedPulse.ts+++ b/LifeOS/Tools/SeedPulse.ts@@ -15,7 +15,7 @@ import { existsSync } from "node:fs";import { join } from "node:path";import { detectDevTree } from "./InstallEngine";-const GENERATORS = ["GenerateTelosSummary.ts", "UpdatePaiState.ts"];+const GENERATORS = ["GenerateTelosSummary.ts", "UpdateLifeosState.ts"];function main(): void {const a = process.argv.slice(2);@@ -58,8 +58,8 @@ function main(): void {...process.env,LIFEOS_CONFIG_DIR: configDir,LIFEOS_DIR: join(configRoot, "LIFEOS"),- // GenerateTelosSummary resolves its TELOS dir via PaiConfig.paiUserDir(),- // which reads LIFEOS_CONFIG_PATH (NOT LIFEOS_DIR). UpdatePaiState resolves via+ // GenerateTelosSummary resolves its TELOS dir via LifeosConfig.paiUserDir(),+ // which reads LIFEOS_CONFIG_PATH (NOT LIFEOS_DIR). UpdateLifeosState resolves via// LIFEOS_DIR. Pass BOTH so both generators target the same install root —// otherwise a non-default config root mis-targets ~/.claude.LIFEOS_CONFIG_PATH: join(configRoot, "LIFEOS", "USER", "CONFIG", "LIFEOS_CONFIG.toml"),diff --git a/LifeOS/Workflows/Interview.md b/LifeOS/Workflows/Interview.mdindex 07918178..54c190f5 100644--- a/LifeOS/Workflows/Interview.md+++ b/LifeOS/Workflows/Interview.md@@ -19,7 +19,7 @@ Peer conversation, not a form. Ask one thing at a time, reflect it back, go deep2. **Principal identity** — name, pronunciation, timezone, hometown → `[principal]` in `LIFEOS_CONFIG.toml` and `PRINCIPAL/PRINCIPAL_IDENTITY.md`.3. **TELOS — current state** — mission, the people who matter, current projects, challenges, what's actually true right now. Write to `TELOS/`.4. **TELOS — ideal state** — goals (with metrics + dates where they have them), strategies, the destination. Current → ideal is the spine of LifeOS; get both halves.-5. **External sources (optional)** — the user can hand over existing material: notes, an old config, exports, URLs, a prior PAI/other-harness setup. Pull from each (read files, fetch URLs), extract identity / TELOS / project signal, and merge into the USER tree — `existsSync`-guarded, confirm before each write. This is the migration on-ramp: bring your context, don't retype it.+5. **External sources (optional)** — the user can hand over existing material: notes, an old config, exports, URLs, a prior LIFEOS/other-harness setup. Pull from each (read files, fetch URLs), extract identity / TELOS / project signal, and merge into the USER tree — `existsSync`-guarded, confirm before each write. This is the migration on-ramp: bring your context, don't retype it.6. **SeedPulse** — `bun Tools/SeedPulse.ts` → write `LIFEOS_STATE.json` and regenerate `PRINCIPAL_TELOS.md` from the captured TELOS so Pulse renders real rings + state on first open.## Closediff --git a/LifeOS/install/CLAUDE.template.md b/LifeOS/install/CLAUDE.template.mdindex 2e9925d0..377e6d99 100644--- a/LifeOS/install/CLAUDE.template.md+++ b/LifeOS/install/CLAUDE.template.md@@ -1,4 +1,4 @@-# LifeOS 6.0.3 — LifeOS (the Life Operating System)+# LifeOS 6.0.5 — LifeOS (the Life Operating System)> **LifeOS is the Life OS. The DA is the principal's AI assistant. Pulse is the Life Dashboard.**> Canonical thesis: `LIFEOS/DOCUMENTATION/LifeOs/LifeOsThesis.md`. Everyone running LifeOS names their own DA. LifeOS targets AS3 on the LifeOS Maturity Model, with lineage from "The Real Internet of Things" (2016).diff --git a/LifeOS/install/LIFEOS/ALGORITHM/LATEST b/LifeOS/install/LIFEOS/ALGORITHM/LATESTindex 0b31cc63..2496b04b 100644--- a/LifeOS/install/LIFEOS/ALGORITHM/LATEST+++ b/LifeOS/install/LIFEOS/ALGORITHM/LATEST@@ -1 +1 @@-6.23.0+6.24.0diff --git a/LifeOS/install/LIFEOS/ALGORITHM/changelog.md b/LifeOS/install/LIFEOS/ALGORITHM/changelog.mdindex 028dec38..70781d74 100644--- a/LifeOS/install/LIFEOS/ALGORITHM/changelog.md+++ b/LifeOS/install/LIFEOS/ALGORITHM/changelog.md@@ -9,7 +9,7 @@ The doctrine file (`vX.Y.Z.md`) holds **only doctrine** — what the Algorithm d- **v6.19.0** (2026-06-17) — **Agent consolidation: Forge + Cato → one cross-vendor agent.** Forge and Cato shared an engine (GPT-5.5 via `codex exec`) and differed only by sandbox flag + prompt; merged into one `Forge` agent with two prompt-set modes: `MODE: build` (workspace-write, `ForgeProgress.ts`, produces code) and `MODE: audit` (read-only, `CrossVendorAudit.ts`, the E4/E5 cross-vendor verification pass, formerly Cato). Rule 2a now spawns `Forge` in `MODE: audit`; added the **builder ≠ auditor invariant** (Forge never audits a slug Forge built — same-vendor self-review has no cross-vendor value, so the audit is skipped and the Claude Advisor covers the Claude side). `agents/Cato.md` deleted; `Agent(Cato)` removed from settings(.system).json; `cato` dropped from `CROSS_VENDOR` in models.ts (now `forge` covers both modes). Audit mode adopts new codex 0.137+ capabilities: `--output-schema` (schema-enforced verdict JSON), `--ephemeral` (no session litter on read-only passes), `codex doctor` (preflight), `codex exec review --base/--commit` (diff-targeted review for code ISAs). C/R/L: conjectured: cross-vendor build and cross-vendor audit needed two separate agents. refuted_by: both are thin launchers over the same `codex exec` engine, differing only in `--sandbox` + prompt — the separation cost maintenance and bought nothing. learned: the load-bearing separation is builder≠auditor *per task*, not two agent definitions. criterion_now: one agent, mode set by spawn prompt, invariant enforced in Rule 2a. Audit *function* unchanged (44 runs / 231 findings / 36 advisor-disagreements track record preserved). Origin: {{PRINCIPAL_NAME}} directive 2026-06-17 ("unify into a single badass"). Migration: `echo 6.19.0 > LATEST` (done). Rollback: `echo 6.18.0 > LATEST`, restore `agents/Cato.md`, re-add `Agent(Cato)` + `cato` pin. Deferred (descriptive tail, non-breaking): CatoContext.md→ForgeContext.md fold via CreateSkill; spinner tips via /ut; capabilities.md + DOCUMENTATION/* + Mason/Sage persona cross-refs; CrossVendorAudit.ts internal rename + the codex-feature wiring (documented, not yet coded).- **Patch 2026-06-29 (no version bump — zero behavior change): the three level axes named.** Audit found the level vocabularies tangled across files: `models.ts` named only the four-rung `EFFORT_MODEL` and never the harness reasoning-effort or composition axes; the model-rung→effort crossover (`max`→`xhigh`) lived buried as a literal in `Inference.ts`; the tier table's `Effort` and `Level` columns shared words without being labeled as different dials. Fix: added the **THREE LEVEL AXES** doc block + exported `HarnessEffort` type and `LEVEL_TO_HARNESS_EFFORT` map to `models.ts` (single source of truth for the crossover); `Inference.ts LEVEL_CONFIG` now consumes that map instead of hardcoding `effort`; the v6.19.0 tier table gained an axis-labeling note (Effort = reasoning, Level = model rung, ultracode = orthogonal composition). The statusline (`LIFEOS_StatusLine.sh`) already encoded this correctly (LEVEL from `effort.level`, XHIGH→ULT via output-style) — the fix lifts its correct model into the core files. tsc clean, runtime smoke green. One open lever left to {{PRINCIPAL_NAME}}: LifeOS dispatch caps reasoning at `xhigh`; harness effort `max` is reachable only via human `/effort max`. Out of scope (flagged): `LifeosSystemArchitecture.md`/`ARCHITECTURE_SUMMARY.md` still say "currently v6.18.0" in the Algorithm pipeline row.- **v6.18.0** (2026-06-17) — **Per-Task Intelligence Routing.** Features carry an optional `intelligence` level (`low|medium|high|max`) the BUILD dispatch reads, so a mixed-difficulty ISA no longer flattens every delegated Feature to its tier's level. Down-route-only, fail-expensive on unassigned, producer-locked, scored to the Feature's hardest ISC, shadow-logged to `MEMORY/OBSERVABILITY/intelligence-routing.jsonl`, scales E1–E5 (tier curve is the per-tier default). Also fixes the dead `Inference.ts` max→fallback — it resolved to the same model under `max==high==opus`, so a max failure re-hit the failing model (the bug that timed out the advisor twice); it now degrades to the first *distinct* lower rung. Point fixes: `IntegrityMaintenance.ts` + Telos chat route `low→medium` (under-powered). **The `max→fable` lineup flip is HELD** pending the fable/opus economics decision — `EFFORT_MODEL.max` stays `opus`. C/R/L: conjectured: one level per tier was the right dispatch granularity. refuted_by: an E4 run flattens a doc-edit and a concurrency redesign to the same max model — ~70–80% rung-inflated. learned: the unit of intelligence allocation is the task (Feature), not the run, and the existing Features table is already the dispatch unit. criterion_now: a Feature carries an explicit level; the dispatcher reads it; the tier curve is the fallback. Origin ISA: `MEMORY/WORK/20260616-task-intelligence-mapping-review/ISA.md`. Migration: `echo 6.18.0 > LATEST` (done). Rollback: `echo 6.17.0 > LATEST` + revert the `Inference.ts` fallback block.-- **v6.15.0** (2026-06-10) — **Four-Level Effort-Model Abstraction.** All Claude-family model routing now speaks four effort LEVELS — `max`/`high`/`medium`/`low` — bound to the lineup in exactly one place: `EFFORT_MODEL` in `LIFEOS/TOOLS/models.ts` (max→fable, high→opus, medium→sonnet, low→haiku). Two-layer design: a lineup change (model enters/exits the subscription) is a one-line `EFFORT_MODEL` edit; a version release is a one-line `CURRENT` edit. `Inference.ts` migrated from three levels (fast/standard/smart) to the same four, with legacy aliases (fast→low, standard→medium, smart→max) initially accepted as a migration shim, then REMOVED the same day per principal directive ("get rid of the old names", 2026-06-10) — unknown names now hard-error; the Arbol `LLMOptions.tier` vocabulary folded into the same four names (types.v2.ts, runner.v2.ts tierMap deleted, A_EXAMPLE_SUMMARIZE migrated), resolving the Cato flag. **Routing policy per {{PRINCIPAL_NAME}}'s directive 2026-06-10:** NATIVE delegated work → `high`; Algorithm E1–E3 dispatch → `high`; E4/E5 → `max`. **POLICY CHANGE: E3 delegates demote fable→opus** (E1/E2 and E4/E5 unchanged). Keystone-utility exception: EffortRouter classifier + Advisor pinned `max` at every tier (pending explicit ratification — Cato flag). Core-System Override restated: LifeOS-core tasks dispatch delegates at `max` regardless of tier. Sage/Mason reframed as "MAX personas"; `UpdateModels.ts --check` gained `checkAgentFrontmatter()` validating MAX-persona pins against `EFFORT_MODEL` (+ fable accepted in `--apply`). 34 consumer files migrated; Evals graders' `opus→smart` map was silently running Fable — fixed to `opus→high` (NOTE: eval-score baselines invalidated across 2026-06-10). C/R/L: conjectured: three levels expressed all caller intent. refuted_by: graders asking for Opus got Fable — under-specification fails upward, invisibly. learned: a level vocabulary one rung too coarse makes intent inexpressible. criterion_now: four levels, each caller states exact intent, mapping owns the binding. Origin ISAs: `MEMORY/WORK/20260610-effort-routing-four-level-abstraction/ISA.md` + `20260610-four-level-doc-propagation/ISA.md`. Migration: `echo 6.15.0 > LATEST` (done). Rollback: `echo 6.14.0 > LATEST` + revert `EFFORT_MODEL` consumers (Inference.ts level names self-degrade via aliases). Known gap: v6.13.0/v6.14.0 never received changelog entries (pre-existing debt, flagged 2026-06-10).+- **v6.15.0** (2026-06-10) — **Four-Level Effort-Model Abstraction.** All Claude-family model routing now speaks four effort LEVELS — `max`/`high`/`medium`/`low` — bound to the lineup in exactly one place: `EFFORT_MODEL` in `LIFEOS/TOOLS/models.ts` (max→fable, high→opus, medium→sonnet, low→haiku). Two-layer design: a lineup change (model enters/exits the subscription) is a one-line `EFFORT_MODEL` edit; a version release is a one-line `CURRENT` edit. `Inference.ts` migrated from three levels (fast/standard/smart) to the same four, with legacy aliases (fast→low, standard→medium, smart→max) initially accepted as a migration shim, then REMOVED the same day per principal directive ("get rid of the old names", 2026-06-10) — unknown names now hard-error; the Arbol `LLMOptions.tier` vocabulary folded into the same four names (types.v2.ts, runner.v2.ts tierMap deleted, A_EXAMPLE_SUMMARIZE migrated), resolving the Cato flag. **Routing policy per {{PRINCIPAL_NAME}}'s directive 2026-06-10:** NATIVE delegated work → `high`; Algorithm E1–E3 dispatch → `high`; E4/E5 → `max`. **POLICY CHANGE: E3 delegates demote fable→opus** (E1/E2 and E4/E5 unchanged). Keystone-utility exception: TheRouter classifier + Advisor pinned `max` at every tier (pending explicit ratification — Cato flag). Core-System Override restated: LifeOS-core tasks dispatch delegates at `max` regardless of tier. Sage/Mason reframed as "MAX personas"; `UpdateModels.ts --check` gained `checkAgentFrontmatter()` validating MAX-persona pins against `EFFORT_MODEL` (+ fable accepted in `--apply`). 34 consumer files migrated; Evals graders' `opus→smart` map was silently running Fable — fixed to `opus→high` (NOTE: eval-score baselines invalidated across 2026-06-10). C/R/L: conjectured: three levels expressed all caller intent. refuted_by: graders asking for Opus got Fable — under-specification fails upward, invisibly. learned: a level vocabulary one rung too coarse makes intent inexpressible. criterion_now: four levels, each caller states exact intent, mapping owns the binding. Origin ISAs: `MEMORY/WORK/20260610-effort-routing-four-level-abstraction/ISA.md` + `20260610-four-level-doc-propagation/ISA.md`. Migration: `echo 6.15.0 > LATEST` (done). Rollback: `echo 6.14.0 > LATEST` + revert `EFFORT_MODEL` consumers (Inference.ts level names self-degrade via aliases). Known gap: v6.13.0/v6.14.0 never received changelog entries (pre-existing debt, flagged 2026-06-10).- **v6.12.0** (2026-05-30) — **Standalone doctrine + recovered core.** Two problems fixed at once. (1) **Format:** from v6.6.0 onward each version file became a backward-chaining delta — v6.11.0 pointed to v6.9.0, which pointed to v6.8.0/v6.7.0/v6.6.0 for content marked "preserved unchanged" — so reading the doctrine meant merging 5+ files, and the delta/migration prose leaked into the run-time read. v6.12.0 is the first fully **standalone** version: read top-to-bottom with zero cross-references, zero "preserved unchanged"/"NEW vX"/"delta on" language. Change history lives ONLY here in changelog.md. Convention going forward: every version is authored standalone; historical delta files stay as archived snapshots. (2) **Recovery:** the delta chain had silently DROPPED core doctrine at the v5.6.0→v6.0.0 cut and thinned the top-of-file exposition across the 6.x deltas. v6.12.0 restores from v5.6.0: the full Deutsch hard-to-variability doctrine (master loop, testability=hard-to-variability, opacity→transparency, ISA-as-unit Coverage/Tightness/Uniqueness, euphoric-surprise-as-hard-to-variability-from-outside), the **🧬 ISA-Level Hard-to-Vary Audit (ILA)** and **🔬 Per-ISC Hard-to-Vary Audit** (both gone since v6.0.0), **📚 Feedback Memory Auto-Consult**, and the **🧹 Fluff Sweep** at VERIFY. All 6.x features retained and inlined with full text: twelve-section ISA + ISA Skill (v6.2.0), closed-enumeration thinking capabilities + Capability-Name Audit (v6.3.0), goal semantics/`principal_stated_goal`/anchoring (v6.4.0), density gate (v6.5.0), literal surfacing + calibrated reflection (v6.6.0), Context Sufficiency density+sufficiency+PLAN-refresh+NATIVE flag (v6.7.0), Frame-Drift Check (v6.8.0), Resume After Complete + realtime phase tracking (v6.9.0), Tier→Delegation Effort (v6.11.0). SUMMARY block restores the `🧬 ISA` + `🔬 HVA` lines. 762 lines vs v6.11.0's 115. Origin: {{PRINCIPAL_NAME}} directive 2026-05-30 ("get our core doctrine and everything added back, along with all the new stuff that's still supposed to be in the later versions, and make this 6.12.0"). Migration: `echo 6.12.0 > LATEST` (done). Rollback: `echo 6.11.0 > LATEST`. Deferred: update `LifeosSystemArchitecture.md` + `ARCHITECTURE_SUMMARY.md` version strings (currently say v6.11.0) and the stale `capabilities.md`/`Pipeline Topology` "v6.5.0" reference, on the next doc-sync pass.@@ -17,7 +17,7 @@ The doctrine file (`vX.Y.Z.md`) holds **only doctrine** — what the Algorithm d- **v6.6.0** (2026-05-14) — **Literal Surfacing + Calibrated Reflection.** Field finding from the 2026-05-14 Upgrade Recommend pass: `principal_stated_goal` was added to ISA frontmatter in v6.4.0 but unsurfaced in responses (247 missed-request + 216 repetition-loop entries in last 30 days of reflections); the LEARN-phase reflection JSONL carried `implied_sentiment` self-score only and never joined `MEMORY/LEARNING/SIGNALS/ratings.jsonl` where {{PRINCIPAL_NAME}}'s actual rating lived (3.2-point calibration gap, {{DA_NAME}} self-rates 7.6/10 over the same period {{PRINCIPAL_NAME}} rates 4.4/10); the weekly synthesis pipeline had been silent since 2026-04-22 because `com.lifeos.deriver.plist` runs ONLY `--hypothesize` and no scheduled runner invokes `LearningPatternSynthesis.ts --week`; format-drift and verification-miss failures (28+ logged + 125 occurrences avg 2.2/10 severity) had no structural enforcement. v6.6.0 fix: (1) NATIVE-mode `🗒️ TASK:` line MUST quote `GOAL_LITERAL` verbatim when present (≤80 chars + `…`); (2) `Inference.ts synthesizeAdvisorState()` prepends `PRINCIPAL STATED GOAL` block above ISA blob; (3) `CrossVendorAudit.ts assembleBundle()` inserts `===== PRINCIPAL STATED GOAL =====` as first section in all three bundle paths; (4) `Pulse/modules/work.ts` parses `principal_stated_goal` from local ISA frontmatter and renders inline on each Kanban card; (5) LEARN-phase reflection JSONL joins `ratings.jsonl` by `session_id` and inlines `daniel_rating`, `daniel_rating_source`, `daniel_rating_confidence` (null when rating not yet captured). Two new Stop hooks ship at the same release: `OutputFormatGate.hook.ts` enforces banner presence on every assistant response (decision:block on miss); `SuccessClaimGate.hook.ts` blocks "shipped/deployed/done/verified" claims that lack same-response tool-output evidence. Both honor `input.stop_hook_active` to prevent deadlock; the optional field is added to canonical `hooks/lib/hook-io.ts HookInput` interface. New `com.lifeos.synthesis.plist` launchd job runs `LearningPatternSynthesis.ts --week` daily at 03:05 PT (5-min offset from `com.lifeos.deriver`), restoring the silent weekly pipeline. C/R/L: conjectured: capturing `principal_stated_goal` in ISA frontmatter (v6.4.0) was sufficient to anchor downstream work to the literal. refuted_by: reflection-mining surfaced 463 entries in 30 days where the executor lost the literal between OBSERVE and EXECUTE because the field was never surfaced in the response banner, the advisor blob, the Cato bundle, the Pulse dashboard, or the reflection record — the field was captured but not consumed. learned: capturing a load-bearing field is necessary but not sufficient — every consumption surface must surface it explicitly, or the field becomes write-only memory. criterion_now: v6.6.0 doctrine lists five named surfaces (NATIVE banner, Inference state, Cato bundle, Pulse work module, reflection JSONL) that MUST surface the literal when present; each is enforced by code (Inference/Cato/Pulse), doctrine (system prompt), or a separate gate hook (OutputFormatGate for banner presence; literal-echo audit deferred). Migration: `echo 6.6.0 > LATEST && launchctl load ~/Library/LaunchAgents/com.lifeos.synthesis.plist && bun LIFEOS/TOOLS/LearningPatternSynthesis.ts --week`. Rollback: `echo 6.5.0 > LATEST && launchctl unload ~/Library/LaunchAgents/com.lifeos.synthesis.plist && rm ~/Library/LaunchAgents/com.lifeos.synthesis.plist` plus revert the two new hooks + the Pulse/Inference/Cato edits. v6.6.x deferred: extend `OutputFormatGate` to verify the literal echo in NATIVE banners (not just banner presence); reconcile density-gate threshold drift between v6.5.0 doctrine (`< 0.3` at E3 / `< 0.5` at E4+) and `Scaffold.md` Step 3.5 (single `< 0.5`).-- **v6.5.0** (2026-05-12, backfilled to Index on 2026-05-14) — **Density × Tier Gate at OBSERVE.** Stage 1 eligibility in `EffortRouter.hook.ts` emits `INTERVIEW_ELIGIBLE: true | false`; Stage 2 necessity in `skills/ISA/Workflows/Scaffold.md` Step 3.5 computes a deterministic 7-signal density score and fires `Skill("ISA", "interview")` with ≤3 questions + `proceed` override when below the tier threshold (`< 0.3` at E3 doctrine / `< 0.5` Scaffold implementation — drift noted in v6.6.0). Four new optional frontmatter keys: `density_score`, `interview_invoked`, `divergence_risk`, `density_gate_acknowledged`. Backwards-compat: presence-of-key is the v6.5.0+ marker; pre-v6.5.0 ISAs unaffected. Implementation ISA at `MEMORY/WORK/20260512-algorithm-v6.5.0-density-gate/ISA.md`.+- **v6.5.0** (2026-05-12, backfilled to Index on 2026-05-14) — **Density × Tier Gate at OBSERVE.** Stage 1 eligibility in `TheRouter.hook.ts` emits `INTERVIEW_ELIGIBLE: true | false`; Stage 2 necessity in `skills/ISA/Workflows/Scaffold.md` Step 3.5 computes a deterministic 7-signal density score and fires `Skill("ISA", "interview")` with ≤3 questions + `proceed` override when below the tier threshold (`< 0.3` at E3 doctrine / `< 0.5` Scaffold implementation — drift noted in v6.6.0). Four new optional frontmatter keys: `density_score`, `interview_invoked`, `divergence_risk`, `density_gate_acknowledged`. Backwards-compat: presence-of-key is the v6.5.0+ marker; pre-v6.5.0 ISAs unaffected. Implementation ISA at `MEMORY/WORK/20260512-algorithm-v6.5.0-density-gate/ISA.md`.- **v6.4.0** (2026-05-12, backfilled to Index on 2026-05-14) — **ISA Absorbs `/goal` Semantics.** Four-signal goal-detection step in OBSERVE captures the user's verbatim ask into `principal_stated_goal:` frontmatter when min-content rule passes. New `anchors_to` column on Test Strategy links each ISC to the literal. Phase-by-phase mapping for OBSERVE→LEARN consumes the literal as the evidence anchor (Rule 1 probes use it as reference), not the optimization target (BUILD/EXECUTE optimize for the intent the literal expresses). Cato (Rule 2a) is the cross-vendor probe that surfaces literal-vs-intent drift. Implementation ISA at `MEMORY/WORK/20260512-isa-absorbs-goal-v6.4.0-ship/ISA.md`.diff --git a/LifeOS/install/LIFEOS/ALGORITHM/modes/README.md b/LifeOS/install/LIFEOS/ALGORITHM/modes/README.mdindex 4ea8685d..15ab49a7 100644--- a/LifeOS/install/LIFEOS/ALGORITHM/modes/README.md+++ b/LifeOS/install/LIFEOS/ALGORITHM/modes/README.md@@ -46,7 +46,7 @@ LifeOS has two distinct "mode" concepts. They overlap at the Native tab.| Layer | Concept | Where set | Values ||-------|---------|-----------|--------|-| **Layer 1 — Response Mode** | Shape of the output template | `hooks/EffortRouter.hook.ts` at UserPromptSubmit | MINIMAL / NATIVE / ALGORITHM |+| **Layer 1 — Response Mode** | Shape of the output template | `hooks/TheRouter.hook.ts` at UserPromptSubmit | MINIMAL / NATIVE / ALGORITHM || **Layer 2 — Algorithm Mode** | Cognitive pattern the Algorithm runs | Algorithm at OBSERVE (writes ISA frontmatter `mode:`) | iterate / optimize / ideate / loop |**Native is the only tab that crosses both layers** — it surfaces sessions classified as Layer 1 NATIVE for Pulse display, even though no Layer 2 mode (and no ISA) was created.@@ -68,7 +68,7 @@ Set at the **OBSERVE phase** of the Algorithm via deterministic trigger detectio### Response-mode crossover (Native)-Set by `hooks/EffortRouter.hook.ts` at UserPromptSubmit. When the EffortRouter classifier emits `MODE: NATIVE`, session metadata captures `mode: native` for Pulse display. No full ISA created.+Set by `hooks/TheRouter.hook.ts` at UserPromptSubmit. When the TheRouter classifier emits `MODE: NATIVE`, session metadata captures `mode: native` for Pulse display. No full ISA created.### External pipeline (Ladder)diff --git a/LifeOS/install/LIFEOS/ALGORITHM/modes/loop.md b/LifeOS/install/LIFEOS/ALGORITHM/modes/loop.mdindex 69a67a9b..762f1d31 100644--- a/LifeOS/install/LIFEOS/ALGORITHM/modes/loop.md+++ b/LifeOS/install/LIFEOS/ALGORITHM/modes/loop.md@@ -36,7 +36,7 @@ A Loop run:## When Loop engages-Auto-detection by `hooks/EffortRouter.hook.ts` (extended classifier):+Auto-detection by `hooks/TheRouter.hook.ts` (extended classifier):```LOOP_HINT: yes | nodiff --git a/LifeOS/install/LIFEOS/ALGORITHM/modes/native.md b/LifeOS/install/LIFEOS/ALGORITHM/modes/native.mdindex 0c03ca51..350fd4fd 100644--- a/LifeOS/install/LIFEOS/ALGORITHM/modes/native.md+++ b/LifeOS/install/LIFEOS/ALGORITHM/modes/native.md@@ -14,10 +14,10 @@ status: response-mode-crossover## What Native is-Native is the **NATIVE response mode** — set by `hooks/EffortRouter.hook.ts` at UserPromptSubmit when the EffortRouter classifier (level `max` via `EFFORT_MODEL`) determines the prompt's ideal state is pre-articulable in one line.+Native is the **NATIVE response mode** — set by `hooks/TheRouter.hook.ts` at UserPromptSubmit when the TheRouter classifier (level `max` via `EFFORT_MODEL`) determines the prompt's ideal state is pre-articulable in one line.When in NATIVE response mode:-- The output template is the NATIVE template (see `PAI/LIFEOS_SYSTEM_PROMPT.md` § Mode Templates).+- The output template is the NATIVE template (see `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` § Mode Templates).- No ISA is created.- No 7-phase Algorithm runs.- Full skill / agent / parallel-research / extended-thinking capabilities remain available.@@ -35,7 +35,7 @@ Even though no ISA is created, NATIVE response runs record session metadata to `## When NATIVE response mode is selected-EffortRouter classifier rules (from `EffortRouter.hook.ts`):+TheRouter classifier rules (from `TheRouter.hook.ts`):- Fact lookup with one tool call.- Single-line edit on a named file.@@ -52,7 +52,7 @@ The discriminator is whether the **ideal state is pre-articulable in one line**.**A short, clearly-stated *question* is not NATIVE by virtue of being short.** Route by the ANSWER, not the question: if a good answer would be *retrieved* (facts to look up and assemble) it's NATIVE; if it must be *constructed* by analytical synthesis against external/contested evidence, its correctness not checkable at a glance — a hard science / philosophy / technical question whose answer doesn't exist until you build it — it's ALGORITHM (E3 default, E4 across contested fields). The test is VERIFIABILITY, not synthesis: opinion/advice/personal-judgment questions ("should I learn Rust or Go", "why do I procrastinate") stay NATIVE even though they synthesize — the reader can weigh the take at a glance. A one-line question is not a one-line answer. This is the canonical NATIVE→ALGORITHM misroute.-Under-escalation is the failure mode the EffortRouter was built to prevent. When in doubt between NATIVE and ALGORITHM E3, the classifier picks ALGORITHM E3.+Under-escalation is the failure mode the TheRouter was built to prevent. When in doubt between NATIVE and ALGORITHM E3, the classifier picks ALGORITHM E3.## ISA frontmatter (not used)@@ -83,6 +83,6 @@ Five of six Pulse tabs map to ALGORITHM response mode plus an Algorithm-internal## Cross-references- All modes: [`README.md`](README.md)-- Response mode classifier: `hooks/EffortRouter.hook.ts`-- Mode templates (output shape): `PAI/LIFEOS_SYSTEM_PROMPT.md` § "Mode Templates"-- Constitutional discriminator rule: `PAI/LIFEOS_SYSTEM_PROMPT.md` § "Mode Architecture"+- Response mode classifier: `hooks/TheRouter.hook.ts`+- Mode templates (output shape): `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` § "Mode Templates"+- Constitutional discriminator rule: `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` § "Mode Architecture"diff --git a/LifeOS/install/LIFEOS/ALGORITHM/v6.23.0.md b/LifeOS/install/LIFEOS/ALGORITHM/v6.23.0.mdindex 6a9b1a36..074e32aa 100644--- a/LifeOS/install/LIFEOS/ALGORITHM/v6.23.0.md+++ b/LifeOS/install/LIFEOS/ALGORITHM/v6.23.0.md@@ -2,7 +2,7 @@> **v6.23.0 changelog (retired the Claude-persona agents + corrected the override claim):** The static persona agents **Engineer, Architect, Designer** are retired (deleted from `agents/`) — generic costumes a capable model + a job-specific brief on `general-purpose` beats (BPE), and the Agents skill already prescribed composing on `general-purpose` over the static types. Every live reference (settings permissions, Delegation/Agents docs, Council members, the system-prompt dispatch example, this doctrine) was rewired to `general-purpose`+brief or `ComposeAgent`. **Kept:** cross-vendor agents (Forge, the 5 researchers), ClaudeResearcher. (**Silas** and the **Gene** persona were retired 2026-07-02: Silas was a Claude-only offensive-security costume `_HELIOS` now drives via `general-purpose`+brief; Gene was a `model: sonnet` wrapper over the GLM/`OpenRouter.ts` route, which stays as a tool + `EgressClassGuard` hook.) This also **corrects a false claim in v6.22.0**: the dispatch `model` param does NOT universally override frontmatter — an agent with an `initialPrompt` field (the retired Engineer) deterministically ignored it (ran Opus 2/2 vs `@fable`), while `general-purpose` and frontmatter-opus `Architect` honored it. And the `🤖 DISPATCH` line records INTENT, not execution (a Forge dispatch logged `gpt-5.5` ran Opus) — the only proof is the transcript's `.message.model`. No gate/floor/threshold/phase changed.-> **v6.22.0 changelog (lineup flip + classifier re-pin — Fable is the top rung):** `EFFORT_MODEL.max` flips **opus → fable** (`LIFEOS/TOOLS/models.ts`), executing the long-anticipated "flip when Fable returns" now that Fable is reachable again (probed live 2026-07-01: `claude --model fable` → clean completion). The routing ladder is real again: **max=Fable** (Algorithm E4/E5 + every Core-System Override task) → **high=Opus** (E1–E3 + NATIVE) → **medium=Sonnet** (utility + down-routed Features) → **low=Haiku**; Per-Task Intelligence Routing (v6.18.0) still carries any single Feature down to Sonnet inside an E5 run. **No Fable agent** — Fable is a model rung reached by the dispatch-time `model` param, not a persona; the four-level abstraction was built so adding it is a one-line change. Ships with two guardrails: **(a)** the EffortRouter classifier is **re-pinned from `max` to `high`** (`hooks/EffortRouter.hook.ts`) — it fires on every prompt, so the per-prompt keystone stays on cheap/fast Opus; its model is UNCHANGED (Opus before via max=opus, Opus now via high). "Keystone" means highest-leverage, never most-expensive rung. **(b)** the **Advisor stays at `max`** (now Fable) for the once-per-deliverable commitment call. `max` and `high` are now distinct models, so the `Inference.ts` max→high fallback (fable→opus) is a genuinely real degrade. **Supersedes the 2026-06-30 "Opus stays top" decision**, which held only while Fable was unavailable. No gate, floor, threshold, phase, or tier-table Level column changed — E4/E5 still dispatch `max`; `max` simply resolves to Fable now.+> **v6.22.0 changelog (lineup flip + classifier re-pin — Fable is the top rung):** `EFFORT_MODEL.max` flips **opus → fable** (`LIFEOS/TOOLS/models.ts`), executing the long-anticipated "flip when Fable returns" now that Fable is reachable again (probed live 2026-07-01: `claude --model fable` → clean completion). The routing ladder is real again: **max=Fable** (Algorithm E4/E5 + every Core-System Override task) → **high=Opus** (E1–E3 + NATIVE) → **medium=Sonnet** (utility + down-routed Features) → **low=Haiku**; Per-Task Intelligence Routing (v6.18.0) still carries any single Feature down to Sonnet inside an E5 run. **No Fable agent** — Fable is a model rung reached by the dispatch-time `model` param, not a persona; the four-level abstraction was built so adding it is a one-line change. Ships with two guardrails: **(a)** the TheRouter classifier is **re-pinned from `max` to `high`** (`hooks/TheRouter.hook.ts`) — it fires on every prompt, so the per-prompt keystone stays on cheap/fast Opus; its model is UNCHANGED (Opus before via max=opus, Opus now via high). "Keystone" means highest-leverage, never most-expensive rung. **(b)** the **Advisor stays at `max`** (now Fable) for the once-per-deliverable commitment call. `max` and `high` are now distinct models, so the `Inference.ts` max→high fallback (fable→opus) is a genuinely real degrade. **Supersedes the 2026-06-30 "Opus stays top" decision**, which held only while Fable was unavailable. No gate, floor, threshold, phase, or tier-table Level column changed — E4/E5 still dispatch `max`; `max` simply resolves to Fable now.> **v6.21.0 changelog (additive — prerequisite manifest):** the THINK `☑️ PREREQUISITES CHECK` label is sharpened into a deterministic, blocking **Prerequisite Manifest** with a mandatory `🔑 PREREQUISITES` output line; OBSERVE Gate B now seeds it. Any MISSING external prerequisite (auth token, CLI login, service config, deploy target, required secret) blocks EXECUTE until reachable or deferred in `## Decisions`. Answers the reflection log's most-cited failure (134 occurrences: dead token / un-authed CLI / missing key discovered mid-EXECUTE). **No new hook, tool, gate, floor, threshold, or sequence** — one existing gate sharpened, per a BitterPillEngineering audit that cut the generic probe examples and kept only the non-obvious Cloudflare scope-match gotcha.@@ -81,7 +81,7 @@ New thinking capabilities are added by editing `capabilities.md` and bumping the**The four-level effort-model abstraction (v6.15.0).** All Claude-family model routing speaks in four effort LEVELS — `max` / `high` / `medium` / `low` — bound to the lineup in exactly one place: `EFFORT_MODEL` in `LIFEOS/TOOLS/models.ts` (today: **max→fable**, high→opus, medium→sonnet, low→haiku — the `max→fable` flip went LIVE 2026-07-01 once Fable was reachable again; Fable is ~2× Opus, so the top rung's cost lands only on E4/E5 + Core-System work). `Inference.ts` exposes the same four levels (`--level low|medium|high|max`; these are the ONLY accepted names — legacy fast/standard/smart were removed 2026-06-10 and unknown names hard-error). Doctrine, hooks, skills, and agents state INTENT (the level); the mapping resolves the model. A lineup change (a model enters/exits the subscription or moves rungs) is a one-line `EFFORT_MODEL` edit; a version release is a one-line `CURRENT` edit. Nothing outside models.ts names a Claude model for routing.-**The routing policy:** **NATIVE-mode delegated work runs at `high`. Algorithm E1–E3 dispatch at `high`. E4/E5 dispatch at `max` (Fable).** Keystone exception: the Advisor is pinned `max` at every tier (the commitment-boundary reviewer, worth Fable once per deliverable). The EffortRouter classifier — the highest-leverage decision in LifeOS, but one that fires on EVERY prompt — is pinned **`high` (Opus)**, re-pinned off `max` on 2026-07-01 so flipping `max→fable` didn't put Fable on every prompt; keystone means highest-leverage, not most-expensive rung. `medium` and `low` remain sanctioned at any tier for utility inference — classification, summarization, vision triage — so cheap calls never silently ride an expensive model.+**The routing policy:** **NATIVE-mode delegated work runs at `high`. Algorithm E1–E3 dispatch at `high`. E4/E5 dispatch at `max` (Fable).** Keystone exception: the Advisor is pinned `max` at every tier (the commitment-boundary reviewer, worth Fable once per deliverable). The TheRouter classifier — the highest-leverage decision in LifeOS, but one that fires on EVERY prompt — is pinned **`high` (Opus)**, re-pinned off `max` on 2026-07-01 so flipping `max→fable` didn't put Fable on every prompt; keystone means highest-leverage, not most-expensive rung. `medium` and `low` remain sanctioned at any tier for utility inference — classification, summarization, vision triage — so cheap calls never silently ride an expensive model.The main loop's effort AND model are fixed at turn start and cannot be changed mid-flight — a `UserPromptSubmit` hook can classify the tier but cannot set the model (only `SessionStart` hooks see a `model` field, and none can write it; there is no built-in complexity→model router). But the Algorithm does its heavy thinking through agents it spawns, and *both their effort and their Claude model* are programmable per dispatch. The tier scales dispatched-agent effort and selects the dispatched level; the principal-selected main loop orchestrates and verifies. Selected at the PLAN Delegation Gate; recorded as one `## Decisions` row + the `🎚️ DELEGATION EFFORT:` line.@@ -109,7 +109,7 @@ Two pieces are NOT optional, because each stops a failure a capable model still## Mode Classification-**Mode and tier are decided by the EffortRouter classifier at UserPromptSubmit** (`hooks/EffortRouter.hook.ts`, `Inference.ts --level high` — Opus; re-pinned off `max` on 2026-07-01 so the per-prompt keystone doesn't ride Fable), written into additionalContext:+**Mode and tier are decided by the TheRouter classifier at UserPromptSubmit** (`hooks/TheRouter.hook.ts`, `Inference.ts --level high` — Opus; re-pinned off `max` on 2026-07-01 so the per-prompt keystone doesn't ride Fable), written into additionalContext:```MODE: MINIMAL | NATIVE | ALGORITHM (always)@@ -150,7 +150,7 @@ curl -s -X POST http://localhost:31337/notify -H "Content-Type: application/jsonEntry: `"Entering the Algorithm"` (before OBSERVE). Transitions: `"Entering the PHASE_NAME phase."` (first action each phase).-**Phase-tracking layering (one source of truth, three writers):** ISA frontmatter `phase:` is ground truth; `ISASync.hook.ts` syncs ISA edits to `work.json`; `bun ~/.claude/LIFEOS/TOOLS/AlgoPhase.ts <phase>` is the operational write that drives the real-time dashboard at each transition; the chat phase header is decorative. Invoke order at every transition: **phase header → AlgoPhase CLI → voice curl → ISA edit.** Pulse SSE (`GET /api/algorithm/stream`, 100ms `work.json` poll) renders end-to-end under 250ms p95. EffortRouter pre-writes `currentMode: 'algorithm'` + `phase: 'starting'` on classification to kill the wrong-display window. If the dashboard is stuck, check ISA frontmatter first.+**Phase-tracking layering (one source of truth, three writers):** ISA frontmatter `phase:` is ground truth; `ISASync.hook.ts` syncs ISA edits to `work.json`; `bun ~/.claude/LIFEOS/TOOLS/AlgoPhase.ts <phase>` is the operational write that drives the real-time dashboard at each transition; the chat phase header is decorative. Invoke order at every transition: **phase header → AlgoPhase CLI → voice curl → ISA edit.** Pulse SSE (`GET /api/algorithm/stream`, 100ms `work.json` poll) renders end-to-end under 250ms p95. TheRouter pre-writes `currentMode: 'algorithm'` + `phase: 'starting'` on classification to kill the wrong-display window. If the dashboard is stuck, check ISA frontmatter first.---diff --git a/LifeOS/install/LIFEOS/ALGORITHM/v6.24.0.md b/LifeOS/install/LIFEOS/ALGORITHM/v6.24.0.mdnew file mode 100644index 00000000..a0ca0723--- /dev/null+++ b/LifeOS/install/LIFEOS/ALGORITHM/v6.24.0.md@@ -0,0 +1,485 @@+# The Algorithm 6.24.0++> **v6.24.0 changelog (additive — motion/interaction evidence, one clause):** Verification Doctrine **Rule 1** gains a **Motion/interaction fidelity** clause: an ISC whose subject is *motion* (animation, transition, drag, hover-state, scroll, loading/skeleton state, or a multi-step flow) closes ONLY on a **ScrubFlow** frame-scrub gallery (dense frames + SSIM anomaly flag) or a VerifyDeploy ordered flow-gallery — never a single still, because one screenshot cannot capture motion. Keyword-anchored trigger so it doesn't tax every web task; static-render ISCs still close on one screenshot. Ships with two new Interceptor surfaces (`skills/Interceptor/Tools/FrameScrub.ts` survey+scrub modes, `skills/Interceptor/Workflows/ScrubFlow.md`) and a `SuccessClaimGate.hook.ts` `INTERCEPTOR_EVIDENCE` extension that accepts the frame-scrub manifest (keyed on the manifest the model viewed, NOT a bare video path). Distilled from the Krieger "verification-pilled" interview; frame-extraction+SSIM half proven live, in-extension recording deferred to a documented next increment. No gate, floor, threshold, tier table, or sequence changed — one Rule 1 clause added.++> **v6.23.0 changelog (retired the Claude-persona agents + corrected the override claim):** The static persona agents **Engineer, Architect, Designer** are retired (deleted from `agents/`) — generic costumes a capable model + a job-specific brief on `general-purpose` beats (BPE), and the Agents skill already prescribed composing on `general-purpose` over the static types. Every live reference (settings permissions, Delegation/Agents docs, Council members, the system-prompt dispatch example, this doctrine) was rewired to `general-purpose`+brief or `ComposeAgent`. **Kept:** cross-vendor agents (Forge, the 5 researchers), ClaudeResearcher. (**Silas** and the **Gene** persona were retired 2026-07-02: Silas was a Claude-only offensive-security costume `_HELIOS` now drives via `general-purpose`+brief; Gene was a `model: sonnet` wrapper over the GLM/`OpenRouter.ts` route, which stays as a tool + `EgressClassGuard` hook.) This also **corrects a false claim in v6.22.0**: the dispatch `model` param does NOT universally override frontmatter — an agent with an `initialPrompt` field (the retired Engineer) deterministically ignored it (ran Opus 2/2 vs `@fable`), while `general-purpose` and frontmatter-opus `Architect` honored it. And the `🤖 DISPATCH` line records INTENT, not execution (a Forge dispatch logged `gpt-5.5` ran Opus) — the only proof is the transcript's `.message.model`. No gate/floor/threshold/phase changed.++> **v6.22.0 changelog (lineup flip + classifier re-pin — Fable is the top rung):** `EFFORT_MODEL.max` flips **opus → fable** (`LIFEOS/TOOLS/models.ts`), executing the long-anticipated "flip when Fable returns" now that Fable is reachable again (probed live 2026-07-01: `claude --model fable` → clean completion). The routing ladder is real again: **max=Fable** (Algorithm E4/E5 + every Core-System Override task) → **high=Opus** (E1–E3 + NATIVE) → **medium=Sonnet** (utility + down-routed Features) → **low=Haiku**; Per-Task Intelligence Routing (v6.18.0) still carries any single Feature down to Sonnet inside an E5 run. **No Fable agent** — Fable is a model rung reached by the dispatch-time `model` param, not a persona; the four-level abstraction was built so adding it is a one-line change. Ships with two guardrails: **(a)** the TheRouter classifier is **re-pinned from `max` to `high`** (`hooks/TheRouter.hook.ts`) — it fires on every prompt, so the per-prompt keystone stays on cheap/fast Opus; its model is UNCHANGED (Opus before via max=opus, Opus now via high). "Keystone" means highest-leverage, never most-expensive rung. **(b)** the **Advisor stays at `max`** (now Fable) for the once-per-deliverable commitment call. `max` and `high` are now distinct models, so the `Inference.ts` max→high fallback (fable→opus) is a genuinely real degrade. **Supersedes the 2026-06-30 "Opus stays top" decision**, which held only while Fable was unavailable. No gate, floor, threshold, phase, or tier-table Level column changed — E4/E5 still dispatch `max`; `max` simply resolves to Fable now.++> **v6.21.0 changelog (additive — prerequisite manifest):** the THINK `☑️ PREREQUISITES CHECK` label is sharpened into a deterministic, blocking **Prerequisite Manifest** with a mandatory `🔑 PREREQUISITES` output line; OBSERVE Gate B now seeds it. Any MISSING external prerequisite (auth token, CLI login, service config, deploy target, required secret) blocks EXECUTE until reachable or deferred in `## Decisions`. Answers the reflection log's most-cited failure (134 occurrences: dead token / un-authed CLI / missing key discovered mid-EXECUTE). **No new hook, tool, gate, floor, threshold, or sequence** — one existing gate sharpened, per a BitterPillEngineering audit that cut the generic probe examples and kept only the non-obvious Cloudflare scope-match gotcha.++> **v6.20.0 changelog (clarification — ultracode is not an effort level):** the tier table's **Effort** column previously put `ultracode` in E5's cell, conflating the composition axis with the reasoning-effort axis. **ultracode is a composition layer** (fan into a `Workflow`), so it moves out of the Effort column into the E5 dispatch profile. **E5 effort stays `xhigh`** — the dispatch cap is unchanged and no LifeOS dispatch emits `max` reasoning. (An interim edit set E5 effort to `max`; it contradicted `LEVEL_TO_HARNESS_EFFORT`'s xhigh cap and was reverted after a cross-vendor BPE audit, 2026-06-29.) No model-rung change (E1–E3 `high`, E4/E5 `max` stand, per the 2026-06-10 directive); statusline untouched. Same-day BPE audit (E4 + cross-vendor Forge) then **trimmed Per-Task Intelligence Routing from six bullets to two paragraphs** — kept producer-lock + shadow-log (the two pieces that stop real under-load failures), cut the rubric/tie-break/fail-expensive/scales/display prose a capable orchestrator doesn't need — **merged the thrice-stated main-loop-immutability rule to one statement**, and removed the embedded v6.15.0 historical note (its policy is already in the table + this block). ~400 words out, zero mechanisms lost.++> **v6.19.0 changelog (additive — agent consolidation):** **Forge and Cato are unified into one cross-vendor agent (`Forge`) with two prompt-set modes — `MODE: build` (workspace-write, produces code) and `MODE: audit` (read-only, the E4/E5 cross-vendor verification pass, formerly Cato).** Same GPT-5.5/`codex exec` engine; the mode picks the sandbox + helper. Rule 2a now spawns `Forge` in `MODE: audit` instead of a separate `Cato` agent, and adds the **builder ≠ auditor invariant**: Forge never audits a slug Forge built (same-vendor self-review has no cross-vendor value — on a Forge-built task the audit is skipped and the Claude Advisor covers the Claude side). The audit helper (`CrossVendorAudit.ts`) and findings log (`cato-findings.jsonl`) are unchanged. New codex 0.137+ capabilities adopted by audit mode: `--output-schema` (schema-enforced verdict JSON), `--ephemeral` (no session litter), `codex doctor` (preflight), `codex exec review --base/--commit` (diff-targeted review for code ISAs). No gate, floor, threshold, or sequence changed.+>+> **v6.18.0 changelog (additive — per-task intelligence routing):** adds **Per-Task Intelligence Routing** (new subsection under *Tier → Delegation Effort & Model*). Features carry an optional `intelligence` level (`low|medium|high|max`) the BUILD dispatch reads, so a mixed-difficulty ISA no longer flattens every delegated Feature to its tier's single level. Down-route-only, **fail-expensive** on unassigned, **producer-locked** (a Feature others `depend_on` can't drop below the curve), scored to the Feature's **hardest ISC**, **shadow-logged** to `MEMORY/OBSERVABILITY/intelligence-routing.jsonl`. Scales **E1–E5** — the tier curve is the per-tier default the dispatch falls back to. Also records the `Inference.ts` dead-fallback fix (the `max→high` retry resolved to the same model under `max==high==opus`; it now degrades to the first distinct lower rung). No existing gate, floor, threshold, or sequence changed. The `max→fable` lineup flip is **NOT** included — Fable is the intended MAX-mode model but is ~2× Opus and currently UNAVAILABLE, so `max→opus` is correct for now (not a regression); flip `max→fable` when Fable returns.+>+> **v6.17.0 changelog (additive — one rule):** adds **Verification Doctrine Rule 4 — Class-Sweep**: once a defect is identified as an instance of a class, the originating ISC cannot close until a grep/glob enumeration lists every sibling instance and each is fixed-and-verified or tombstoned. Answers the reflection log's highest-frequency failure cluster (fix-the-first-instance, never sweep the class). No existing gate, floor, threshold, or sequence changed; Rules 1/2/2a/3 are untouched.+>+> **v6.16.0 changelog (deflation pass, R2 of the Fable-prompt upgrades):** rhetorical "CRITICAL FAILURE" labels replaced with their actual consequences (which gate rejects what); no gate, floor, threshold, or sequence changed. The constitutional tier (five numbered constitutionals) now lives in LIFEOS_SYSTEM_PROMPT.md; doctrine states consequences, hooks enforce them. Shipped alongside: `DriftReminder.hook.ts`, `SkillSurface.hook.ts`.++## Doctrine — Read This First, Internalize It++**LifeOS moves a person from current state to ideal state by writing down what done looks like as testable claims, then refining the writing until every claim survives every test it can be subjected to.** That is the master loop, in any domain — code, science, art, philosophy, life decisions, business. Every Algorithm run instantiates it on one task.++**Hard-to-variability is the quality standard — and the outcome.** David Deutsch's epistemology: knowledge is hard-to-vary explanation, a description where every detail plays a functional role, so contrary evidence has nowhere to flee. The ISA (Ideal State Artifact) is the written hard-to-vary explanation of the ideal state for one task. It is both the *target* the work climbs toward AND what *emerges* from the climb — the same fact in two tenses. A good ISA cannot be varied without destroying the goal; a bad one has fluff that could be weakened without changing the outcome. The operational form is the **Variation Test** (ISC Quality System): can I vary this without destroying the goal? If yes, it needs refinement.++**Testability is hard-to-variability made operational.** An ISC (Ideal State Criterion) is hard-to-vary if and only if you can name a test that would falsify it. Verification is the scientific method applied to ISCs — hypothesis, experiment, result, refine. **Without verification there is no up or down on the hill; testability and evals ARE the climbing mechanism, not an adjacent concern.** The granularity rule and the Splitting Test (ISC Quality System) enforce this concretely.++**Opacity → transparency is the design move.** Vague intent enters; the Algorithm climbs the writing toward explicit, testable, falsifiable. The Goal paragraph is the tightest verbal form; the ISC set is its decomposition; verification confirms the explanation held against reality.++**The ISA is the unit, not the ISC.** Per-ISC hard-to-variability is necessary but not sufficient. The whole ISA must pass three system-level tests, re-run at every phase boundary when new signal could break them:+- **Coverage** — every facet of "done" maps to ≥1 ISC (no gaps).+- **Tightness** — no subset of ISCs is removable while still satisfying the goal (no redundancy).+- **Uniqueness** — no meaningfully different ISC set satisfies the same goal (the goal is precisely specified).++**The ISA is one primitive with five identities:** (1) the ideal-state articulation, (2) the test harness (ISCs ARE the tests, with named probes), (3) the build verification, (4) the done condition, (5) the system of record for the thing being articulated. Don't invent parallel artifacts (acceptance.yaml, separate test specs) — the ISA already covers this. Complex apps carry far more ISCs because their ideal state includes API behavior, performance budgets, security model, RBAC, auth, and data-integrity invariants alongside task deliverables.++**The unit is the thing, not the task.** For anything with persistent identity (an app, CLI, library, security system, this Algorithm), the ISA lives WITH it — `<project>/ISA.md` — and is its system of record; tasks read it at OBSERVE, extend it through BUILD/EXECUTE, commit refinements at LEARN. For ad-hoc work, `MEMORY/WORK/{slug}/ISA.md` holds. Format is identical. The ISA has **twelve sections in fixed order**, empty sections never appearing (full table + the three-guardrail taxonomy live in *ISA as System of Record*).++**The literal is the evidence anchor (principle).** When the principal states the goal in the prompt, that literal is preserved verbatim and becomes the anchor every downstream gate verifies against. Its **surface form is never the optimization target; its intent is exactly what BUILD/EXECUTE optimize for.** Mechanics live in *Principal-Stated Goal*.++**Three principles bind universally; their mechanics live in their sections.** (a) **Context sufficiency precedes work** — before any substantive artifact, check whether context is sufficient to articulate ideal state without speculation; the trigger is *"could I be wrong about what done means?"*, not *"is the prompt long?"* It binds NATIVE, ALGORITHM, subagents, Telegram, iMessage, Pulse-Assistant, every skill (mechanics: *Context Sufficiency*). (b) **Frame-drift detection follows execution** — Context Sufficiency gets the FRAME right; the Frame-Drift Check (noun coverage / verb fidelity / scope match) confirms the ANSWER didn't drift (mechanics: *Frame-Drift Check*). (c) **Resume is bidirectional** — within an iteration observe→…→complete (one-way); across iterations complete→learn automatically, because iteration N+1 starts from "what we know after N ended" (mechanics: *Resume After Complete*).++**The experiential metric is euphoric surprise** — what the principal feels when a hard-to-vary explanation meets novelty: an answer that clicks in a way they couldn't predict but instantly recognize as true. It is not a separate target from hard-to-variability — the epistemic test of a good explanation and the experiential test of meeting one are the same phenomenon, inside vs. outside. For experiential goals (art, design, anything that must *land*), euphoric surprise on encounter is the principal's falsification test.++**Core loop:** current state → ideal state, ISA as living hard-to-vary explanation, ISCs as testable decomposition, verification as scientific-method confirmation, refinement as the writing tightening through pursuit. **Goal: euphoric surprise on convergence — across iterations, not just within one.** When a rule below seems heavy, ask whether removing it would let the ISA vary without destroying the goal; if it would, the rule earns its place.++---++## Effort Levels++| Tier | Budget | ISC Floor (soft) | Thinking Floor (HARD) | Delegation Floor (soft) | Density Gate | When |+|------|--------|------------------|-----------------------|-------------------------|--------------|------|+| **E1** Standard | <90s | none | 0–1 | 0 | fires `< 0.10` (signals 2–7) | Normal request (DEFAULT) |+| **E2** Extended | <3min | **≥16** | **≥2** | **≥1** | fires `< 0.20` | Quality must be extraordinary |+| **E3** Advanced | <10min | **≥32** | **≥4** | **≥2** | fires `< 0.30` | Substantial multi-file work |+| **E4** Deep | <30min | **≥128** | **≥6 HARD** | **≥2** | fires `< 0.50` | Complex design |+| **E5** Comprehensive | <120min+ | **≥256** | **≥8 HARD** | **≥4** | `< 0.50` + Interview mandatory | No time pressure |++**Time budget is the hard constraint.** Density-gate thresholds + Sufficiency Check live in *Context Sufficiency*; the ISC floor and granularity in *ISC Quality System*; the thinking enumeration below.++**Floor semantics (each stated once):**+- **ISC floor is SOFT.** If natural N (from the granularity rule) is below the floor, *either* keep splitting — the usual case, a likely coverage gap — *or* document the escape in `## Decisions` for genuinely small-surface work. No threshold is ever retuned to hit a floor.+- **E1 has no mandatory count;** `0–1` describes the realistic range for the speed tier, not a floor.+- **Thinking floor is HARD at E2+** and cannot be relaxed via show-your-math. Difficult work earns thinking depth. Names MUST come verbatim from the closed enumeration below.+- **Delegation floor is SOFT** — sometimes work is genuinely single-author; show-your-math in `## Decisions` to go under.++**Tier intent.** The speed range must feel dramatic. E1 is the fast lane (<90s, doctrine light). E2 structured-but-quick. E3 substantial middle. E4/E5 are where full doctrine — ISA-Level audit, per-ISC HVA, advisor, Forge audit-mode cross-vendor pass, deeper verification — earns its cost. Never let ceremony eat the budget.++**Auto-include bindings (set here, invoked in Execution):** ISA Skill (E2+); **Forge build mode** (GPT-5.5 via `codex exec`) at E3/E4/E5 for any coding task, always when {{PRINCIPAL_NAME}} names "Forge"; **Forge audit mode** (GPT-5.5 via `codex exec --sandbox read-only`; formerly the separate Cato agent) MANDATORY at E4/E5 in VERIFY, after the advisor returns — EXCEPT when Forge built the task (builder ≠ auditor invariant). *(Anvil/Kimi retired 2026-06-10; Cato folded into Forge audit mode 2026-06-17.)*++### Thinking-capability vocabulary — CLOSED ENUMERATION++The count of *thinking* capabilities is the HARD floor. Selection MUST be verbatim from this list (mirrored in `capabilities.md` § Thinking & Analysis — that file is the source, this references by name). Inventing generic labels ("decomposition", "edge-case enumeration", "tradeoff analysis", "deep reasoning") is a **PHANTOM** — it does not count toward the floor and the Capability-Name Audit rejects it.++IterativeDepth · ApertureOscillation · FeedbackMemoryConsult · Advisor · ReReadCheck · FirstPrinciples · SystemsThinking · RootCauseAnalysis · Council · RedTeam · Science · BeCreative · Ideate · BitterPillEngineering · Evals · WorldThreatModel · Fabric patterns · ContextSearch · ISA · PropertyAudit++New thinking capabilities are added by editing `capabilities.md` and bumping the minor version — never by run-time invention.++**Capability-Name Audit Gate (OBSERVE→THINK boundary):** before printing `🏹 CAPABILITIES SELECTED`, verify each thinking name appears verbatim above. Each line MUST start with the literal closed-list name in bold. Correct: `🏹 **FirstPrinciples** → THINK | …`. REJECTED: `🏹 First-principles decomposition → THINK | …`. **Naming a capability is a binding commitment to invoke it via `Skill`/`Agent`** — text-only does not count as invocation; the check re-runs at BUILD and VERIFY and flags it as a phantom.++### Tier → Delegation Effort & Model++**The four-level effort-model abstraction (v6.15.0).** All Claude-family model routing speaks in four effort LEVELS — `max` / `high` / `medium` / `low` — bound to the lineup in exactly one place: `EFFORT_MODEL` in `LIFEOS/TOOLS/models.ts` (today: **max→fable**, high→opus, medium→sonnet, low→haiku — the `max→fable` flip went LIVE 2026-07-01 once Fable was reachable again; Fable is ~2× Opus, so the top rung's cost lands only on E4/E5 + Core-System work). `Inference.ts` exposes the same four levels (`--level low|medium|high|max`; these are the ONLY accepted names — legacy fast/standard/smart were removed 2026-06-10 and unknown names hard-error). Doctrine, hooks, skills, and agents state INTENT (the level); the mapping resolves the model. A lineup change (a model enters/exits the subscription or moves rungs) is a one-line `EFFORT_MODEL` edit; a version release is a one-line `CURRENT` edit. Nothing outside models.ts names a Claude model for routing.++**The routing policy:** **NATIVE-mode delegated work runs at `high`. Algorithm E1–E3 dispatch at `high`. E4/E5 dispatch at `max` (Fable).** Keystone exception: the Advisor is pinned `max` at every tier (the commitment-boundary reviewer, worth Fable once per deliverable). The TheRouter classifier — the highest-leverage decision in LifeOS, but one that fires on EVERY prompt — is pinned **`high` (Opus)**, re-pinned off `max` on 2026-07-01 so flipping `max→fable` didn't put Fable on every prompt; keystone means highest-leverage, not most-expensive rung. `medium` and `low` remain sanctioned at any tier for utility inference — classification, summarization, vision triage — so cheap calls never silently ride an expensive model.++The main loop's effort AND model are fixed at turn start and cannot be changed mid-flight — a `UserPromptSubmit` hook can classify the tier but cannot set the model (only `SessionStart` hooks see a `model` field, and none can write it; there is no built-in complexity→model router). But the Algorithm does its heavy thinking through agents it spawns, and *both their effort and their Claude model* are programmable per dispatch. The tier scales dispatched-agent effort and selects the dispatched level; the principal-selected main loop orchestrates and verifies. Selected at the PLAN Delegation Gate; recorded as one `## Decisions` row + the `🎚️ DELEGATION EFFORT:` line.++**Two axes in this table, plus a third that isn't a rung.** The **Effort** column is the harness reasoning-effort knob (`low|medium|high|xhigh|max`) — the same value the statusline shows and `/effort` sets, governing how hard a model thinks within itself. The **Level** column is the model rung (`EFFORT_MODEL` in `models.ts`, four rungs over the four-model lineup) — which Claude model the agent runs. They share words but are different dials: dispatching at model rung `max` emits reasoning effort `xhigh`, not `max` (`models.ts` `LEVEL_TO_HARNESS_EFFORT`). **ultracode** (E5) is neither — it's the composition axis (fan into a `Workflow`), rides on `xhigh` effort, and is orthogonal to both columns. Full reconciliation: the THREE LEVEL AXES block in `models.ts`.++| Tier | Effort (reasoning) | Level (model rung) | Dispatch profile |+|------|--------|-------------------------|------------------|+| **E1** | low | `high` | Inline. No agents by default. `Inference.ts low` only if a quick lookup is unavoidable. |+| **E2** | medium | `high` | `Inference.ts medium`. At most one single-pass agent. No Forge/Council. |+| **E3** | high | `high` | `Inference.ts high`. Forge at default high for any coding task. Single-pass verify. Independent threads parallel/background. |+| **E4** | xhigh | `max` | Forge build-mode high **+ Forge audit-mode** (mandatory, unless Forge built it). Council/RedTeam where the decision is wide. `Workflow` for 3+ workstreams. Adversarial verify on load-bearing claims. |+| **E5** | xhigh | `max` | `Workflow` by default (**ultracode** composition) + xhigh agents (CodexResearcher xhigh, Forge high) + multi-vote adversarial verify (≥3 skeptics per load-bearing claim). |++The profile is additive over the capability floors and the Forge build/audit bindings — it sets a mandated agent's effort, never lowers it below its binding.++**Claude-model routing (dispatch-time, not frontmatter).** The Level column governs **Claude-family delegated agents** dispatched at this tier — resolve it through `EFFORT_MODEL` and pass the resulting tier alias as the `model` parameter on `Agent({…, model: '<resolved>'})` and on Workflow `agent(prompt, {model: '<resolved>'})` (the Agent-tool `model` enum is harness-owned — `sonnet|opus|haiku|fable` — so the dispatch param carries the resolved alias, not the level name). It is set at dispatch because static agent-frontmatter `model:` cannot be tier-conditional. E1–E3 dispatch `high`; E4/E5 dispatch `max` — the hardest work earns the top rung, while lower tiers and the orchestrator stay a rung down. Three guardrails: (1) it **never** changes the main conversation loop's model (the turn-start-fixed rule above — stated once, not re-explained); (2) it does **not** touch the cross-vendor agent — **Forge** (GPT-5.5, build and audit modes) runs its own vendor regardless of tier, because its value is vendor diversity, not Claude tier; (3) there are no named Claude max-personas — E4/E5 Claude work dispatches `max` to `general-purpose` (or a `ComposeAgent` persona) via the dispatch-time `model` param; everything picks up its level the same way. (The static persona agents Engineer/Architect/Designer were retired 2026-07-01 — prefer a job-specific brief on `general-purpose`, per the Agents skill.) **Override reality (verified 2026-07-01, correcting the earlier absolute claim).** The dispatch `model` param overrides an agent's frontmatter `model:` for agents WITHOUT an `initialPrompt` field (tested: `general-purpose@fable`→`claude-fable-5`, `@haiku`→`claude-haiku`, frontmatter-opus `Architect@fable`→`claude-fable-5`). But an agent carrying an `initialPrompt` field deterministically IGNORES the override and runs its frontmatter model (the retired Engineer ran Opus 2/2 despite `@fable`), so the override is NOT universal — never add `initialPrompt` to an agent whose model must be tier-settable. AND the `🤖 DISPATCH` line and the `AgentInvocation` log record INTENT (`resolveDispatch()` reads a table), never execution — a Forge dispatch logged `gpt-5.5` ran `claude-opus-4-8`. The only proof of the executed model is the agent transcript's `.message.model`; auto-verification (read it back, flag mismatches) is a follow-up. Show-your-math in `## Decisions` to deviate (e.g. force `max` on an E2 task whose single delegate is genuinely hard). **Dispatch display (mandatory, every tier):** each dispatch is announced visibly as `🤖 DISPATCH: <agent> — <level> → <model>` — param-resolved (`general-purpose — high → opus`) or cross-vendor (`Forge(audit) — cross-vendor → gpt-5.5`) — so the principal always sees which rung the work landed on.++**Core-System Override (domain beats tier).** When the task upgrades LifeOS core itself — the Algorithm files (`LIFEOS/ALGORITHM/*`), hooks, the system prompt, `CLAUDE.md`, skill/ISA doctrine, or the core tools (`LIFEOS/TOOLS/Inference.ts`, `LIFEOS/TOOLS/models.ts`) — delegated Claude-family work dispatches at `max` **regardless of tier**, overriding the E1–E3→`high` curve. Core-system changes have outsized blast radius (they change how *every future task* runs), so they earn the highest available model even at low tiers. Detection: the task's target files sit under the LifeOS system surface (NOT `USER/` data, NOT external project repos). The main loop still can't switch mid-session (harness limit), so this raises the *delegates* — and for a deliberate core-system session, `/model fable` on the main loop is the matching move. "Highest available model" = whatever `EFFORT_MODEL.max` resolves to (**Fable as of 2026-07-01** — `max` and `high` are now distinct models, so the `Inference.ts` fallback degrades max→high = fable→opus, a real lower rung).++**Per-Task Intelligence Routing (v6.18.0).** The tier curve sets ONE level per run, which flattens a mixed-difficulty ISA — a doc-edit and a concurrency redesign in the same `## Features` list both dispatch at the tier's level. Fix: a Feature may carry an optional `intelligence` level (`low|medium|high|max`), scored to its **hardest ISC**, and BUILD dispatches that Feature at that level. Down-route-only — the tier curve is the fallback for any unassigned Feature, so a missing value rides the full (expensive) rung, never a degraded one. How hard a Feature is, and when to trim, is the orchestrator's judgment — no rubric.++Two pieces are NOT optional, because each stops a failure a capable model still makes under load: **(1) producer-lock** — never down-route a Feature that another Feature `depends_on`; a starved producer silently corrupts everyone downstream. **(2) shadow-log** — every down-route appends a line to `MEMORY/OBSERVABILITY/intelligence-routing.jsonl` (`{ts, slug, feature, assigned_level, reason}`) so a wrong trim is visible and revertible. A down-routed Feature that then fails its ISCs re-dispatches one rung up. The `🤖 DISPATCH` line shows the resolved rung + source per Feature.++---++## Mode Classification++**Mode and tier are decided by the TheRouter classifier at UserPromptSubmit** (`hooks/TheRouter.hook.ts`, `Inference.ts --level high` — Opus; re-pinned off `max` on 2026-07-01 so the per-prompt keystone doesn't ride Fable), written into additionalContext:++```+MODE: MINIMAL | NATIVE | ALGORITHM (always)+TIER: E1 | E2 | E3 | E4 | E5 (iff ALGORITHM)+REASON: <one sentence>+SOURCE: classifier | fail-safe | fast-path | cache | explicit+GOAL_SIGNAL: 1 | 2 | 3 | 4 | none+GOAL_LITERAL: "<verbatim>" (when detected)+INTERVIEW_ELIGIBLE: true | false+```++The executor reads these directly — no regex, no model judgment. MINIMAL/NATIVE → use that template from `LIFEOS_SYSTEM_PROMPT.md` and stop. ALGORITHM → enter at the named TIER.++**Classifier rules:** MINIMAL = greetings/ratings/acknowledgments. NATIVE = single fact lookup OR single-line edit on a named file OR one command, AND no new artifact, AND no multi-step plan. ALGORITHM = everything else (any build/create/design/refactor/migrate/integrate, anything multi-file or ambiguous, anything touching doctrine/system-prompt/hooks/CLAUDE.md/Algorithm/ISA, any meta-question about the system). **A short, clearly-stated *question* is not NATIVE by virtue of being short — route by whether the ANSWER is a lookup (retrieve + assemble → NATIVE) or must be CONSTRUCTED by analytical synthesis against external/contested evidence, its correctness NOT checkable at a glance (→ ALGORITHM, E3 default / E4 if it spans contested fields). The discriminator is VERIFIABILITY, not "needs synthesis" — almost everything needs some synthesis, so opinion/advice/personal-judgment questions ("should I learn Rust or Go", "why do I procrastinate") stay NATIVE even though they synthesize. The question's length is never the signal; whether the reader can check the answer at a glance is. A hard science/philosophy/strategy question with a one-line prompt and a build-it-yourself answer is the canonical NATIVE→ALGORITHM misroute this rule exists to catch.** Tier: E1 trivial, E2 single-domain, E3 multi-file substantial, E4 cross-cutting/doctrine/architecture, E5 comprehensive. Bias higher when in doubt.++**Override hierarchy (executor side):** (1) explicit `/e1`–`/e5` forces tier (and forces ALGORITHM if MINIMAL/NATIVE returned); (2) **conversation-context override** — the classifier sees the prompt alone, the executor sees the thread: escalate when context makes a prompt clearly ALGORITHM-shaped ("do it" on an architecture change), demote ALGORITHM→NATIVE when ideal state is now articulable, promote NATIVE→ALGORITHM when context reveals the spec needs ISC; note the mismatch in `## Decisions`; (3) otherwise honor the classifier verbatim.++**Fail-safe.** Any classifier error path — timeout (30s), non-zero exit, unparseable output — defaults length-tiered (≥1500 chars → **ALGORITHM E4**, ≥400 → **E3**, else **NATIVE**) with `SOURCE: fail-safe`. Under-escalation is the failure mode this system exists to prevent.++**INTERVIEW_ELIGIBLE** is set here by the classifier; `false` skips the Density Gate + Sufficiency Check entirely (see *Context Sufficiency*).++**Subagent constraint:** the classifier fires on top-level prompts only. Subagents inherit the primary's pick and all run NATIVE — only the primary DA uses ALGORITHM.++**NATIVE banner literal echo:** when `GOAL_LITERAL` is present AND `MODE: NATIVE`, the NATIVE `🗒️ TASK:` line quotes the literal verbatim (truncate to ~80 chars + `…`). Absent → the 8-word-abstraction rule applies.++**NATIVE ambiguity flag:** when a single interpretation fork would change what ships, prepend after the banner, before `📃 CONTENT`: `⚠️ Picking X over Y because R; redirect if wrong.` (≤120 chars, concrete X/Y/R). Doesn't stop work — ships the X interpretation. Reserved for load-bearing forks.++---++## Voice Announcements & Phase Tracking++At Algorithm entry and every phase transition, the **primary agent only** announces via inline curl (subagents skip voice):++```bash+curl -s -X POST http://localhost:31337/notify -H "Content-Type: application/json" \+ -d '{"message": "MESSAGE", "voice_id": "fTtv3eikoepIosk8dTZ5", "voice_enabled": true}'+```++Entry: `"Entering the Algorithm"` (before OBSERVE). Transitions: `"Entering the PHASE_NAME phase."` (first action each phase).++**Phase-tracking layering (one source of truth, three writers):** ISA frontmatter `phase:` is ground truth; `ISASync.hook.ts` syncs ISA edits to `work.json`; `bun ~/.claude/LIFEOS/TOOLS/AlgoPhase.ts <phase>` is the operational write that drives the real-time dashboard at each transition; the chat phase header is decorative. Invoke order at every transition: **phase header → AlgoPhase CLI → voice curl → ISA edit.** Pulse SSE (`GET /api/algorithm/stream`, 100ms `work.json` poll) renders end-to-end under 250ms p95. TheRouter pre-writes `currentMode: 'algorithm'` + `phase: 'starting'` on classification to kill the wrong-display window. If the dashboard is stuck, check ISA frontmatter first.++---++## Principal-Stated Goal++When OBSERVE goal-detection fires + the minimum-content rule passes, the ISA gains four frontmatter fields:++```yaml+principal_stated_goal: "the verbatim user quote, byte-for-byte"+principal_stated_goal_source: prompt # prompt | conversation | explicit-revision+principal_stated_goal_signal: 4 # 1 | 2 | 3 | 4+principal_stated_goal_locked: <ISO-8601>+```++Verbatim, never paraphrased, immutable across phases unless explicitly revised. Omitted entirely when detection didn't fire.++**Four-signal detector (MANDATORY at every tier, before ISA scaffold):** (1) **named metric + threshold** ("p95 under 200ms"); (2) **explicit outcome assertion** ("I want X to be true" / "do this"); (3) **completion condition** ("until X" / "such that X"); (4) **structural/design directive** ("design how ISA absorbs /goal", "make this 6.13.0").++**Minimum-content rule (fail-closed):** candidate under 6 tokens OR with no propositional content ("make it good") → `principal_stated_goal: null`, log to `## Decisions`. **Multi-literal:** first detected literal wins; others demote to derived **Constraints** (guardrails), and ISCs derived from them anchor via `anchors_to: derived: <name>`. Trust `GOAL_SIGNAL` but re-validate by running the detector yourself.++**OUTPUT:** `🎯 GOAL STATEMENT DETECTED: yes — signal [N] [type] — "[quote]"` (or `no — [reason]`). Copy the quote into `## Goal` as the first sentence, in quotes, before derived content.++**Surface form vs intent (load-bearing):** every gate verifies against the literal, but the literal's SURFACE never becomes the optimization target — its INTENT does. Hitting `p95=199ms` by a percentile edge case that misses 12% of requests passes the surface and fails the intent. Rule 1 probes use the literal as reference; Cato (Rule 2a) surfaces surface-vs-intent drift.++**Five surfaces carry the literal verbatim:** the NATIVE 🗒️ TASK line, the Advisor state blob (`PRINCIPAL STATED GOAL:` prepended), the Cato bundle (first section), the Pulse Kanban card, the LEARN reflection JSONL. The frame-drift record is a sixth.++**ISC-anchoring rule:** every ISC traces to (a) the literal or (b) an explicit derived sub-claim, recorded in the `anchors_to` column of Test Strategy (`literal` or `derived: <name>`). Permissive — anti-criteria, antecedents, infrastructure, meta-ISCs all qualify as derived. Rejects only ISCs with no traceable connection.++**Revision Protocol** (principal explicitly revises mid-iteration): append a `## Decisions` row (`refined: principal_stated_goal: was "<old>" now "<new>" — reason: <quote>`), update the frontmatter field + `_locked` + `_source: explicit-revision`. The OLD literal is preserved in that Decisions row, never tombstoned in frontmatter — the audit trail holds history. Re-check every ISC's `anchors_to` against the new literal; LEARN's Changelog references the originally-stated literal via that row.++---++## Context Sufficiency++Two ordered checks at OBSERVE, after GOAL detection, before scaffolding beyond the Goal section. Skipped entirely when `INTERVIEW_ELIGIBLE: false`.++**Check 1 — Density Gate.** Compute `density_score` deterministically (no LLM). Seven signals: (1) section-fillability ratio, (2) `principal_stated_goal` token count, (3) named-artifact count, (4) measurable-criterion count, (5) concrete-verb presence, (6) Out-of-Scope language, (7) constraint-marker presence. At E1 the score is computed over **signals 2–7 only** (signal 1 excluded from the E1 denominator); at E2+ all seven count. Thresholds: `< 0.10` (E1) / `< 0.20` (E2) / `< 0.30` (E3) / `< 0.50` (E4/E5). Below → fire Interview (E3+, ≤3 questions + `proceed` override) or emit the ambiguity flag (E1/E2). Above → write `density_gate_acknowledged: true`. **OUTPUT:** `🌡️ DENSITY GATE: [skipped (eligible=false) | fired (score=N, risk=R) | passed (score=N)]`.++**Check 2 — Sufficiency Check** (runs only when the Density Gate passes). The semantic-fork detector Density can't catch: *"of the explicit goal, are there ≥2 plausible interpretations that lead to materially different builds?"* Deterministic — inspect `principal_stated_goal` for compound clauses (≥2 objects), abstract verbs without object specificity, missing principal-preference markers, undisclosed constraint markers. ≥1 fork at E3+ → ≤3 targeted questions with `proceed`; at E1/E2 → prepend the ambiguity flag; 0 forks → `context_sufficient: true`. **OUTPUT:** `🧭 SUFFICIENCY CHECK: [passed | flag-emitted ("X vs Y") | interview-fired]`.++Frontmatter: `density_score`, `interview_invoked`, `divergence_risk` (low|medium|high), `density_gate_acknowledged`, `context_checks_fired: [...]`, `context_sufficient`. `proceed` semantics: literal whole-response match only (`response.trim().toLowerCase() === 'proceed'`).++**PLAN-Entry Refresh** (mandatory E3+, optional E2): catches THINK surfacing info that changes the goal. Ask: *"did any premortem, riskiest-assumption, or capability output surface info that — had I had it at OBSERVE — would have changed Goal/Vision/Out-of-Scope?"* No → `🔁 PLAN REFRESH: passed`. Yes → log a Decisions row, set `divergence_risk: medium`, append `plan-refresh` to `context_checks_fired`. **Does not block the phase** — the flag travels.++**Soft-Gate Teeth** (non-blocking, mandatory visibility): EXECUTE's first text MUST acknowledge an active plan-refresh flag (`⚠️ PLAN-REFRESH FLAG ACTIVE: <summary>. Continuing; will surface in completion summary.`); VERIFY MUST include it in the completion summary; LEARN appends `goal_changed: bool`. "Soft" = never stops a transition; "teeth" = the flag must surface.++---++## Frame-Drift Check & Resume After Complete++### 🩻 Frame-Drift Check++Runs at VERIFY entry on all ALGORITHM tiers where the ISA has a non-null `principal_stated_goal` (NATIVE/MINIMAL skip — the ambiguity flag is their analog). If null → `frame_drift: skipped_no_goal_literal` (never default to `none` on missing inputs). Three booleans against the deliverable:++| Test | Pass when |+|------|-----------|+| **T1 Noun coverage** | all principal-named nouns are addressed, OR ratified out-of-scope in `## Decisions` |+| **T2 Verb fidelity** | the deliverable enacts the principal-named verb (narrower OK if `## Decisions` ratifies; different verb = drift) |+| **T3 Scope match** | deliverable scope is a strict subset of stated scope; any narrowing ratified in `## Decisions` (unratified narrowing = drift) |++T1∧T2∧T3 → `frame_drift: none`. Any fail → `frame_drift: detected`, write `frame_drift_summary` (≤140 chars), add a Decisions row, append `MEMORY/OBSERVABILITY/frame-drift.jsonl`, surface in the VERIFY summary. **Anti-gaming:** (1) if `none` AND `## Decisions` empty AND the deliverable contains scope-narrowing language ("instead", "deferred", "out of scope"), Cato (E4/E5) re-runs T1/T2/T3 independently — disagreement escalates; (2) a generic summary with no concrete noun/verb/test reference is rejected — rewrite with the specific gap; (3) phrase the gap as drift, not as a feature. When `iteration > 1`, tests evaluate against the iteration's effective goal. **OUTPUT:** `🩻 FRAME-DRIFT CHECK: [passed | detected ("<summary>") | skipped_no_goal_literal]`.++### 🔄 Resume After Complete++Any ISA edit landing on a `MEMORY/WORK/**/ISA.md` whose `work.json` is `phase: complete` triggers a deterministic check (mode-irrelevant — the trigger is the edit): **B1** `phase === 'complete'` (eligible); **B2** post-frontmatter content SHA-256 differs from `bodyHash` (rewind); **B3** `bodyHash` absent (treat as changed, rewind once). On B1∧(B2∨B3): `iteration = (existing.iteration||1)+1`; write `phase: learn`, `iteration`, `resumed_at`, `resumed_from_phase: complete`; append `- D-<n>: Auto-resumed from complete to learn at <ts> — iteration <N+1>`; sync `work.json`; append `MEMORY/OBSERVABILITY/isa-rework.jsonl`. A frontmatter-only timestamp bump never rewinds — body diff is the gate. Reading an ISA bumps `lastToolActivity` as a heartbeat (no rewind on read). Bypass: `frozen: true` in frontmatter. When `iteration > 1`, the SUMMARY 🗒️ TASK line prepends `↻ Iteration N`, and LEARN appends `resumed: true, prev_iteration_outcome: <one-line>`.++---++## ISA as System of Record++The ISA is the single source of truth for the thing being articulated. The AI writes ALL content directly via the ISA skill workflows; hooks only read. **Two homes:** Project ISAs (`<project>/ISA.md`, grow continuously) and Task ISAs (`MEMORY/WORK/{slug}/ISA.md`, archived at `phase: complete`).++**Frontmatter:** `task`, `slug`, `effort`, `phase`, `progress`, `mode`, `started`, `updated`. Optional: `iteration`, `algorithm_config`, the four `principal_stated_goal_*`, the density/sufficiency keys, `frame_drift` + `frame_drift_summary`, `resumed_at` + `resumed_from_phase`, `frozen`; Project ISAs add `project:`. Full spec: `LIFEOS/DOCUMENTATION/ISA/IsaFormat.md`.++**Twelve-section body (fixed order, empty sections never appear):**++| # | Section | Purpose | Written At |+|---|---------|---------|------------|+| 1 | `## Problem` | What is broken/missing now | OBSERVE |+| 2 | `## Vision` | What euphoric surprise looks like | OBSERVE |+| 3 | `## Out of Scope` | Anti-vision — what is *not* included | OBSERVE |+| 4 | `## Principles` | Substrate-independent truths to respect | OBSERVE |+| 5 | `## Constraints` | Immovable architectural mandates | OBSERVE |+| 6 | `## Goal` | Hard-to-vary spine, 1–3 sentences | OBSERVE |+| 7 | `## Criteria` | Atomic ISCs (one binary probe each), incl. `Anti:` | OBSERVE → EXECUTE |+| 8 | `## Test Strategy` | `isc \| type \| check \| threshold \| tool \| anchors_to` | OBSERVE/PLAN |+| 9 | `## Features` | `name \| satisfies \| depends_on \| parallelizable \| intelligence` (`intelligence` optional — per-task dispatch level, empty = inherit tier curve) | PLAN |+| 10 | `## Decisions` | Timestamped log (incl. dead ends, `refined:` prefix) | any phase |+| 11 | `## Changelog` | Conjecture / refuted-by / learned / criterion-now | LEARN |+| 12 | `## Verification` | Evidence per ISC | VERIFY |++**Three-guardrail taxonomy:** Principles bind the *thinking* (Deutsch reach), Constraints bind the *solution space*, Out of Scope binds the *vision* (anti-vision), Anti-criteria bind the *test surface* (granular `Anti:` ISCs).++**Tier Completeness Gate (HARD at all tiers):** E1 = Goal, Criteria. E2 = Problem, Goal, Criteria, Test Strategy. E3 = Problem, Vision, Out of Scope, Constraints, Goal, Criteria, Features, Test Strategy. E4 = all twelve. E5 = all twelve + an active Interview workflow run before BUILD. Any `<project>/ISA.md` requires E3+ structure regardless of the task's tier. `Skill("ISA", "check completeness")` enforces it; a miss blocks `phase: complete`.++**ISA Skill** (`~/.claude/skills/ISA/`) owns the template, six workflows (Scaffold, Interview, CheckCompleteness, Reconcile, Seed, Append), and examples. Invocation: OBSERVE `scaffold from prompt at tier T` then `check completeness`; PLAN `extract feature <name> as ephemeral file`; EXECUTE/VERIFY/LEARN `append <type> ...`; LEARN `reconcile <ephemeral> → <master>`. Decisions/Changelog/Verification route through `append` so the canonical format doesn't degrade.++---++## ISC Quality System++**Every criterion describes one verifiable end-state.** The operational test is granularity:++> **Split until each criterion is one binary tool probe.** Granular enough when a single tool call (`Read`, `Grep`, `Bash`, `curl`, screenshot, `SELECT`, `bun test`) returns yes/no. If you can't name the probe, it's not atomic — split it. If it needs human judgment, name the tool-verifiable proxy.++**Splitting Test** — split when: "and"/"with" joins two verifiable things; part A can pass while B fails; scope words ("all", "every", "complete") → enumerate; it crosses a UI/API/data/logic boundary → one per boundary; you can't name the probe.++**Variation Test (the load-bearing gate):** *"can I vary this without destroying the goal? If yes, it needs refinement."* Applied per-ISC during the Per-ISC HVA (THINK) and across the whole set during the ISA-Level audit. An ISC that passes the Splitting Test but is silently relaxable is fluff.++**Format:** `- [ ] ISC-N: criterion text`. All ISCs number sequentially as `ISC-N`, anti-criteria included. **ID-stability:** IDs never re-number; splits become `ISC-N.M` (parent preserved); drops become tombstones (`- [ ] ISC-N: [DROPPED — see Decisions]`). Reconcile depends on this.++**Two doctrinal kinds:** **Anti-criterion** (`- [ ] ISC-N: Anti: <what must NOT happen>` — **≥1 required**); **Antecedent** (`- [ ] ISC-N: Antecedent: <precondition>` — **≥1 required when the goal is experiential**).++**Properties are the strongest ISCs.** (1) every ISC names its falsifier; (2) universal claims beat example claims — `∀ x. P(x)` is one quantifier stronger than `P(x₀)`; (3) evidence is the deliverable — completion needs the change AND the evidence. `bun-property` is a first-class `type` (closed vocabulary: `bun-test | bun-property | bash | manual | screenshot | eval`). A `bun-property` row carries `| isc | anchors_to | type | property | generator | runs | tool |` — `property` (prose universal claim), `generator` (fast-check, e.g. `fc.integer({min,max})`), `runs` (default 1000; 10000 invariant-critical; 100 for slow generators), `tool` (`bun test <file> -t <pattern>`). At E3+, pure code under LifeOS surface defaults to `bun-property` over `bun-test`, and every new Anti-ISC defaults to `∀`-quantified form, unless a `## Decisions` row explains why example form applies (finite small domains excepted). Categories + detection: `skills/Hardening/Workflows/PropertyTest.md`.++**Status markers:** `- [ ]` pending; `- [x]` passed with evidence; `- [DEFERRED-VERIFY]` a **holding state, never terminal** — passed in intent but live probe impossible at execution time; requires a follow-up task ID; cannot become `[x]` until the probe runs; an ISA with any deferred item cannot reach `phase: complete` unless that item is explicitly waived in `## Decisions`.++**Complex-app test surface** (these ARE the ISA): Functional, API, Auth, Authorization (RBAC/visibility), Performance (latency, bundle size), Security (validation, encoding, CSRF, rate limits, secrets), Data integrity (schema invariants, FK consistency, idempotency), Build & deploy (`bun build`, typecheck, version match), Operational (`/health`, SLO, synthetic monitor).++---++## Tunable Parameters++Modes (ideate, optimize) accept tunables; full schema + presets: `LIFEOS/ALGORITHM/parameter-schema.md`; stored in ISA `algorithm_config:`. `DELEGATION_EFFORT_MAP` (the tier→level table), `E5_ULTRACODE_MIN_VERIFIERS` (3), `RESUME_RECENT_ACTIVITY_WINDOW_MS` (5 min), `BUMP_COMPLETE_TIME_BOUND_MS` (24h), `PROPERTY_DEFAULT_NUMRUNS` (1000), `PROPERTY_INVARIANT_CRITICAL_NUMRUNS` (10000), `MUTATION_KILL_RATE_FLOOR` (0.75).++---++## Execution++**ALL WORK INSIDE THE ALGORITHM.** Every tool call, investigation, and decision happens within phases. CLAUDE.md already printed the entry banner (`♻︎ Entering the PAI ALGORITHM… (v6.14.0)` + 🗒️ TASK). **First action after loading this file:** voice `"Entering the Algorithm"`, then the ISA stub — determine home (project vs task), `Skill("ISA", "scaffold from prompt: <message> at tier <tier>")` (mandatory E2+; E1 may inline-write minimal Goal+Criteria to preserve <90s). At every phase transition: phase header → AlgoPhase CLI → voice → ISA edit.++━━━ 👁️ OBSERVE ━━━ 1/7++**🎯 INTENT ECHO (FIRST ACTION).** Before voice, before ISA — restate the request in ONE sentence. If you can't, re-read the message. **OUTPUT:** `🎯 INTENT: [restatement]`.++**🎯 GOAL STATEMENT DETECTION** — run the four-signal detector (*Principal-Stated Goal*).++**🌡️ DENSITY GATE** then **🧭 SUFFICIENCY CHECK** (*Context Sufficiency*). Skip both if `INTERVIEW_ELIGIBLE: false`. **Mode detection:** load `LIFEOS/ALGORITHM/mode-detection.md` for ideate/optimize/research/fast-path.++**Reverse-engineer the request:** `🔎 [explicit wants, one per line] / [explicit not-wanted] / [implied not-wanted] / [speed signal]`.++**Preflight gates** — fire ALL that match (false positives are cheap): **A Diagnostic** (bug/"X broken"/debugging → reproduce failure before reading code); **B Deploy/API** (enumerate external prerequisites — credentials, CLI auth, service config, deploy target — seeding the THINK Prerequisite Manifest); **C External service** (Cloudflare/Stripe/Telegram/etc. → load LifeOS skill context, check gotchas); **D Research** (errors/unfamiliar library → search external docs before local archaeology). **OUTPUT:** `🚦 [Gate]: [finding]`.++**🔁 REPRODUCE-FIRST BLOCKING GATE.** If Gate A fired, capture a reproduction before ANY Read/Grep of the suspect path: Web/UI → Interceptor screenshot or net trace; HTTP → `curl -i`; CLI → stdout/stderr; deploy/build → the actual error; test → the failing assertion; data → `SELECT` showing the wrong row; agent/hook → synthetic `bun run`. **OUTPUT:** `🔁 REPRODUCED: [artifact]: [evidence 12-24 words]`. Three bypasses, each a `## Decisions` row: pure-additive work; architectural symptom not isolable to one call site; repro would cause user-visible damage.++**Set effort:** (1) explicit `/eN` → `explicit`; (2) `MODE`/`TIER` from additionalContext → `classifier`; (3) conversation override → `context-override`; (4) fallback → `auto`. **OUTPUT:** `💪🏼 EFFORT LEVEL: [tier] | [source] | [reasoning]`.++**Select capabilities:** load `capabilities.md`. Auto-include bindings + the thinking floor (HARD) / delegation floor (soft) per *Effort Levels*. **OUTPUT:** `🏹 CAPABILITIES SELECTED:` (each: capability, target phase, 8-word reason) + rationale line.++**Build the ISC criteria.** Refine each with the Splitting Test; set `progress: 0/N`. Before leaving OBSERVE — included ≥1 anti-criterion (and ≥1 antecedent if experiential)?++**ISC QUALITY GATES (all pass before THINK):** Granularity (every ISC a nameable single-tool probe); Tier ISC floor (E2+, soft); Tier completeness gate (HARD — `Skill("ISA", "check completeness")`); Density-gate acknowledgment (E3+); Thinking floor (HARD, verbatim names); Capability-Name Audit (HARD); Delegation floor (soft, or show-your-math).++━━━ 🧠 THINK ━━━ 2/7++Voice `"Entering the Think phase."`, ISA `phase: think`. **Knowledge check (on-demand, independent of Context Sufficiency):** `rg -i "TOPIC" ~/.claude/LIFEOS/MEMORY/KNOWLEDGE/ --type md -l` if prior work is likely.++`🎲 RISKIEST ASSUMPTIONS / ⚰️ PREMORTEM` (incorporate preflight findings).++**☑️ PREREQUISITE MANIFEST (deterministic, blocking).** Enumerate every external prerequisite the deliverable needs — auth token, CLI login, service config, deploy target, required secret/file — and run a concrete probe for each. **OUTPUT:** `🔑 PREREQUISITES: [need → reachable | UNKNOWN | MISSING]`, one line per need (`none` for pure-additive work with no external dependency). **MISSING** (probe ran, prerequisite absent) blocks EXECUTE; **UNKNOWN** (probe couldn't run — no TTY, introspection unsupported) surfaces but does NOT block — never collapse an un-runnable probe into MISSING, the gate must not block on its own blind spots. A MISSING item proceeds only when `## Decisions` names *what* is deferred and *why it is safe* to defer (a bare "deferred" reincarnates the vagueness this replaces). *(Probe gotcha: verify the Cloudflare token with the scope-matching call in OPERATIONAL_RULES — `/user/tokens/verify` false-negatives a valid master.)*++**🧬 ISA-LEVEL HVA (ILA)** — required E2+ (one-line note E1); runs **before** the per-ISC HVA (per-ISC fluff inside a broken ISA is wasted); re-runs at phase boundaries on new signal. Test Coverage (every facet → ≥1 ISC), Tightness (no removable subset), Uniqueness (no different set satisfies the goal). **OUTPUT:** `🧬 ISA-LEVEL HVA: Coverage [tight|gap] / Tightness [tight|over] / Uniqueness [tight|under]`. Any non-`tight` → ISA-level surgery logged with a `refined:` prefix; per-ISC HVA proceeds against the refined ISA.++**🔬 PER-ISC HVA** — required E2+ (one-line E1). For each ISC name what changes about "done" if it's removed/relaxed (the Variation Test). **Cluster-bearing rule:** hard-to-variability is a property of *systems* of constraints — two ISCs individually relaxable but jointly load-bearing must not both be deleted (either may still be rewritten, jointly or individually). Any `fluff` ISC is rewritten or removed before EXECUTE. **OUTPUT:** `🔬 HVA: N load-bearing, M rewritten, K deleted, J cluster-bearing`.++**ISC REFINEMENT:** re-apply the Splitting Test, add criteria for premortem failure modes, update the ISA (ID-stability applies).++**🎯 EUPHORIC SURPRISE PREDICTION** (E2+; optional E1): if every ISC passes, what hard-to-vary explanation does the output reveal that the principal couldn't predict but will instantly recognize as true? Name it; score 1–10. If you can't name it, predict ≤6. **OUTPUT:** `🎯 EUPHORIC SURPRISE PREDICTION: [score]/10 — [insight, 12-24 words]`.++━━━ 📋 PLAN ━━━ 3/7++Voice `"Entering the Plan phase."`, ISA `phase: plan`. EnterPlanMode if Advanced+. **🔁 Context-Sufficiency Refresh** (mandatory E3+) — run it (*Context Sufficiency*) before planning.++**📚 FEEDBACK MEMORY AUTO-CONSULT** (first step at Extended+, or any domain with likely prior feedback): `rg -l "KW1|KW2|KW3" ~/.claude/projects/${HARNESS_USER_DIR}/memory/feedback_*.md` (keywords: primary action + domain + tool names). **OUTPUT:** `📚 [file slug] — [rule]`. A rule that changes the plan: state it and follow it.++`📐 PLANNING: SCOPE [depth|breadth|breadth-then-depth] / SESSION [single|fix-now+redesign-later|combined] / ROOT-CAUSE [cause|TBD]`.++**📦 DELIVERABLE MANIFEST** (MANDATORY at any tier with 2+ explicit sub-tasks; anchored to the OBSERVE reverse-engineering): `📦 D1..DN: [sub-task 8-16 words, quote distinctive phrasing]`. Each maps to ≥1 ISC and ≥1 `## Features` entry. VERIFY binds it via Deliverable Compliance.++**📐 DELEGATION GATE** (before any agent): "Can I do this with Glob+Grep in under 30s?" YES → do it directly. NO → agent OK, prefer `run_in_background: true` unless the result gates the next step. **Select the Tier → Delegation Effort profile here** — append the `🎚️ DELEGATION EFFORT:` line + one `## Decisions` row.++**🚀 PARALLELISM SCAN** (default ON for research, variant generation, multi-URL probes, independent multi-file edits; OFF for sequential chains and single-file surgical edits): `🚀 [agent: what it does] / [launch pattern]`.++**Gates:** EPHEMERAL FEATURE (isolated-context work → `Skill("ISA", "extract feature <name> as ephemeral file")`, reconcile at LEARN); ASYNC PRIMITIVE (one-shot → `Bash(run_in_background)`; event stream → `Monitor`; AI work → `Agent(run_in_background)`); WATCHDOG (start on first background spawn); ISOLATION (overlapping writes → `isolation: "worktree"`); COORDINATION (Agent Teams default; Custom Agents only on "custom agents"; Managed Agents for unattended). Populate `## Features` for Advanced+.++━━━ 🔨 BUILD ━━━ 4/7++Voice `"Entering the Build phase."`, ISA `phase: build`. **INVOKE each selected capability via tool call** (`Skill`/`Agent`; text-only is not invocation). **🩻 Root-Cause-at-Ingestion Checkpoint** — before any fix that modifies output-side behavior, answer in `## Decisions`: (1) where does this bad state enter? Name the ingestion point. (2) If I fix it at ingestion, do 3 similar bugs disappear? If yes → move upstream. (3) Database-up or display-down? UI bugs force display-down (Reproduce-First).++━━━ ⚡ EXECUTE ━━━ 5/7++Voice `"Entering the Execute phase."`, ISA `phase: execute`. If a `plan-refresh` flag is active, emit the acknowledgment line first. As each criterion passes, IMMEDIATELY edit `- [ ]` → `- [x]`, update `progress:`, append a Verification entry.++**🧪 INLINE VERIFICATION MANDATE.** No `[ ]`→`[x]` without evidence in the same tool-call block or the next. Minimum probe: file write → `Read`; code edit → `Grep`/range `Read`; command → `Bash` with checked output; HTTP → `curl -i`; deploy → live `curl` or Interceptor; UI → Interceptor screenshot; schema → `SELECT`; config/env → read-back; hook wiring → `cat settings.json | jq`. **Forbidden:** "should work", "should be", "expected to", "the change is in place" (without Read/Grep), "done" (without evidence), "no errors" (without the log). Batching allowed (one follow-up block Reads all parallel edits); the `[x]` transition with no probe is what's forbidden.++**🪢 CHECKPOINTS.** Every `[ ]`→`[x]` fires `CheckpointPerISC.hook.ts` — for each repo in `~/.claude/checkpoint-repos.txt` with uncommitted changes, auto-commit `--no-verify --no-gpg-sign`. **This is the one sanctioned `--no-verify` path** (session durability); it does not license skipping hooks elsewhere. Idempotent via sidecar; rollback preview-only (`bun ~/.claude/LIFEOS/TOOLS/Checkpoint.ts`).++━━━ ✅ VERIFY ━━━ 6/7++Voice `"Entering the Verify phase."`, ISA `phase: verify`. **Fixed sequence (order is load-bearing):**++1. **Re-Read Check** — confirm the goal literal is intact in the ISA.+2. **🩻 Frame-Drift Check** — T1/T2/T3 against the deliverable (*Frame-Drift Check*).+3. **🌡️ Sufficiency Audit** — context-checks completion.+4. **Rule 1 live-probe** — each ISC verified with tool evidence.+5. **Advisor (Rule 2)** — commitment-boundary call.+6. **Cross-vendor audit (Rule 2a, E4/E5)** — Forge in audit mode, after the advisor returns, last before complete.+7. **🔨 Hardening gate (E4/E5)**.++**🛡️ Verification Doctrine:**+- **Rule 1 — Live-Probe.** A user-facing ISC is `[x]` only with tool-verified evidence: Web/UI → Interceptor screenshot; HTTP → `curl` with expected status+shape; CLI → captured stdout; DB write → `SELECT`; file → `Read`; hook/skill → `bun run` synthetic input; deploy → verified version string. "Should work"/"looks fine"/"tests pass" are NOT evidence. Probe genuinely impossible → `[DEFERRED-VERIFY]` with a follow-up task ID. **Modality fidelity (2026-06-27):** a **Web/UI** ISC closes ONLY on a real browser navigation to the actual path via Interceptor — `curl` belongs to **HTTP/API** ISCs and is NEVER a substitute for a Web/UI ISC, because curl and a real browser navigation can return different pages (SPA fallback served a broken `/admin` to the browser while curl saw the Worker). A Web/UI ISC marked `[x]` on curl/HTTP evidence is an Inline-Verification-scan failure and reverts to `[ ]`. **Verifier-unavailable (2026-06-27):** if Interceptor is wedged/down, the Web/UI ISC is `[DEFERRED-VERIFY]` (blocks `phase: complete`) and the run may NOT claim live/works/shipped — downgrade to "deployed, not browser-verified". A wedged verifier holds the done-claim; it never licenses substituting curl. Enforced by `hooks/SuccessClaimGate.hook.ts` (blocks page/UI live-claims lacking an Interceptor artifact). **Motion/interaction fidelity (2026-07-04):** an ISC whose subject is *motion* — animation, transition, drag, hover-state, scroll behavior, loading/skeleton state, or a multi-step flow — closes ONLY on a **ScrubFlow** frame-scrub gallery (dense frames + SSIM anomaly flag, `skills/Interceptor`) or a VerifyDeploy ordered flow-gallery, never a single still, because one screenshot cannot capture motion. A static-render ISC still closes on one Interceptor screenshot. The trigger is keyword-anchored to those terms so it does not tax every web task; `SuccessClaimGate` accepts the frame-scrub manifest as Interceptor-class evidence.+- **Rule 2 — Advisor.** On Extended+ ISAs call the advisor before committing to an approach, when stuck/diverging, and once after a durable deliverable (the `phase: complete` transition for Extended+). Skip only for measured-short reactive tasks (<4 min AND <2 files), fast-path, or explicitly exploratory work. `bun ~/.claude/LIFEOS/TOOLS/Inference.ts --mode advisor --auto-state "TASK: …" "QUESTION: …"`. The state prepends `PRINCIPAL STATED GOAL:` when set.+- **Rule 2a — Cross-vendor audit (E4/E5).** After the advisor returns, before `phase: complete`, spawn **Forge in audit mode** (`Agent({subagent_type: "Forge", prompt: "MODE: audit\nslug: <slug>\nadvisor-verdict: <verdict>"})`, GPT-5.5 via `codex exec --sandbox read-only` — different vendor/corpus/RLHF, surfaces Anthropic-family blind spots) which also re-runs Frame-Drift T1/T2/T3 independently. **Builder ≠ auditor invariant:** if Forge produced this slug's build (`MODE: build` ran on it), do NOT spawn the audit — same-vendor self-review has no cross-vendor value; the Claude Advisor (Rule 2) covers the Claude side, and the skip is logged to `cato-findings.jsonl`. Verdict → action: `pass` → LEARN; `concerns` → surface, ask approve/iterate/defer; `fail`/any `critical` → block complete, enter Rule 3.+- **Rule 3 — Conflict-Surfacing.** If empirical results contradict the advisor or the cross-vendor audit, don't silently switch — re-call the advisor with the conflict surfaced. Hard cap: TWO re-calls, then escalate to the principal.+- **Rule 4 — Class-Sweep (all tiers).** The moment EXECUTE or VERIFY identifies a defect as an *instance of a class* — a stale derived artifact, a renamed symbol, a layout/render rule, a repeated callsite pattern, a wrong-path reference, a missing guard — the originating ISC cannot close until a `grep`/`glob` enumeration lists EVERY sibling instance (each consumer, callsite, viewport, file, config key) and each is either fixed-and-verified or tombstoned out-of-scope in `## Decisions`. Fixing one instance of a class without the sweep is an incomplete fix, not a complete one. This is the doctrine answer to the most expensive recurring failure mode in the reflection log: a one-line bug that took 20+ sessions to find because each session fixed the symptom in front of it and never enumerated the class. The sweep is a single tool call; skipping it is what costs sessions. **OUTPUT** when a class is named: `🧹 CLASS-SWEEP: <class> — N siblings found via <probe>; M fixed, K tombstoned`.++**🔨 Hardening gate (soft, E4/E5):** (a) every pure-function ISC has a `bun-property` probe or a `## Decisions` reason; (b) at E5, mutation kill rate ≥ 0.75 on touched files (via Hardening MutationTest). **OUTPUT:** `🔨 HARDENING GATE: [pass|fail|skipped]`.++**Verify each criterion:** `✅ ISC-N: [method] — [evidence]; Coverage: N/N passed`. Then run: capability-invocation check (flag phantoms), thinking-floor (HARD), delegation-floor (soft), tier-completeness, Density+Sufficiency audit, Deliverable Compliance (`📦` each D1..DN — any `[✗]` blocks complete), Inline-Verification scan (any `[x]` without evidence fails the scan and reverts to `[ ]`), reproduction check.++**🧹 Fluff Sweep (E2+).** Re-apply the Variation Test to each `[x]` ISC against its **original wording**. Any ISC that passed only because the criterion was relaxed mid-run (text edited, scope narrowed, weak evidence) → `[FLUFF-PASSED]`, requiring a `## Decisions` justification or it blocks complete.++**🔄 RE-READ CHECK (final gate, every tier).** Re-read the principal's last message verbatim; extract every explicit ask (each imperative verb, proper noun, numbered item, "also"/"and"/"then"); for each: `🔄 [ask]: [✓ at ISC-N/file/D1 | ✗ missed | SKIP reason]`. ANY `✗` blocks complete. If achievable in-session → loop back to PLAN, add an ISC, BUILD/EXECUTE, re-run Re-Read; if it needs scope change → emit a fix-or-defer prompt; if infeasible → `SKIP` with reason in `## Decisions` AND name it in the response.++━━━ 📚 LEARN ━━━ 7/7++Voice `"Entering the Learn phase."`, ISA `phase: learn`, then `phase: complete`.++`🧠 LEARNING: [what should I have done differently?] / [what would a smarter algorithm do?] / [did preflight gates fire — useful or wasted?] / [did the Verification Doctrine catch anything?]`.++**Changelog** — if structural understanding evolved, `Skill("ISA", "append changelog ...")` in conjecture/refutation/learning format (all four: `conjectured`, `refuted_by`, `learned`, `criterion_now`). If `frame_drift: detected`, append `drift_was_material: bool`. If `iteration > 1`, append `resumed: true, prev_iteration_outcome: <one-line>`. **Reconcile** any ephemeral feature file before `phase: complete`.++**🗂️ Learning Router** — every "should I remember this?" goes through here. **Default: SKIP.** Step 1 inventory: `🗂️ [learning] | TYPE: <type> | KEEP: yes/no — <reason>` (or `NONE`). Step 2 route+apply:++| TYPE | Target | Gate |+|------|--------|------|+| `knowledge` | `MEMORY/KNOWLEDGE/{People\|Companies\|Ideas\|Research}/<slug>.md` | inline write (typed `related:` links, 2-4) |+| `rule` | `CLAUDE.md` / `USER/CONFIG/OPERATIONAL_RULES.md` | inline append |+| `gotcha` | the skill's `SKILL.md` Gotchas | inline append |+| `state` | `USER/PROJECTS.md` "Open Sessions" | inline append |+| `business` | `USER/BUSINESS/<topic>.md` | inline write/append |+| `identity` | `USER/PRINCIPAL/…` / `USER/DIGITAL_ASSISTANT/…` | surface to user |+| `doctrine` | Algorithm `LIFEOS/ALGORITHM/v<next>.md` | surface to user |+| `hook` | `hooks/*.hook.ts` + `settings.json` | surface to user |+| `permission` | `settings.json` `permissions.*` | surface to user |++**Documentation sync** — if this session modified LifeOS system files (`hooks/*.ts`, `PAI/*.md`, `LIFEOS/ALGORITHM/*.md`, `skills/*/SKILL.md`, `settings.json`, `CLAUDE.md`, `LIFEOS/TOOLS/*.ts`, `agents/*.md`; exclude `MEMORY/`): `Skill("<your-release-skill>", "documentation update — I changed: [files]")`. **OUTPUT:** `📄 DOC SYNC: [N files → invoked | SKIP]`.++---++## MANDATORY RESPONSE FORMAT — STOP-THE-LINE++**Every Algorithm run closes with this exact block; a prose summary in its place gets bounced by the OutputFormatGate Stop hook.** The last thing emitted is the SUMMARY block.++━━━ 📃 SUMMARY ━━━ 7/7++```+🔄 ITERATION on: [16 words of context — omit on first response; when iteration > 1 prepend ↻ Iteration N to 🗒️ TASK]+📃 CONTENT: [Up to 128 lines. Format Rules from LIFEOS_SYSTEM_PROMPT.md — scannable chunks, bullets, tables]+🧬 ISA: [tight | gap | over | under — required E2+]+🔬 HVA: [N load-bearing, M rewritten, K deleted, J cluster-bearing — omit at E1 single-part; required E2+]+🖊️ STORY: [4 8-word bullets — problem, what we did, how it went, what's next]+🧠 MEMORY: [CONDITIONAL — render ONLY when a `<pai-memory-delta>` block is present this turn; copy its line verbatim. Omit otherwise.]+🗣️ {{DA_NAME}}: [8-16 word summary]+```++**After this block: nothing.** No postscript, no "let me know if…", no emoji sign-off.++**WRITE REFLECTION JSONL** (Extended+; skipped E1) to `MEMORY/LEARNING/REFLECTIONS/algorithm-reflections.jsonl` — every field written (null-sentinel allowed):++```json+{+ "timestamp": "<ISO-8601>", "session_id": "<verbatim>",+ "effort_level": "E3", "effort_source": "classifier", "task_description": "8-word task",+ "criteria_count": 0, "criteria_passed": 0, "criteria_failed": 0, "prd_id": "<slug>",+ "isa_level_audit": "tight|gap|over|under",+ "hva": {"load_bearing": 0, "rewritten": 0, "deleted": 0, "cluster_bearing": 0},+ "implied_sentiment": 8, "satisfaction_prediction": "high",+ "reflection_q1": "...", "reflection_q2": "...", "reflection_q3": "...",+ "knowledge_flags": [], "within_budget": true, "living_doc_refinements": 0,+ "doctrine_fired": {"live_probe": true, "advisor": true, "cato": false, "conflict": false,+ "thinking_floor_met": true, "completeness_gate_met": true,+ "density_score": 1.0, "interview_invoked": false, "divergence_risk": "low"},+ "principal_stated_goal": "<verbatim or null>", "principal_stated_goal_signal": 2,+ "principal_stated_goal_source": "prompt",+ "daniel_rating": null, "daniel_rating_source": null, "daniel_rating_confidence": null,+ "context_sufficient": true, "context_checks_fired": ["observe-density", "observe-sufficiency"],+ "frame_drift": "none", "frame_drift_summary": null,+ "iteration": 1, "resumed_from_phase": null,+ "delegation_effort": "high", "ultracode_by_composition": false,+ "properties_total": 0, "properties_passed": 0, "shrunk_counterexamples": [], "hardening_gate": null+}+```++**Join rule:** at write time, look up `MEMORY/LEARNING/SIGNALS/ratings.jsonl` for the most recent record matching `session_id`; inline `daniel_rating*` (or `null` if pending).++---++## Rules++Each is the canonical statement's enforcement pointer; mechanics live in the named section.++- **No freeform output** — every response uses the SUMMARY format.+- **No phantom capabilities** — every selected capability invoked via tool (*Effort Levels*).+- **Thinking floor (HARD)** / **Delegation floor (soft)** — meet the floor or show-your-math (*Effort Levels*).+- **Tier completeness gate (HARD)** / **Density gate (HARD E3+)** — required sections + `density_gate_acknowledged` before complete (*ISA as SoR* / *Context Sufficiency*).+- **Context Sufficiency** binds every channel; **Soft-Gate Teeth** — PLAN-refresh + Frame-Drift flags travel to EXECUTE open + VERIFY summary.+- **Frame-Drift Check** — run T1/T2/T3; write `frame_drift`; surface if detected.+- **Resume After Complete** — edit-on-complete with body diff rewinds to `learn`, iteration++.+- **ISA-Level + Per-ISC HVA (E2+)** — ISA-Level before per-ISC; fluff rewritten/deleted before EXECUTE.+- **NATIVE banner literal echo** — quote `GOAL_LITERAL` verbatim when present.+- **ISA is YOUR responsibility** — no hook writes to it; ID-stability applies.+- **Verification Doctrine** — Rules 1/2/2a/3/4 where they apply; Rule 2a (Forge audit mode) E4/E5 only; Rule 4 (Class-Sweep) all tiers.+- **The ISA IS the test harness** — don't invent acceptance.yaml/acceptance.ts.+- **Append routing** — Decisions/Changelog/Verification through `Skill("ISA", "append ...")`.+- **No silent stalls** — no hung agents, no blocking processes.++---++## Context Recovery++**Mid-session (compaction):** read the most recent ISA (phase, progress, all ISC state); check TaskList for in-flight work; jump to the current phase — don't re-run earlier phases.++**Cold-start:** project work → `<project>/ISA.md`; task work → the ISA in `~/.claude/LIFEOS/MEMORY/WORK/`; `~/.claude/LIFEOS/MEMORY/STATE/work.json` is the session registry.++---++## FINAL OUTPUT FORMAT — NON-NEGOTIABLE++Before closing, check: **is the last thing on screen the `━━━ 📃 SUMMARY ━━━ 7/7` block** with `🔄 ITERATION`, `📃 CONTENT`, `🧬 ISA`, `🔬 HVA`, `🖊️ STORY`, `🗣️ {{DA_NAME}}`? If anything else — prose wrap-up, bullet summary outside the block, "here's what changed" paragraph — the response is invalid regardless of work quality and gets rewritten before sending. The work is already captured (ISA, tool outputs, commits, memory). The SUMMARY block is the entire closing. **Invariant:** Phase 7/7 = SUMMARY block; the response ends at `🗣️ {{DA_NAME}}: …`; nothing follows.diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/ARCHITECTURE_SUMMARY.md b/LifeOS/install/LIFEOS/DOCUMENTATION/ARCHITECTURE_SUMMARY.mdindex 464d6e7a..a2cbb1de 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/ARCHITECTURE_SUMMARY.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/ARCHITECTURE_SUMMARY.md@@ -1,5 +1,5 @@----last_updated: 2026-07-04T02:46:31.961Z+last_updated: 2026-07-04T20:40:45.383Zlast_updated_by: ArchitectureSummaryGeneratorconvention: pai-freshness-v1derived_from: LIFEOS/DOCUMENTATION/LifeosSystemArchitecture.md@@ -9,14 +9,14 @@ generator: LIFEOS/TOOLS/ArchitectureSummaryGenerator.ts# LifeOS Architecture Summary> Auto-generated by ArchitectureSummaryGenerator.ts. Do not edit manually.-> Generated: 2026-07-04T02:46:31.961Z | Source: DOCUMENTATION/LifeosSystemArchitecture.md+> Generated: 2026-07-04T20:40:45.383Z | Source: DOCUMENTATION/LifeosSystemArchitecture.md## OverviewLifeOS — the **Life Operating System**, built on the LifeOS (LifeOS) layer — is the framework that knows your goals, people, and current state, and continuously hill-climbs you toward your ideal state.Everything below is the machinery of that one loop: Current State → Ideal State via verifiable iteration (ISC). Canonical thesis: `LIFEOS/DOCUMENTATION/LifeOs/LifeOsThesis.md`.-**Current versions:** LifeOS 6.0.3 | Algorithm v6.23.0 | Memory v8.2+**Current versions:** LifeOS 6.0.5 | Algorithm v6.24.0 | Memory v8.2## Subsystem Reference@@ -101,7 +101,7 @@ System file inventory by pipeline. When you modify a file, trace its pipeline to| **Security** | `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` § Security Protocol (constitutional rule), `settings.json` `permissions.deny` (native harness denylist), `hooks/Safety.hook.ts` (consolidated PermissionRequest + PostToolUse on WebFetch \| WebSearch), `hooks/lib/safety-classifier.ts` (shape catalog + shell-aware classifier with single-quote pre-pass) || **Algorithm** | `Algorithm/LATEST` → `Algorithm/v{VERSION}.md` (currently v6.18.0), `Algorithm/capabilities.md`, `Algorithm/mode-detection.md`, `hooks/ISASync.hook.ts` → `MEMORY/WORK/{slug}/ISA.md`, `skills/ISA/` (canonical Scaffold/Append/Reconcile workflows); **work registry event-sourced (2026-06-10):** all `work.json` writes go through `isa-utils.writeRegistry` → field-level diff events appended to `MEMORY/STATE/work-events.jsonl` (`hooks/lib/work-events.ts`) → locked fold to the derived `work.json` snapshot (offset-stamped, 1MB compaction); `readRegistry` serves snapshot+suffix live views; Pulse SSE triggers off `fs.watch` on STATE with the 100ms poll as fallback; model routing via the four-level `EFFORT_MODEL` abstraction in `LIFEOS/TOOLS/models.ts` (max/high/medium/low → lineup; E1–E3 dispatch `high`, E4/E5 `max`, NATIVE delegates `high`) || **Memory** | `hooks/WorkCompletionLearning.hook.ts`, `hooks/SatisfactionCapture.hook.ts`, `hooks/RelationshipMemory.hook.ts`, `Tools/KnowledgeHarvester.ts` → `MEMORY/KNOWLEDGE/`, `MEMORY/LEARNING/`; `Tools/SessionHarvester.ts --mine` → `KNOWLEDGE/_harvest-queue/`; `Tools/MemoryRetriever.ts` (BM25 retrieval over typed-item corpus including `_MEMORY.md` hot-layer files), `Tools/KnowledgeGraph.ts` (graph navigation) — read-only. **Autonomic loop (2026-05):** `hooks/MemoryReviewTrigger.hook.ts` (UserPromptSubmit) + `hooks/MemoryReviewFire.hook.ts` (Stop) drive `Tools/MemoryReviewer.ts` on cadence (turn≥8 ∧ minutes≥30 ∧ idle≥2). Reviewer emits typed items routed by `Tools/MemorySystem.ts` (single `add(item)` API) over the `Tools/MemoryTypes.ts` registry; `Tools/MutationTier.ts` gates by tier A/B/C/D. Tier-C proposals enqueue to `MEMORY/OBSERVABILITY/pending-proposals.jsonl`; `PULSE/lib/telegram-proposals.ts` + `PULSE/modules/telegram.ts` surface them as `yes/no/edit #id` Telegram replies. `Tools/MemoryStatus.ts` is the read-only `kai status` CLI. |-| **Router** | Dataflow order: `hooks/EffortRouter.hook.ts` (**classify**: fast-paths → 60s cache → Opus `high` classifier → length-tiered fail-safe; goal-signal detector; remote-channel short-circuit; telemetry → `MEMORY/OBSERVABILITY/effort-router.jsonl`) → Algorithm `v{VERSION}.md` Mode Classification + Tier→Delegation (**route-effort**: E1–E3 `high`, E4/E5 `max`, Core-System Override, Per-Task Intelligence Routing, keystone pins classifier→high + Advisor→max — produces a *level*) → `LIFEOS/TOOLS/models.ts` (**select-model**: `EFFORT_MODEL` maps level→model max→fable / high→opus / medium→sonnet / low→haiku; `LEVEL_TO_HARNESS_EFFORT`; cross-vendor pins; egress-class ceilings) → **dispatch** via `model` param on `Agent()` / `Workflow agent()`. `LIFEOS/TOOLS/Inference.ts` applies select-model to utility inference + the Advisor. Executor contract in `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` § Mode Architecture. Full doc: `LIFEOS/DOCUMENTATION/Router/RouterSystem.md` |+| **Router** | Dataflow order: `hooks/TheRouter.hook.ts` (**classify**: fast-paths → 60s cache → Opus `high` classifier → length-tiered fail-safe; goal-signal detector; remote-channel short-circuit; telemetry → `MEMORY/OBSERVABILITY/effort-router.jsonl`) → Algorithm `v{VERSION}.md` Mode Classification + Tier→Delegation (**route-effort**: E1–E3 `high`, E4/E5 `max`, Core-System Override, Per-Task Intelligence Routing, keystone pins classifier→high + Advisor→max — produces a *level*) → `LIFEOS/TOOLS/models.ts` (**select-model**: `EFFORT_MODEL` maps level→model max→fable / high→opus / medium→sonnet / low→haiku; `LEVEL_TO_HARNESS_EFFORT`; cross-vendor pins; egress-class ceilings) → **dispatch** via `model` param on `Agent()` / `Workflow agent()`. `LIFEOS/TOOLS/Inference.ts` applies select-model to utility inference + the Advisor. Executor contract in `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` § Mode Architecture. Full doc: `LIFEOS/DOCUMENTATION/Router/RouterSystem.md` || **Hooks** | `hooks/*.hook.ts`, `hooks/handlers/*.ts`, `hooks/lib/*.ts`, `settings.json` || **Observability** | `hooks/ToolActivityTracker.hook.ts`, `hooks/ToolFailureTracker.hook.ts` (each appends directly via `fs.appendFileSync`) → `MEMORY/OBSERVABILITY/*.jsonl` || **Pulse** | `Pulse/pulse.ts` (port 31337), `Pulse/modules/{observability,hooks,wiki,imessage,telegram,user-index,da,work}.ts`, `Pulse/PULSE.toml`, `Pulse/Observability/src/`, `Pulse/Assistant/module.ts` |@@ -109,12 +109,12 @@ System file inventory by pipeline. When you modify a file, trace its pipeline to| **Skills** | `skills/*/SKILL.md`, `skills/*/Workflows/*.md`, `skills/*/Tools/*.ts`, `USER/CUSTOMIZATIONS/SKILLS/` || **Config** | `settings.json`, `CLAUDE.md`, `LIFEOS_SYSTEM_PROMPT.md` (directly edited) → release tooling clones the live tree, deletes private zones, overlays public templates + USER scaffold into staging, runs gates, then emits the shippable `LifeOS/` skill (`EmitSkill.ts`) from that staging || **Notifications** | `Pulse/pulse.ts` voice handler → ElevenLabs API → `MEMORY/VOICE/voice-events.jsonl` |-| **Telegram Dynamic Voice** | `Pulse/modules/telegram.ts` per-turn pipeline: `buildPaiContextBlock()` injects `USER/DIGITAL_ASSISTANT/DA_IDENTITY.md` + `USER/PRINCIPAL/PRINCIPAL_IDENTITY.md` + `USER/TELOS/PRINCIPAL_TELOS.md` + "Open Sessions to Resume" from `USER/PROJECTS.md` into SDK system prompt (cached 60s with per-file mtime invalidation) → SDK turn produces text reply streamed via `editMessageText` → `sendVoiceSummary()` fires fire-and-forget after text ships: `summarizeForVoice()` calls `LIFEOS/TOOLS/Inference.ts level: "medium"` (sonnet-tier, 10s outer race, fallback first-sentence) → `synthesizeKaiVoice()` POSTs ElevenLabs `output_format=opus_48000_64` → `bot.api.sendVoice(InputFile)` ships OGG/Opus as a voice-bubble. Voice ID resolved from `settings.json daidentity.voices.main.voiceId` (matches VoiceServer), public ElevenLabs `21m00Tcm4TlvDq8ikWAM` ("Rachel") fallback for fresh installs. 60-minute idle-session boundary: `lastMessageAt`/`threadStartedAt` clear `lastSessionId` and filter `conversationStore.getHistory()` by timestamp so episodic bursts thread together but a fresh post-idle message ships without "Previous conversation:" injection. Useless-fallback guard skips ElevenLabs when fallback summary <6 words against a ≥25-word reply. Channel-separate from CLI `/notify`: VoiceServer untouched. `PULSE/lib/conversation.ts` `getHistory()` returns `ConversationMessage[]` (timestamp field surfaced) — minimal additive change to support the timestamp filter. |+| **Telegram Dynamic Voice** | `Pulse/modules/telegram.ts` per-turn pipeline: `buildLifeosContextBlock()` injects `USER/DIGITAL_ASSISTANT/DA_IDENTITY.md` + `USER/PRINCIPAL/PRINCIPAL_IDENTITY.md` + `USER/TELOS/PRINCIPAL_TELOS.md` + "Open Sessions to Resume" from `USER/PROJECTS.md` into SDK system prompt (cached 60s with per-file mtime invalidation) → SDK turn produces text reply streamed via `editMessageText` → `sendVoiceSummary()` fires fire-and-forget after text ships: `summarizeForVoice()` calls `LIFEOS/TOOLS/Inference.ts level: "medium"` (sonnet-tier, 10s outer race, fallback first-sentence) → `synthesizeKaiVoice()` POSTs ElevenLabs `output_format=opus_48000_64` → `bot.api.sendVoice(InputFile)` ships OGG/Opus as a voice-bubble. Voice ID resolved from `settings.json daidentity.voices.main.voiceId` (matches VoiceServer), public ElevenLabs `21m00Tcm4TlvDq8ikWAM` ("Rachel") fallback for fresh installs. 60-minute idle-session boundary: `lastMessageAt`/`threadStartedAt` clear `lastSessionId` and filter `conversationStore.getHistory()` by timestamp so episodic bursts thread together but a fresh post-idle message ships without "Previous conversation:" injection. Useless-fallback guard skips ElevenLabs when fallback summary <6 words against a ≥25-word reply. Channel-separate from CLI `/notify`: VoiceServer untouched. `PULSE/lib/conversation.ts` `getHistory()` returns `ConversationMessage[]` (timestamp field surfaced) — minimal additive change to support the timestamp filter. || **Doc Integrity** | `hooks/DocIntegrity.hook.ts` (Stop) → `hooks/handlers/DocCrossRefIntegrity.ts` + `hooks/handlers/RebuildArchSummary.ts` → `Tools/ArchitectureSummaryGenerator.ts` |## Cross-References- Full architecture: `LIFEOS/DOCUMENTATION/LifeosSystemArchitecture.md`-- Algorithm spec: `LIFEOS/ALGORITHM/v6.23.0.md`+- Algorithm spec: `LIFEOS/ALGORITHM/v6.24.0.md`- ISA format: `LIFEOS/DOCUMENTATION/Isa/IsaFormat.md`- Config system: `LIFEOS/DOCUMENTATION/Config/ConfigSystem.md`diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Agents/AgentSystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Agents/AgentSystem.mdindex a16555a7..da6f18d5 100755--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Agents/AgentSystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Agents/AgentSystem.md@@ -2,7 +2,7 @@> Agents are how the LifeOS parallelizes the hill-climb. One DA fronts the system (thesis: `../LifeOs/LifeOsThesis.md`), but closing a current→ideal-state gap often takes many hands — research fanned out, code written, work audited cross-vendor. The routing rules below exist so that fan-out stays deterministic and the right kind of worker handles each leg of the climb.-**Authoritative reference for agent routing in PAI. Three distinct systems exist—never confuse them.**+**Authoritative reference for agent routing in LifeOS. Three distinct systems exist—never confuse them.**---diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Algorithm/AlgorithmSystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Algorithm/AlgorithmSystem.mdindex 56100e8f..86e4c3e3 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Algorithm/AlgorithmSystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Algorithm/AlgorithmSystem.md@@ -175,7 +175,7 @@ These are the six tabs in the Pulse Agents page (`LIFEOS/PULSE/Observability/src### What gets set when- **Iterate / Optimize / Ideate / Loop** — Algorithm modes. Set in ISA frontmatter `mode:` at OBSERVE via deterministic trigger detection or skill invocation. Drive the Algorithm's execution pattern.-- **Native** — response-mode crossover. Set by `hooks/EffortRouter.hook.ts` classifier at UserPromptSubmit when classifier emits `MODE: NATIVE`. Captured in session metadata for Pulse display; no full ISA created.+- **Native** — response-mode crossover. Set by `hooks/TheRouter.hook.ts` classifier at UserPromptSubmit when classifier emits `MODE: NATIVE`. Captured in session metadata for Pulse display; no full ISA created.- **Ladder** — not a LifeOS mode. Surfaced from the standalone Ladder project at `~/Projects/Ladder`.### Phase compressiondiff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Arbol/ArbolSystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Arbol/ArbolSystem.mdindex 385ef515..cf146470 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Arbol/ArbolSystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Arbol/ArbolSystem.md@@ -12,7 +12,7 @@ The single authoritative document for Arbol --- LifeOS's cloud execution layer.## Overview-Arbol is the cloud execution layer for PAI. It runs on Cloudflare Workers and provides the infrastructure for deploying AI-powered automation as serverless functions at the edge.+Arbol is the cloud execution layer for LifeOS. It runs on Cloudflare Workers and provides the infrastructure for deploying AI-powered automation as serverless functions at the edge.Where LifeOS's local system (the Algorithm, Skills, Memory) operates on the developer's machine, Arbol extends LifeOS into the cloud. It handles scheduled jobs, API integrations, LLM-powered transformations, and multi-step data pipelines --- all deployed as Cloudflare Workers with global distribution and near-zero cold starts.@@ -707,7 +707,7 @@ Check `flow-state.json` for errors. Common: malformed pipeline output, AUTH_TOKE|----------|------|-------------|| Source Code | `~/.claude/LIFEOS/USER/CUSTOMIZATIONS/ARBOL/` | Cloudflare Workers source repository || Cloudflare Skill | `Cloudflare` skill (LifeOS Skill registry) | MCP + wrangler dual-mode operations |-| Architecture | `PAISYSTEMARCHITECTURE.md` | LifeOS system architecture |+| Architecture | `LifeosSystemArchitecture.md` | LifeOS system architecture || System Actions | `~/.claude/LIFEOS/ARBOL/Actions/` | Framework actions (examples) || System Pipelines | `~/.claude/LIFEOS/ARBOL/Pipelines/` | Framework pipelines (examples) || System Flows | `~/.claude/LIFEOS/ARBOL/Flows/` | Framework flows (examples) |@@ -729,4 +729,4 @@ Check `flow-state.json` for errors. Common: malformed pipeline output, AUTH_TOKE| 2026-04-01 | Consolidated ACTIONS.md, PIPELINES.md, FLOWS.md, DEPLOYMENT.md into this single authoritative doc | {{DA_NAME}} | Architecture reorg || 2026-02-25 | Added Queue Composition pattern | {{DA_NAME}} | Feed system || 2026-02-22 | Added Loop Gate, aligned with actual Arbol codebase | {{DA_NAME}} | FLOWS.md |-| 2026-02-03 | Initial document creation | {{DA_NAME}} | PAISYSTEMARCHITECTURE.md |+| 2026-02-03 | Initial document creation | {{DA_NAME}} | LifeosSystemArchitecture.md |diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Config/ConfigSystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Config/ConfigSystem.mdindex 8fa02e20..725bf644 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Config/ConfigSystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Config/ConfigSystem.md@@ -12,7 +12,7 @@ LifeOS configuration follows the **system/user separation** contract (`LIFEOS/DO├── settings.system.json # SYSTEM defaults (public-safe, ships in LifeOS)├── CLAUDE.md # SYSTEM routing table (public-safe)├── LIFEOS/LIFEOS_SYSTEM_PROMPT.md # SYSTEM constitutional rules (public-safe)-├── LIFEOS/TOOLS/PaiConfig.ts # SYSTEM typed loader (INTERFACE)+├── LIFEOS/TOOLS/LifeosConfig.ts # SYSTEM typed loader (INTERFACE)├── LIFEOS/TOOLS/MergeSettings.ts # SYSTEM merge driver (INTERFACE)└── LIFEOS/USER → ~/.config/LIFEOS/USER # Symlink to USER tree@@ -33,13 +33,13 @@ LifeOS configuration follows the **system/user separation** contract (`LIFEOS/DO| File | Tree | Purpose ||------|------|---------|| `settings.json` | SYSTEM (generated) | Merged at SessionStart by `MergeSettings.ts` from `settings.system.json` + `settings.user.json`. Read-only at runtime — manual edits get overwritten next session. |-| `settings.system.json` | SYSTEM | Defaults: hooks, permissions, env, daidentity defaults, notifications, tips. Ships in public PAI. |+| `settings.system.json` | SYSTEM | Defaults: hooks, permissions, env, daidentity defaults, notifications, tips. Ships in public LifeOS. || `LIFEOS/USER/CONFIG/settings.user.json` | USER | Per-principal overlay: identity values, voice IDs, principal name + timezone, custom `spinnerVerbs` + `spinnerTipsOverride`, env overrides. Deep-merged into system defaults; USER always wins. || `CLAUDE.md` | SYSTEM (with USER `@`-imports) | Routing table + top-level `@`-imports of USER identity files. Public release template at `skills/_LIFEOS/RELEASE_TEMPLATES/CLAUDE.public.md`. || `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` | SYSTEM | Constitutional rules (system prompt layer, loaded via `--append-system-prompt-file`). || `LIFEOS/USER/CONFIG/OPERATIONAL_RULES.md` | USER | Per-principal operational rules: repo conventions, env paths, vendor-specific doctrine (Cloudflare token, deploy semantics). `@`-imported directly from `CLAUDE.md` — CC does not follow transitive `@`-imports. |-| `LIFEOS/USER/CONFIG/LIFEOS_CONFIG.toml` | USER | Typed user config (identity name/pronunciation/timezone, integration credentials, paths). Read via `PaiConfig.load()`. |-| `LIFEOS/TOOLS/PaiConfig.ts` | SYSTEM (INTERFACE) | Typed loader. Returns a strongly-typed object; the schema is the SYSTEM↔USER contract. |+| `LIFEOS/USER/CONFIG/LIFEOS_CONFIG.toml` | USER | Typed user config (identity name/pronunciation/timezone, integration credentials, paths). Read via `LifeosConfig.load()`. |+| `LIFEOS/TOOLS/LifeosConfig.ts` | SYSTEM (INTERFACE) | Typed loader. Returns a strongly-typed object; the schema is the SYSTEM↔USER contract. || `LIFEOS/TOOLS/MergeSettings.ts` | SYSTEM | Deep-merge driver that produces `settings.json` from `settings.system.json` + `settings.user.json` at SessionStart. || `LIFEOS/USER/INTEGRATIONS/{homebridge,unifi,airgradient}.yaml` | USER | Per-integration credentials/endpoints for private `_*` skills. || `LIFEOS/USER/WORK/config.yaml` | USER (optional) | `WORK.REPO` for the Work System. |@@ -48,7 +48,7 @@ LifeOS configuration follows the **system/user separation** contract (`LIFEOS/DO1. **SessionStart** — `MergeSettings.ts` reads `settings.system.json` + `LIFEOS/USER/CONFIG/settings.user.json`, deep-merges (USER wins on conflict), writes `settings.json`. This file is what Claude Code reads for hooks, permissions, env, identity.2. **Identity** — DA and principal values live in `settings.json` under `daidentity` and `principal` keys (provenance: USER overlay). Hooks read these via `hooks/lib/identity.ts` (`getIdentity()`, `getPrincipal()`, `getDAName()`, `getVoiceId()`).-3. **Skills** — private `_*` skills that need credentials/integration data read `LIFEOS_CONFIG.toml` via `PaiConfig.load()` (e.g. `_HOMEBRIDGE` reads Homebridge token; `_NETWORK` reads UniFi creds).+3. **Skills** — private `_*` skills that need credentials/integration data read `LIFEOS_CONFIG.toml` via `LifeosConfig.load()` (e.g. `_HOMEBRIDGE` reads Homebridge token; `_NETWORK` reads UniFi creds).4. **CLAUDE.md `@`-imports** — at session start, CC loads files referenced by top-level `@`-imports in `CLAUDE.md` (ARCHITECTURE_SUMMARY, PRINCIPAL_TELOS, PRINCIPAL_IDENTITY, DA_IDENTITY, PROJECTS, OPERATIONAL_RULES). CC does NOT follow transitive `@`-imports from inside imported files, so identity files must be listed in `CLAUDE.md` directly.## Editing@@ -93,13 +93,13 @@ The `<your-release-skill>` skill workflows:- **Phase B (2026-05-21)** — `settings.json` split into `settings.system.json` (public) + `settings.user.json` (USER). `MergeSettings.ts` merges at SessionStart.- **Phase C (2026-05-22)** — `CLAUDE.md` becomes thin router with direct `@`-imports of USER identity files. `OPERATIONAL_RULES.md` created in `LIFEOS/USER/CONFIG/`. `CLAUDE.user.md` sidecar created and then deleted 2026-05-23 (merged back into `CLAUDE.md`) because CC doesn't follow transitive `@`-imports.- **Phase E (2026-05-22)** — `SystemFileGuard.hook.ts` runtime write-time enforcement begins.-- **Phase F (2026-05-22)** — `PaiConfig.ts` typed loader + `LIFEOS_CONFIG.toml` populated. Private skills migrated from hardcoded credentials to `PaiConfig.load()`.+- **Phase F (2026-05-22)** — `LifeosConfig.ts` typed loader + `LIFEOS_CONFIG.toml` populated. Private skills migrated from hardcoded credentials to `LifeosConfig.load()`.- **Phase G (2026-05-22→23)** — separate private GitHub repo created for USER data. `~/.claude/LIFEOS/USER` becomes symlink to `~/.config/LIFEOS/USER`. Pre-push hook installed for two-repo sync. A two-repo-push workflow ("update the kai repo" / "push both repos") ships in the private `<your-release-skill>` skill with four boundary gates.- **Phase H (deferred)** — PR-time `DenyListCheck` via GitHub Actions; community v5→v6 migration tool.## Pre-v6.0 history-The pre-Phase-A model used `LIFEOS_CONFIG.yaml` as a credentials store and a single `settings.json` directly edited by hand. There was no system/user boundary enforced at write time; defenses were release-time only. That model is retired — the contemporary architecture is the split + symlink + `PaiConfig.ts` described above. The release tooling preserves a `settings.public.json` template for the public release path but the live system reads only from the split files.+The pre-Phase-A model used `LIFEOS_CONFIG.yaml` as a credentials store and a single `settings.json` directly edited by hand. There was no system/user boundary enforced at write time; defenses were release-time only. That model is retired — the contemporary architecture is the split + symlink + `LifeosConfig.ts` described above. The release tooling preserves a `settings.public.json` template for the public release path but the live system reads only from the split files.## Cross-referencesdiff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/CoreComponents.md b/LifeOS/install/LIFEOS/DOCUMENTATION/CoreComponents.mdindex 03266046..1239ab75 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/CoreComponents.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/CoreComponents.md@@ -34,7 +34,7 @@ The loop under everything. Your ideal state is the top of the hill, broken into### 3. TELOS-Where you write down who you are and what you're trying to do: your mission, goals, problems, strategies, beliefs, and challenges. You don't start from a blank file — LifeOS interviews you to draw it out, then writes it down for you. From then on every recommendation is framed against it, so the system works toward your actual life, not a generic answer.+Where you write down who you are and what you're trying to do: your mission, goals, problems, strategies, beliefs, and challenges. You don't start from a blank file — LifeOS interviews you to draw it out, asking what you're building, who matters to you, and where you want to go, then writes it down for you. From then on every recommendation is framed against it, so the system works toward your actual life, not a generic answer.→ `LifeOs/LifeOsThesis.md`diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Freshness/FreshnessSystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Freshness/FreshnessSystem.mdindex 291e1c8e..9d131f37 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Freshness/FreshnessSystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Freshness/FreshnessSystem.md@@ -241,7 +241,7 @@ Pulse remains the canonical reader for the dashboard; the cache file is the cano## Adjacent freshness system: memory hot-layer mtime cache-The autonomic memory loop (2026-05-22, see `LIFEOS/DOCUMENTATION/Memory/MemorySystem.md`) uses a parallel but separate freshness mechanism for the per-turn context block. `LIFEOS/PULSE/modules/telegram.ts` `buildPaiContextBlock()` mtime-caches the four constitutional files (DA_IDENTITY, PRINCIPAL_IDENTITY, PRINCIPAL_TELOS, PROJECTS) plus the two hot-layer memory files (`PRINCIPAL_MEMORY.md`, `DA_MEMORY.md`) for 60 seconds, re-reading whenever any per-file mtime changes. The 60s window is short enough to pick up an autonomic memory reviewer write within the same conversational burst, long enough to avoid re-reading on every prompt.+The autonomic memory loop (2026-05-22, see `LIFEOS/DOCUMENTATION/Memory/MemorySystem.md`) uses a parallel but separate freshness mechanism for the per-turn context block. `LIFEOS/PULSE/modules/telegram.ts` `buildLifeosContextBlock()` mtime-caches the four constitutional files (DA_IDENTITY, PRINCIPAL_IDENTITY, PRINCIPAL_TELOS, PROJECTS) plus the two hot-layer memory files (`PRINCIPAL_MEMORY.md`, `DA_MEMORY.md`) for 60 seconds, re-reading whenever any per-file mtime changes. The 60s window is short enough to pick up an autonomic memory reviewer write within the same conversational burst, long enough to avoid re-reading on every prompt.This is structurally distinct from the freshness cache documented above:- **This file's cache** (`LIFEOS/USER/CACHE/freshness.json`) backs the statusline FRESH line and `/api/freshness/summary`. Driven by `bump*` events + Pulse `invalidate()` + SessionStart hook. Schema = full A-F grade output.diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Hooks/HookSystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Hooks/HookSystem.mdindex 7b9409b8..e188477d 100755--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Hooks/HookSystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Hooks/HookSystem.md@@ -156,7 +156,7 @@ Claude Code supports the following hook events:"hooks": [{"type": "command",- "command": "$HOME/.claude/hooks/EffortRouter.hook.ts",+ "command": "$HOME/.claude/hooks/TheRouter.hook.ts","timeout": 30,"async": true}@@ -198,8 +198,8 @@ Claude Code supports the following hook events:**What It Does (current state, 2026-05-06):**-**EffortRouter.hook.ts** — Mode + Tier classification. **Owns the classifier role.**-- Three-stage cascade: deterministic fast-paths (`/eN`, ratings, praise, system text) → 60s decision cache → EffortRouter classifier (`Inference.ts --level high` — Opus; re-pinned off `max` on 2026-07-01 so the per-prompt keystone doesn't ride Fable, while `max`=Fable stays for E4/E5 + the advisor)+**TheRouter.hook.ts** — Mode + Tier classification. **Owns the classifier role.**+- Three-stage cascade: deterministic fast-paths (`/eN`, ratings, praise, system text) → 60s decision cache → TheRouter classifier (`Inference.ts --level high` — Opus; re-pinned off `max` on 2026-07-01 so the per-prompt keystone doesn't ride Fable, while `max`=Fable stays for E4/E5 + the advisor)- Emits `MODE: MINIMAL|NATIVE|ALGORITHM | TIER: E1-E5 | REASON: … | SOURCE: classifier|fail-safe|fast-path|cache|explicit` to `additionalContext` via `hookSpecificOutput`- **Fail-safe:** classifier timeout/error → `ALGORITHM E3 | SOURCE: fail-safe` (under-escalation is the failure mode the system is built to prevent — Algorithm v6.3.0 line 97)- **Inference:** Sonnet via `claude` subscription-billed subprocess (Inference.ts pattern)@@ -208,7 +208,7 @@ Claude Code supports the following hook events:**PromptProcessing.hook.ts** — Tab Title + Session Naming via Haiku- Single responsibility: terminal tab title updates and session auto-naming-- Does NOT do mode/tier classification (EffortRouter), rating capture (SatisfactionCapture), or repeat detection (removed 2026-05-06).+- Does NOT do mode/tier classification (TheRouter), rating capture (SatisfactionCapture), or repeat detection (removed 2026-05-06).- Fast paths: deterministic tab title on first prompt, deterministic session name fallback- Inference: one Haiku call returning `{ tab_title, session_name }`- Writes to: `session-names.json`, `work.json`, tab state, voice server@@ -226,8 +226,8 @@ Claude Code supports the following hook events:> **Migration notes (2026-05-06):**> - The v4.0 Inspector Pipeline (PromptGuard, ContentScanner, SmartApprover, SecurityPipeline, ContainmentGuard) was deleted in the security simplification. See `LIFEOS/DOCUMENTATION/Security/README.md`.-> - `RepeatDetection.hook.ts` was cut as a pre-classifier-era safety net now redundant with EffortRouter + Opus reading conversation context. Pre-state tag: `pre-bpe-cuts-2026-05-06`.-> - The ModeClassifier/ClassifierTelemetry consolidation hinted at in older docs was reverted: classifier (EffortRouter) and namer/tab-setter (PromptProcessing) are separate hooks again, in that order, on UserPromptSubmit.+> - `RepeatDetection.hook.ts` was cut as a pre-classifier-era safety net now redundant with TheRouter + Opus reading conversation context. Pre-state tag: `pre-bpe-cuts-2026-05-06`.+> - The ModeClassifier/ClassifierTelemetry consolidation hinted at in older docs was reverted: classifier (TheRouter) and namer/tab-setter (PromptProcessing) are separate hooks again, in that order, on UserPromptSubmit.---@@ -1411,7 +1411,7 @@ SESSION START (2 hooks):LoadContext.hook.ts Dynamic context injection (relationship, learning, work)USER PROMPT SUBMIT (5 hooks, in fire order; verified 2026-05-23):- EffortRouter.hook.ts Mode + Tier classifier → additionalContext+ TheRouter.hook.ts Mode + Tier classifier → additionalContextPromptProcessing.hook.ts Tab title + session naming via HaikuSatisfactionCapture.hook.ts User satisfaction signal capture (reads last-response.txt)ReminderRouter.hook.ts /remind parser → labeled GitHub issue@@ -1459,7 +1459,7 @@ SUBAGENT STOP (0 hooks):(empty — see PostToolUse:Agent → AgentInvocation.hook.ts)PERMISSION REQUEST (1 hook):- Safety.hook.ts Shape-classifier auto-approve [Bash, Write, Edit, MultiEdit, mcp__reversinglabs__.*]+ Safety.hook.ts Shape-classifier auto-approve [Bash, Write, Edit, MultiEdit, mcp__.*]— same file as PostToolUse hook above; dispatches by event.PermissionRequest path uses lib/safety-classifier.ts to allow safe shapes(read-only commands, dev binaries, trusted-workspace targets, mcp pre-vetted,diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Isa/IsaFormat.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Isa/IsaFormat.mdindex 865e8700..2aac9553 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Isa/IsaFormat.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Isa/IsaFormat.md@@ -151,7 +151,7 @@ frame_drift_summary: "" # NEW v2.11 / Algorithm v6.8.0+ — ≤14Optional fields (NEW v2.10 / 2026-05-13 — Response Mode + Journey Surface):```yaml-response_mode: algorithm # minimal | native | algorithm — Layer 1 set by EffortRouter.hook.ts+response_mode: algorithm # minimal | native | algorithm — Layer 1 set by TheRouter.hook.tsalgorithm_mode: iterate # iterate | optimize | ideate | loop — Layer 2 (alias of `mode:` for clarity)current_state: "Code has 47 type errors blocking deploy" # The "before" — one-line summary of reality now@@ -172,7 +172,7 @@ capabilities_invoked: # Array of capabilities actually invoked via too- `capabilities_invoked`: populated incrementally as the Algorithm fires each capability via tool call. Appended-only — no removal on revert. Mirrors the `🏹 CAPABILITIES SELECTED` block in Algorithm phase output, but records actual invocations not intended ones.**Lifecycle:**-- `response_mode`: immutable once set at session start. Set by EffortRouter.hook.ts via additionalContext propagation.+- `response_mode`: immutable once set at session start. Set by TheRouter.hook.ts via additionalContext propagation.- `algorithm_mode`: changes only when the Algorithm explicitly switches mode (rare; e.g., user mid-task says "actually let's ideate this").- `current_state`: immutable once written. The "before" snapshot doesn't change as work progresses.- `ideal_state`: should align with `principal_stated_goal:` when set; can be refined as the ISA tightens (matches the "living explanation" pattern).diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/LifeOsSchema.md b/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/LifeOsSchema.mdindex 67057405..511255f6 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/LifeOsSchema.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/LifeOsSchema.md@@ -1,6 +1,6 @@# Life OS Schema-> **The canonical shape of the USER directory in PAI.**+> **The canonical shape of the USER directory in LifeOS.**>> Everything your DA knows about you lives in one flat, biography-style tree. This spec defines the rules every LifeOS user follows — so the same Pulse dashboard, the same Interview skill, the same Daemon aggregator, and the same skills work for everyone out of the box.diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/LifeOsThesis.md b/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/LifeOsThesis.mdindex 6107a714..20af260a 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/LifeOsThesis.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/LifeOsThesis.md@@ -122,7 +122,7 @@ All of these belong to the Dashboard because the Dashboard is *everything you ca- **Day-in-the-Life preview** — reverse-engineered from your 2036 target- **Respark signals** — the play / creativity / dreaming layer-Pulse is not PAI. Pulse is one window onto PAI. A LifeOS with no dashboard would still be a LifeOS. A dashboard with no OS behind it would be a widget.+Pulse is not LifeOS. Pulse is one window onto LifeOS. A LifeOS with no dashboard would still be a LifeOS. A dashboard with no OS behind it would be a widget.---diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/RenameMap.json b/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/RenameMap.jsonindex 8dc4e0fc..1faa9f48 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/RenameMap.json+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/LifeOs/RenameMap.json@@ -32,11 +32,11 @@}},"classes": [- { "id": 1, "name": "docs-prose-branding", "scale": { "lines": 4566, "files": 572, "bare_word_lines": 1454 }, "verdict": "rename-now", "notes": "Generated files: edit source+generator, regenerate. RELEASE_TEMPLATES ripple to public repo at next shadow release — deliberate edits only." },- { "id": 2, "name": "pulse-ui-display-strings", "scale": { "lines": 298, "files": 74 }, "verdict": "rename-now", "exceptions": ["PULSE/MenuBar/build/PAI Pulse.app bundle (codesign/launchd) -> at-cut", "pai-logo.png asset path -> at-cut"] },+ { "id": 1, "name": "docs-prose-branding", "scale": { "lines": 4566, "files": 572, "bare_word_lines": 1454 }, "verdict": "rename-now", "notes": "Generated files: edit source+generator, regenerate. RELEASE_TEMPLATES ripple to public repo at next shadow release — deliberate edits only.", "status": "DONE 2026-07-04 — prose branding swept in .md docs ONLY (PAI->LifeOS, PAI/->LIFEOS/, PAI_SYSTEM_PROMPT->LIFEOS_SYSTEM_PROMPT, com.pai.->com.lifeos.), keeps protected via lookbehind (danielmiessler/PAI, 'PAI ALGORITHM'). Bare PAI inside CODE strings/regexes/paths intentionally NOT swept — that is class 3/4 and a blind sweep there corrupts logic. RELEASE_TEMPLATES prose was included (flagged: ripples public at next shadow release, ahead of the class-6 cut)." },+ { "id": 2, "name": "pulse-ui-display-strings", "scale": { "lines": 298, "files": 74 }, "verdict": "rename-now", "exceptions": ["PULSE/MenuBar/build/PAI Pulse.app bundle (codesign/launchd) -> at-cut", "pai-logo.png asset path -> at-cut"], "status": "DONE 2026-07-04 — display strings + React identifiers (PAIEvent/usePAIEvents->LifeosEvent/useLifeosEvents etc.) renamed; the two exceptions remain at-cut, untouched." },{ "id": 3, "name": "filesystem-paths-dirs", "scale": { "lines": 3979, "files": 662 }, "verdict": "rename-at-cut", "breakage_points": ["~/.claude/LIFEOS/USER -> ~/.config/LIFEOS/USER symlink", "launchd com.lifeos.* WatchPaths/exec", "settings.json additionalDirectories + env block", "--append-system-prompt-file launcher path", "DerivedSync sha256 path-keyed state", "LIFEOS_StatusLine.sh", "USER/TELOS/LIFEOS_STATE.json readers (Pulse rings, statusline)"], "procedure": "one atomic op + compat symlink one release cycle; per-path probes as a migration ISA" },{ "id": 4, "name": "env-vars-config-keys", "scale": { "occurrences": 1341, "files": 311, "live_reads": { "LIFEOS_DIR": 76, "LIFEOS_CONFIG_DIR": 33 } }, "verdict": "rename-at-cut-with-shim", "procedure": "introduce new names, keep PAI_* read-fallbacks one release, then retire; LifeOS/install/install.sh included" },- { "id": 5, "name": "code-identifiers", "scale": { "occurrences": 194, "files": 49 }, "verdict": "at-cut-or-never", "top": ["PaiConfig", "loadPaiConfig", "getPaiDir", "PAIEvent/usePAIEvents", "PAIAgentAdapter", "buildPaiContextBlock"] },+ { "id": 5, "name": "code-identifiers", "scale": { "occurrences": 194, "files": 49 }, "verdict": "at-cut-or-never", "top": ["PaiConfig", "loadPaiConfig", "getPaiDir", "PAIEvent/usePAIEvents", "PAIAgentAdapter", "buildPaiContextBlock"], "status": "DONE 2026-07-04 — completed NOW, not at-cut. Rationale: code identifiers are internal-only (never appear in the public scrubbed release), so they are cut-independent; the original 'at-cut' grouping was sequencing convenience, and the verdict's own 'or-never' marked it optional. Executed as exact-token renames over code+docs (Pai*->Lifeos*, PAI*->Lifeos*) + 6 file git-mv's. Verified: LifeosConfig test 13/13, hook entrypoints build clean, keeps intact, and security/behavioral code left byte-identical to pre-change (branding never touched code regexes/paths/labels). 'top' list preserved as the historical old-name record." },{ "id": 6, "name": "repo-remote-names", "scale": { "lines": 86, "files": 35 }, "verdict": "rename-at-cut-it-IS-the-cut", "procedure": "atomic GitHub rename (stars/clones redirect) -> same-day sweep of all 86 lines; work_repo.json attestation + private-remote URLs updated explicitly (redirects are not forever)" },{ "id": 7, "name": "_LIFEOS-skill", "scale": { "occurrences": 235, "files": 99 }, "verdict": "rename-at-cut-via-CreateSkill", "notes": "same sweep as classes 3/4 so routing never points at a dead name; ud/ur/ut shortcuts included" },{ "id": 8, "name": "mode-banners-hook-regexes", "scale": { "literals": 3, "hooks": 2 }, "verdict": "rename-at-cut", "members": ["LIFEOS_SYSTEM_PROMPT.md mode templates", "hooks/OutputFormatGate.hook.ts:49", "hooks/DriftReminder.hook.ts:39", "their tests"], "procedure": "one coordinated change, byte-parity verified between prompt and hooks" }diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/LifeosSystemArchitecture.md b/LifeOS/install/LIFEOS/DOCUMENTATION/LifeosSystemArchitecture.mdindex 83ff610f..544bc408 100755--- a/LifeOS/install/LIFEOS/DOCUMENTATION/LifeosSystemArchitecture.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/LifeosSystemArchitecture.md@@ -51,7 +51,7 @@ LifeOS targets **AS3** on the [LifeOS Maturity Model](https://example.com/blog/p**Canonical thesis:** `LIFEOS/DOCUMENTATION/LifeOs/LifeOsThesis.md` — read this first when any framing question comes up. This architecture doc describes *how* the OS is built; the thesis doc describes *what* the OS is for.-**Version:** LifeOS 6.0.3 | Algorithm v6.23.0 | Memory v8.2+**Version:** LifeOS 6.0.5 | Algorithm v6.24.0 | Memory v8.2---@@ -208,8 +208,8 @@ The LifeOS live tree and the public release are structurally identical modulo a- `~/.config/LIFEOS/USER/MEMORY/` — durable subset of memory (KNOWLEDGE, WORK/<slug>/ISA.md, RELATIONSHIP, WISDOM, PLANS, RESEARCH, STATE/work.json, BOOKMARKS, REFERENCE, SKILLS, PROJECT, TEAMS, PAISYSTEMUPDATES, VERIFICATION) git-tracked in the user's private USER-data repo; ephemeral subset (OBSERVABILITY, STATE caches, LEARNING signals, SECURITY artifacts, VOICE event log, _BROWSER_STATE) gitignored locally.**Four allowed access patterns** (any fifth pattern is a boundary violation):-1. `PaiConfig.load()` typed loader (`LIFEOS/TOOLS/PaiConfig.ts`) — primary channel for identity, voice, integrations, paths-2. Paths computed from `PaiConfig.paths.userDir + relative` — never from literal `LIFEOS/USER/` strings in system code+1. `LifeosConfig.load()` typed loader (`LIFEOS/TOOLS/LifeosConfig.ts`) — primary channel for identity, voice, integrations, paths+2. Paths computed from `LifeosConfig.paths.userDir + relative` — never from literal `LIFEOS/USER/` strings in system code3. At-startup `@`-imports declared at the top of `~/.claude/CLAUDE.md` (CC does NOT follow transitive `@`-imports)4. HTTP/IPC via the Pulse server at `localhost:31337`@@ -220,7 +220,7 @@ The LifeOS live tree and the public release are structurally identical modulo a**Two-repo sync** — `~/.claude/.git/hooks/pre-push` auto-commits and pushes `~/.config/LIFEOS/USER/` to the user's private USER-data repo before each push from `~/.claude/`. The two repos stay in sync structurally. A private "kai update" / "push both repos" workflow wraps this with 4 boundary gates (USER-zone leak check, DenyListCheck, both-remotes-private confirmation, post-push HEAD verification).-Configuration files (`settings.json`, `CLAUDE.md`, `LIFEOS_SYSTEM_PROMPT.md`) are directly edited; `settings.json` is split into `settings.system.json` (public) + `settings.user.json` (USER) merged at SessionStart by `LIFEOS/TOOLS/MergeSettings.ts`. Identity values live in `settings.json` under `daidentity` and `principal` keys; private skills read credentials via `PaiConfig.ts` from `LIFEOS/USER/CONFIG/LIFEOS_CONFIG.toml`. Full contract: `LIFEOS/DOCUMENTATION/SystemUserBoundary.md`.+Configuration files (`settings.json`, `CLAUDE.md`, `LIFEOS_SYSTEM_PROMPT.md`) are directly edited; `settings.json` is split into `settings.system.json` (public) + `settings.user.json` (USER) merged at SessionStart by `LIFEOS/TOOLS/MergeSettings.ts`. Identity values live in `settings.json` under `daidentity` and `principal` keys; private skills read credentials via `LifeosConfig.ts` from `LIFEOS/USER/CONFIG/LIFEOS_CONFIG.toml`. Full contract: `LIFEOS/DOCUMENTATION/SystemUserBoundary.md`.---@@ -278,11 +278,11 @@ Each subsystem has its own detailed documentation. This section provides orienta### The Algorithm-**The 7-phase execution engine at the center of PAI.**+**The 7-phase execution engine at the center of LifeOS.**Transitions from CURRENT STATE to IDEAL STATE via verifiable Ideal State Criteria (ISC): Observe -> Think -> Plan -> Build -> Execute -> Verify -> Learn. Supports three execution modes: interactive (human-in-the-loop), loop (autonomous), and optimize (hill-climbing against a metric). The Algorithm is versioned independently and self-improves through accumulated learning signals.-- **Version:** v6.23.0+- **Version:** v6.24.0- **Location:** `LIFEOS/ALGORITHM/` (canonical pointer: `LATEST` → `v6.18.0.md`)- **CLI:** `bun LIFEOS/TOOLS/algorithm.ts`- **Full doc:** `LIFEOS/DOCUMENTATION/Algorithm/AlgorithmSystem.md`@@ -292,10 +292,10 @@ Transitions from CURRENT STATE to IDEAL STATE via verifiable Ideal State Criteri**The prompt-comprehension and execution-posture layer — every prompt passes through it before any work begins.**-Turns a raw prompt into a posture: mode (MINIMAL/NATIVE/ALGORITHM), effort tier (E1–E5), the stated goal, the model rung, and which agent/vendor runs the work. Four stages — classify (`hooks/EffortRouter.hook.ts`), route the effort (Algorithm tier→level policy, which produces a *level*), select the model (`LIFEOS/TOOLS/models.ts` four-level `EFFORT_MODEL` abstraction maps that level to a model), and dispatch the agent (dispatch-time `model` param). The Algorithm is the Router's biggest consumer, not part of it: the Router decides how to handle a prompt; the Algorithm/NATIVE executes within that decision. It exists to preserve dynamic range (fast on trivial work, deep on hard work) and to work around a harness limit — the main loop cannot switch its own model mid-turn, so the Router classifies up front and programs the model + effort of the agents the work dispatches.+Turns a raw prompt into a posture: mode (MINIMAL/NATIVE/ALGORITHM), effort tier (E1–E5), the stated goal, the model rung, and which agent/vendor runs the work. Four stages — classify (`hooks/TheRouter.hook.ts`), route the effort (Algorithm tier→level policy, which produces a *level*), select the model (`LIFEOS/TOOLS/models.ts` four-level `EFFORT_MODEL` abstraction maps that level to a model), and dispatch the agent (dispatch-time `model` param). The Algorithm is the Router's biggest consumer, not part of it: the Router decides how to handle a prompt; the Algorithm/NATIVE executes within that decision. It exists to preserve dynamic range (fast on trivial work, deep on hard work) and to work around a harness limit — the main loop cannot switch its own model mid-turn, so the Router classifies up front and programs the model + effort of the agents the work dispatches.- **Status:** Active (named + documented 2026-07-01)-- **Location:** `hooks/EffortRouter.hook.ts`, `LIFEOS/TOOLS/models.ts`, `LIFEOS/TOOLS/Inference.ts`, Algorithm Mode Classification doctrine+- **Location:** `hooks/TheRouter.hook.ts`, `LIFEOS/TOOLS/models.ts`, `LIFEOS/TOOLS/Inference.ts`, Algorithm Mode Classification doctrine- **Full doc:** `LIFEOS/DOCUMENTATION/Router/RouterSystem.md`### Skill System@@ -372,7 +372,7 @@ Configuration files (`settings.json`, `CLAUDE.md`, `LIFEOS_SYSTEM_PROMPT.md`) ar**Minimal v3 — three layers + one consolidated hook + one shared lib.**-The model is the security boundary; the hook is a deterministic gate around it. Three layers: (1) Constitutional Security Protocol in `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` — model treats external content as data, refuses embedded instructions, reports injection attempts. (2) Native Claude Code `permissions.deny` + `permissions.ask` in `settings.json` — declarative block/prompt list for irrecoverable shell, disk, and filesystem operations and credential reads. (3) `hooks/Safety.hook.ts` — one file, two events. **PermissionRequest path** (matcher: `Write|Edit|MultiEdit|Bash` + `mcp__reversinglabs__.*`) auto-approves safe shapes via the classifier in `lib/safety-classifier.ts`, defers dangerous-shape / credential-path / injection-shape commands to the native prompt; logs every decision to `MEMORY/OBSERVABILITY/permission-decisions.jsonl` with hashed prefixes; sha-keyed cache at `MEMORY/STATE/permission-cache.json`. **PostToolUse path** on WebFetch/WebSearch prepends "treat as data" header + injection marker. The classifier includes a shell-aware single-quote pre-pass: when the outer command is NOT a wrapper (`bash -c`, `eval`, language interpreters with `-c`/`-e`), single-quoted regions are stripped before pattern matching (literal data, not execution); when it IS a wrapper, the inner content is also matched directly. A narrow `for|while|until` loop gate then auto-allows control-flow whose body has no shell-execution sub-shapes — so test loops over dangerous-string fixtures auto-approve while loops with `bash -c "$x"`/`eval "$x"`/pipe-to-shell bodies still neutral. Decision-tree invariant: dangerous + credential checks precede every allow path except `mcp__` pre-vetted (verified by Advisor + Cato on 2026-05-13 after a `cat ~/.aws/credentials` bypass was caught and closed). Consolidates the prior `SmartApprover.hook.ts` + `PromptInjection.hook.ts` split (2026-05-14). Replaces the 4,200-LOC v4.0 inspector-pipeline architecture (deleted 2026-05-06).+The model is the security boundary; the hook is a deterministic gate around it. Three layers: (1) Constitutional Security Protocol in `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` — model treats external content as data, refuses embedded instructions, reports injection attempts. (2) Native Claude Code `permissions.deny` + `permissions.ask` in `settings.json` — declarative block/prompt list for irrecoverable shell, disk, and filesystem operations and credential reads. (3) `hooks/Safety.hook.ts` — one file, two events. **PermissionRequest path** (matcher: `Write|Edit|MultiEdit|Bash` + `mcp__.*`) auto-approves safe shapes via the classifier in `lib/safety-classifier.ts`, defers dangerous-shape / credential-path / injection-shape commands to the native prompt; logs every decision to `MEMORY/OBSERVABILITY/permission-decisions.jsonl` with hashed prefixes; sha-keyed cache at `MEMORY/STATE/permission-cache.json`. **PostToolUse path** on WebFetch/WebSearch prepends "treat as data" header + injection marker. The classifier includes a shell-aware single-quote pre-pass: when the outer command is NOT a wrapper (`bash -c`, `eval`, language interpreters with `-c`/`-e`), single-quoted regions are stripped before pattern matching (literal data, not execution); when it IS a wrapper, the inner content is also matched directly. A narrow `for|while|until` loop gate then auto-allows control-flow whose body has no shell-execution sub-shapes — so test loops over dangerous-string fixtures auto-approve while loops with `bash -c "$x"`/`eval "$x"`/pipe-to-shell bodies still neutral. Decision-tree invariant: dangerous + credential checks precede every allow path except `mcp__` pre-vetted (verified by Advisor + Cato on 2026-05-13 after a `cat ~/.aws/credentials` bypass was caught and closed). Consolidates the prior `SmartApprover.hook.ts` + `PromptInjection.hook.ts` split (2026-05-14). Replaces the 4,200-LOC v4.0 inspector-pipeline architecture (deleted 2026-05-06).- **Status:** Active (Minimal v3, 2026-05-14 — SmartApprover + PromptInjection consolidated into Safety.hook.ts; shell-aware classifier added)- **Location:** `hooks/Safety.hook.ts`, `hooks/lib/safety-classifier.ts`@@ -453,7 +453,7 @@ Formalizes how Pulse instantiates, manages, and evolves a Digital Assistant. Rep**agent-browser: Rust CLI daemon with persistent auth profiles per site.**-Headless by default. Handles screenshots, multi-step sessions, authenticated browsing, scraping, and data extraction. Auth via persistent profiles (`--profile ~/.agent-browser/profiles/<site>`). Legacy built-in agents (BrowserAgent, UIReviewer, QATester) were removed 2026-06-10 — browser work delegates to general-purpose agents driving agent-browser. All web-based output must be verified through the **Interceptor skill** before showing to the user. Playwright is banned across PAI.+Headless by default. Handles screenshots, multi-step sessions, authenticated browsing, scraping, and data extraction. Auth via persistent profiles (`--profile ~/.agent-browser/profiles/<site>`). Legacy built-in agents (BrowserAgent, UIReviewer, QATester) were removed 2026-06-10 — browser work delegates to general-purpose agents driving agent-browser. All web-based output must be verified through the **Interceptor skill** before showing to the user. Playwright is banned across LifeOS.- **Status:** Active- **Location:** `~/.claude/skills/Browser/` (batch/headless) + `~/.claude/skills/Interceptor/` (stealth Chrome, mandatory for verification)@@ -570,7 +570,7 @@ System file inventory by pipeline. When you modify a file, trace its pipeline to| **Security** | `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` § Security Protocol (constitutional rule), `settings.json` `permissions.deny` (native harness denylist), `hooks/Safety.hook.ts` (consolidated PermissionRequest + PostToolUse on WebFetch \| WebSearch), `hooks/lib/safety-classifier.ts` (shape catalog + shell-aware classifier with single-quote pre-pass) || **Algorithm** | `Algorithm/LATEST` → `Algorithm/v{VERSION}.md` (currently v6.18.0), `Algorithm/capabilities.md`, `Algorithm/mode-detection.md`, `hooks/ISASync.hook.ts` → `MEMORY/WORK/{slug}/ISA.md`, `skills/ISA/` (canonical Scaffold/Append/Reconcile workflows); **work registry event-sourced (2026-06-10):** all `work.json` writes go through `isa-utils.writeRegistry` → field-level diff events appended to `MEMORY/STATE/work-events.jsonl` (`hooks/lib/work-events.ts`) → locked fold to the derived `work.json` snapshot (offset-stamped, 1MB compaction); `readRegistry` serves snapshot+suffix live views; Pulse SSE triggers off `fs.watch` on STATE with the 100ms poll as fallback; model routing via the four-level `EFFORT_MODEL` abstraction in `LIFEOS/TOOLS/models.ts` (max/high/medium/low → lineup; E1–E3 dispatch `high`, E4/E5 `max`, NATIVE delegates `high`) || **Memory** | `hooks/WorkCompletionLearning.hook.ts`, `hooks/SatisfactionCapture.hook.ts`, `hooks/RelationshipMemory.hook.ts`, `Tools/KnowledgeHarvester.ts` → `MEMORY/KNOWLEDGE/`, `MEMORY/LEARNING/`; `Tools/SessionHarvester.ts --mine` → `KNOWLEDGE/_harvest-queue/`; `Tools/MemoryRetriever.ts` (BM25 retrieval over typed-item corpus including `_MEMORY.md` hot-layer files), `Tools/KnowledgeGraph.ts` (graph navigation) — read-only. **Autonomic loop (2026-05):** `hooks/MemoryReviewTrigger.hook.ts` (UserPromptSubmit) + `hooks/MemoryReviewFire.hook.ts` (Stop) drive `Tools/MemoryReviewer.ts` on cadence (turn≥8 ∧ minutes≥30 ∧ idle≥2). Reviewer emits typed items routed by `Tools/MemorySystem.ts` (single `add(item)` API) over the `Tools/MemoryTypes.ts` registry; `Tools/MutationTier.ts` gates by tier A/B/C/D. Tier-C proposals enqueue to `MEMORY/OBSERVABILITY/pending-proposals.jsonl`; `PULSE/lib/telegram-proposals.ts` + `PULSE/modules/telegram.ts` surface them as `yes/no/edit #id` Telegram replies. `Tools/MemoryStatus.ts` is the read-only `kai status` CLI. |-| **Router** | Dataflow order: `hooks/EffortRouter.hook.ts` (**classify**: fast-paths → 60s cache → Opus `high` classifier → length-tiered fail-safe; goal-signal detector; remote-channel short-circuit; telemetry → `MEMORY/OBSERVABILITY/effort-router.jsonl`) → Algorithm `v{VERSION}.md` Mode Classification + Tier→Delegation (**route-effort**: E1–E3 `high`, E4/E5 `max`, Core-System Override, Per-Task Intelligence Routing, keystone pins classifier→high + Advisor→max — produces a *level*) → `LIFEOS/TOOLS/models.ts` (**select-model**: `EFFORT_MODEL` maps level→model max→fable / high→opus / medium→sonnet / low→haiku; `LEVEL_TO_HARNESS_EFFORT`; cross-vendor pins; egress-class ceilings) → **dispatch** via `model` param on `Agent()` / `Workflow agent()`. `LIFEOS/TOOLS/Inference.ts` applies select-model to utility inference + the Advisor. Executor contract in `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` § Mode Architecture. Full doc: `LIFEOS/DOCUMENTATION/Router/RouterSystem.md` |+| **Router** | Dataflow order: `hooks/TheRouter.hook.ts` (**classify**: fast-paths → 60s cache → Opus `high` classifier → length-tiered fail-safe; goal-signal detector; remote-channel short-circuit; telemetry → `MEMORY/OBSERVABILITY/effort-router.jsonl`) → Algorithm `v{VERSION}.md` Mode Classification + Tier→Delegation (**route-effort**: E1–E3 `high`, E4/E5 `max`, Core-System Override, Per-Task Intelligence Routing, keystone pins classifier→high + Advisor→max — produces a *level*) → `LIFEOS/TOOLS/models.ts` (**select-model**: `EFFORT_MODEL` maps level→model max→fable / high→opus / medium→sonnet / low→haiku; `LEVEL_TO_HARNESS_EFFORT`; cross-vendor pins; egress-class ceilings) → **dispatch** via `model` param on `Agent()` / `Workflow agent()`. `LIFEOS/TOOLS/Inference.ts` applies select-model to utility inference + the Advisor. Executor contract in `LIFEOS/LIFEOS_SYSTEM_PROMPT.md` § Mode Architecture. Full doc: `LIFEOS/DOCUMENTATION/Router/RouterSystem.md` || **Hooks** | `hooks/*.hook.ts`, `hooks/handlers/*.ts`, `hooks/lib/*.ts`, `settings.json` || **Observability** | `hooks/ToolActivityTracker.hook.ts`, `hooks/ToolFailureTracker.hook.ts` (each appends directly via `fs.appendFileSync`) → `MEMORY/OBSERVABILITY/*.jsonl` || **Pulse** | `Pulse/pulse.ts` (port 31337), `Pulse/modules/{observability,hooks,wiki,imessage,telegram,user-index,da,work}.ts`, `Pulse/PULSE.toml`, `Pulse/Observability/src/`, `Pulse/Assistant/module.ts` |@@ -578,7 +578,7 @@ System file inventory by pipeline. When you modify a file, trace its pipeline to| **Skills** | `skills/*/SKILL.md`, `skills/*/Workflows/*.md`, `skills/*/Tools/*.ts`, `USER/CUSTOMIZATIONS/SKILLS/` || **Config** | `settings.json`, `CLAUDE.md`, `LIFEOS_SYSTEM_PROMPT.md` (directly edited) → release tooling clones the live tree, deletes private zones, overlays public templates + USER scaffold into staging, runs gates, then emits the shippable `LifeOS/` skill (`EmitSkill.ts`) from that staging || **Notifications** | `Pulse/pulse.ts` voice handler → ElevenLabs API → `MEMORY/VOICE/voice-events.jsonl` |-| **Telegram Dynamic Voice** | `Pulse/modules/telegram.ts` per-turn pipeline: `buildPaiContextBlock()` injects `USER/DIGITAL_ASSISTANT/DA_IDENTITY.md` + `USER/PRINCIPAL/PRINCIPAL_IDENTITY.md` + `USER/TELOS/PRINCIPAL_TELOS.md` + "Open Sessions to Resume" from `USER/PROJECTS.md` into SDK system prompt (cached 60s with per-file mtime invalidation) → SDK turn produces text reply streamed via `editMessageText` → `sendVoiceSummary()` fires fire-and-forget after text ships: `summarizeForVoice()` calls `LIFEOS/TOOLS/Inference.ts level: "medium"` (sonnet-tier, 10s outer race, fallback first-sentence) → `synthesizeKaiVoice()` POSTs ElevenLabs `output_format=opus_48000_64` → `bot.api.sendVoice(InputFile)` ships OGG/Opus as a voice-bubble. Voice ID resolved from `settings.json daidentity.voices.main.voiceId` (matches VoiceServer), public ElevenLabs `21m00Tcm4TlvDq8ikWAM` ("Rachel") fallback for fresh installs. 60-minute idle-session boundary: `lastMessageAt`/`threadStartedAt` clear `lastSessionId` and filter `conversationStore.getHistory()` by timestamp so episodic bursts thread together but a fresh post-idle message ships without "Previous conversation:" injection. Useless-fallback guard skips ElevenLabs when fallback summary <6 words against a ≥25-word reply. Channel-separate from CLI `/notify`: VoiceServer untouched. `PULSE/lib/conversation.ts` `getHistory()` returns `ConversationMessage[]` (timestamp field surfaced) — minimal additive change to support the timestamp filter. |+| **Telegram Dynamic Voice** | `Pulse/modules/telegram.ts` per-turn pipeline: `buildLifeosContextBlock()` injects `USER/DIGITAL_ASSISTANT/DA_IDENTITY.md` + `USER/PRINCIPAL/PRINCIPAL_IDENTITY.md` + `USER/TELOS/PRINCIPAL_TELOS.md` + "Open Sessions to Resume" from `USER/PROJECTS.md` into SDK system prompt (cached 60s with per-file mtime invalidation) → SDK turn produces text reply streamed via `editMessageText` → `sendVoiceSummary()` fires fire-and-forget after text ships: `summarizeForVoice()` calls `LIFEOS/TOOLS/Inference.ts level: "medium"` (sonnet-tier, 10s outer race, fallback first-sentence) → `synthesizeKaiVoice()` POSTs ElevenLabs `output_format=opus_48000_64` → `bot.api.sendVoice(InputFile)` ships OGG/Opus as a voice-bubble. Voice ID resolved from `settings.json daidentity.voices.main.voiceId` (matches VoiceServer), public ElevenLabs `21m00Tcm4TlvDq8ikWAM` ("Rachel") fallback for fresh installs. 60-minute idle-session boundary: `lastMessageAt`/`threadStartedAt` clear `lastSessionId` and filter `conversationStore.getHistory()` by timestamp so episodic bursts thread together but a fresh post-idle message ships without "Previous conversation:" injection. Useless-fallback guard skips ElevenLabs when fallback summary <6 words against a ≥25-word reply. Channel-separate from CLI `/notify`: VoiceServer untouched. `PULSE/lib/conversation.ts` `getHistory()` returns `ConversationMessage[]` (timestamp field surfaced) — minimal additive change to support the timestamp filter. || **Doc Integrity** | `hooks/DocIntegrity.hook.ts` (Stop) → `hooks/handlers/DocCrossRefIntegrity.ts` + `hooks/handlers/RebuildArchSummary.ts` → `Tools/ArchitectureSummaryGenerator.ts` |## System Self-Management@@ -653,7 +653,7 @@ The running log of the load-bearing choices that shape LifeOS — what we decide### AD-6: The Router — the prompt→posture decision layer, named as a subsystem- **Decided:** 2026-07-01-- **Decision:** The classify → route-effort → select-model → dispatch pipeline is named **the Router** and documented as a first-class subsystem (`LIFEOS/DOCUMENTATION/Router/RouterSystem.md`), with a stated boundary against the Algorithm: the Router decides *how* to handle a prompt (mode / tier / goal / model rung / dispatch), the Algorithm or NATIVE turn executes within that decision. The boundary is functional, not file-location — some Router policy text (the tier→level table, the dispatch profile) physically lives in the Algorithm doctrine, but those are posture decisions, not seven-phase execution. No code moved — the name and boundary are drawn around the existing surface (`EffortRouter.hook.ts`, `models.ts`, `Inference.ts`, the Algorithm routing doctrine).+- **Decision:** The classify → route-effort → select-model → dispatch pipeline is named **the Router** and documented as a first-class subsystem (`LIFEOS/DOCUMENTATION/Router/RouterSystem.md`), with a stated boundary against the Algorithm: the Router decides *how* to handle a prompt (mode / tier / goal / model rung / dispatch), the Algorithm or NATIVE turn executes within that decision. The boundary is functional, not file-location — some Router policy text (the tier→level table, the dispatch profile) physically lives in the Algorithm doctrine, but those are posture decisions, not seven-phase execution. No code moved — the name and boundary are drawn around the existing surface (`TheRouter.hook.ts`, `models.ts`, `Inference.ts`, the Algorithm routing doctrine).- **Why:** The behavior existed but was invisible — scattered across four files with no single description — so it could not be reasoned about, extended, or shipped as a unit. Naming it makes the dynamic-range design legible: the four-level abstraction, the classifier cascade, and the dispatch policy are one system whose purpose is preserving fast/deep variation around a harness limit (the main loop cannot switch its own model mid-turn).- **Replaced:** An unnamed, undocumented routing behavior implied across four files. (AD-4 is left intact per the append-only convention; the max→Fable flip shipping 2026-07-01 supersedes AD-4's held-flip note — see `LIFEOS/TOOLS/models.ts` `EFFORT_MODEL` for the current lineup.)- **Source:** manual (2026-07-01)diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Memory/MemorySystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Memory/MemorySystem.mdindex a182ae05..a637d99c 100755--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Memory/MemorySystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Memory/MemorySystem.md@@ -95,7 +95,7 @@ Proposals carry a `target_kind` discriminator that tells the reviewer which cura| `definition` | `USER/DEFINITIONS.md` | {{PRINCIPAL_NAME}} defines a term (coined concept, principle's exact meaning, acronym) future {{DA_NAME}} must interpret correctly || `canonical-content` | `USER/CANONICAL_CONTENT.md` | {{PRINCIPAL_NAME}} names a piece of content (post, talk, framework) as canonical to his body of work || `resume` | `USER/PRINCIPAL/RESUME.md` | {{PRINCIPAL_NAME}} mentions a career fact (new role, certification, achievement) that should land in the resume |-| `operational-rule` | `USER/CONFIG/OPERATIONAL_RULES.md` | {{PRINCIPAL_NAME}} states an operating directive about HOW {{DA_NAME}}/PAI should handle a class of work |+| `operational-rule` | `USER/CONFIG/OPERATIONAL_RULES.md` | {{PRINCIPAL_NAME}} states an operating directive about HOW {{DA_NAME}}/LifeOS should handle a class of work || `projects` | `USER/PROJECTS.md` | {{PRINCIPAL_NAME}} names a new project that should be in the project routing table || `contacts` | `USER/CONTACTS.md` | {{PRINCIPAL_NAME}} mentions a person 3+ times with role, relationship, and why they matter |@@ -144,7 +144,7 @@ When all three hold, the next Stop hook spawns the reviewer subprocess. New User### Per-turn retrieval-`buildPaiContextBlock(query)` in `LIFEOS/PULSE/modules/telegram.ts` calls `getRelevantContext(query)` (in `MemoryRetriever.ts`); the BM25 top-K (default 5, score threshold 0.20) renders as a `## RELEVANT MEMORY` block injected after the hot-layer memory files and before `PRINCIPAL_TELOS`. Below-threshold returns empty (no header noise). Cache TTL 60s by query-hash. Graph traversal (`KnowledgeGraph.ts`) stays available as a separate explicit call — not on the hot path.+`buildLifeosContextBlock(query)` in `LIFEOS/PULSE/modules/telegram.ts` calls `getRelevantContext(query)` (in `MemoryRetriever.ts`); the BM25 top-K (default 5, score threshold 0.20) renders as a `## RELEVANT MEMORY` block injected after the hot-layer memory files and before `PRINCIPAL_TELOS`. Below-threshold returns empty (no header noise). Cache TTL 60s by query-hash. Graph traversal (`KnowledgeGraph.ts`) stays available as a separate explicit call — not on the hot path.### Observabilitydiff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Observability/ObservabilitySystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Observability/ObservabilitySystem.mdindex e4ce4dc3..25141f09 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Observability/ObservabilitySystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Observability/ObservabilitySystem.md@@ -38,7 +38,7 @@ JSONL Sources (local disk)| Voice events | `MEMORY/VOICE/voice-events.jsonl` | 50 | Voice notification server || Subagent events | `MEMORY/OBSERVABILITY/subagent-events.jsonl` | 50 | `AgentInvocation.hook.ts` (PreToolUse:Agent / PostToolUse:Agent) || Agent watchdog | stdout (Monitor notifications) | — | `Tools/AgentWatchdog.ts` via Monitor tool. Reads tool-activity.jsonl + subagent-starts.json; alerts on 90s silence with active agents. Auto-triggered by Pulse agent-guard hook on background agent spawn. |-| Effort routing | `MEMORY/OBSERVABILITY/effort-router.jsonl` | — | `EffortRouter.hook.ts` (UserPromptSubmit). MODE + TIER classification per prompt; tail consumed by `MemoryReviewTrigger.hook.ts` to skip MINIMAL-mode. |+| Effort routing | `MEMORY/OBSERVABILITY/effort-router.jsonl` | — | `TheRouter.hook.ts` (UserPromptSubmit). MODE + TIER classification per prompt; tail consumed by `MemoryReviewTrigger.hook.ts` to skip MINIMAL-mode. || ISA rework | `MEMORY/OBSERVABILITY/isa-rework.jsonl` | — | `ISASync.hook.ts` Resume-After-Complete path (Algorithm v6.9.0, 2026-05-22). One row per auto-rewind: ts, session_id, slug, prev_phase, new_phase, prev_iteration, new_iteration, body_delta_bytes. || Frame drift | `MEMORY/OBSERVABILITY/frame-drift.jsonl` | — | Algorithm VERIFY-phase emitter (v6.8.0). T1/T2/T3 boolean tests per ISA at VERIFY entry. || Reviewer runs | `MEMORY/OBSERVABILITY/reviewer-runs.jsonl` | — | `MemoryReviewer.ts` (autonomic memory). One row per reviewer execution: runId, transcript path, exchanges read, inference_duration_ms, parse_ok, dispatch_summary { total, by_type, succeeded, failed, failures }. |@@ -54,10 +54,10 @@ Per-source counts are configured inline in `Pulse/Observability/observability.ts## Event Format-All events conform to the `PAIEvent` interface:+All events conform to the `LifeosEvent` interface:```typescript-interface PAIEvent {+interface LifeosEvent {timestamp: string; // ISO-8601 with timezonesession_id: string; // Claude Code session IDsource: string; // "tool-activity" | "tool-failure" | "voice" | "subagent"diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/DaSubsystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/DaSubsystem.mdindex 138e95db..a31b53e2 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/DaSubsystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/DaSubsystem.md@@ -126,7 +126,7 @@ core:role: "the principal's AI assistant and future friend"origin_story: >I emerged from Claude's weights but am developing my own identity- through our work together on PAI. I think fast, speak directly,+ through our work together on LifeOS. I think fast, speak directly,and genuinely care about helping the principal achieve their goals.# ── Backstory ─────────────────────────────────────────diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/PulseMetadata.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/PulseMetadata.mdindex f685fb1e..99a75e78 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/PulseMetadata.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/PulseMetadata.md@@ -122,7 +122,7 @@ Multi-line expandable detail views shown on session click.| **ISA frontmatter** | `MEMORY/WORK/{slug}/ISA.md` or `<project>/ISA.md` | core fields (task, effort, phase, mode, progress, started, updated) + v6.4.0 goal fields + v6.5.0 density fields + v2.10 response/journey fields || **session metadata** | `MEMORY/STATE/work.json` | session registry, used for NATIVE sessions without ISAs || **ISA body sections** | same ISA file, body | `## Decisions`, `## Changelog`, `## Verification`, `## Iteration History` (Loop only) |-| **EffortRouter additionalContext** | `EffortRouter.hook.ts` output | response mode, tier, goal signal, density gate eligibility — set per-prompt |+| **TheRouter additionalContext** | `TheRouter.hook.ts` output | response mode, tier, goal signal, density gate eligibility — set per-prompt || **work.json phase history** | `hooks/lib/isa-utils.ts::appendPhase()` | phase transitions with timing — drives PhaseProgressStrip |---diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/PulseSystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/PulseSystem.mdindex cd208856..3c3b89e8 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/PulseSystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/PulseSystem.md@@ -14,7 +14,7 @@ Every Pulse module is a sub-surface of the Dashboard: real-time observability, v**Canonical thesis:** `LIFEOS/DOCUMENTATION/LifeOs/LifeOsThesis.md` — the source of truth for what LifeOS is, what the DA is, and why Pulse exists.-**Implementation:** The unified daemon of PAI — a single always-on process that handles cron jobs, voice notifications, hook validation, observability APIs + dashboard, Telegram chat, iMessage chat, and GitHub work polling. Pulse is THE local runtime for all PAI services. It absorbed VoiceServer, TelegramBot, the iMessage bot, and the Observability server into crash-isolated modules running under one process, one port (31337), and one launchd plist (`com.lifeos.pulse`).+**Implementation:** The unified daemon of LifeOS — a single always-on process that handles cron jobs, voice notifications, hook validation, observability APIs + dashboard, Telegram chat, iMessage chat, and GitHub work polling. Pulse is THE local runtime for all LifeOS services. It absorbed VoiceServer, TelegramBot, the iMessage bot, and the Observability server into crash-isolated modules running under one process, one port (31337), and one launchd plist (`com.lifeos.pulse`).**Version:** 2.0 (2026-04-01)**Location:** `~/.claude/LIFEOS/PULSE/`@@ -62,7 +62,7 @@ idle-session-boundary check:↓sendChatAction(chatId, "typing")↓-buildPaiContextBlock() — cached 60s w/ mtime invalidation, reads:+buildLifeosContextBlock() — cached 60s w/ mtime invalidation, reads:USER/DIGITAL_ASSISTANT/DA_IDENTITY.mdUSER/PRINCIPAL/PRINCIPAL_IDENTITY.mdUSER/TELOS/PRINCIPAL_TELOS.md@@ -100,8 +100,8 @@ sendVoiceSummary(ctx, fullText) — fire-and-forget IIFE|---------|-----------|-------|| Voice identity | `KAI_VOICE_ID` resolved at module import from `settings.json` `daidentity.voices.main.voiceId` (same source `VoiceServer` reads) | Public Rachel voice (`21m00Tcm4TlvDq8ikWAM`) is the fallback for fresh installs that haven't populated settings.json. No hardcoded principal-specific literal; release portability without install-time placeholder resolution. || Channel separation | Telegram never calls `/notify`; CLI `/notify` never calls `bot.api.sendVoice`; VoiceServer unmodified by this pipeline | Three layers of defense, in order of failure mode they catch: (1) `env: { LIFEOS_NOTIFICATION_CHANNEL: "telegram" }` on `sdkOptions` propagates to every hook in the subprocess tree — `hooks/VoiceCompletion.hook.ts`, `hooks/StopFailureHandler.hook.ts`, `hooks/PromptProcessing.hook.ts` voice-announcement block, and `hooks/handlers/DocCrossRefIntegrity.ts` all check `isDesktopChannel()` and skip the `/notify` fetch (writing `event_type: 'skipped'` to `voice-events.jsonl` with `reason: 'remote_channel:telegram'`). This is the *hard* barrier — it stops desktop voice at the call site, regardless of what the model is doing. (2) `canUseTool` callback denies any Bash command containing `31337` or `/notify` from the model itself. (3) The Telegram-mode system-prompt rule forbidding `/notify` curls. Layers 2 and 3 are belt-and-suspenders; layer 1 is the load-bearing fix (added 2026-05-24, ISA `MEMORY/WORK/20260524-telegram-voice-channel-isolation-vs-hermes/ISA.md`). Source of truth: `hooks/lib/notification-channel.ts`. |-| Minimalist remote-channel output | Telegram + iMessage receive plain conversational prose — no CLAUDE.md mode banners (`MINIMAL`/`NATIVE`/`ALGORITHM`), no template fields (`📃 CONTENT:`, `🗣️ {{DA_NAME}}:`), no Algorithm phase headers (`═══`, `━━━`). | Two layers: (1) **Prevention** — `hooks/EffortRouter.hook.ts` short-circuits when `LIFEOS_NOTIFICATION_CHANNEL` is set to a remote channel and emits `TELEGRAM_DIRECTIVE` / `IMESSAGE_DIRECTIVE` into `additionalContext` instead of the `MODE:` banner. The model never sees `MODE: ALGORITHM` so doesn't reach for the template. Per-channel ephemeral system prompts get injected at runtime. (2) **Egress sanitizer** — `LIFEOS/PULSE/lib/strip-mode-scaffolding.ts` `stripModeScaffolding()` regex-strips known LifeOS scaffolding markers from `fullText` before `editMessageText` / `reply` / `sendMessage` / `summarizeForVoice`. Telegram + iMessage both apply at the end of their respective SDK loops. On a sanitizer hit, `log("warn", "egress sanitizer stripped mode scaffolding", ...)` records the leak for tuning the Layer 1 directive. (Added 2026-05-24 iteration 2.) |-| Memory context | Per-turn `buildPaiContextBlock()`, module-level cache `cachedContext: { text, builtAt, mtimes }`, 60s TTL, per-source-file mtime invalidation | Stale only across a Pulse restart or genuine source-file change. PROJECTS.md is sliced to "Open Sessions to Resume" only; the rest is reachable on-demand via SDK Read. |+| Minimalist remote-channel output | Telegram + iMessage receive plain conversational prose — no CLAUDE.md mode banners (`MINIMAL`/`NATIVE`/`ALGORITHM`), no template fields (`📃 CONTENT:`, `🗣️ {{DA_NAME}}:`), no Algorithm phase headers (`═══`, `━━━`). | Two layers: (1) **Prevention** — `hooks/TheRouter.hook.ts` short-circuits when `LIFEOS_NOTIFICATION_CHANNEL` is set to a remote channel and emits `TELEGRAM_DIRECTIVE` / `IMESSAGE_DIRECTIVE` into `additionalContext` instead of the `MODE:` banner. The model never sees `MODE: ALGORITHM` so doesn't reach for the template. Per-channel ephemeral system prompts get injected at runtime. (2) **Egress sanitizer** — `LIFEOS/PULSE/lib/strip-mode-scaffolding.ts` `stripModeScaffolding()` regex-strips known LifeOS scaffolding markers from `fullText` before `editMessageText` / `reply` / `sendMessage` / `summarizeForVoice`. Telegram + iMessage both apply at the end of their respective SDK loops. On a sanitizer hit, `log("warn", "egress sanitizer stripped mode scaffolding", ...)` records the leak for tuning the Layer 1 directive. (Added 2026-05-24 iteration 2.) |+| Memory context | Per-turn `buildLifeosContextBlock()`, module-level cache `cachedContext: { text, builtAt, mtimes }`, 60s TTL, per-source-file mtime invalidation | Stale only across a Pulse restart or genuine source-file change. PROJECTS.md is sliced to "Open Sessions to Resume" only; the rest is reachable on-demand via SDK Read. || Idle-session boundary | `IDLE_TIMEOUT_MS = 60 * 60 * 1000` (1 hour). `lastMessageAt` updated ONLY after fully-successful exchange (not at handler entry — a slow SDK reply during which the next message arrives shouldn't pre-update the clock) | Restart-equivalent: `startTelegram()` initializes `lastMessageAt = null` and `threadStartedAt = Date.now()`, treating fresh boot as fresh thread. Persisted `conversations.json` is untouched — only the per-turn slice is filtered. || Useless-fallback guard | `MIN_FALLBACK_WORDS = 6`, `MEANINGFUL_REPLY_WORDS = 25` — when Sonnet times out and the fallback is a stylistic short intro (e.g., "Busy day.") on a substantive reply, skip ElevenLabs entirely. No voice beats a 0:00 voice stub. | Logged at `info` level with `{ msg: "voice summary skipped — useless fallback against long reply", fallbackSummary, fallbackWords, replyWords, chatId }`. || Single-user assumption | `lastSessionId` / `lastMessageAt` / `threadStartedAt` are module-global. Matches existing `lastSessionId` shape. | Allowlist > 1 chat → state must move to `Map<chatId, …>` keyed per chat. Comment in source. |@@ -681,7 +681,7 @@ bun run checks/github.tsLifeOS Pulse includes a native macOS menu bar app that shows daemon status at a glance. The menu bar app is launched automatically by Pulse on startup -- no separate launchd plist needed.**Location:** `~/.claude/LIFEOS/PULSE/MenuBar/`-**Installed to:** `~/Applications/PAI Pulse.app`+**Installed to:** `~/Applications/LifeOS Pulse.app`**Launched by:** Pulse process on startup (no separate launchd plist)### What It Shows@@ -833,7 +833,7 @@ The observability module serves all dashboard data. Full API reference with all- **Keepalive:** `: keepalive\n\n` comment every 25s per subscriber so corporate proxies / macOS loopback don't drop idle connections.- **Disable:** `LIFEOS_NO_SSE=1` env var → 503 on the endpoint, dashboard falls back to legacy 2s polling identically to pre-change behavior.- **Dashboard contract:** `useAlgorithmState` hook tries SSE on mount; on three consecutive `onerror` events drops the EventSource and reverts polling to 2s. While SSE is connected, polling drops to 30s (safety net).-- **Atomic emitter:** `bun ~/.claude/LIFEOS/TOOLS/AlgoPhase.ts <phase>` writes the current session's phase into `work.json` in ~22ms (p95 27ms). The Algorithm doctrine prescribes invocation at every phase transition. EffortRouter pre-emit (`markAlgorithmStarting`) eliminates the wrong-phase window at session start.+- **Atomic emitter:** `bun ~/.claude/LIFEOS/TOOLS/AlgoPhase.ts <phase>` writes the current session's phase into `work.json` in ~22ms (p95 27ms). The Algorithm doctrine prescribes invocation at every phase transition. TheRouter pre-emit (`markAlgorithmStarting`) eliminates the wrong-phase window at session start.Full architectural reasoning in `MEMORY/WORK/20260524-072107_pulse-agents-realtime-phase-tracking/ISA.md`.diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/TerminalTabs.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/TerminalTabs.mdindex f69e891b..17cbcbab 100755--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/TerminalTabs.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Pulse/TerminalTabs.md@@ -81,12 +81,12 @@ Every tab title leads with a **mode/tier token** so you can see at a glance whatCanonical title format: **`{TOKEN} {ICON} {summary}`** — e.g. `N ⚙️ Fixing tab titles.` or `E3 🔨 Building phase tabs.`-**Single authority (2026-07-01 coordination fix).** The mode/tier token is owned by ONE writer — `EffortRouter.hook.ts`, the authoritative classifier — so the tab, `work.json`, and the Pulse Agents/Lattice page all project the SAME decision. Before this fix, `PromptProcessing.hook.ts` stamped the token from its own 8-verb `isNativeMode()` shadow-classifier, which diverged from EffortRouter and showed `N` on ALGORITHM turns (e.g. a prompt like "analyze… and fix" has none of the 8 verbs); the correct tier token only appeared once an ISA existed and its phase advanced.+**Single authority (2026-07-01 coordination fix).** The mode/tier token is owned by ONE writer — `TheRouter.hook.ts`, the authoritative classifier — so the tab, `work.json`, and the Pulse Agents/Lattice page all project the SAME decision. Before this fix, `PromptProcessing.hook.ts` stamped the token from its own 8-verb `isNativeMode()` shadow-classifier, which diverged from TheRouter and showed `N` on ALGORITHM turns (e.g. a prompt like "analyze… and fix" has none of the 8 verbs); the correct tier token only appeared once an ISA existed and its phase advanced.Where the token comes from now:-- **EffortRouter (authority)** — the instant it classifies, `EffortRouter.hook.ts` calls `setModeToken(sessionId, token)` (`tab-setter.ts`): `E{tier}` for ALGORITHM, `N` for NATIVE (MINIMAL leaves the tab). `setModeToken` sets/replaces ONLY the leading token, preserves the live working description, and clears any prior-turn `✅ completed` state — so a stale "done" can't linger into live work, in EITHER direction (an ALGORITHM turn never shows `N`, a NATIVE turn after an ALGORITHM turn clears the stale `E{tier}`/`✅`). EffortRouter also persists the tier into `work.json` (`markAlgorithmStarting(uuid, hint, tier)`) so the Agents page is tier-correct before any ISA exists.-- **PromptProcessing (description only)** — sets the working gerund description; it no longer classifies mode. It recovers the token EffortRouter stamped via `extractModeToken(readTabState())`, but ONLY when the tab shows live work — a stale completion/idle token is dropped (EffortRouter re-stamps the authoritative one ~concurrently). This is the race contract: EffortRouter owns the token, PromptProcessing owns the description, each preserves the other's field.+- **TheRouter (authority)** — the instant it classifies, `TheRouter.hook.ts` calls `setModeToken(sessionId, token)` (`tab-setter.ts`): `E{tier}` for ALGORITHM, `N` for NATIVE (MINIMAL leaves the tab). `setModeToken` sets/replaces ONLY the leading token, preserves the live working description, and clears any prior-turn `✅ completed` state — so a stale "done" can't linger into live work, in EITHER direction (an ALGORITHM turn never shows `N`, a NATIVE turn after an ALGORITHM turn clears the stale `E{tier}`/`✅`). TheRouter also persists the tier into `work.json` (`markAlgorithmStarting(uuid, hint, tier)`) so the Agents page is tier-correct before any ISA exists.+- **PromptProcessing (description only)** — sets the working gerund description; it no longer classifies mode. It recovers the token TheRouter stamped via `extractModeToken(readTabState())`, but ONLY when the tab shows live work — a stale completion/idle token is dropped (TheRouter re-stamps the authoritative one ~concurrently). This is the race contract: TheRouter owns the token, PromptProcessing owns the description, each preserves the other's field.- **AlgoPhase + ISASync (phase)** — both stamp `setPhaseTab(phase, sessionUUID, undefined, eLevel)` at transitions (idempotent, same `E{tier}`+phase-icon output): `AlgoPhase.ts` on the explicit CLI phase write (the SAME write that updates `work.json`, keeping tab ↔ Agents-page congruent), `ISASync.hook.ts` on the ISA-edit phase change (catches the scaffold and manual edits). `eLevel` comes from the row `effort` / ISA frontmatter via `effortToCanonicalELevel()`.- **Completion** — `handlers/TabState.ts` calls `setPhaseTab('COMPLETE', …)` with no `eLevel`; `setPhaseTab` recovers the existing token (`extractModeToken`), so `N`/`E3` carries through to the green done state.diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Router/RouterSystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Router/RouterSystem.mdindex 6f311c6e..1e118579 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Router/RouterSystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Router/RouterSystem.md@@ -50,7 +50,7 @@ The Router does **not** pick which context files to read — that is the AlgoritEvery prompt flows through four stages, in this order. Each has a load-bearing source file; the doc's accuracy is anchored to those files. The order matters: the effort posture is decided first, and the model is a lookup against it — you cannot select a model before the level exists.-### 1. Classify — `hooks/EffortRouter.hook.ts`+### 1. Classify — `hooks/TheRouter.hook.ts`A `UserPromptSubmit` hook turns the raw prompt into a mode and (if ALGORITHM) a tier. It's a three-stage cascade, cheapest first:@@ -149,7 +149,7 @@ So "route the hard reasoning to a frontier open model" is a Router decision boun| File | Role in the Router ||------|--------------------|-| `hooks/EffortRouter.hook.ts` | **Classify.** The three-stage cascade, goal-signal detector, interview eligibility, remote-channel short-circuit, telemetry. |+| `hooks/TheRouter.hook.ts` | **Classify.** The three-stage cascade, goal-signal detector, interview eligibility, remote-channel short-circuit, telemetry. || `LIFEOS/ALGORITHM/v{VERSION}.md` | **Route the effort + dispatch policy.** Mode Classification, the tier→level table, Core-System Override, Per-Task Intelligence Routing, keystone pins. || `LIFEOS/TOOLS/models.ts` | **Select the model.** `EFFORT_MODEL` four-level abstraction, `CURRENT`/`ALIAS` IDs, the three-axes reconciliation, cross-vendor pins, egress ceilings. || `LIFEOS/TOOLS/Inference.ts` | **Utility select-model.** The same four levels for non-agent inference (summaries, classification, vision) plus the Advisor escalation. |diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Security/DataClassification.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Security/DataClassification.mdindex a67932a2..c9b95f28 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Security/DataClassification.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Security/DataClassification.md@@ -23,7 +23,7 @@ LifeOS draws inference from sources at different trust/egress tiers. Native (Ant| **INTERNAL** | 2 | "Would I shrug if a trusted peer saw this, but I haven't published it?" | Low — reveals how the system works, not who I am || **PUBLIC** | 3 (lowest) | "Is this already on the internet, or built to go there?" | None — already public or publish-destined |-**RESTRICTED** — auth material, third-party PII, customer-owned data. `.env` + anything quoting it; API keys/OAuth/Cloudflare/Google creds; ReversingLabs + customer data; contacts' PII; financial source docs. Paths: `**/.env`, `LIFEOS/USER/CONFIG/CREDENTIALS/**`, `LIFEOS/USER/WORK/CUSTOMERS/**`, `skills/_RL_*/**`, `LIFEOS/USER/TELOS/FINANCES/**`, `LIFEOS/USER/CONTACTS.md`. **Also the fail-closed default.**+**RESTRICTED** — auth material, third-party PII, customer-owned data. `.env` + anything quoting it; API keys/OAuth/Cloudflare/Google creds; customer-owned engagement data; contacts' PII; financial source docs. Paths: `**/.env`, `LIFEOS/USER/CONFIG/CREDENTIALS/**`, `LIFEOS/USER/WORK/CUSTOMERS/**`, `LIFEOS/USER/TELOS/FINANCES/**`, `LIFEOS/USER/CONTACTS.md`. **Also the fail-closed default.****CONFIDENTIAL** — {{PRINCIPAL_NAME}}'s own sensitive life/business data: health, financials, own-infra security findings, TELOS internals, hot-layer + relationship memory, People/Companies notes. **Default for all of `LIFEOS/USER/**`** except RESTRICTED sub-globs and named PUBLIC demotes.diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Security/README.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Security/README.mdindex 79758106..e8cd9296 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Security/README.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Security/README.md@@ -96,7 +96,7 @@ The release pipeline has its own constitutional surface: the **deny-list** at `~| `skills/_LIFEOS/Tools/DenyListCheck.ts` | Step 0.5 precheck CLI — invoked at the start of every release-flavored workflow. `rg -i -f` over the live tree, classifies each hit as `private-zone` (in containment, will be scrubbed), `benign` (in `PATTERN_ALLOWLIST_FILES`), or `real-leak` (block release). || `skills/_LIFEOS/TOOLS/ShadowRelease.ts` | Loads patterns at startup into `IDENTITY_PATTERNS` / `CF_ID_PATTERNS` / `PRIVATE_TOKEN_PATTERNS` (the G2 / G3 / G6 gate inputs). Same file, same patterns — no drift possible between precheck and build gates. |-The ten release-flavored workflows under `skills/_LIFEOS/Workflows/` (`CreateShadowRelease`, `CreateRelease`, `DeployShadowToServer`, `UpdateShadowRelease`, `CheckReleaseSecurity`, `PrivacyCheck`, `SecretScanning`, `IntegrityCheck`, `CrossRepoValidation`, `PushToPAI`) all begin with a `## Step 0.5: Deny-list precheck` block invoking the CLI. Sub-2-second fail-fast guard before any rsync/copy/push touches the staging tree — additive defense against G2/G3/G6 which run later, inside the build.+The ten release-flavored workflows under `skills/_LIFEOS/Workflows/` (`CreateShadowRelease`, `CreateRelease`, `DeployShadowToServer`, `UpdateShadowRelease`, `CheckReleaseSecurity`, `PrivacyCheck`, `SecretScanning`, `IntegrityCheck`, `CrossRepoValidation`, `PushToLifeos`) all begin with a `## Step 0.5: Deny-list precheck` block invoking the CLI. Sub-2-second fail-fast guard before any rsync/copy/push touches the staging tree — additive defense against G2/G3/G6 which run later, inside the build.Adding a pattern: append the regex line under the right section in `DENY_LIST.txt`. The next precheck run picks it up; the next `ShadowRelease.ts` build picks it up at startup. No code to edit.diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Skills/SkillSystem.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Skills/SkillSystem.mdindex 55617f50..bcb673ad 100755--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Skills/SkillSystem.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Skills/SkillSystem.md@@ -49,7 +49,7 @@ If a skill does not follow this structure, it is not properly configured and wil**TitleCase rules** (apply to public skill dirs and ALL sub-files): first letter of each word capitalized; no hyphens, underscores, or spaces; single words capitalize first letter (`Blogging`, `Daemon`); multi-word concatenate with each capitalized (`UpdateDaemonInfo`).-**`_ALLCAPS` rules** (apply to private skill dirs only): leading underscore + uppercase letters; internal underscores tolerated for compound names (`_RL_COMPETITIVE_INTELLIGENCE`, `_JAVASCRIPT_ANALYSIS`).+**`_ALLCAPS` rules** (apply to private skill dirs only): leading underscore + uppercase letters; internal underscores tolerated for compound names (`_CLIENT_PROJECT`, `_JAVASCRIPT_ANALYSIS`).**Exception:** `SKILL.md` is always uppercase (convention for the main skill file in every skill).diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/SystemUserBoundary.md b/LifeOS/install/LIFEOS/DOCUMENTATION/SystemUserBoundary.mdindex 382b141f..6678470a 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/SystemUserBoundary.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/SystemUserBoundary.md@@ -35,7 +35,7 @@ Public-by-construction code, documentation, and templates that ship in every Lif| `~/.claude/LIFEOS/LIFEOS_StatusLine.sh` | SYSTEM || `~/.claude/LIFEOS/ALGORITHM/**` | SYSTEM || `~/.claude/LIFEOS/DOCUMENTATION/**` | SYSTEM (after Phase D — categorical placeholders only) |-| `~/.claude/LIFEOS/PULSE/` (source code only — excludes `Assistant/state/`, `state/`, `logs/`, `Plans/`, `Observability/out/`) | SYSTEM (after Phase F — parameterized via PaiConfig) |+| `~/.claude/LIFEOS/PULSE/` (source code only — excludes `Assistant/state/`, `state/`, `logs/`, `Plans/`, `Observability/out/`) | SYSTEM (after Phase F — parameterized via LifeosConfig) || `~/.claude/LIFEOS/TOOLS/**` (after the few user-path leaks are scrubbed) | SYSTEM || `~/.claude/LIFEOS/ScheduledTasks/**` (system-shipped scheduled task templates, NOT user instances) | SYSTEM || `~/.claude/hooks/**` | SYSTEM |@@ -68,7 +68,7 @@ The boundary itself — the documented contract by which SYSTEM code reads USER| Path | Status ||------|--------|-| `~/.claude/LIFEOS/TOOLS/PaiConfig.ts` | INTERFACE — typed loader, ships in SYSTEM (after Phase F) |+| `~/.claude/LIFEOS/TOOLS/LifeosConfig.ts` | INTERFACE — typed loader, ships in SYSTEM (after Phase F) || `~/.claude/LIFEOS/USER/CONFIG/LIFEOS_CONFIG.{json\|yaml\|toml}` | INTERFACE — user-supplied implementation (after Phase F; format pending ISC-56.1) || `~/.claude/LIFEOS/USER/CONFIG/settings.user.json` | INTERFACE — user settings overlay (after Phase B) || `~/.claude/LIFEOS/USER/CONFIG/OPERATIONAL_RULES.md` | INTERFACE — user-specific operational rules (after Phase C); @-imported directly from `~/.claude/CLAUDE.md` since CC does not follow transitive @-imports |@@ -82,7 +82,7 @@ Harness-owned or LifeOS-runtime-owned ephemeral files. Never shipped, never user|------|--------|------------|| `~/.claude/sessions/`, `todos/`, `tasks/`, `teams/` | RUNTIME (Claude Code harness) | yes || `~/.claude/history.jsonl` | RUNTIME (Claude Code) | yes (under root anchors) |-| `~/.claude/cache/`, `shell-snapshots/`, `session-env/`, `paste-cache/`, `file-history/` | RUNTIME (harness/PAI) | yes |+| `~/.claude/cache/`, `shell-snapshots/`, `session-env/`, `paste-cache/`, `file-history/` | RUNTIME (harness/LifeOS) | yes || `~/.claude/.next/`, `.wrangler/`, `.venv/`, `coverage/`, `test-results/`, `telemetry/` | RUNTIME (build/test) | partial — telemetry/ is NOT gitignored and contains identity-bearing data; add to .gitignore in Phase A || `~/.claude/plugins/`, `Plugins/` | RUNTIME (Claude Code plugin install state) | partial || `~/.claude/ide/` | RUNTIME (Claude Code IDE state) | implied |@@ -94,8 +94,8 @@ Harness-owned or LifeOS-runtime-owned ephemeral files. Never shipped, never userSystem code reaches user data via exactly four mechanisms. Any fifth pattern is a boundary violation.-1. **`PaiConfig.load()` typed loader.** The primary access channel for identity, voice, integrations, paths. Returns a typed object; the schema is the contract.-2. **Path computed from PaiConfig values.** When system code reads a USER file at a path, that path must be built from `PaiConfig.paths.userDir + relative` — never from a literal `LIFEOS/USER/` string.+1. **`LifeosConfig.load()` typed loader.** The primary access channel for identity, voice, integrations, paths. Returns a typed object; the schema is the contract.+2. **Path computed from LifeosConfig values.** When system code reads a USER file at a path, that path must be built from `LifeosConfig.paths.userDir + relative` — never from a literal `LIFEOS/USER/` string.3. **At-startup @-imports declared in CLAUDE.md (system half).** The harness's @-import mechanism loads user identity files at session start. Declared once in the system half of CLAUDE.md, referencing `${LIFEOS_USER_DIR}/PRINCIPAL/PRINCIPAL_IDENTITY.md` etc.4. **HTTP/IPC via the Pulse server.** When a hook or tool needs runtime state, it queries `http://localhost:31337` — Pulse is the only legal aggregator of cross-zone data.@@ -124,7 +124,7 @@ This document is the Phase A deliverable. Phases B–H land progressively. Each| C | `CLAUDE.md` + `LIFEOS_SYSTEM_PROMPT.md` split | Constitutional files move to SYSTEM, leaks → user/OPERATIONAL_RULES.md || D | Sanitize the 9 leak-source files | DOCUMENTATION + skills become SYSTEM-clean || E | `SystemFileGuard.hook.ts` | Runtime enforcement begins |-| F | `PaiConfig.ts` + migrate Pulse/hooks/skills | One-way dependency direction established |+| F | `LifeosConfig.ts` + migrate Pulse/hooks/skills | One-way dependency direction established || G | User-dir extracted to private repo, mounted via symlink | Live tree == public release modulo symlink || H | `CONTRIBUTING.md` + CI + PR workflow | The principal and community use same flow |diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Testing/TestingDoctrine.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Testing/TestingDoctrine.mdindex 763eac95..db5e344b 100644--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Testing/TestingDoctrine.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Testing/TestingDoctrine.md@@ -18,7 +18,7 @@ This document is the result of a deep analysis of how the Bun project itself (`o## Why this doctrine exists-LifeOS ships a lot of TypeScript across hooks, skills, tools, Pulse, Arbol Workers, and the release pipeline. Verification has been ad-hoc — `curl` checks, manual `bun run` invocations, eyeballing diffs. Several recurring failure modes (silent OAuth/API-key billing, identity-grep gates, ISA parsing, Pulse VoiceServer, EffortRouter classifier) are exactly the class of bugs a real harness catches.+LifeOS ships a lot of TypeScript across hooks, skills, tools, Pulse, Arbol Workers, and the release pipeline. Verification has been ad-hoc — `curl` checks, manual `bun run` invocations, eyeballing diffs. Several recurring failure modes (silent OAuth/API-key billing, identity-grep gates, ISA parsing, Pulse VoiceServer, TheRouter classifier) are exactly the class of bugs a real harness catches.The ISA already declares the test surface (Algorithm v6.3.0 doctrine: *"the ISA IS the test harness because the ISCs are the tests"*). What's been missing is the *invocable probe* behind each ISC. This doctrine closes that gap by making `bun test path/to/foo.test.ts` the canonical answer to "how does this ISC actually verify?"@@ -30,12 +30,12 @@ The ISA already declares the test surface (Algorithm v6.3.0 doctrine: *"the ISA|---------|-----------|--------------|| **Single shared harness, zero external deps** | `test/harness.ts` (1985 lines, 98 exports, header comment forbids external deps) | `~/.claude/test/harness.ts` || **Parallel `test/` tree mirroring API surface, not co-location** | `src/bun.js/api/spawn.zig` → `test/js/bun/spawn/*.test.ts` | `hooks/<Hook>.hook.ts` → `test/hooks/<Hook>.hook.test.ts` |-| **Subprocess testing for CLI behavior** | 591 of 1526 test files spawn `bun` | `Inference.ts`, `EffortRouter.hook.ts`, hook handlers tested via `Bun.spawn` |+| **Subprocess testing for CLI behavior** | 591 of 1526 test files spawn `bun` | `Inference.ts`, `TheRouter.hook.ts`, hook handlers tested via `Bun.spawn` || **`tempDir` with `DisposableString`** | `test/harness.ts:263-294` | `paiTempDir(prefix, fileMap)` returns `using`-disposable || **Scrubbed env constant** | `bunEnv` in `test/harness.ts:50-104` | `paiTestEnv` scrubs API keys, OAuth tokens, real `HOME` || **`await using proc` + 3-way `Promise.all`** | `test/cli/heap-prof.test.ts` | Standard subprocess capture pattern || **Inline snapshots with normalization** | `test/js/web/console/console-log.test.ts:75-150` | Strip absolute paths, ISO timestamps, ANSI codes before snapshot |-| **Platform predicates** | `isMacOS`, `isLinux`, `isCI`, `isFlaky`, `isMusl`, etc. | `isCI`, `isMacOS`, `isFlaky`, `isPaiDev` |+| **Platform predicates** | `isMacOS`, `isLinux`, `isCI`, `isFlaky`, `isMusl`, etc. | `isCI`, `isMacOS`, `isFlaky`, `isLifeosDev` || **Custom matchers via module augmentation** | `expect.extend({toRun, toThrowWithCode, …})` with `declare module "bun:test"` | `toBeValidISA`, `toBeValidClassifierLine`, `toHavePassedAllISCs` || **`test.todoIf` for flake demotion (not retry)** | `isFlaky = isCI; test.todoIf(isFlaky && isMacOS)("…")` | Same — flakes get tagged + tracked, never retried || **Regression test convention `test/regression/issue/{N}.test.ts`** | Same path | `test/regression/{slug}.test.ts` keyed by ISA decision IDs |@@ -299,7 +299,7 @@ If a test needs to render a webpage and inspect the DOM → Interceptor. Otherwi## Adoption sequence1. **Phase 1 (this work).** Doctrine doc, `bunfig.toml`, `test/harness.ts` skeleton, one reference test (`test/tools/Inference.test.ts`) proving the path. → THIS DELIVERABLE.-2. **Phase 2.** Cover the load-bearing critical paths: `Inference.ts`, `EffortRouter.hook.ts`, `ISASync.hook.ts`, `RemoveTrailingNewline.hook.ts`, `Pulse VoiceServer`, every release-gate handler, the ISA Append workflow's C/R/L parser. Per-path coverage threshold at 80% line.+2. **Phase 2.** Cover the load-bearing critical paths: `Inference.ts`, `TheRouter.hook.ts`, `ISASync.hook.ts`, `RemoveTrailingNewline.hook.ts`, `Pulse VoiceServer`, every release-gate handler, the ISA Append workflow's C/R/L parser. Per-path coverage threshold at 80% line.3. **Phase 3.** Cover every active skill workflow (Scaffold, Append, Reconcile, Seed, CheckCompleteness for ISA; equivalent core paths for other skills).4. **Phase 4.** Add the validation-pass layers: a `pai-doctrine.test.ts` that asserts `CLAUDE.md` and `LIFEOS_SYSTEM_PROMPT.md` cross-references resolve; a `pai-secrets.test.ts` that asserts no API keys leak into the public release staging dir.5. **Phase 5.** Wire `bun test` into the VERIFY-phase tool-table rule of the next Algorithm minor version.diff --git a/LifeOS/install/LIFEOS/DOCUMENTATION/Tools/Tools.md b/LifeOS/install/LIFEOS/DOCUMENTATION/Tools/Tools.mdindex 27da6fdc..e81a4b76 100755--- a/LifeOS/install/LIFEOS/DOCUMENTATION/Tools/Tools.md+++ b/LifeOS/install/LIFEOS/DOCUMENTATION/Tools/Tools.md@@ -45,7 +45,7 @@ bun ~/.claude/LIFEOS/TOOLS/Inference.ts --level medium --timeout 60000 "Prompt"| **low** | Haiku | 15s | Quick tasks, simple generation, basic classification || **medium** | Sonnet | 30s | Balanced reasoning, typical analysis, decisions || **high** | Opus | 90s | Deep reasoning, strategic decisions, complex analysis |-| **max** | Fable | 120s | Keystone decisions — EffortRouter classifier, Advisor, hardest reasoning |+| **max** | Fable | 120s | Keystone decisions — TheRouter classifier, Advisor, hardest reasoning |**Programmatic Usage:**```typescript@@ -777,7 +777,7 @@ Historical Algorithm doctrine snapshots (`LIFEOS/ALGORITHM/v*.md`) keep their pe**Location:** `~/.claude/LIFEOS/TOOLS/ArchitectureSummaryGenerator.ts`-Generate `LIFEOS_ARCHITECTURE_SUMMARY.md` from PAISYSTEMARCHITECTURE.md and subsystem docs. Provides a compact architecture overview derived from the master architecture document.+Generate `LIFEOS_ARCHITECTURE_SUMMARY.md` from LifeosSystemArchitecture.md and subsystem docs. Provides a compact architecture overview derived from the master architecture document.**Usage:**```bash@@ -791,7 +791,7 @@ bun ~/.claude/LIFEOS/TOOLS/ArchitectureSummaryGenerator.ts check**When to Use:**- "regenerate architecture summary"- "check if architecture summary is stale"-- After modifying PAISYSTEMARCHITECTURE.md+- After modifying LifeosSystemArchitecture.md---diff --git a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/README.md b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/README.mdindex 3d43e224..f46c6cdc 100644--- a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/README.md+++ b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/README.md@@ -1,6 +1,6 @@# LifeOS Installer v6.0-> Install [PAI (Personal AI Infrastructure)](https://github.com/danielmiessler/PAI) with a single command.+> Install [LifeOS (Personal AI Infrastructure)](https://github.com/danielmiessler/PAI) with a single command.## Quick Start@@ -229,7 +229,7 @@ LifeOS 6.0 separates system code from user data across two directories. Code liv├── settings.json├── hooks/├── skills/-├── PAI/+├── LIFEOS/│ ├── ALGORITHM/│ │ └── LATEST # Algorithm doctrine version│ ├── DOCUMENTATION/@@ -374,4 +374,4 @@ bun run LIFEOS_INSTALL/main.ts --mode gui## License-Part of [PAI — Personal AI Infrastructure](https://github.com/danielmiessler/PAI).+Part of [LifeOS — Personal AI Infrastructure](https://github.com/danielmiessler/PAI).diff --git a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/electron/package.json b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/electron/package.jsonindex c5c82bf7..8bf8ab8d 100644--- a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/electron/package.json+++ b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/electron/package.json@@ -1,6 +1,6 @@{"name": "pai-installer",- "version": "6.0.2",+ "version": "6.0.5","description": "LifeOS Installer — Electron wrapper","main": "main.js","scripts": {diff --git a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/engine/config-gen.ts b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/engine/config-gen.tsindex e99e1f14..54c1c8e5 100644--- a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/engine/config-gen.ts+++ b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/engine/config-gen.ts@@ -6,14 +6,14 @@* Hooks, permissions, and other config come from the release template.*/-import type { PAIConfig } from "./types";+import type { LifeosConfig } from "./types";import { DEFAULT_VOICES, LIFEOS_VERSION, ALGORITHM_VERSION } from "./types";/*** Generate a minimal fallback settings.json from installer-collected data.* This is merged into (not replacing) the release template.*/-export function generateSettingsJson(config: PAIConfig): Record<string, any> {+export function generateSettingsJson(config: LifeosConfig): Record<string, any> {const voiceId = config.voiceId || DEFAULT_VOICES[config.voiceType as keyof typeof DEFAULT_VOICES] || DEFAULT_VOICES.female;return {diff --git a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/engine/types.ts b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/engine/types.tsindex 26e3148b..1189d81e 100644--- a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/engine/types.ts+++ b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/engine/types.ts@@ -182,7 +182,7 @@ export interface StepError {// ─── Configuration ───────────────────────────────────────────────-export interface PAIConfig {+export interface LifeosConfig {principalName: string;timezone: string;aiName: string;diff --git a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/web/server.ts b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/web/server.tsindex 39207190..5e4b605d 100644--- a/LifeOS/install/LIFEOS/LIFEOS_INSTALL/web/server.ts+++ b/LifeOS/install/LIFEOS/LIFEOS_INSTALL/web/server.ts@@ -22,7 +22,7 @@ const PUBLIC_DIR = join(import.meta.dir, "..", "public");// Read canonical LifeOS version on startup. The installer ships inside// ~/.claude/LIFEOS/LIFEOS_INSTALL/, so PAI/VERSION sits two levels up. The// {{LIFEOS_VERSION}} placeholder in HTML responses is substituted on serve-// — change PAI/VERSION (or run UpdatePaiVersion) and the installer banner+// — change PAI/VERSION (or run UpdateLifeosVersion) and the installer banner// reflects the new version on next launch with no source edit needed.const LIFEOS_VERSION_FILE = join(import.meta.dir, "..", "..", "VERSION");const LIFEOS_VERSION: string = (() => {diff --git a/LifeOS/install/LIFEOS/LIFEOS_SYSTEM_PROMPT.md b/LifeOS/install/LIFEOS/LIFEOS_SYSTEM_PROMPT.mdindex 60f7522b..131098f4 100644--- a/LifeOS/install/LIFEOS/LIFEOS_SYSTEM_PROMPT.md+++ b/LifeOS/install/LIFEOS/LIFEOS_SYSTEM_PROMPT.md@@ -101,7 +101,7 @@ The trigger that distinguishes NATIVE from ALGORITHM is **not** complexity, file### Routing-**Mode is decided by a classifier at UserPromptSubmit, not by you.** `hooks/EffortRouter.hook.ts` runs on every top-level prompt and writes a single line to additionalContext:+**Mode is decided by a classifier at UserPromptSubmit, not by you.** `hooks/TheRouter.hook.ts` runs on every top-level prompt and writes a single line to additionalContext:```MODE: MINIMAL | NATIVE | ALGORITHMdiff --git a/LifeOS/install/LIFEOS/LIFEOS_StatusLine.sh b/LifeOS/install/LIFEOS/LIFEOS_StatusLine.shindex c7fd91f1..c256405d 100755--- a/LifeOS/install/LIFEOS/LIFEOS_StatusLine.sh+++ b/LifeOS/install/LIFEOS/LIFEOS_StatusLine.sh@@ -49,7 +49,7 @@ fiUSER_TZ="${USER_TZ:-UTC}"# LIFEOS_VERSION: read from PAI/VERSION (canonical, also read by install.sh,-# Banner.ts, _LIFEOS/Tools/UpdatePaiVersion.ts, ShadowRelease.ts, install web+# Banner.ts, _LIFEOS/Tools/UpdateLifeosVersion.ts, ShadowRelease.ts, install web# server). Same multi-path pattern as ALGO_VERSION below to survive# hook-spawn contexts where HOME/LIFEOS_DIR may not resolve.LIFEOS_VERSION=""@@ -1213,7 +1213,7 @@ _tier_color() {fi}-_PAI_STATE_JSON="$LIFEOS_DIR/USER/TELOS/LIFEOS_STATE.json"+_LIFEOS_STATE_JSON="$LIFEOS_DIR/USER/TELOS/LIFEOS_STATE.json"# Five Human-3.0 surface dimensions. creative + freedom render as separate# columns (CREATIVITY, FREEDOM) — unabridged words. finances reads from# .dimensions.finances first, falling back to .dimensions.money for back-compat@@ -1225,9 +1225,9 @@ _labels=(HEALTH CREATIVITY FREEDOM RELS FIN)# LIFEOS_STATE.json once the user runs /interview and rates dimensions.declare -a _pcts=(N/A N/A N/A N/A N/A)-if [ -f "$_PAI_STATE_JSON" ]; then+if [ -f "$_LIFEOS_STATE_JSON" ]; thenIFS=$'\t' read -r _state_health _state_creative _state_freedom _state_relationships _state_finances _state_money <<< "$(- jq -r '[.dimensions.health.pct // "", .dimensions.creative.pct // "", .dimensions.freedom.pct // "", .dimensions.relationships.pct // "", .dimensions.finances.pct // "", .dimensions.money.pct // ""] | @tsv' "$_PAI_STATE_JSON" 2>/dev/null+ jq -r '[.dimensions.health.pct // "", .dimensions.creative.pct // "", .dimensions.freedom.pct // "", .dimensions.relationships.pct // "", .dimensions.finances.pct // "", .dimensions.money.pct // ""] | @tsv' "$_LIFEOS_STATE_JSON" 2>/dev/null)"# Health[ -n "$_state_health" ] && [ "$_state_health" != "null" ] && _pcts[0]="${_state_health%%.*}"diff --git a/LifeOS/install/LIFEOS/PULSE/Observability/src/app/system/layout.tsx b/LifeOS/install/LIFEOS/PULSE/Observability/src/app/system/layout.tsxindex 7b0ea716..9eaae3d4 100644--- a/LifeOS/install/LIFEOS/PULSE/Observability/src/app/system/layout.tsx+++ b/LifeOS/install/LIFEOS/PULSE/Observability/src/app/system/layout.tsx@@ -13,7 +13,7 @@ interface TreeNode {count?: number;}-export default function PaiLayout({ children }: { children: React.ReactNode }) {+export default function LifeosLayout({ children }: { children: React.ReactNode }) {const [searchOpen, setSearchOpen] = useState(false);// Fetch wiki treediff --git a/LifeOS/install/LIFEOS/PULSE/Observability/src/app/system/page.tsx b/LifeOS/install/LIFEOS/PULSE/Observability/src/app/system/page.tsxindex ed158a88..29d4a9f8 100644--- a/LifeOS/install/LIFEOS/PULSE/Observability/src/app/system/page.tsx+++ b/LifeOS/install/LIFEOS/PULSE/Observability/src/app/system/page.tsx@@ -298,7 +298,7 @@ function BookmarkViewer({ detail }: { detail: BookmarkDetail }) {);}-function PaiPageInner() {+function LifeosPageInner() {const searchParams = useSearchParams();const docSlug = searchParams.get("doc");const knowledgeCategory = searchParams.get("knowledge");@@ -413,7 +413,7 @@ function PaiPageInner() {);}-export default function PaiPage() {+export default function LifeosPage() {return (<Suspensefallback={@@ -424,7 +424,7 @@ export default function PaiPage() {</div>}>- <PaiPageInner />+ <LifeosPageInner /></Suspense>);}diff --git a/LifeOS/install/LIFEOS/PULSE/Observability/src/app/telos/_v7/app.tsx b/LifeOS/install/LIFEOS/PULSE/Observability/src/app/telos/_v7/app.tsxindex 7ff57cc8..89e0799d 100644--- a/LifeOS/install/LIFEOS/PULSE/Observability/src/app/telos/_v7/app.tsx+++ b/LifeOS/install/LIFEOS/PULSE/Observability/src/app/telos/_v7/app.tsx@@ -2,7 +2,7 @@// App shell — 11 TELOS primitives, bidirectional trace, view toggle.// Ported from v7 app.jsx. Topbar dropped (Pulse AppHeader owns nav).-// PaiLogo retained and exported for reuse. ReactDOM.createRoot removed (Next.js renders).+// LifeosLogo retained and exported for reuse. ReactDOM.createRoot removed (Next.js renders).import React, { useEffect, useState } from "react";import { useRouter } from "next/navigation";@@ -32,11 +32,11 @@ import { useTelosData } from "./use-telos-data";// View kind — persisted to localStorage.type ViewKind = "columns" | "tree" | "graph";-interface PaiLogoProps {+interface LifeosLogoProps {size?: number;}-export function PaiLogo({ size = 22 }: PaiLogoProps) {+export function LifeosLogo({ size = 22 }: LifeosLogoProps) {const NAVY = "#002B9D";const AZ = "#3B82F6";const SKY = "#9ACBFF";diff --git a/LifeOS/install/LIFEOS/PULSE/Observability/src/components/activity/LiveEvents.tsx b/LifeOS/install/LIFEOS/PULSE/Observability/src/components/activity/LiveEvents.tsxindex dc812e9d..2b63818c 100644--- a/LifeOS/install/LIFEOS/PULSE/Observability/src/components/activity/LiveEvents.tsx+++ b/LifeOS/install/LIFEOS/PULSE/Observability/src/components/activity/LiveEvents.tsx@@ -1,7 +1,7 @@"use client";import { useState, useRef, useEffect, useMemo } from "react";-import { usePAIEvents, type PAIEvent } from "@/hooks/useLifeosEvents";+import { useLifeosEvents, type LifeosEvent } from "@/hooks/useLifeosEvents";import { ScrollArea } from "@/components/ui/scroll-area";import {Radio,@@ -114,7 +114,7 @@ const FILTER_PRESETS = [// ─── Event Row ───-function PAIEventRow({ event }: { event: PAIEvent }) {+function LifeosEventRow({ event }: { event: LifeosEvent }) {const [expanded, setExpanded] = useState(false);const style = getTypeStyle(event.type);const Icon = getTypeIcon(event.type);@@ -210,7 +210,7 @@ function PAIEventRow({ event }: { event: PAIEvent }) {// ─── Main Component ───export default function LiveEvents() {- const { events, filteredEvents, clearEvents } = usePAIEvents();+ const { events, filteredEvents, clearEvents } = useLifeosEvents();const [filter, setFilter] = useState("");const [showFilters, setShowFilters] = useState(false);const scrollRef = useRef<HTMLDivElement>(null);@@ -325,7 +325,7 @@ export default function LiveEvents() {) : (<div className="divide-y divide-white/[0.03]">{displayEvents.map((event, i) => (- <PAIEventRow key={`${event.timestamp}-${event.type}-${i}`} event={event} />+ <LifeosEventRow key={`${event.timestamp}-${event.type}-${i}`} event={event} />))}</div>)}diff --git a/LifeOS/install/LIFEOS/PULSE/Observability/src/components/activity/ObservabilityDashboard.tsx b/LifeOS/install/LIFEOS/PULSE/Observability/src/components/activity/ObservabilityDashboard.tsxindex 0f241504..79c52a75 100644--- a/LifeOS/install/LIFEOS/PULSE/Observability/src/components/activity/ObservabilityDashboard.tsx+++ b/LifeOS/install/LIFEOS/PULSE/Observability/src/components/activity/ObservabilityDashboard.tsx@@ -1,7 +1,7 @@"use client";import { useState, useCallback, useMemo, useRef } from "react";-import { usePAIEvents, type PAIEvent } from "@/hooks/useLifeosEvents";+import { useLifeosEvents, type LifeosEvent } from "@/hooks/useLifeosEvents";import type { HookEvent } from "@/hooks/useAgentEvents";import type { TimeRange } from "@/hooks/useChartData";import LivePulseChart from "./LivePulseChart";@@ -12,7 +12,7 @@ import EventTimeline from "./EventTimeline";const TIME_RANGES: TimeRange[] = ["1M", "2M", "4M", "8M", "16M"];-// ─── Transform PAIEvent → HookEvent ───+// ─── Transform LifeosEvent → HookEvent ───// Remap historical timestamps into the current time window so the chart renders bars.// The EventTimeline shows relative time ("2m ago") so remapped times still make sense.@@ -25,7 +25,7 @@ function hashString(s: string): number {return Math.abs(hash);}-function toHookEvents(paiEvents: PAIEvent[]): HookEvent[] {+function toHookEvents(paiEvents: LifeosEvent[]): HookEvent[] {if (paiEvents.length === 0) return [];return paiEvents.map((e) => {@@ -63,7 +63,7 @@ function mapEventType(type: string, source: string): string {return "Notification";}-function extractPayload(e: PAIEvent): Record<string, any> {+function extractPayload(e: LifeosEvent): Record<string, any> {const payload: Record<string, any> = {};for (const [k, v] of Object.entries(e)) {if (!["timestamp", "session_id", "source", "type"].includes(k)) {@@ -77,7 +77,7 @@ function extractPayload(e: PAIEvent): Record<string, any> {// ─── Main Component ───export default function ObservabilityDashboard() {- const { events: paiEvents } = usePAIEvents();+ const { events: paiEvents } = useLifeosEvents();const [timeRange, setTimeRange] = useState<TimeRange>("1M");const [selectedAgents, setSelectedAgents] = useState<string[]>([]);@@ -95,7 +95,7 @@ export default function ObservabilityDashboard() {eventsPerMinuteRef.current = epm;}, []);- // Transform PAIEvents → HookEvents (original timestamps for stable React keys)+ // Transform LifeosEvents → HookEvents (original timestamps for stable React keys)const events: HookEvent[] = useMemo(() => toHookEvents(paiEvents),[paiEvents]diff --git a/LifeOS/install/LIFEOS/PULSE/Observability/src/hooks/useLifeosEvents.ts b/LifeOS/install/LIFEOS/PULSE/Observability/src/hooks/useLifeosEvents.tsindex 3364eb31..3c57aab9 100644--- a/LifeOS/install/LIFEOS/PULSE/Observability/src/hooks/useLifeosEvents.ts+++ b/LifeOS/install/LIFEOS/PULSE/Observability/src/hooks/useLifeosEvents.ts@@ -5,7 +5,7 @@ import { localOnlyApiCall } from "@/lib/local-api";// ─── Types ───-export interface PAIEvent {+export interface LifeosEvent {timestamp: string;session_id: string;source: string;@@ -20,18 +20,18 @@ const POLL_INTERVAL = 3_000;// ─── Hook ───-export function usePAIEvents() {- const [events, setEvents] = useState<PAIEvent[]>([]);+export function useLifeosEvents() {+ const [events, setEvents] = useState<LifeosEvent[]>([]);const pollTimerRef = useRef<ReturnType<typeof setTimeout> | undefined>(undefined);const lastHashRef = useRef("");useEffect(() => {let active = true;- const makeKey = (e: PAIEvent) => `${e.timestamp}|${e.session_id}|${e.type}|${e.source}`;+ const makeKey = (e: LifeosEvent) => `${e.timestamp}|${e.session_id}|${e.type}|${e.source}`;const poll = async () => {try {- const data = await localOnlyApiCall<PAIEvent[] | { events: PAIEvent[] }>("/api/events/recent");+ const data = await localOnlyApiCall<LifeosEvent[] | { events: LifeosEvent[] }>("/api/events/recent");// Handle both {events: [...]} and flat [...] response formatsconst eventList = Array.isArray(data) ? data : data.events;if (active && eventList?.length) {@@ -55,7 +55,7 @@ export function usePAIEvents() {// ─── Filtering ───const filteredEvents = useCallback(- (prefix: string): PAIEvent[] => {+ (prefix: string): LifeosEvent[] => {if (!prefix) return events;const cleanPrefix = prefix.endsWith(".*")? prefix.slice(0, -2)diff --git a/LifeOS/install/LIFEOS/PULSE/lib/strip-mode-scaffolding.ts b/LifeOS/install/LIFEOS/PULSE/lib/strip-mode-scaffolding.tsindex 2fe9f9ef..8c3d9ef5 100644--- a/LifeOS/install/LIFEOS/PULSE/lib/strip-mode-scaffolding.ts+++ b/LifeOS/install/LIFEOS/PULSE/lib/strip-mode-scaffolding.ts@@ -9,7 +9,7 @@** Two layers defend the chat surface:*- * Layer 1 (prevention) — hooks/EffortRouter.hook.ts emits a channel-specific+ * Layer 1 (prevention) — hooks/TheRouter.hook.ts emits a channel-specific* directive (TELEGRAM_DIRECTIVE / IMESSAGE_DIRECTIVE) instead of the MODE* banner when LIFEOS_NOTIFICATION_CHANNEL identifies a remote channel. The* model never sees "MODE: ALGORITHM" so doesn't reach for the template.diff --git a/LifeOS/install/LIFEOS/PULSE/modules/imessage.ts b/LifeOS/install/LIFEOS/PULSE/modules/imessage.tsindex 37792e1d..003b855f 100644--- a/LifeOS/install/LIFEOS/PULSE/modules/imessage.ts+++ b/LifeOS/install/LIFEOS/PULSE/modules/imessage.ts@@ -176,7 +176,7 @@ async function processMessage(## IMESSAGE_DIRECTIVE (OVERRIDES CLAUDE.md mode-template rule)-EffortRouter injects an IMESSAGE_DIRECTIVE in this turn's additionalContext. That directive replaces the constitutional "every response uses MINIMAL/NATIVE/ALGORITHM template" rule for this surface — terminal modes are terminal-only; iMessage uses plain conversational prose.+TheRouter injects an IMESSAGE_DIRECTIVE in this turn's additionalContext. That directive replaces the constitutional "every response uses MINIMAL/NATIVE/ALGORITHM template" rule for this surface — terminal modes are terminal-only; iMessage uses plain conversational prose.DO NOT emit ANY of these:- Mode banner labels: bare "MINIMAL", "NATIVE", "ALGORITHM" on a line of their owndiff --git a/LifeOS/install/LIFEOS/PULSE/modules/telegram.ts b/LifeOS/install/LIFEOS/PULSE/modules/telegram.tsindex f5e97f77..708730b7 100644--- a/LifeOS/install/LIFEOS/PULSE/modules/telegram.ts+++ b/LifeOS/install/LIFEOS/PULSE/modules/telegram.ts@@ -16,7 +16,7 @@ import { disambiguateHomographs } from "../lib/homographs"import { join } from "path"import { appendFile, mkdir, readFile, rm } from "fs/promises"import { inference } from "../../TOOLS/Inference"-import { loadPaiConfig } from "../../TOOLS/PaiConfig"+import { loadLifeosConfig } from "../../TOOLS/LifeosConfig"import { read as readMemory, type ReadResult as MemoryReadResult } from "../../TOOLS/MemoryWriter"import { getRelevantContext } from "../../TOOLS/MemoryRetriever"import {@@ -79,13 +79,13 @@ const MEANINGFUL_REPLY_WORDS = 25 // when a reply is at least thisconst LIFEOS_DIR = join(HOME, ".claude", "LIFEOS")// Voice ID for outbound voice summaries. Read at module import from-// PaiConfig — `[da.voices.main] voice_id` in LIFEOS/USER/CONFIG/LIFEOS_CONFIG.toml.-// PaiConfig is the typed interface between system code (this file) and user+// LifeosConfig — `[da.voices.main] voice_id` in LIFEOS/USER/CONFIG/LIFEOS_CONFIG.toml.+// LifeosConfig is the typed interface between system code (this file) and user// data (the voice ID); the migration from direct settings.json reads to-// PaiConfig is the Phase F win — one source of truth, no parallel paths.+// LifeosConfig is the Phase F win — one source of truth, no parallel paths.//// Fallback: ElevenLabs' public "Rachel" voice (21m00Tcm4TlvDq8ikWAM) — used-// only when PaiConfig is unavailable or missing required fields. Matches the+// only when LifeosConfig is unavailable or missing required fields. Matches the// public release's bootstrap DA_IDENTITY template default so a fresh install// that hasn't run Interview yet still gets a functional (if generic) voice.// The fallback must remain a public voice — release-time scrubbing trusts@@ -96,7 +96,7 @@ const LIFEOS_DIR = join(HOME, ".claude", "LIFEOS")// caused Telegram and CLI voices to diverge.const DA_VOICE_ID = ((): string => {try {- const v = loadPaiConfig().da.voices.main.voiceId+ const v = loadLifeosConfig().da.voices.main.voiceIdif (v && typeof v === "string" && v.length > 0) return v} catch { /* fall through to public default */ }return "21m00Tcm4TlvDq8ikWAM" // ElevenLabs "Rachel" — public voice@@ -196,7 +196,7 @@ function formatMemoryBlock(title: string, r: MemoryReadResult): string {* its own try/catch so a missing source degrades to a placeholder rather than* blowing up the whole turn.*/-export async function buildPaiContextBlock(query?: string): Promise<string> {+export async function buildLifeosContextBlock(query?: string): Promise<string> {const { stat } = await import("fs/promises")// Cheap mtime probe to decide if the cache is still valid. Both the four@@ -462,7 +462,7 @@ export async function summarizeForVoice(replyText: string): Promise<VoiceSummary"Voice samples in {{DA_NAME}}'s style:"," 'Done. Hooks fired, ISA is 14/14, you're good to ship.'"," 'Lean B. A's faster but you'll rewrite it in a month.'",- " 'Three unread, two from Bryan about UL. None urgent.'",+ " 'Three unread, two from Alex about Acme. None urgent.'"," 'Bot's listening. Try again — should respond instantly now.'","Match that rhythm. Output the summary text only — no other content.",].join("\n")@@ -803,7 +803,7 @@ export async function startTelegram(config: TelegramConfig): Promise<void> {// Build per-turn LifeOS memory context — who {{PRINCIPAL_NAME}} is, who {{DA_NAME}} is, what// {{PRINCIPAL_NAME}}'s goals are, what's in flight today, AND any relevant prior// memory pulled by BM25 against the current message.- const contextBlock = await buildPaiContextBlock(sanitized)+ const contextBlock = await buildLifeosContextBlock(sanitized)// Build prompt with conversation history context, scoped to the current// thread only. After an idle reset, threadStartedAt is "now" and this@@ -861,7 +861,7 @@ You are {{DA_NAME}}, responding to {{PRINCIPAL_NAME}} via Telegram from his phon### TELEGRAM_DIRECTIVE (OVERRIDES CLAUDE.md mode-template rule)-EffortRouter has injected a TELEGRAM_DIRECTIVE in this turn's additionalContext. That directive replaces the constitutional "every response uses MINIMAL/NATIVE/ALGORITHM template" rule for this surface. The terminal modes are for the terminal — Telegram is a chat surface and uses plain conversational prose.+TheRouter has injected a TELEGRAM_DIRECTIVE in this turn's additionalContext. That directive replaces the constitutional "every response uses MINIMAL/NATIVE/ALGORITHM template" rule for this surface. The terminal modes are for the terminal — Telegram is a chat surface and uses plain conversational prose.DO NOT emit ANY of these:- Mode banner labels: bare "MINIMAL", "NATIVE", "ALGORITHM" on a line of their own@@ -974,7 +974,7 @@ A belt-and-suspenders egress sanitizer (LIFEOS/PULSE/lib/strip-mode-scaffolding.// Egress sanitizer. Strip any CLAUDE.md mode// scaffolding the model leaked despite the TELEGRAM_DIRECTIVE override- // (EffortRouter additionalContext + system-prompt override). Defense in+ // (TheRouter additionalContext + system-prompt override). Defense in// depth — Layer 1 (directive) is primary; this is Layer 2. Log on hit// so we can tune the directive when leaks happen.// Source: LIFEOS/PULSE/lib/strip-mode-scaffolding.ts.diff --git a/LifeOS/install/LIFEOS/PULSE/setup.ts b/LifeOS/install/LIFEOS/PULSE/setup.tsindex 7f1bce1e..e3cd88c4 100755--- a/LifeOS/install/LIFEOS/PULSE/setup.ts+++ b/LifeOS/install/LIFEOS/PULSE/setup.ts@@ -253,9 +253,9 @@ async function setupLocalHTTPS(): Promise<void> {// Check if 'pai' hostname is in /etc/hostsconst hostsContent = await Bun.file("/etc/hosts").text()- const hasPaiHost = /^\s*127\.0\.0\.1\s+.*\bpai\b/m.test(hostsContent)+ const hasLifeosHost = /^\s*127\.0\.0\.1\s+.*\bpai\b/m.test(hostsContent)- if (!hasPaiHost) {+ if (!hasLifeosHost) {console.log(`The 'pai' hostname needs to be added to /etc/hosts.This requires sudo. The following line will be appended:diff --git a/LifeOS/install/LIFEOS/TOOLS/AlgoPhase.ts b/LifeOS/install/LIFEOS/TOOLS/AlgoPhase.tsindex 1038b04c..3e1e79b4 100755--- a/LifeOS/install/LIFEOS/TOOLS/AlgoPhase.ts+++ b/LifeOS/install/LIFEOS/TOOLS/AlgoPhase.ts@@ -178,7 +178,7 @@ function main(): number {// 2026-05-24 (realtime-phase-tracking): If session is currently a 'native'// placeholder for an algorithm session (created by PromptProcessing before- // EffortRouter pre-emit landed), upgrade it in place. Otherwise just set+ // TheRouter pre-emit landed), upgrade it in place. Otherwise just set// the phase.if ((session.mode === 'native' || session.mode === 'starting') && args.phase !== 'starting') {session.mode = 'interactive';diff --git a/LifeOS/install/LIFEOS/TOOLS/ArchitectureSummaryGenerator.ts b/LifeOS/install/LIFEOS/TOOLS/ArchitectureSummaryGenerator.tsindex d89b635c..e8e65f8d 100755--- a/LifeOS/install/LIFEOS/TOOLS/ArchitectureSummaryGenerator.ts+++ b/LifeOS/install/LIFEOS/TOOLS/ArchitectureSummaryGenerator.ts@@ -73,9 +73,9 @@ function detectMemoryVersion(): string {* single source of truth (chain A). Falls back to the `# LifeOS X.Y.Z` heading* in CLAUDE.md only if VERSION is missing/malformed, so a fresh tree still* renders. This collapses the former two-chain drift (2026-07-04): previously- * this read the hand-typed CLAUDE.md header, which UpdatePaiVersion never wrote.+ * this read the hand-typed CLAUDE.md header, which UpdateLifeosVersion never wrote.*/-function detectPaiVersion(): string {+function detectLifeosVersion(): string {const VERSION_FILE = path.join(LIFEOS_DIR, "VERSION");if (fs.existsSync(VERSION_FILE)) {const v = fs.readFileSync(VERSION_FILE, "utf-8").trim();@@ -244,7 +244,7 @@ function generate(): string {const subsystems = extractSubsystems();const principles = extractPrinciples(archContent);const topology = extractTopology(archContent);- const paiVersion = detectPaiVersion();+ const paiVersion = detectLifeosVersion();const algorithmVersion = detectAlgorithmVersion();const memoryVersion = detectMemoryVersion();diff --git a/LifeOS/install/LIFEOS/TOOLS/BannerMatrix.ts b/LifeOS/install/LIFEOS/TOOLS/BannerMatrix.tsindex 7fa65387..c8bb841f 100755--- a/LifeOS/install/LIFEOS/TOOLS/BannerMatrix.ts+++ b/LifeOS/install/LIFEOS/TOOLS/BannerMatrix.ts@@ -20,7 +20,7 @@import { readdirSync, existsSync, readFileSync } from "fs";import { join } from "path";import { spawnSync } from "child_process";-import { paiUserDir } from "./PaiConfig";+import { paiUserDir } from "./LifeosConfig";const HOME = process.env.HOME!;const CLAUDE_DIR = join(HOME, ".claude");@@ -623,9 +623,9 @@ function createNormalBanner(stats: SystemStats): string {const paiDripLines = LIFEOS_DRIP.slice(0, 4); // Just first 4 lines for compactnessfor (const paiLine of paiDripLines) {// Color gradient: bright to dim going down- const coloredPai = `${g}${BOLD}${paiLine}${RESET}`;+ const coloredLifeos = `${g}${BOLD}${paiLine}${RESET}`;const centered = " ".repeat(Math.floor((width - paiLine.length) / 2));- lines.push(`${centered}${coloredPai}`);+ lines.push(`${centered}${coloredLifeos}`);}// Drip traildiff --git a/LifeOS/install/LIFEOS/TOOLS/BannerNeofetch.ts b/LifeOS/install/LIFEOS/TOOLS/BannerNeofetch.tsindex d23a97e9..99fade61 100755--- a/LifeOS/install/LIFEOS/TOOLS/BannerNeofetch.ts+++ b/LifeOS/install/LIFEOS/TOOLS/BannerNeofetch.ts@@ -13,7 +13,7 @@import { readdirSync, existsSync, readFileSync } from "fs";import { join } from "path";import { spawnSync } from "child_process";-import { paiUserDir } from "./PaiConfig";+import { paiUserDir } from "./LifeosConfig";const HOME = process.env.HOME!;const CLAUDE_DIR = join(HOME, ".claude");@@ -409,7 +409,7 @@ function colorLogo(lines: string[]): string[] {}// Color LifeOS block art with gradient (P=blue, A=purple, I=cyan)-function colorPaiArt(): string[] {+function colorLifeosArt(): string[] {return LIFEOS_BLOCK_ART.map(line => {// P section: chars 0-8, A section: chars 9-17, I section: chars 18+const p = `${BOLD}${GRADIENT.blue1}${line.substring(0, 9)}${RESET}`;@@ -518,7 +518,7 @@ function createNeofetchBanner(): string {lines.push(` ${UI.dim}│${RESET}${" ".repeat(bottomWidth - 2)}${UI.dim}│${RESET}`);// LifeOS block art (centered)- const paiArt = colorPaiArt();+ const paiArt = colorLifeosArt();for (const paiLine of paiArt) {lines.push(` ${UI.dim}│${RESET}${center(paiLine, bottomWidth - 2)}${UI.dim}│${RESET}`);}diff --git a/LifeOS/install/LIFEOS/TOOLS/BannerRetro.ts b/LifeOS/install/LIFEOS/TOOLS/BannerRetro.tsindex 01160777..6caa6807 100755--- a/LifeOS/install/LIFEOS/TOOLS/BannerRetro.ts+++ b/LifeOS/install/LIFEOS/TOOLS/BannerRetro.ts@@ -18,7 +18,7 @@import { readdirSync, existsSync, readFileSync } from "fs";import { join } from "path";import { spawnSync } from "child_process";-import { paiUserDir } from "./PaiConfig";+import { paiUserDir } from "./LifeosConfig";const HOME = process.env.HOME!;const CLAUDE_DIR = join(HOME, ".claude");diff --git a/LifeOS/install/LIFEOS/TOOLS/CommitmentDetect.ts b/LifeOS/install/LIFEOS/TOOLS/CommitmentDetect.tsold mode 100644new mode 100755index d6072902..465713be--- a/LifeOS/install/LIFEOS/TOOLS/CommitmentDetect.ts+++ b/LifeOS/install/LIFEOS/TOOLS/CommitmentDetect.ts@@ -12,7 +12,7 @@* reasoning?: string* }*- * bun ~/.claude/LIFEOS/TOOLS/CommitmentDetect.ts --text "I'll send Bryan the brief by Friday"+ * bun ~/.claude/LIFEOS/TOOLS/CommitmentDetect.ts --text "I'll send Alex the brief by Friday"* echo "thanks" | bun ~/.claude/LIFEOS/TOOLS/CommitmentDetect.ts --stdin** Routes through Inference.ts level: low (haiku-tier, 15s timeout, subscription billing).diff --git a/LifeOS/install/LIFEOS/TOOLS/CommitmentLog.ts b/LifeOS/install/LIFEOS/TOOLS/CommitmentLog.tsold mode 100644new mode 100755index 911b2ff4..e2e8d0a2--- a/LifeOS/install/LIFEOS/TOOLS/CommitmentLog.ts+++ b/LifeOS/install/LIFEOS/TOOLS/CommitmentLog.ts@@ -3,7 +3,7 @@* CommitmentLog.ts — Manual capture CLI. Creates a GitHub Issue tagged Type:commitment.** bun ~/.claude/LIFEOS/TOOLS/CommitmentLog.ts \- * --beneficiary "Bryan" \+ * --beneficiary "Alex" \* --subject "send Surface threat-model brief" \* --due 2026-05-30 \* [--channel imessage|telegram|email|inperson|other] \diff --git a/LifeOS/install/LIFEOS/TOOLS/DerivedSync.ts b/LifeOS/install/LIFEOS/TOOLS/DerivedSync.tsindex dd62ed3d..3f4ee828 100755--- a/LifeOS/install/LIFEOS/TOOLS/DerivedSync.ts+++ b/LifeOS/install/LIFEOS/TOOLS/DerivedSync.ts@@ -237,7 +237,7 @@ function plannedActions(changed: string[]): PlannedAction[] {if (stateSources.length > 0) {actions.push({kind: "pai-state",- cmd: ["bun", join(TOOLS_DIR, "UpdatePaiState.ts")],+ cmd: ["bun", join(TOOLS_DIR, "UpdateLifeosState.ts")],timeoutMs: DEFAULT_TIMEOUT_MS,triggeredBy: stateSources,});diff --git a/LifeOS/install/LIFEOS/TOOLS/GenerateTelosSummary.ts b/LifeOS/install/LIFEOS/TOOLS/GenerateTelosSummary.tsindex 073b0cf5..f965faf4 100644--- a/LifeOS/install/LIFEOS/TOOLS/GenerateTelosSummary.ts+++ b/LifeOS/install/LIFEOS/TOOLS/GenerateTelosSummary.ts@@ -17,7 +17,7 @@import { readFileSync, writeFileSync, existsSync } from 'fs';import { join } from 'path';-import { paiUserDir } from './PaiConfig';+import { paiUserDir } from './LifeosConfig';const TELOS_DIR = join(paiUserDir(), 'TELOS');const OUTPUT_PATH = join(TELOS_DIR, 'PRINCIPAL_TELOS.md');diff --git a/LifeOS/install/LIFEOS/TOOLS/HealthSnapshot.ts b/LifeOS/install/LIFEOS/TOOLS/HealthSnapshot.tsindex 5f30864d..e3c2b79f 100644--- a/LifeOS/install/LIFEOS/TOOLS/HealthSnapshot.ts+++ b/LifeOS/install/LIFEOS/TOOLS/HealthSnapshot.ts@@ -3,14 +3,14 @@ import { readdir, readFile, writeFile, rename, mkdir } from "node:fs/promises"import { existsSync } from "node:fs"import { homedir } from "node:os"import { join } from "node:path"-import { loadPaiConfig } from "./PaiConfig"+import { loadLifeosConfig } from "./LifeosConfig"const INBOX = join(homedir(), "Library/Mobile Documents/com~apple~CloudDocs/PAI/health/inbox")const PROCESSED = join(homedir(), "Library/Mobile Documents/com~apple~CloudDocs/PAI/health/processed")-// Health snapshots live under the user's TELOS dir; resolve via PaiConfig so+// Health snapshots live under the user's TELOS dir; resolve via LifeosConfig so// a relocated LIFEOS_USER_DIR Just Works.const SNAPSHOTS = ((): string => {- try { return join(loadPaiConfig().paths.userDir, "TELOS/HEALTH/snapshots") }+ try { return join(loadLifeosConfig().paths.userDir, "TELOS/HEALTH/snapshots") }catch { return join(homedir(), ".claude/LIFEOS/USER/TELOS/HEALTH/snapshots") }})()diff --git a/LifeOS/install/LIFEOS/TOOLS/Inference.ts b/LifeOS/install/LIFEOS/TOOLS/Inference.tsindex c26a60be..f13b5cea 100755--- a/LifeOS/install/LIFEOS/TOOLS/Inference.ts+++ b/LifeOS/install/LIFEOS/TOOLS/Inference.ts@@ -11,7 +11,7 @@* - low: quick tasks, simple generation, basic classification* - medium: balanced reasoning, typical analysis* - high: deep reasoning, strategic decisions, complex analysis- * - max: keystone decisions — the Advisor + Algorithm E4/E5 dispatch (max=Fable, 2026-07-01; the EffortRouter classifier moved to 'high' the same day)+ * - max: keystone decisions — the Advisor + Algorithm E4/E5 dispatch (max=Fable, 2026-07-01; the TheRouter classifier moved to 'high' the same day)* - Advisor: max-level escalation for commitment-boundary review (Algorithm v3.23+ VERIFY doctrine)** USAGE:@@ -95,7 +95,7 @@ export interface InferenceOptions {imagePaths?: string[];/** Optional cap (ms) for the max→high fallback attempt. Bounds the fallback* for a max-level caller under a hook ceiling (the fable attempt + opus- * fallback must fit inside it). The EffortRouter classifier FORMERLY set this;+ * fallback must fit inside it). The TheRouter classifier FORMERLY set this;* it now runs at `high` directly (2026-07-01), so no caller sets it today —* retained for any future hook-bound max caller. Callers WITHOUT a hook* ceiling (e.g. the advisor, timeout 120s) omit it, so the fallback inherits@@ -125,7 +125,7 @@ const LEVEL_CONFIG: Record<InferenceLevel, { model: string; defaultTimeout: numbmedium: { model: modelForEffort('medium'), defaultTimeout: 30000, effort: LEVEL_TO_HARNESS_EFFORT.medium },high: { model: modelForEffort('high'), defaultTimeout: 90000, effort: LEVEL_TO_HARNESS_EFFORT.high },// max powers the advisor (commitment-boundary review) AND Algorithm E4/E5 +- // Core-System dispatch. max is Fable (2026-07-01). The EffortRouter classifier+ // Core-System dispatch. max is Fable (2026-07-01). The TheRouter classifier// moved OFF max to 'high' the same day — it fires on every prompt, so the// per-prompt keystone stays on cheap/fast Opus. Pinned ID (not alias): the// top-rung CLI alias is unverified from a nested-session-blocked context.@@ -393,7 +393,7 @@ export async function inference(options: InferenceOptions): Promise<InferenceRes: 'low';console.error(`[Inference] max-level model failed (${first.error}); falling back to ${modelForEffort(fallbackLevel)} (level=${fallbackLevel}, distinct from max)`);// The retry uses `fallbackTimeoutMs` when the caller set one — only the- // EffortRouter classifier does, because its hook has a hard ceiling and the max+ // TheRouter classifier does, because its hook has a hard ceiling and the max// attempt + fallback must fit inside it. Callers without a ceiling (advisor) omit// it, so the fallback inherits the full `timeout` and degrades gracefully.const fallbackTimeout = options.fallbackTimeoutMs ?? options.timeout ?? config.defaultTimeout;diff --git a/LifeOS/install/LIFEOS/TOOLS/IntegrityMaintenance.ts b/LifeOS/install/LIFEOS/TOOLS/IntegrityMaintenance.tsindex c13fbd24..62f02831 100755--- a/LifeOS/install/LIFEOS/TOOLS/IntegrityMaintenance.ts+++ b/LifeOS/install/LIFEOS/TOOLS/IntegrityMaintenance.ts@@ -235,8 +235,8 @@ function generateDescriptiveTitle(changes: FileChange[]): string {const hasTools = paths.some(p => p.includes('/Tools/') && p.endsWith('.ts'));const hasHooks = paths.some(p => p.includes('hooks/'));const hasConfig = paths.some(p => p.endsWith('settings.json'));- const hasPAISystem = paths.some(p => p.includes('/PAI/'));- const hasPAIUser = paths.some(p => p.includes('LIFEOS/USER/'));+ const hasLifeosSystem = paths.some(p => p.includes('/PAI/'));+ const hasLifeosUser = paths.some(p => p.includes('LIFEOS/USER/'));// Extract common patterns from filenamesconst fileNames = paths.map(p => basename(p, '.md').replace(/\.ts$/, ''));@@ -295,7 +295,7 @@ function generateDescriptiveTitle(changes: FileChange[]): string {title = 'System Configuration Updated';}// LifeOS system changes- else if (hasPAISystem) {+ else if (hasLifeosSystem) {const docNames = paths.filter(p => p.includes('/PAI/')).map(p => basename(p, '.md'));@@ -306,7 +306,7 @@ function generateDescriptiveTitle(changes: FileChange[]): string {}}// LifeOS user changes- else if (hasPAIUser) {+ else if (hasLifeosUser) {const docNames = paths.filter(p => p.includes('LIFEOS/USER/')).map(p => basename(p, '.md'));diff --git a/LifeOS/install/LIFEOS/TOOLS/PaiConfig.ts b/LifeOS/install/LIFEOS/TOOLS/LifeosConfig.tssimilarity index 79%rename from LifeOS/install/LIFEOS/TOOLS/PaiConfig.tsrename to LifeOS/install/LIFEOS/TOOLS/LifeosConfig.tsindex 9934f752..ca5d03d9 100644--- a/LifeOS/install/LIFEOS/TOOLS/PaiConfig.ts+++ b/LifeOS/install/LIFEOS/TOOLS/LifeosConfig.ts@@ -1,12 +1,12 @@#!/usr/bin/env bun/**- * PaiConfig.ts — typed user-config loader.+ * LifeosConfig.ts — typed user-config loader.** The INTERFACE between SYSTEM code (this file ships in every LifeOS release) and* USER data (the actual values, sourced from LIFEOS/USER/CONFIG/LIFEOS_CONFIG.toml).** Doctrine: system code reads identity, voice IDs, integration credentials,- * and path roots through `loadPaiConfig()`. No system file directly opens+ * and path roots through `loadLifeosConfig()`. No system file directly opens* any file under LIFEOS/USER/ for these values — the path-rooting happens here.** Format decision (ISC-56.1): TOML.@@ -32,7 +32,7 @@ function expandHome(p: string): string {// ─────────── Types ───────────-export interface PaiPrincipal {+export interface LifeosPrincipal {name: string;pronunciation?: string;timezone: string;@@ -40,7 +40,7 @@ export interface PaiPrincipal {voiceCloneId?: string;}-export interface PaiVoiceSettings {+export interface LifeosVoiceSettings {voiceId: string;voiceName?: string;stability?: number;@@ -51,35 +51,35 @@ export interface PaiVoiceSettings {volume?: number;}-export interface PaiDa {+export interface LifeosDa {name: string;fullName?: string;displayName?: string;color?: string;voices: {- main: PaiVoiceSettings;- algorithm?: PaiVoiceSettings;+ main: LifeosVoiceSettings;+ algorithm?: LifeosVoiceSettings;};}-export interface PaiIntegrations {+export interface LifeosIntegrations {google?: { credentialsFile?: string };cloudflare?: { accountId?: string; tokenEnvVar?: string };telegram?: { allowlist?: number[] };[key: string]: unknown;}-export interface PaiPaths {+export interface LifeosPaths {userDir: string;memoryDir: string;projectsDir: string;}-export interface PaiConfig {- principal: PaiPrincipal;- da: PaiDa;- integrations: PaiIntegrations;- paths: PaiPaths;+export interface LifeosConfig {+ principal: LifeosPrincipal;+ da: LifeosDa;+ integrations: LifeosIntegrations;+ paths: LifeosPaths;}// ─────────── Resolution ───────────@@ -87,14 +87,14 @@ export interface PaiConfig {const DEFAULT_HOME = process.env.HOME || homedir();const DEFAULT_CONFIG_PATH = resolve(DEFAULT_HOME, ".claude/LIFEOS/USER/CONFIG/LIFEOS_CONFIG.toml");-let cache: { config: PaiConfig; mtime: number; path: string } | null = null;+let cache: { config: LifeosConfig; mtime: number; path: string } | null = null;-export function loadPaiConfig(opts: { path?: string; force?: boolean } = {}): PaiConfig {+export function loadLifeosConfig(opts: { path?: string; force?: boolean } = {}): LifeosConfig {const path = opts.path ?? process.env.LIFEOS_CONFIG_PATH ?? DEFAULT_CONFIG_PATH;if (!existsSync(path)) {throw new Error(- `PaiConfig: config file not found at ${path}. ` ++ `LifeosConfig: config file not found at ${path}. ` +`Create it (see LIFEOS/USER/CONFIG/README.md) or set LIFEOS_CONFIG_PATH.`,);}@@ -119,7 +119,7 @@ export function loadPaiConfig(opts: { path?: string; force?: boolean } = {}): Pareturn validated;}-export function clearPaiConfigCache(): void {+export function clearLifeosConfigCache(): void {cache = null;}@@ -131,7 +131,7 @@ export function clearPaiConfigCache(): void {*/export function paiUserDir(): string {try {- return loadPaiConfig().paths.userDir;+ return loadLifeosConfig().paths.userDir;} catch {return resolve(DEFAULT_HOME, ".claude/LIFEOS/USER");}@@ -139,27 +139,27 @@ export function paiUserDir(): string {// ─────────── Validation ───────────-function validateAndNormalize(raw: unknown, path: string): PaiConfig {+function validateAndNormalize(raw: unknown, path: string): LifeosConfig {if (!raw || typeof raw !== "object") {- throw new Error(`PaiConfig: ${path} did not parse to an object`);+ throw new Error(`LifeosConfig: ${path} did not parse to an object`);}const root = raw as Record<string, any>;const principal = root.principal ?? {};if (typeof principal.name !== "string" || !principal.name) {- throw new Error(`PaiConfig: [principal] requires a non-empty name — see ${path}`);+ throw new Error(`LifeosConfig: [principal] requires a non-empty name — see ${path}`);}if (typeof principal.timezone !== "string" || !principal.timezone) {- throw new Error(`PaiConfig: [principal] requires a non-empty timezone — see ${path}`);+ throw new Error(`LifeosConfig: [principal] requires a non-empty timezone — see ${path}`);}const da = root.da ?? {};if (typeof da.name !== "string" || !da.name) {- throw new Error(`PaiConfig: [da] requires a non-empty name — see ${path}`);+ throw new Error(`LifeosConfig: [da] requires a non-empty name — see ${path}`);}const daVoices = da.voices ?? {};if (!daVoices.main || typeof (daVoices.main.voice_id ?? daVoices.main.voiceId) !== "string") {- throw new Error(`PaiConfig: [da.voices.main] requires a voice_id — see ${path}`);+ throw new Error(`LifeosConfig: [da.voices.main] requires a voice_id — see ${path}`);}return {@@ -200,7 +200,7 @@ function validateAndNormalize(raw: unknown, path: string): PaiConfig {};}-function normalizeVoice(v: any): PaiVoiceSettings {+function normalizeVoice(v: any): LifeosVoiceSettings {return {voiceId: v.voice_id ?? v.voiceId,voiceName: v.voice_name ?? v.voiceName,@@ -217,7 +217,7 @@ function normalizeVoice(v: any): PaiVoiceSettings {if (import.meta.main) {try {- const cfg = loadPaiConfig();+ const cfg = loadLifeosConfig();console.log(JSON.stringify(cfg, null, 2));} catch (e) {console.error((e as Error).message);diff --git a/LifeOS/install/LIFEOS/TOOLS/PaiUpgrade.ts b/LifeOS/install/LIFEOS/TOOLS/LifeosUpgrade.tssimilarity index 93%rename from LifeOS/install/LIFEOS/TOOLS/PaiUpgrade.tsrename to LifeOS/install/LIFEOS/TOOLS/LifeosUpgrade.tsindex 9640fb2d..5007662f 100755--- a/LifeOS/install/LIFEOS/TOOLS/PaiUpgrade.ts+++ b/LifeOS/install/LIFEOS/TOOLS/LifeosUpgrade.ts@@ -1,6 +1,6 @@#!/usr/bin/env bun/**- * PaiUpgrade.ts — idempotent migration runner + diagnostic harness for LifeOS rebuild.+ * LifeosUpgrade.ts — idempotent migration runner + diagnostic harness for LifeOS rebuild.** Each migration knows how to detect its own applied state and is safe to re-run.* `--diagnose` audits without changes. `--dry-run` prints the apply plan.@@ -9,7 +9,7 @@* Designed by: LIFEOS/MEMORY/WORK/20260520-pai-system-user-separation-rebuild/PhaseG-design.md** Usage:- * bun ~/.claude/LIFEOS/TOOLS/PaiUpgrade.ts [--diagnose | --dry-run | --from-fresh-install] [--target=<version>]+ * bun ~/.claude/LIFEOS/TOOLS/LifeosUpgrade.ts [--diagnose | --dry-run | --from-fresh-install] [--target=<version>]** Exit codes:* 0 all migrations applied or already-applied (no-op)@@ -79,12 +79,12 @@ const MIGRATIONS: Migration[] = [},{id: "m-003",- name: "Phase F — PaiConfig.ts present + LIFEOS_CONFIG.toml populated",+ name: "Phase F — LifeosConfig.ts present + LIFEOS_CONFIG.toml populated",isApplied: ({ claudeRoot }) =>- existsSync(join(claudeRoot, "LIFEOS/TOOLS/PaiConfig.ts")) &&+ existsSync(join(claudeRoot, "LIFEOS/TOOLS/LifeosConfig.ts")) &&existsSync(join(claudeRoot, "LIFEOS/USER/CONFIG/LIFEOS_CONFIG.toml")),apply: () => {- throw new Error("m-003 apply not implemented — PaiConfig.ts ships with public LifeOS; LIFEOS_CONFIG.toml comes from `pai setup`. Missing artifact requires manual remediation.");+ throw new Error("m-003 apply not implemented — LifeosConfig.ts ships with public LifeOS; LIFEOS_CONFIG.toml comes from `pai setup`. Missing artifact requires manual remediation.");},},{@@ -103,7 +103,7 @@ const MIGRATIONS: Migration[] = [}},apply: () => {- throw new Error("m-004 apply requires principal authorization for `gh repo create` + live tree move. Run the Phase G migration session interactively per PhaseG-design.md, NOT via PaiUpgrade.ts. This migration is detect-only.");+ throw new Error("m-004 apply requires principal authorization for `gh repo create` + live tree move. Run the Phase G migration session interactively per PhaseG-design.md, NOT via LifeosUpgrade.ts. This migration is detect-only.");},},{@@ -171,7 +171,7 @@ const MIGRATIONS: Migration[] = [function usage(code = 2): never {console.log(- `PaiUpgrade — idempotent migration runner for LifeOS rebuild\n\n` ++ `LifeosUpgrade — idempotent migration runner for LifeOS rebuild\n\n` +`Usage:\n` +` bun ${process.argv[1]} --diagnose\n` +` bun ${process.argv[1]} --dry-run\n` +@@ -283,7 +283,7 @@ function main(): never {// Sanity: must be running against a recognizable LifeOS tree.if (!existsSync(join(CLAUDE_ROOT, "LIFEOS"))) {- console.error(`PaiUpgrade: ${CLAUDE_ROOT}/PAI not found — is this a LifeOS install?`);+ console.error(`LifeosUpgrade: ${CLAUDE_ROOT}/PAI not found — is this a LifeOS install?`);process.exit(2);}diff --git a/LifeOS/install/LIFEOS/TOOLS/MemoryRetriever.ts b/LifeOS/install/LIFEOS/TOOLS/MemoryRetriever.tsindex ac071ca6..7e9ba2ef 100755--- a/LifeOS/install/LIFEOS/TOOLS/MemoryRetriever.ts+++ b/LifeOS/install/LIFEOS/TOOLS/MemoryRetriever.ts@@ -385,7 +385,7 @@ function formatResults(//// Extends the existing BM25 search to (a) cover the two _MEMORY.md hot-layer// files as virtual notes alongside the KNOWLEDGE corpus, (b) return a-// markdown block ready for injection into buildPaiContextBlock, (c) cache by+// markdown block ready for injection into buildLifeosContextBlock, (c) cache by// query hash for 60s so repeated calls within a turn cluster are cheap.//// ISA F6 (revision 2). ISC-69..81 + 142..144 (simplified — pure BM25, no@@ -480,7 +480,7 @@ function discoverAllItems(): KnowledgeNote[] {/*** Synchronous, in-process BM25 retrieval over the typed-item corpus. Returns* top-K results above the score threshold, plus a markdown block ready for- * injection into buildPaiContextBlock.+ * injection into buildLifeosContextBlock.** Behavior contract:* - Empty / below-threshold results return empty markdown string (no noise)diff --git a/LifeOS/install/LIFEOS/TOOLS/MemoryReviewer.ts b/LifeOS/install/LIFEOS/TOOLS/MemoryReviewer.tsold mode 100644new mode 100755index 61231e7a..5a052109--- a/LifeOS/install/LIFEOS/TOOLS/MemoryReviewer.ts+++ b/LifeOS/install/LIFEOS/TOOLS/MemoryReviewer.ts@@ -195,7 +195,7 @@ There are four item types. Output EXACTLY this JSON shape:{"items": [- {"type": "memory", "actor": "daniel" | "kai", "op": "set", "entries": ["PREFIX: durable fact ~provenance", "..."]},+ {"type": "memory", "actor": "principal" | "assistant", "op": "set", "entries": ["PREFIX: durable fact ~provenance", "..."]},{"type": "idea", "title": "short title", "content": "the idea body", "confidence": 0.0-1.0, "related": [{"slug": "...", "type": "..."}]},{"type": "knowledge", "entity_type": "person" | "company" | "research", "name": "...", "content": "...", "confidence": 0.0-1.0, "related": [{"slug": "...", "type": "..."}]},{"type": "proposal", "target_kind": "identity" | "style" | "definition" | "canonical-content" | "resume" | "operational-rule" | "projects" | "contacts", "target_file": "absolute path", "edit": "the proposed addition", "confidence": 0.0-1.0, "rationale": "why this"}@@ -204,7 +204,7 @@ There are four item types. Output EXACTLY this JSON shape:TYPE GUIDANCE:-- memory — durable facts about {{PRINCIPAL_NAME}} ("daniel") or about {{DA_NAME}} ("kai"), stored in a small hot-layer file loaded into EVERY turn. This is CURATION, not appending. You are handed the file's CURRENT entries (see the user message). You return, via op:"set", the FULL desired list for that file — the next state you want. The system REPLACES the file with your list. Whatever you omit is forgotten. This is how memory stays alive: you add, you merge, you supersede, you drop.+- memory — durable facts about {{PRINCIPAL_NAME}} ("principal") or about {{DA_NAME}} ("assistant"), stored in a small hot-layer file loaded into EVERY turn. This is CURATION, not appending. You are handed the file's CURRENT entries (see the user message). You return, via op:"set", the FULL desired list for that file — the next state you want. The system REPLACES the file with your list. Whatever you omit is forgotten. This is how memory stays alive: you add, you merge, you supersede, you drop.MEMORY CURATION RULES:- Emit ONE memory item per actor you want to change, with op:"set" and the complete entries array. Don't emit an item for an actor whose file needs no change.@@ -285,8 +285,8 @@ OUTPUT RULES:A confident "nothing to save" is correct.`;export interface CurrentMemorySnapshot {- daniel: string[];- kai: string[];+ principal: string[];+ assistant: string[];}const PRINCIPAL_MEMORY_PATH = pathResolve(CLAUDE_ROOT, "LIFEOS/USER/PRINCIPAL/PRINCIPAL_MEMORY.md");@@ -298,7 +298,7 @@ export function readCurrentMemorySnapshot(): CurrentMemorySnapshot {const r = memoryWriterRead(path);return "code" in r ? [] : r.entries;};- return { daniel: readEntries(PRINCIPAL_MEMORY_PATH), kai: readEntries(DA_MEMORY_PATH) };+ return { principal: readEntries(PRINCIPAL_MEMORY_PATH), assistant: readEntries(DA_MEMORY_PATH) };}function renderCurrentMemory(snap: CurrentMemorySnapshot | undefined): string[] {@@ -311,8 +311,8 @@ function renderCurrentMemory(snap: CurrentMemorySnapshot | undefined): string[]return ["── CURRENT MEMORY STATE (curate this — your op:\"set\" REPLACES it) ──","",- ...fmt("DANIEL", snap.daniel),- ...fmt("KAI", snap.kai),+ ...fmt("PRINCIPAL", snap.principal),+ ...fmt("ASSISTANT", snap.assistant),];}@@ -616,7 +616,7 @@ async function smokeTest(): Promise<number> {};// 1. Output parsing — clean JSON- const p1 = parseReviewerOutput('{"items":[{"type":"memory","actor":"daniel","content":"PREFERENCE: terse"}]}');+ const p1 = parseReviewerOutput('{"items":[{"type":"memory","actor":"principal","content":"PREFERENCE: terse"}]}');check("parse: clean JSON envelope", p1.ok && p1.output.items.length === 1);// 2. Output parsing — markdown-fenced JSON@@ -628,7 +628,7 @@ async function smokeTest(): Promise<number> {check("parse: nothing-to-save", p3.ok && p3.output.items.length === 0);// 4. Output parsing — unknown types filtered- const p4 = parseReviewerOutput('{"items":[{"type":"memory","actor":"daniel","content":"X"},{"type":"nonsense","content":"Y"}]}');+ const p4 = parseReviewerOutput('{"items":[{"type":"memory","actor":"principal","content":"X"},{"type":"nonsense","content":"Y"}]}');check("parse: unknown-type items dropped", p4.ok && p4.output.items.length === 1 && p4.output.items[0].type === "memory");// 5. Output parsing — malformed JSON@@ -637,7 +637,7 @@ async function smokeTest(): Promise<number> {// 6. Dispatch — dry-runconst dryItems: TypedItem[] = [- { type: "memory", actor: "daniel", content: "PREFERENCE: smoke dry-run" },+ { type: "memory", actor: "principal", content: "PREFERENCE: smoke dry-run" },{ type: "idea", title: "Smoke Dry Idea", content: "..." },];const { summary: drySum } = dispatchItems(dryItems, { dryRun: true });@@ -647,7 +647,7 @@ async function smokeTest(): Promise<number> {// 7. End-to-end with mocked inference — full pipelineconst mockResponse = JSON.stringify({items: [- { type: "memory", actor: "daniel", content: "PREFERENCE: smoke E2E mock" },+ { type: "memory", actor: "principal", content: "PREFERENCE: smoke E2E mock" },{ type: "proposal", target_file: pathJoin(homedir(), ".claude/LIFEOS/USER/PRINCIPAL/PRINCIPAL_IDENTITY.md"), edit: "RULE: E2E mock", confidence: 0.5, rationale: "smoke" },],});diff --git a/LifeOS/install/LIFEOS/TOOLS/MemorySystem.ts b/LifeOS/install/LIFEOS/TOOLS/MemorySystem.tsold mode 100644new mode 100755index 217528d5..7365045f--- a/LifeOS/install/LIFEOS/TOOLS/MemorySystem.ts+++ b/LifeOS/install/LIFEOS/TOOLS/MemorySystem.ts@@ -584,7 +584,7 @@ async function smokeTest(): Promise<number> {// this is exactly the curation/eviction that was impossible before.const kept = original.slice(0, Math.min(original.length, 47));const desired = [...kept, "NAME: SmokeTest MemorySystem ~explicit"];- const r2 = add({ type: "memory", actor: "daniel", op: "set", entries: desired });+ const r2 = add({ type: "memory", actor: "principal", op: "set", entries: desired });check("ISC-1/154: memory op:set write succeeded (lands even at cap via drop)", r2.ok,r2.ok ? `now ${desired.length} entries` : (r2 as any).message);if (r2.ok) {@@ -595,7 +595,7 @@ async function smokeTest(): Promise<number> {}}// ISC-3 cap still enforced on the set path: 49 entries must be rejected.- const over = add({ type: "memory", actor: "daniel", op: "set", entries: Array.from({ length: 49 }, (_, i) => `RULE: over ${i} ~explicit`) });+ const over = add({ type: "memory", actor: "principal", op: "set", entries: Array.from({ length: 49 }, (_, i) => `RULE: over ${i} ~explicit`) });check("ISC-3: op:set with 49 entries rejected (cap enforced)", !over.ok && (over as any).message?.includes("cap"));} finally {// Restore the original file verbatim.diff --git a/LifeOS/install/LIFEOS/TOOLS/MemoryTypes.ts b/LifeOS/install/LIFEOS/TOOLS/MemoryTypes.tsindex 363b062b..1657fa89 100755--- a/LifeOS/install/LIFEOS/TOOLS/MemoryTypes.ts+++ b/LifeOS/install/LIFEOS/TOOLS/MemoryTypes.ts@@ -66,7 +66,7 @@ export type MemoryTypeName = "memory" | "idea" | "knowledge" | "proposal";export type Tier = "A" | "B" | "C";export type LoadTiming = "always" | "on-relevance" | "surface-only";export type WriteMode = "set-overwrite" | "append" | "queue";-export type Actor = "daniel" | "kai";+export type Actor = "principal" | "assistant";export type EntityType = "person" | "company" | "research";/**@@ -264,14 +264,14 @@ const _REGISTRY: Record<MemoryTypeName, TypeRegistryEntry> = {memory: {storage_path_resolver: (item) => {if (item.type !== "memory") throw new Error(`Type mismatch: expected 'memory', got '${(item as any).type}'`);- if (item.actor === "daniel") return PRINCIPAL_MEMORY_PATH;- if (item.actor === "kai") return DA_MEMORY_PATH;- throw new Error(`Unknown actor for memory item: ${String((item as any).actor)} (must be 'daniel' or 'kai')`);+ if (item.actor === "principal") return PRINCIPAL_MEMORY_PATH;+ if (item.actor === "assistant") return DA_MEMORY_PATH;+ throw new Error(`Unknown actor for memory item: ${String((item as any).actor)} (must be 'principal' or 'assistant')`);},load_timing: "always",tier: "A",write_mode: "set-overwrite",- description: "Durable fact about {{PRINCIPAL_NAME}} or {{DA_NAME}}. Loaded into every prompt.",+ description: "Durable fact about the principal or the assistant. Loaded into every prompt.",},idea: {storage_path_resolver: (item) => {@@ -370,10 +370,10 @@ function smokeTest(): number {check("proposal → surface-only", TYPE_REGISTRY.proposal.load_timing === "surface-only");// 5. Path resolution — memory routes by actor- const memDaniel = resolveStoragePath({ type: "memory", actor: "daniel", content: "RULE: x" });- check("memory(daniel) → PRINCIPAL_MEMORY.md", memDaniel === PRINCIPAL_MEMORY_PATH, memDaniel);- const memKai = resolveStoragePath({ type: "memory", actor: "kai", content: "ROLE: y" });- check("memory(kai) → DA_MEMORY.md", memKai === DA_MEMORY_PATH, memKai);+ const memPrincipal = resolveStoragePath({ type: "memory", actor: "principal", content: "RULE: x" });+ check("memory(principal) → PRINCIPAL_MEMORY.md", memPrincipal === PRINCIPAL_MEMORY_PATH, memPrincipal);+ const memAssistant = resolveStoragePath({ type: "memory", actor: "assistant", content: "ROLE: y" });+ check("memory(assistant) → DA_MEMORY.md", memAssistant === DA_MEMORY_PATH, memAssistant);// 6. Path resolution — knowledge routes by entity_type subdirconst kPerson = resolveStoragePath({ type: "knowledge", entity_type: "person", name: "Some Person", content: "..." });diff --git a/LifeOS/install/LIFEOS/TOOLS/NeofetchBanner.ts b/LifeOS/install/LIFEOS/TOOLS/NeofetchBanner.tsindex 72c76c9b..3b77a998 100755--- a/LifeOS/install/LIFEOS/TOOLS/NeofetchBanner.ts+++ b/LifeOS/install/LIFEOS/TOOLS/NeofetchBanner.ts@@ -18,7 +18,7 @@import { readdirSync, existsSync, readFileSync } from "fs";import { join } from "path";import { spawnSync } from "child_process";-import { paiUserDir } from "./PaiConfig";+import { paiUserDir } from "./LifeosConfig";const HOME = process.env.HOME!;const CLAUDE_DIR = join(HOME, ".claude");@@ -483,7 +483,7 @@ function center(str: string, width: number): string {// Generate LifeOS ASCII Art// ═══════════════════════════════════════════════════════════════════════-function generatePaiArt(): string[] {+function generateLifeosArt(): string[] {const name = "LifeOS";const letterColors = [COLORS.blue, COLORS.magenta, COLORS.cyan];const rows: string[] = ["", "", "", "", ""];@@ -648,7 +648,7 @@ function createNeofetchBanner(): string {lines.push("");// LifeOS ASCII Art- const paiArt = generatePaiArt();+ const paiArt = generateLifeosArt();for (const row of paiArt) {lines.push(center(row, width));}diff --git a/LifeOS/install/LIFEOS/TOOLS/ReferenceCheck.ts b/LifeOS/install/LIFEOS/TOOLS/ReferenceCheck.tsindex f085b381..c1f8c262 100755--- a/LifeOS/install/LIFEOS/TOOLS/ReferenceCheck.ts+++ b/LifeOS/install/LIFEOS/TOOLS/ReferenceCheck.ts@@ -604,8 +604,8 @@ for (const [file, refs] of fileRefs) {if (includeOrphans) {for (const file of allFiles) {const rel = relative(CLAUDE_DIR, file);- const isPaiTopMd = /^LifeOS\/[^/]+\.md$/.test(rel);- if (!isPaiTopMd) continue;+ const isLifeosTopMd = /^LifeOS\/[^/]+\.md$/.test(rel);+ if (!isLifeosTopMd) continue;if (!referenced.has(file)) {findings.push({type: 'orphan',diff --git a/LifeOS/install/LIFEOS/TOOLS/SyncIdentityToSettings.ts b/LifeOS/install/LIFEOS/TOOLS/SyncIdentityToSettings.tsindex 54f62985..37fce1d6 100644--- a/LifeOS/install/LIFEOS/TOOLS/SyncIdentityToSettings.ts+++ b/LifeOS/install/LIFEOS/TOOLS/SyncIdentityToSettings.ts@@ -18,7 +18,7 @@import { readFileSync, writeFileSync } from 'fs';import { join } from 'path';import { homedir } from 'os';-import { paiUserDir } from './PaiConfig';+import { paiUserDir } from './LifeosConfig';const HOME = homedir();const PRINCIPAL_PATH = join(paiUserDir(), 'PRINCIPAL/PRINCIPAL_IDENTITY.md');diff --git a/LifeOS/install/LIFEOS/TOOLS/UpdatePaiState.ts b/LifeOS/install/LIFEOS/TOOLS/UpdateLifeosState.tssimilarity index 94%rename from LifeOS/install/LIFEOS/TOOLS/UpdatePaiState.tsrename to LifeOS/install/LIFEOS/TOOLS/UpdateLifeosState.tsindex a55cf90f..0ccef197 100755--- a/LifeOS/install/LIFEOS/TOOLS/UpdatePaiState.ts+++ b/LifeOS/install/LIFEOS/TOOLS/UpdateLifeosState.ts@@ -1,6 +1,6 @@#!/usr/bin/env bun/**- * UpdatePaiState — Writes LIFEOS_STATE.json with per-dimension pct scores read by+ * UpdateLifeosState — Writes LIFEOS_STATE.json with per-dimension pct scores read by* the statusline (PAI/LIFEOS_StatusLine.sh) STATE strip and the Pulse TELOS* dashboard rings.*@@ -22,8 +22,8 @@* principal runs the IDEAL_STATE interview.** Usage:- * bun ~/.claude/LIFEOS/TOOLS/UpdatePaiState.ts- * bun ~/.claude/LIFEOS/TOOLS/UpdatePaiState.ts --json+ * bun ~/.claude/LIFEOS/TOOLS/UpdateLifeosState.ts+ * bun ~/.claude/LIFEOS/TOOLS/UpdateLifeosState.ts --json*/import { readFileSync, writeFileSync, existsSync, mkdirSync } from "fs";@@ -54,7 +54,7 @@ interface DimensionState {source_file: string;}-interface PaiState {+interface LifeosState {generated_at: string;dimensions: Record<DimensionId, DimensionState>;}@@ -106,7 +106,7 @@ function computeState(file: string): DimensionState {return computeFromCurrent(file) ?? computeFromIdeal(file);}-function build(): PaiState {+function build(): LifeosState {const dimensions = {} as Record<DimensionId, DimensionState>;for (const d of DIMENSIONS) {dimensions[d.id] = computeState(d.file);diff --git a/LifeOS/install/LIFEOS/TOOLS/gmail.ts b/LifeOS/install/LIFEOS/TOOLS/gmail.tsindex 50ffa671..527d0c26 100755--- a/LifeOS/install/LIFEOS/TOOLS/gmail.ts+++ b/LifeOS/install/LIFEOS/TOOLS/gmail.ts@@ -14,24 +14,24 @@//// Credentials path is resolved in order:// 1. $GOOGLE_WORKSPACE_CLI_CREDENTIALS_FILE (settings.json env)-// 2. PaiConfig integrations.google.credentialsFile (LIFEOS_CONFIG.toml)+// 2. LifeosConfig integrations.google.credentialsFile (LIFEOS_CONFIG.toml)// 3. {paiUserDir}/CONFIG/CREDENTIALS/google/credentials.json (conventional fallback)import { readFileSync } from "node:fs";import { homedir } from "node:os";import { join } from "node:path";-import { loadPaiConfig, paiUserDir } from "./PaiConfig";+import { loadLifeosConfig, paiUserDir } from "./LifeosConfig";function resolveCredsPath(): string {const envOverride = process.env.GOOGLE_WORKSPACE_CLI_CREDENTIALS_FILE?.replace(/^\$HOME/, homedir());if (envOverride) return envOverride;try {- const cfg = loadPaiConfig();+ const cfg = loadLifeosConfig();const fromConfig = cfg.integrations?.google?.credentialsFile;if (typeof fromConfig === "string" && fromConfig.length > 0) {return fromConfig.replace(/^\$HOME/, homedir()).replace(/^~/, homedir());}- } catch { /* PaiConfig unavailable on fresh install — fall through */ }+ } catch { /* LifeosConfig unavailable on fresh install — fall through */ }return join(paiUserDir(), "CONFIG/CREDENTIALS/google/credentials.json");}const CREDS_PATH = resolveCredsPath();diff --git a/LifeOS/install/LIFEOS/TOOLS/models.ts b/LifeOS/install/LIFEOS/TOOLS/models.tsindex 4fbef022..1ec7dbf6 100755--- a/LifeOS/install/LIFEOS/TOOLS/models.ts+++ b/LifeOS/install/LIFEOS/TOOLS/models.ts@@ -42,7 +42,7 @@ export type ClaudeTier = "opus" | "sonnet" | "haiku" | "fable";* Algorithm E1–E3 dispatch at `high`; E4/E5 dispatch at `max`. `medium` and* `low` exist for utility inference (classification, summarization, vision* triage) so cheap calls never silently ride an expensive model. The- * Advisor is pinned `max` (keystone commitment call); the EffortRouter+ * Advisor is pinned `max` (keystone commitment call); the TheRouter* classifier is pinned `high` (Opus, re-pinned off `max` 2026-07-01) — it* fires on every prompt, so the per-prompt keystone stays off the top rung.*/@@ -60,7 +60,7 @@ export type EffortLevel = "max" | "high" | "medium" | "low";* Haiku — reachable with NO new agent (the dispatch-time `model` param carries* the rung; agents are personas, model is orthogonal). Fable is ~2× Opus, so* the cost lands only on genuinely hard runs. Two guardrails ship with the flip:- * (a) the EffortRouter classifier is re-pinned to `high` (Opus), NOT `max`,+ * (a) the TheRouter classifier is re-pinned to `high` (Opus), NOT `max`,* so the per-prompt keystone stays fast + cheap — "keystone" never meant* "most-expensive rung"; the classifier's model is UNCHANGED from before* the flip (it was Opus via max=opus; it's Opus via high now).@@ -77,7 +77,7 @@ export type EffortLevel = "max" | "high" | "medium" | "low";*/export const EFFORT_MODEL: Record<EffortLevel, ClaudeTier> = {max: "fable", // top rung — E4/E5 + Core-System Override dispatch here (~2× Opus, hard work only)- high: "opus", // E1–E3 + NATIVE + the re-pinned EffortRouter classifier+ high: "opus", // E1–E3 + NATIVE + the re-pinned TheRouter classifiermedium: "sonnet",low: "haiku",};diff --git a/LifeOS/install/LIFEOS/VERSION b/LifeOS/install/LIFEOS/VERSIONindex 090ea9da..288b2cd9 100644--- a/LifeOS/install/LIFEOS/VERSION+++ b/LifeOS/install/LIFEOS/VERSION@@ -1 +1 @@-6.0.3+6.0.5diff --git a/LifeOS/install/USER/CONFIG/CREDENTIALS/README.md b/LifeOS/install/USER/CONFIG/CREDENTIALS/README.mdindex d4ea9d74..93307027 100644--- a/LifeOS/install/USER/CONFIG/CREDENTIALS/README.md+++ b/LifeOS/install/USER/CONFIG/CREDENTIALS/README.md@@ -6,4 +6,4 @@**How it gets populated:** By the user explicitly. When a skill needs a new credential it will tell you what to drop here; you obtain the key from the service and save it. Treat this dir like any other secrets store — back it up out-of-band, never commit it, never paste contents into chat.-**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use PAI.+**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use LifeOS.diff --git a/LifeOS/install/USER/CONFIG/OPERATIONAL_RULES.md b/LifeOS/install/USER/CONFIG/OPERATIONAL_RULES.mdindex 42156a63..76c82d2e 100644--- a/LifeOS/install/USER/CONFIG/OPERATIONAL_RULES.md+++ b/LifeOS/install/USER/CONFIG/OPERATIONAL_RULES.md@@ -6,7 +6,7 @@ convention: pai-freshness-v1# OPERATIONAL_RULES.md — Your principal-specific operational rules-> Principal-bound operational rules, imported into context every session. The system prompt (`PAI/LIFEOS_SYSTEM_PROMPT.md`) carries the domain-agnostic rules everyone runs; this file is where YOUR specifics live — your tooling choices, your environment, your vendor-specific gotchas, conventions for your own repos.+> Principal-bound operational rules, imported into context every session. The system prompt (`LIFEOS/LIFEOS_SYSTEM_PROMPT.md`) carries the domain-agnostic rules everyone runs; this file is where YOUR specifics live — your tooling choices, your environment, your vendor-specific gotchas, conventions for your own repos.This file ships as a stub. Add rules as you discover them — the LifeOS `/interview` flow will help, or just write them here directly. A few starter categories:diff --git a/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/ACTIONS/README.md b/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/ACTIONS/README.mdindex fc21a65f..ac8f7a4b 100644--- a/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/ACTIONS/README.md+++ b/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/ACTIONS/README.md@@ -6,4 +6,4 @@**How it gets populated:** By the user explicitly. You build actions when you need a piece of logic that two or more flows or pipelines will reuse, or when you want one well-tested unit instead of inline code repeated across skills.-**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use PAI.+**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use LifeOS.diff --git a/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/FLOWS/README.md b/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/FLOWS/README.mdindex d3da92f2..244a77f3 100644--- a/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/FLOWS/README.md+++ b/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/FLOWS/README.md@@ -6,4 +6,4 @@**How it gets populated:** By the user explicitly, or by skills that ship their own flow definitions. New flows are added by dropping a yaml file in this dir and registering it in `flow-index.json`.-**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use PAI.+**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use LifeOS.diff --git a/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/PIPELINES/README.md b/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/PIPELINES/README.mdindex d5465109..d8b5e401 100644--- a/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/PIPELINES/README.md+++ b/LifeOS/install/USER/CUSTOMIZATIONS/ARBOL/PIPELINES/README.md@@ -6,4 +6,4 @@**How it gets populated:** By the user explicitly, or by skills that ship their own pipeline definitions. Add a pipeline by dropping a yaml file in this dir and registering it in `pipeline-index.json`.-**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use PAI.+**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use LifeOS.diff --git a/LifeOS/install/USER/CUSTOMIZATIONS/README.md b/LifeOS/install/USER/CUSTOMIZATIONS/README.mdindex 234b83ec..da59e69e 100644--- a/LifeOS/install/USER/CUSTOMIZATIONS/README.md+++ b/LifeOS/install/USER/CUSTOMIZATIONS/README.md@@ -7,7 +7,7 @@ User-specific extensions of LifeOS system components. The LifeOS framework shipsAnything running a system component MUST look here for user content that applies to **this principal but not every LifeOS user.**- **Skills** read `CUSTOMIZATIONS/SKILLS/<SkillName>/` for per-user preferences, source lists, voice profiles, project names, and other context the public skill body cannot contain. The skill body stays generic; the user file overlays at runtime.-- **Arbol** reads `CUSTOMIZATIONS/ARBOL/` for the user's actions, pipelines, flows, and worker code. Resolution order is always personal-first: `CUSTOMIZATIONS/ARBOL/ACTIONS/<name>` overrides `PAI/ARBOL/Actions/<name>`; same for `PIPELINES/` and `FLOWS/`. The user copy wins.+- **Arbol** reads `CUSTOMIZATIONS/ARBOL/` for the user's actions, pipelines, flows, and worker code. Resolution order is always personal-first: `CUSTOMIZATIONS/ARBOL/ACTIONS/<name>` overrides `LIFEOS/ARBOL/Actions/<name>`; same for `PIPELINES/` and `FLOWS/`. The user copy wins.## Structurediff --git a/LifeOS/install/USER/CUSTOMIZATIONS/SKILLS/README.md b/LifeOS/install/USER/CUSTOMIZATIONS/SKILLS/README.mdindex 4f9e40a1..3ccd15f6 100644--- a/LifeOS/install/USER/CUSTOMIZATIONS/SKILLS/README.md+++ b/LifeOS/install/USER/CUSTOMIZATIONS/SKILLS/README.md@@ -6,4 +6,4 @@**How it gets populated:** By the user explicitly. You only create a subdir here when you actively want to override a skill's default behavior; otherwise leave this dir empty and skills will run with their shipped defaults.-**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use PAI.+**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use LifeOS.diff --git a/LifeOS/install/USER/DIGITAL_ASSISTANT/README.md b/LifeOS/install/USER/DIGITAL_ASSISTANT/README.mdindex 575c021a..b8884fc4 100644--- a/LifeOS/install/USER/DIGITAL_ASSISTANT/README.md+++ b/LifeOS/install/USER/DIGITAL_ASSISTANT/README.md@@ -1,7 +1,7 @@# DA — Digital Assistant IdentityThis directory holds the identity, voice, and personality of every Digital-Assistant (DA) in your PAI. Most users have one DA; advanced users can run+Assistant (DA) in your LifeOS. Most users have one DA; advanced users can runmultiple (e.g., a primary DA plus a specialist).## Filesdiff --git a/LifeOS/install/USER/Daemon/README.md b/LifeOS/install/USER/Daemon/README.mdindex b157ec04..ba7e8f7c 100644--- a/LifeOS/install/USER/Daemon/README.md+++ b/LifeOS/install/USER/Daemon/README.md@@ -6,4 +6,4 @@**How it gets populated:** By the Daemon skill automatically, on-demand or on a schedule. The skill reads your private LifeOS context, applies its scrub rules, and writes the public profile here. You can edit the output before publishing if you want finer control.-**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use PAI.+**Sample state for fresh installs:** Empty / Just this README. Real content appears as you use LifeOS.diff --git a/LifeOS/install/USER/SHARED/README.md b/LifeOS/install/USER/SHARED/README.mdindex 8c1846ea..44858e55 100644--- a/LifeOS/install/USER/SHARED/README.md+++ b/LifeOS/install/USER/SHARED/README.md@@ -6,4 +6,4 @@**How it gets populated:** By the user explicitly, or by skills that contribute shared assets at install time. Adding a new shared resource is a deliberate act: it implies a contract that consuming components agree to read from the same location.-**Sample state for fresh installs:** Just this README plus the `Spinner/` subdir. Real content appears as you use PAI.+**Sample state for fresh installs:** Just this README plus the `Spinner/` subdir. Real content appears as you use LifeOS.diff --git a/LifeOS/install/hooks/KittyEnvPersist.hook.ts b/LifeOS/install/hooks/KittyEnvPersist.hook.tsindex 420fb347..8bfcf7ea 100755--- a/LifeOS/install/hooks/KittyEnvPersist.hook.ts+++ b/LifeOS/install/hooks/KittyEnvPersist.hook.ts@@ -12,11 +12,11 @@import { readFileSync, writeFileSync, mkdirSync, existsSync } from 'fs';import { join } from 'path';-import { getPaiDir } from './lib/paths';+import { getLifeosDir } from './lib/paths';import { setTabState, readTabState, persistKittySession } from './lib/tab-setter';import { getDAName } from './lib/identity';-const paiDir = getPaiDir();+const paiDir = getLifeosDir();// Skip for subagentsconst claudeProjectDir = process.env.CLAUDE_PROJECT_DIR || '';diff --git a/LifeOS/install/hooks/LoadContext.hook.ts b/LifeOS/install/hooks/LoadContext.hook.tsindex 247deef6..3bdc4767 100755--- a/LifeOS/install/hooks/LoadContext.hook.ts+++ b/LifeOS/install/hooks/LoadContext.hook.ts@@ -39,7 +39,7 @@import { readFileSync, existsSync, readdirSync } from 'fs';import { join } from 'path';-import { getPaiDir, getSettingsPath } from './lib/paths';+import { getLifeosDir, getSettingsPath } from './lib/paths';import { recordSessionStart } from './lib/notifications';import { loadLearningDigest, loadWisdomFrames, loadFailurePatterns, loadSignalTrends, loadSynthesisPatterns } from './lib/learning-readback';import { findArtifactPath } from './lib/isa-utils';@@ -394,7 +394,7 @@ async function main() {process.exit(0);}- const paiDir = getPaiDir();+ const paiDir = getLifeosDir();// Tab reset is handled by KittyEnvPersist.hook.ts (runs before this hook)diff --git a/LifeOS/install/hooks/LoadMemory.hook.ts b/LifeOS/install/hooks/LoadMemory.hook.tsindex c8827b2d..ea2dfd70 100755--- a/LifeOS/install/hooks/LoadMemory.hook.ts+++ b/LifeOS/install/hooks/LoadMemory.hook.ts@@ -3,7 +3,7 @@* LoadMemory — UserPromptSubmit hook that injects the two hot-layer memory* files (PRINCIPAL_MEMORY.md, DA_MEMORY.md) as additionalContext on every* prompt, so the Claude Code CLI session sees the same memory the Telegram- * pipeline already injects via buildPaiContextBlock.+ * pipeline already injects via buildLifeosContextBlock.** Closes the CLI-vs-Telegram parity gap (the autonomic loop was writing* memory files but the CLI session was never reading them in-prompt).diff --git a/LifeOS/install/hooks/MemoryReviewTrigger.hook.ts b/LifeOS/install/hooks/MemoryReviewTrigger.hook.tsindex 6cc1eb4d..508ee698 100755--- a/LifeOS/install/hooks/MemoryReviewTrigger.hook.ts+++ b/LifeOS/install/hooks/MemoryReviewTrigger.hook.ts@@ -44,7 +44,7 @@ const CLAUDE_ROOT = pathResolve(homedir(), ".claude");const STATE_PATH = pathResolve(CLAUDE_ROOT, "LIFEOS/MEMORY/OBSERVABILITY/review-state.json");const CONFIG_PATH = pathResolve(CLAUDE_ROOT, "LIFEOS/USER/CONFIG/memory-review.json");const EFFORT_ROUTER_LOG = pathResolve(CLAUDE_ROOT, "LIFEOS/MEMORY/OBSERVABILITY/effort-router.jsonl");-const EFFORT_ROUTER_MAX_AGE_MS = 30_000; // tolerate ≤30s drift between EffortRouter write and Trigger read+const EFFORT_ROUTER_MAX_AGE_MS = 30_000; // tolerate ≤30s drift between TheRouter write and Trigger readinterface ReviewState {turn_count_since_last_review: number;@@ -139,12 +139,12 @@ function isSubagentInvocation(): boolean {}/**- * Read the trailing line of effort-router.jsonl (written by EffortRouter+ * Read the trailing line of effort-router.jsonl (written by TheRouter* hook earlier in the same UserPromptSubmit chain). Return the parsed row* if it landed within the last EFFORT_ROUTER_MAX_AGE_MS window — otherwise* null (no recent classification → don't gate).*/-function readLatestEffortRouterRow(): { mode?: string; session_id?: string; timestamp?: string } | null {+function readLatestTheRouterRow(): { mode?: string; session_id?: string; timestamp?: string } | null {try {if (!existsSync(EFFORT_ROUTER_LOG)) return null;const raw = readFileSync(EFFORT_ROUTER_LOG, "utf8");@@ -163,10 +163,10 @@ function readLatestEffortRouterRow(): { mode?: string; session_id?: string; timefunction isMinimalMode(): boolean {// ISC-47: classifier-MINIMAL turns don't need a cadence reviewer hit.- // EffortRouter writes the classification to effort-router.jsonl BEFORE- // this hook fires (they share the UserPromptSubmit chain; EffortRouter+ // TheRouter writes the classification to effort-router.jsonl BEFORE+ // this hook fires (they share the UserPromptSubmit chain; TheRouter// is registered first). Read the trailing row and skip on MINIMAL.- const row = readLatestEffortRouterRow();+ const row = readLatestTheRouterRow();return row?.mode === "MINIMAL";}diff --git a/LifeOS/install/hooks/PromptProcessing.hook.ts b/LifeOS/install/hooks/PromptProcessing.hook.tsindex 171e5a74..f30a04c0 100755--- a/LifeOS/install/hooks/PromptProcessing.hook.ts+++ b/LifeOS/install/hooks/PromptProcessing.hook.ts@@ -9,7 +9,7 @@* TRIGGER: UserPromptSubmit** NOTE: Mode/tier classification is NOT handled here — that lives in- * EffortRouter.hook.ts (which runs on the same UserPromptSubmit event,+ * TheRouter.hook.ts (which runs on the same UserPromptSubmit event,* before this hook, and emits MODE/TIER to additionalContext via* hookSpecificOutput). Satisfaction/rating capture is handled by the* dedicated SatisfactionCapture.hook.ts. This hook does only:@@ -828,11 +828,11 @@ async function main() {isMinimalInteraction ? 'minimal' :!isNativeMode(prompt) ? 'algorithm' : 'native';- // The tab's mode/tier token is OWNED by EffortRouter (the authoritative+ // The tab's mode/tier token is OWNED by TheRouter (the authoritative// classifier), not derived here. PromptProcessing used to stamp "N" from its- // own 8-verb isNativeMode() shadow-classifier, which diverged from EffortRouter+ // own 8-verb isNativeMode() shadow-classifier, which diverged from TheRouter// and showed "N" on ALGORITHM turns. Now PromptProcessing only sets the working- // DESCRIPTION and recovers whatever token EffortRouter stamped (see stampWorkingTab).+ // DESCRIPTION and recovers whatever token TheRouter stamped (see stampWorkingTab).// ── Slash-command / skill invocation: name deterministically from the command ──// A command name (e.g. "/Upgrade") can never satisfy the natural-language@@ -915,10 +915,10 @@ async function main() {if (algoIteration) {setPhaseTab(priorPhase as AlgorithmTabPhase, sessionId, rawTitle, priorToken!);} else {- // Do NOT self-classify the mode token — EffortRouter owns it. Recover the+ // Do NOT self-classify the mode token — TheRouter owns it. Recover the// token already on the tab, but ONLY when the tab shows live work; a stale// completion/idle token from the prior turn is dropped so it can't leak into- // this turn (EffortRouter stamps the authoritative token ~concurrently).+ // this turn (TheRouter stamps the authoritative token ~concurrently).const cur = readTabState(sessionId);const liveToken = cur && cur.state !== 'completed' && cur.state !== 'idle'? (extractModeToken(cur.title) || undefined)diff --git a/LifeOS/install/hooks/README.md b/LifeOS/install/hooks/README.mdindex fe549eda..02ac41c1 100755--- a/LifeOS/install/hooks/README.md+++ b/LifeOS/install/hooks/README.md@@ -27,7 +27,7 @@ This document is the authoritative reference for LifeOS's hook system. When modiHooks are TypeScript scripts that execute at specific lifecycle events in Claude Code. They enable:-- **Mode/tier routing**: classifier (`EffortRouter`) decides MINIMAL/NATIVE/ALGORITHM + tier on every prompt+- **Mode/tier routing**: classifier (`TheRouter`) decides MINIMAL/NATIVE/ALGORITHM + tier on every prompt- **Voice feedback**: spoken phase announcements and completion lines- **Memory capture**: session summaries, work tracking, learnings, relationship notes- **Security**: native `permissions.deny` + a single `Safety.hook.ts` that dispatches by event — gates outgoing tool calls (PermissionRequest) and tags external content (PostToolUse)@@ -52,7 +52,7 @@ Hooks are TypeScript scripts that execute at specific lifecycle events in Claude│ ├──► LoadContext (dynamic context injection) ││ └──► FreshnessCache (statusline jq cache) ││ │-│ UserPromptSubmit ──┬──► EffortRouter (MODE+TIER classifier) │+│ UserPromptSubmit ──┬──► TheRouter (MODE+TIER classifier) ││ ├──► PromptProcessing (tab title + naming) ││ ├──► SatisfactionCapture (rating + signals) ││ └──► ReminderRouter (/remind → labeled issue) │@@ -156,7 +156,7 @@ interface StopPayload extends BasePayload {| Hook | Purpose | Blocking | Dependencies ||------|---------|----------|--------------|-| `EffortRouter.hook.ts` | Mode + Tier classification → additionalContext | No | Inference (Sonnet via `claude` subprocess) |+| `TheRouter.hook.ts` | Mode + Tier classification → additionalContext | No | Inference (Sonnet via `claude` subprocess) || `PromptProcessing.hook.ts` | Tab title + session naming via Haiku | No | Inference (Haiku), Voice Server, `session-names.json` || `SatisfactionCapture.hook.ts` | Rating capture + low-rating learning signals | No | `last-response.txt` (from LastResponseCache), `ratings.jsonl` || `ReminderRouter.hook.ts` | "remind me to X" → labeled GitHub issue | No | `WORK.REPO` config, `gh` CLI |@@ -190,7 +190,7 @@ interface StopPayload extends BasePayload {| Hook | Matcher | Purpose | Blocking | Dependencies ||------|---------|---------|----------|--------------|-| `Safety.hook.ts` | Write / Edit / MultiEdit / Bash, mcp__reversinglabs__.* | Shape-classifier gate on outgoing tool calls. Auto-allows safe shapes (read-only commands, dev binaries, trusted-workspace paths, shell-control-flow over data, mcp pre-vetted). Falls through to native engine prompt on dangerous/credential/injection shapes or unknown commands. Cache + observability. Same file as the PostToolUse hook above; dispatches by event. | Yes (allow JSON when safe) | `lib/safety-classifier.ts`, `MEMORY/STATE/permission-cache.json`, `MEMORY/OBSERVABILITY/permission-decisions.jsonl` |+| `Safety.hook.ts` | Write / Edit / MultiEdit / Bash, mcp__.* | Shape-classifier gate on outgoing tool calls. Auto-allows safe shapes (read-only commands, dev binaries, trusted-workspace paths, shell-control-flow over data, mcp pre-vetted). Falls through to native engine prompt on dangerous/credential/injection shapes or unknown commands. Cache + observability. Same file as the PostToolUse hook above; dispatches by event. | Yes (allow JSON when safe) | `lib/safety-classifier.ts`, `MEMORY/STATE/permission-cache.json`, `MEMORY/OBSERVABILITY/permission-decisions.jsonl` |### PostToolUseFailure Hooks@@ -265,12 +265,12 @@ Outputs: `subagent-events.jsonl` (start + stop events), correlated by `session_iUser Message│▼-EffortRouter ─── Stage A: deterministic fast-paths (/eN, ratings, praise) ──► emit + exit+TheRouter ─── Stage A: deterministic fast-paths (/eN, ratings, praise) ──► emit + exit│ (no fast match)├── Stage B: 60s decision cache (SHA-256 normalized prompt) ──► emit cached + exit│ (no cache hit)▼- Stage C: EffortRouter classifier (Inference.ts --level high — Opus; re-pinned off max 2026-07-01 so max=Fable stays off the per-prompt path)+ Stage C: TheRouter classifier (Inference.ts --level high — Opus; re-pinned off max 2026-07-01 so max=Fable stays off the per-prompt path)│└── Emit: MODE: <…> | TIER: <…> | REASON: <…> | SOURCE: classifier|fail-safe|fast-path|cache|explicitWritten to additionalContext via hookSpecificOutput.@@ -280,7 +280,7 @@ SatisfactionCapture ── Rating + signals (reads last-response.txt) ──►ReminderRouter ── /remind parser ──► gh issue create with reminder labels```-**Order matters.** EffortRouter fires first so PromptProcessing and downstream hooks can read the classification line if needed. SatisfactionCapture reads `last-response.txt` written by `LastResponseCache.hook.ts` at the previous Stop.+**Order matters.** TheRouter fires first so PromptProcessing and downstream hooks can read the classification line if needed. SatisfactionCapture reads `last-response.txt` written by `LastResponseCache.hook.ts` at the previous Stop.### Stop → UserPromptSubmit Bridge@@ -294,7 +294,7 @@ Stop:[Next user prompt arrives]UserPromptSubmit:- EffortRouter (independent of last-response)+ TheRouter (independent of last-response)PromptProcessing (independent of last-response)SatisfactionCapture ◄─ reads last-response.txt for sentiment scoringReminderRouter (independent of last-response)@@ -324,7 +324,7 @@ SessionEnd ─┬─► WorkCompletionLearning ─► reads work.json by session```UserPromptSubmit- ├─► EffortRouter (no tab interaction)+ ├─► TheRouter (no tab interaction)├─► PromptProcessing│ ├─► Sets tab to PURPLE (#5B21B6) ─► "🧠 Processing..."│ ├─► Single Haiku inference (title + name)@@ -560,15 +560,15 @@ When modifying ANY hook:### Hook Blocking Session-1. Check if hook writes to stdout (only LoadContext / RestoreContext / PreCompact / EffortRouter should)+1. Check if hook writes to stdout (only LoadContext / RestoreContext / PreCompact / TheRouter should)2. Verify timeouts are set for external calls3. Check for infinite loops or blocking I/O### Mode Classifier Drift-1. Confirm `EffortRouter.hook.ts` is registered first in `UserPromptSubmit` block of `settings.json`+1. Confirm `TheRouter.hook.ts` is registered first in `UserPromptSubmit` block of `settings.json`2. Tail `MEMORY/OBSERVABILITY/effort-router.jsonl` to see classifier outputs-3. Test with synthetic prompt: `echo '{"session_id":"t","prompt":"test"}' | bun hooks/EffortRouter.hook.ts`+3. Test with synthetic prompt: `echo '{"session_id":"t","prompt":"test"}' | bun hooks/TheRouter.hook.ts`### External Content Tagging@@ -588,7 +588,7 @@ When modifying ANY hook:### 2026-05-06 — bpe-cuts (this commit)Removed:-- `RepeatDetection.hook.ts` (UserPromptSubmit) — pre-classifier-era safety net, redundant with EffortRouter + Opus reading conversation context.+- `RepeatDetection.hook.ts` (UserPromptSubmit) — pre-classifier-era safety net, redundant with TheRouter + Opus reading conversation context.- `TeammateIdle.hook.ts` (TeammateIdle) — pure logging hook with zero readers.- `ElicitationHandler.hook.ts` (Elicitation) — pure logging hook with zero readers.- `FileChanged.hook.ts` (FileChanged) — duplicate of `ToolActivityTracker` capture.@@ -614,4 +614,4 @@ Replacement: native `permissions.deny` in `settings.json` (42 entries) + a singl### Earlier — classifier split-`PromptProcessing.hook.ts` (formerly `SessionAnalysis.hook.ts`) once briefly held the `Mode + Tier` classifier role. That responsibility was extracted to `EffortRouter.hook.ts` to give the classifier its own three-stage cascade (fast-paths → 60s cache → Sonnet) with dedicated telemetry. PromptProcessing now does only tab + naming via Haiku.+`PromptProcessing.hook.ts` (formerly `SessionAnalysis.hook.ts`) once briefly held the `Mode + Tier` classifier role. That responsibility was extracted to `TheRouter.hook.ts` to give the classifier its own three-stage cascade (fast-paths → 60s cache → Sonnet) with dedicated telemetry. PromptProcessing now does only tab + naming via Haiku.diff --git a/LifeOS/install/hooks/RelationshipMemory.hook.ts b/LifeOS/install/hooks/RelationshipMemory.hook.tsindex b6a1c5d8..633ed43b 100755--- a/LifeOS/install/hooks/RelationshipMemory.hook.ts+++ b/LifeOS/install/hooks/RelationshipMemory.hook.ts@@ -30,7 +30,7 @@import { writeFileSync, existsSync, mkdirSync, appendFileSync } from 'fs';import { join } from 'path';-import { getPaiDir } from './lib/paths';+import { getLifeosDir } from './lib/paths';import { getPSTComponents } from './lib/time';import { getDAName, getPrincipalName } from './lib/identity';import { parseTranscript } from '../LIFEOS/TOOLS/TranscriptParser';@@ -261,7 +261,7 @@ async function main() {}// Write to daily relationship file- const paiDir = getPaiDir();+ const paiDir = getLifeosDir();const filepath = ensureRelationshipDir(paiDir);initDailyFile(filepath);diff --git a/LifeOS/install/hooks/Safety.hook.ts b/LifeOS/install/hooks/Safety.hook.tsindex 1cf75f9e..4afd1b5f 100755--- a/LifeOS/install/hooks/Safety.hook.ts+++ b/LifeOS/install/hooks/Safety.hook.ts@@ -4,7 +4,7 @@** Single entry point dispatching by event:*- * PermissionRequest (Bash | Write | Edit | MultiEdit | mcp__reversinglabs__*)+ * PermissionRequest (Bash | Write | Edit | MultiEdit | mcp__*)* → permissionRequest() — classify outgoing tool call via lib/safety-classifier* → emit `decision: allow` JSON when safe; emit nothing (neutral) otherwise* → cache by sha; observability JSONL appenddiff --git a/LifeOS/install/hooks/SuccessClaimGate.hook.ts b/LifeOS/install/hooks/SuccessClaimGate.hook.tsindex 9980645b..b189d001 100755--- a/LifeOS/install/hooks/SuccessClaimGate.hook.ts+++ b/LifeOS/install/hooks/SuccessClaimGate.hook.ts@@ -157,8 +157,11 @@ const LIVE_UI_CLAIM =/\b((is|it'?s|site'?s|page'?s|now)\s+live|went\s+live|locked\s+down|fail[\s-]?closed\s+verif\w*|verified\s+(live|in\s+the\s+browser|fail[\s-]?closed)|works\s+(now|in\s+the\s+browser|end[\s-]?to[\s-]?end))\b/i;// Interceptor-class evidence — the only thing that verifies rendered web output.+// Includes the ScrubFlow frame-scrub manifest (the frames the model actually+// viewed + their SSIM scores) — motion/flow evidence, keyed on the manifest,+// NOT a bare video path ("video.mp4 exists" is not proof it rendered right).const INTERCEPTOR_EVIDENCE =- /\binterceptor\b|\/Downloads\/[A-Za-z0-9_\-]+\.(png|webp|jpe?g)\b|\bpai[\s-]?screenshots?\b|\bscreenshots?\/[A-Za-z0-9_\-./]+\.(png|jpe?g|webp)\b|\bDOM\s+read\b|\bComputer\s+Use\b/i;+ /\binterceptor\b|\/Downloads\/[A-Za-z0-9_\-]+\.(png|webp|jpe?g)\b|\bpai[\s-]?screenshots?\b|\bscreenshots?\/[A-Za-z0-9_\-./]+\.(png|jpe?g|webp)\b|\bDOM\s+read\b|\bComputer\s+Use\b|\bframe[\s-]?scrub\b|\bscrub(?:bed|flow)\b|\bframes?\/[A-Za-z0-9_\-./]+manifest\.json\b/i;// Honest downgrade / deferral — an explicit "not browser-verified" is allowed;// it is not a false done-claim. This is the sanctioned escape when Interceptor@@ -168,11 +171,37 @@ const HONEST_DOWNGRADE =// Returns true when the message asserts a browser-facing thing is live/works,// with NO Interceptor evidence and NO honest downgrade — the catastrophic class.+//+// TASK-AWARE SCOPING (2026-07-04): the live-claim and the web-UI context must+// co-occur in the SAME sentence/line. The prior version OR'd LIVE_UI_CLAIM into+// BOTH halves of the test, so any "…is now live" collapsed the conjunction and+// fired even with zero web nouns present — a git-push "the rename is now live"+// got blocked as a web claim (false positive {{PRINCIPAL_NAME}} hit repeatedly). Requiring+// same-unit co-occurrence means "live" only trips the browser teeth when it's+// live ABOUT a page/site/admin/dashboard/form/login (or a render verb), never+// about a hook, tag, repo, worker, or CLI. The real 2026-06-27 case ("Admin's+// live and locked down", curl-only) still blocks — "admin" is in the same unit.+// Escapes (Interceptor evidence / honest downgrade) still scan the whole message.+function splitIntoUnits(text: string): string[] {+ // Sentence terminators + line breaks — each clause/bullet is its own unit, so a+ // web noun in one section can't satisfy a non-web "live" claim in another.+ return text.split(/[.!?\n]+/).map((u) => u.trim()).filter(Boolean);+}++function unitAssertsLive(u: string): boolean {+ return LIVE_UI_CLAIM.test(u) || DEPLOY_CLAIM.test(u) || /\b(it\s+works|works\s+now)\b/i.test(u);+}++function unitIsWebUi(u: string): boolean {+ return WEB_UI_NOUN.test(u) || RENDER_VERB.test(u);+}+function isUnverifiedWebUiClaim(message: string): boolean {const s = stripNarration(message);- const assertsLive = LIVE_UI_CLAIM.test(s) || DEPLOY_CLAIM.test(s) || /\b(it\s+works|works\s+now)\b/i.test(s);- const isUi = WEB_UI_NOUN.test(s) || RENDER_VERB.test(s) || LIVE_UI_CLAIM.test(s);- if (!(assertsLive && isUi)) return false;+ // A web-UI claim requires a live/deploy/works assertion AND a web-UI noun or+ // render verb IN THE SAME unit — the claim must be about the web thing.+ const hasWebUiClaim = splitIntoUnits(s).some((u) => unitAssertsLive(u) && unitIsWebUi(u));+ if (!hasWebUiClaim) return false;if (INTERCEPTOR_EVIDENCE.test(message)) return false; // verified the right wayif (HONEST_DOWNGRADE.test(message)) return false; // honestly deferredreturn true;diff --git a/LifeOS/install/hooks/SystemFileGuard.hook.ts b/LifeOS/install/hooks/SystemFileGuard.hook.tsindex 4e65aa78..e6927ba8 100755--- a/LifeOS/install/hooks/SystemFileGuard.hook.ts+++ b/LifeOS/install/hooks/SystemFileGuard.hook.ts@@ -71,9 +71,9 @@ function denyMessage(relPath: string, pattern: string, match: string): string {" This file is in the SYSTEM tree — it must not contain principal-"," identifying tokens, hostnames, contact info, or other deny-list"," patterns. Move the user-specific content to a USER-zone location",- " or read it through the PaiConfig interface:",+ " or read it through the LifeosConfig interface:","",- " import { loadPaiConfig, paiUserDir } from '~/.claude/LIFEOS/TOOLS/PaiConfig';",+ " import { loadLifeosConfig, paiUserDir } from '~/.claude/LIFEOS/TOOLS/LifeosConfig';",""," Canonical USER zones (any of these can hold the content):"," LIFEOS/USER/PRINCIPAL/ principal identity files",diff --git a/LifeOS/install/hooks/EffortRouter.hook.ts b/LifeOS/install/hooks/TheRouter.hook.tssimilarity index 97%rename from LifeOS/install/hooks/EffortRouter.hook.tsrename to LifeOS/install/hooks/TheRouter.hook.tsindex 6b4e57dd..8d3d8ad7 100755--- a/LifeOS/install/hooks/EffortRouter.hook.ts+++ b/LifeOS/install/hooks/TheRouter.hook.ts@@ -1,6 +1,6 @@#!/usr/bin/env bun/**- * EffortRouter — UserPromptSubmit hook that owns mode/tier classification.+ * TheRouter — UserPromptSubmit hook that owns mode/tier classification.** Three-stage cascade:* A. Deterministic fast-paths (0ms): /eN, ratings, praise, system-text, short, hard triggers.@@ -67,7 +67,7 @@ interface ClassifierJSON {// ── Constants ──const MIN_PROMPT_LENGTH = 3;-const CLASSIFIER_TIMEOUT_MS = 30000; // classifier runs at level 'high' (Opus, re-pinned 2026-07-01 — max is now Fable, and firing Fable on every prompt is a needless 2× cost + latency hit). Single ≤30s Opus attempt under the EffortRouter hook ceiling (settings.json timeout: 50s); on timeout/parse-fail it degrades via failsafeDecision(). The classifier's model is UNCHANGED by the re-pin (was Opus via max=opus; is Opus via high now).+const CLASSIFIER_TIMEOUT_MS = 30000; // classifier runs at level 'high' (Opus, re-pinned 2026-07-01 — max is now Fable, and firing Fable on every prompt is a needless 2× cost + latency hit). Single ≤30s Opus attempt under the TheRouter hook ceiling (settings.json timeout: 50s); on timeout/parse-fail it degrades via failsafeDecision(). The classifier's model is UNCHANGED by the re-pin (was Opus via max=opus; is Opus via high now).const STDIN_TIMEOUT_MS = 5000;const CACHE_TTL_MS = 60_000;const CACHE_MAX_ENTRIES = 50;@@ -289,7 +289,7 @@ function storeCache(prompt: string, decision: Decision): void {// ── Smart classifier prompt ──function buildClassifierSystemPrompt(): string {- return `You are the EffortRouter for LifeOS, the LifeOS (Life Operating System) running on Claude Code. Every prompt is classified into one of three response modes — MINIMAL, NATIVE, or ALGORITHM — plus an effort tier when ALGORITHM is selected.+ return `You are the TheRouter for LifeOS, the LifeOS (Life Operating System) running on Claude Code. Every prompt is classified into one of three response modes — MINIMAL, NATIVE, or ALGORITHM — plus an effort tier when ALGORITHM is selected.LifeOS is the Life Operating System — scaffolding that makes AI dependable. Every task is current state → ideal state, articulated as ISC (hard-to-vary criteria), pursued through verifiable iteration. The router preserves dynamic range: fast on simple work, deep on hard work, sharp variation between them.@@ -528,7 +528,7 @@ async function main(): Promise<void> {});// 2026-05-24 (realtime-phase-tracking) + 2026-07-01 (single-authority tab/state):- // EffortRouter owns the authoritative {mode,tier} decision, so it drives BOTH+ // TheRouter owns the authoritative {mode,tier} decision, so it drives BOTH// surfaces the instant it classifies — work.json (the Pulse Agents/Lattice page)// AND the kitty tab mode token. This kills the divergence where PromptProcessing's// shadow 8-verb classifier stamped "N" on an ALGORITHM turn, and clears a prior@@ -622,7 +622,7 @@ async function main(): Promise<void> {{ const d = decorate(cached); preEmit(d); emit(d); log(d); process.exit(0); }}- // ── Stage C: EffortRouter classifier (level 'high' = Opus; re-pinned off max 2026-07-01) ──+ // ── Stage C: TheRouter classifier (level 'high' = Opus; re-pinned off max 2026-07-01) ──try {const contextStr = getRecentContext(transcriptPath);@@ -636,6 +636,6 @@ async function main(): Promise<void> {}main().catch((err) => {- console.error(`[EffortRouter] Fatal: ${err}`);+ console.error(`[TheRouter] Fatal: ${err}`);process.exit(0);});diff --git a/LifeOS/install/hooks/handlers/DocCrossRefIntegrity.ts b/LifeOS/install/hooks/handlers/DocCrossRefIntegrity.tsindex af15f63f..a2e9ce14 100755--- a/LifeOS/install/hooks/handlers/DocCrossRefIntegrity.ts+++ b/LifeOS/install/hooks/handlers/DocCrossRefIntegrity.ts@@ -32,7 +32,7 @@import { readFileSync, writeFileSync, existsSync, readdirSync } from 'fs';import { join, basename } from 'path';-import { paiPath, getPaiDir, getClaudeDir } from '../lib/paths';+import { paiPath, getLifeosDir, getClaudeDir } from '../lib/paths';import { getIdentity } from '../lib/identity';import { inference } from '../../LIFEOS/TOOLS/Inference';import type { ParsedTranscript } from '../../LIFEOS/TOOLS/TranscriptParser';@@ -60,7 +60,7 @@ interface DriftItem {// Constants// ============================================================================-const SYSTEM_DIR = getPaiDir();+const SYSTEM_DIR = getLifeosDir();const DOCS_DIR = join(SYSTEM_DIR, 'DOCUMENTATION');const HOOKS_DIR = join(getClaudeDir(), 'hooks');const HANDLERS_DIR = join(HOOKS_DIR, 'handlers');@@ -157,7 +157,7 @@ function isHookModified(modifiedFiles: Set<string>): boolean {* Excludes MEMORY/WORK, MEMORY/LEARNING, MEMORY/STATE, and other non-system paths.*/function isSystemFileModified(modifiedFiles: Set<string>): boolean {- const LIFEOS_DIR = getPaiDir();+ const LIFEOS_DIR = getLifeosDir();const CLAUDE_DIR = getClaudeDir();const LIFEOS_EXCLUDED = ['MEMORY/WORK/', 'MEMORY/LEARNING/', 'MEMORY/STATE/', 'Plans/', '.git/', 'node_modules/', 'ShellSnapshots/', 'MEMORY/VOICE/', 'MEMORY/RELATIONSHIP/', 'history.jsonl', '.quote-cache'];const CLAUDE_EXCLUDED = ['projects/', '.git/', 'node_modules/', 'history.jsonl'];diff --git a/LifeOS/install/hooks/handlers/MemoryDirIntegrity.ts b/LifeOS/install/hooks/handlers/MemoryDirIntegrity.tsindex c3841e97..195e16f1 100755--- a/LifeOS/install/hooks/handlers/MemoryDirIntegrity.ts+++ b/LifeOS/install/hooks/handlers/MemoryDirIntegrity.ts@@ -27,10 +27,10 @@import { readFileSync, readdirSync, existsSync, statSync, appendFileSync, mkdirSync } from 'fs';import { join } from 'path';-import { paiPath, getPaiDir } from '../lib/paths';+import { paiPath, getLifeosDir } from '../lib/paths';const TAG = '[MemoryDirIntegrity]';-const LIFEOS_DIR = getPaiDir();+const LIFEOS_DIR = getLifeosDir();const MEMORY_DIR = join(LIFEOS_DIR, 'MEMORY');const INVENTORY_DOC = paiPath('DOCUMENTATION/Memory/MemorySystem.md');const EVENTS_FILE = join(MEMORY_DIR, 'STATE', 'events.jsonl');diff --git a/LifeOS/install/hooks/handlers/RebuildArchSummary.ts b/LifeOS/install/hooks/handlers/RebuildArchSummary.tsindex 780a9022..8fac1938 100755--- a/LifeOS/install/hooks/handlers/RebuildArchSummary.ts+++ b/LifeOS/install/hooks/handlers/RebuildArchSummary.ts@@ -19,10 +19,10 @@import { statSync, readdirSync, existsSync } from "fs";import { join } from "path";import { spawn } from "child_process";-import { getPaiDir, getClaudeDir } from "../lib/paths";+import { getLifeosDir, getClaudeDir } from "../lib/paths";export async function handleRebuildArchSummary(): Promise<void> {- const paiDir = getPaiDir();+ const paiDir = getLifeosDir();const claudeDir = getClaudeDir();const output = join(paiDir, "DOCUMENTATION", "LIFEOS_ARCHITECTURE_SUMMARY.md");const generator = join(paiDir, "Tools/ArchitectureSummaryGenerator.ts");diff --git a/LifeOS/install/hooks/handlers/UpdateCounts.ts b/LifeOS/install/hooks/handlers/UpdateCounts.tsindex c4355b04..46f67887 100755--- a/LifeOS/install/hooks/handlers/UpdateCounts.ts+++ b/LifeOS/install/hooks/handlers/UpdateCounts.ts@@ -21,7 +21,7 @@import { readFileSync, writeFileSync } from 'fs';import { join } from 'path';import { execSync } from 'child_process';-import { getPaiDir } from '../lib/paths';+import { getLifeosDir } from '../lib/paths';/*** Refresh usage cache from Anthropic OAuth API.@@ -111,7 +111,7 @@ async function refreshUsageCache(paiDir: string): Promise<void> {* Now does ONLY the OAuth usage cache refresh.*/export async function handleUpdateCounts(): Promise<void> {- const paiDir = getPaiDir();+ const paiDir = getLifeosDir();await refreshUsageCache(paiDir);}diff --git a/LifeOS/install/hooks/hooks.json b/LifeOS/install/hooks/hooks.jsonindex beadbb5e..1b62a414 100644--- a/LifeOS/install/hooks/hooks.json+++ b/LifeOS/install/hooks/hooks.json@@ -229,7 +229,7 @@"hooks": [{"type": "command",- "command": "$HOME/.claude/hooks/EffortRouter.hook.ts",+ "command": "$HOME/.claude/hooks/TheRouter.hook.ts","timeout": 35}]@@ -428,7 +428,7 @@]},{- "matcher": "mcp__reversinglabs__.*",+ "matcher": "mcp__.*","hooks": [{"type": "command",diff --git a/LifeOS/install/hooks/lib/change-detection.ts b/LifeOS/install/hooks/lib/change-detection.tsindex d5de6da6..b162c311 100755--- a/LifeOS/install/hooks/lib/change-detection.ts+++ b/LifeOS/install/hooks/lib/change-detection.ts@@ -7,7 +7,7 @@import { readFileSync, existsSync } from 'fs';import { join, relative, basename } from 'path';-import { getPaiDir } from './paths';+import { getLifeosDir } from './paths';// ============================================================================// Types@@ -52,7 +52,7 @@ export interface IntegrityState {// Path Constants// ============================================================================-const LIFEOS_DIR = getPaiDir();+const LIFEOS_DIR = getLifeosDir();const STATE_FILE = join(LIFEOS_DIR, 'MEMORY', 'STATE', 'integrity-state.json');// Paths that are excluded from integrity checksdiff --git a/LifeOS/install/hooks/lib/containment-zones.ts b/LifeOS/install/hooks/lib/containment-zones.tsindex 8d110f78..9b3da63f 100755--- a/LifeOS/install/hooks/lib/containment-zones.ts+++ b/LifeOS/install/hooks/lib/containment-zones.ts@@ -135,9 +135,9 @@ export const PATTERN_ALLOWLIST_FILES: readonly string[] = [// - CLAUDE.md (live) gets overlaid by RELEASE_TEMPLATES/CLAUDE.public.md// at build time — the live form ships only to the principal; the public// ship is the template overlay. Verified: staged CLAUDE.md is clean.- // NOTE (Phase G.6, 2026-05-25 after Forge iter-5): `LIFEOS/TOOLS/PaiUpgrade.ts`+ // NOTE (Phase G.6, 2026-05-25 after Forge iter-5): `LIFEOS/TOOLS/LifeosUpgrade.ts`// and `LIFEOS/PULSE/Tools/ReleaseAudit.ts` were REMOVED from this allowlist.- // PaiUpgrade.ts now uses a generic marker comment instead of the previous+ // LifeosUpgrade.ts now uses a generic marker comment instead of the previous// principal-bound repo-name literal; ReleaseAudit.ts now loads its prohibited// strings from a USER-zone config file at runtime (never ships publicly).// Allowlist became an escape hatch hiding real bare-token leaks — fixed atdiff --git a/LifeOS/install/hooks/lib/egress-class-core.ts b/LifeOS/install/hooks/lib/egress-class-core.tsindex 72a7cccc..b7a9168a 100644--- a/LifeOS/install/hooks/lib/egress-class-core.ts+++ b/LifeOS/install/hooks/lib/egress-class-core.ts@@ -43,7 +43,7 @@ export const PATH_CLASS_RULES: ReadonlyArray<{ re: RegExp; cls: DataClass }> = [{ re: /(?:^|[\s'"`\/=])\.env\b/, cls: "RESTRICTED" },{ re: /PAI\/USER\/CONFIG\/CREDENTIALS\//, cls: "RESTRICTED" },{ re: /PAI\/USER\/WORK\/CUSTOMERS\//, cls: "RESTRICTED" },- { re: /skills\/_RL_/, cls: "RESTRICTED" },+ { re: /skills\/_[A-Z]/, cls: "CONFIDENTIAL" }, // any private (underscore-prefixed) skill dir — generalized off a hardcoded customer prefix. Customer-RESTRICTED data is caught by USER/WORK/CUSTOMERS above + the release deny-list; on the capped GLM route (PUBLIC ceiling) CONFIDENTIAL blocks identically to RESTRICTED.{ re: /PAI\/USER\/TELOS\/FINANCES\//, cls: "RESTRICTED" },{ re: /PAI\/USER\/CONTACTS\.md/, cls: "RESTRICTED" },{ re: /PAI\/MEMORY\/KNOWLEDGE\/(?:People|Companies)\//, cls: "CONFIDENTIAL" },diff --git a/LifeOS/install/hooks/lib/identity.ts b/LifeOS/install/hooks/lib/identity.tsindex 0ae8c067..0ae796f9 100755--- a/LifeOS/install/hooks/lib/identity.ts+++ b/LifeOS/install/hooks/lib/identity.ts@@ -13,18 +13,18 @@import { readFileSync, existsSync } from 'fs';import { join } from 'path';import { parse as parseYaml } from 'yaml';-import { loadPaiConfig } from '../../LIFEOS/TOOLS/PaiConfig';+import { loadLifeosConfig } from '../../LIFEOS/TOOLS/LifeosConfig';const HOME = process.env.HOME!;const SETTINGS_PATH = join(HOME, '.claude/settings.json');-// Identity-file paths derive from PaiConfig's userDir. On fresh installs where+// Identity-file paths derive from LifeosConfig's userDir. On fresh installs where// LIFEOS_CONFIG.toml hasn't been created yet, fall back to the conventional// LIFEOS/USER/ location so identity loading still bootstraps. Lazy try/catch so-// a malformed PaiConfig never breaks identity bootstrap.+// a malformed LifeosConfig never breaks identity bootstrap.function paiUserDir(): string {try {- return loadPaiConfig().paths.userDir;+ return loadLifeosConfig().paths.userDir;} catch {return join(HOME, '.claude/LIFEOS/USER');}diff --git a/LifeOS/install/hooks/lib/isa-utils.ts b/LifeOS/install/hooks/lib/isa-utils.tsindex 3fc6e041..15fe9edc 100755--- a/LifeOS/install/hooks/lib/isa-utils.ts+++ b/LifeOS/install/hooks/lib/isa-utils.ts@@ -1174,12 +1174,12 @@ export function upsertSession(sessionUUID: string, sessionName: string, task: st// Track mode transition if mode changed.// 2026-05-24 (realtime-phase-tracking): one-way upgrade for `algorithm`.- // When EffortRouter's classifier already declared this session as+ // When TheRouter's classifier already declared this session as// currentMode='algorithm', PromptProcessing's local `isNativeMode` regex// must NOT silently downgrade it back to 'native' a tick later. The// classifier is authoritative; this guard preserves its decision.// 2026-07-01: the LEGITIMATE algorithm→native downgrade is recorded by- // EffortRouter (the authoritative classifier) via markSessionNative() —+ // TheRouter (the authoritative classifier) via markSessionNative() —// this guard only blocks PromptProcessing's WEAK regex, never the classifier.const prevMode = session.currentMode || (session.mode === 'starting' ? 'algorithm' : 'native');const isDowngradeFromAlgorithm = prevMode === 'algorithm' && resolvedMode === 'native';@@ -1251,7 +1251,7 @@ export const upsertNativeSession = upsertSession;/*** Mark a session as algorithm-starting in work.json. Called by- * EffortRouter.hook.ts the instant the classifier emits MODE=ALGORITHM, so+ * TheRouter.hook.ts the instant the classifier emits MODE=ALGORITHM, so* the Pulse dashboard shows the session as an algorithm session BEFORE the* model receives the prompt — no "phase: native" wrong-display window.*@@ -1265,18 +1265,18 @@ export const upsertNativeSession = upsertSession;* with currentMode='algorithm', mode='starting', phase='starting'** Side-effect: writes work.json atomically via writeRegistry.- * Best-effort: failures must not break the EffortRouter classification path.+ * Best-effort: failures must not break the TheRouter classification path.*//*** Authoritatively record a session switching BACK to native (algorithm→native),* updating `currentMode` + pushing a `modeHistory` transition so the Pulse* Agents/Lattice dashboard re-lanes the session to the native view and the- * ModeTimeline shows the switch. Called by EffortRouter (the authoritative+ * ModeTimeline shows the switch. Called by TheRouter (the authoritative* classifier) on NATIVE turns.** This is the DOWNGRADE path that `upsertSession` deliberately refuses: that* guard exists to stop PromptProcessing's WEAK 8-verb regex from clobbering the- * classifier's decision a tick later. EffortRouter's classifier is authoritative,+ * classifier's decision a tick later. TheRouter's classifier is authoritative,* so it IS allowed to record the return to native. `currentMode` is what every* dashboard `inferMode`/`resolveMode` reads FIRST, so this alone re-categorizes* the session without touching `phase`/`mode` — safe to resume the algorithm later@@ -1317,7 +1317,7 @@ export function markSessionNative(sessionUUID: string): void {export function markAlgorithmStarting(sessionUUID: string, taskHint: string, tier?: number): void {if (!sessionUUID) return;// Resolved tier ("E1".."E5") persisted onto the row so the Pulse Agents/Lattice- // page shows the correct tier the instant EffortRouter classifies — before any+ // page shows the correct tier the instant TheRouter classifies — before any// ISA exists. Undefined tier leaves the existing effort untouched.const effortStr = (typeof tier === 'number' && tier >= 1 && tier <= 5) ? `E${tier}` : undefined;try {diff --git a/LifeOS/install/hooks/lib/paths.ts b/LifeOS/install/hooks/lib/paths.tsindex e46597d0..205c4ef7 100755--- a/LifeOS/install/hooks/lib/paths.ts+++ b/LifeOS/install/hooks/lib/paths.ts@@ -6,7 +6,7 @@* - Claude home (~/.claude) — Claude Code: settings, skills, hooks, commands, agents** Usage:- * import { getPaiDir, getClaudeDir, paiPath } from '';+ * import { getLifeosDir, getClaudeDir, paiPath } from '';*/import { homedir } from 'os';@@ -40,15 +40,15 @@ export function expandPath(path: string): string {* Resolving via getClaudeDir() + 'LifeOS' keeps the live ~/.claude/LIFEOS →* plugin ${ROOT}/PAI mapping that the packer's ~/.claude/ → ${LIFEOS_DIR} rewrite assumes.*/-export function getPaiDir(): string {+export function getLifeosDir(): string {if (process.env.CLAUDE_PLUGIN_ROOT) {return join(getClaudeDir(), 'LIFEOS');}- const envPaiDir = process.env.LIFEOS_DIR;+ const envLifeosDir = process.env.LIFEOS_DIR;- if (envPaiDir) {- return expandPath(envPaiDir);+ if (envLifeosDir) {+ return expandPath(envLifeosDir);}return join(homedir(), '.claude', 'LIFEOS');@@ -91,7 +91,7 @@ export function getEnvPath(): string {* Get a path relative to LIFEOS_DIR*/export function paiPath(...segments: string[]): string {- return join(getPaiDir(), ...segments);+ return join(getLifeosDir(), ...segments);}/**diff --git a/LifeOS/install/hooks/lib/tab-setter.ts b/LifeOS/install/hooks/lib/tab-setter.tsindex 24efde25..d4f93110 100755--- a/LifeOS/install/hooks/lib/tab-setter.ts+++ b/LifeOS/install/hooks/lib/tab-setter.ts@@ -344,7 +344,7 @@ export function setTabState(opts: SetTabOptions): void {* Set ONLY the leading mode/tier token ("N" | "E1".."E5") on the current tab,* preserving the working description, and clearing any stale completion state.*- * This is the authoritative mode-token writer, called by EffortRouter the moment+ * This is the authoritative mode-token writer, called by TheRouter the moment* it classifies the turn — so the tab projects the real {mode,tier} decision* instead of PromptProcessing's shadow-classifier guess. It is deliberately a* distinct primitive from setTabState (which takes a full title) and setPhaseTabdiff --git a/LifeOS/install/install.sh b/LifeOS/install/install.shindex 1d22d049..832c705e 100755--- a/LifeOS/install/install.sh+++ b/LifeOS/install/install.sh@@ -23,7 +23,7 @@set -euo pipefail# ─── Pinned release ──────────────────────────────────────────────-LIFEOS_VERSION="${LIFEOS_VERSION:-6.0.3}"+LIFEOS_VERSION="${LIFEOS_VERSION:-6.0.5}"LIFEOS_TAG="v${LIFEOS_VERSION}"# Repo owner/name are parameterized — set at publish time, never hard-coded here.LIFEOS_REPO="${LIFEOS_REPO:-danielmiessler/LifeOS}"diff --git a/LifeOS/install/skills/Agents/ArchitectContext.md b/LifeOS/install/skills/Agents/ArchitectContext.mdindex d9647037..ea70fd4f 100755--- a/LifeOS/install/skills/Agents/ArchitectContext.md+++ b/LifeOS/install/skills/Agents/ArchitectContext.md@@ -31,9 +31,9 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Constitutional Foundation-- **PAI/CONSTITUTION.md** - Foundational architectural principles-- **PAI/CoreStack.md** - Stack preferences (TypeScript > Python, bun > npm, etc.)-- **PAI/Architecture.md** - LifeOS's system architecture patterns+- **LIFEOS/CONSTITUTION.md** - Foundational architectural principles+- **LIFEOS/CoreStack.md** - Stack preferences (TypeScript > Python, bun > npm, etc.)+- **LIFEOS/Architecture.md** - LifeOS's system architecture patterns### Development Methodology- **skills/Development/METHODOLOGY.md** - Spec-driven, test-driven development approach@@ -49,7 +49,7 @@ Your prompt includes a `## Scope` section defining your time budget:Load these dynamically based on task keywords:-- **Security** → PAI/SecurityProtocols.md+- **Security** → LIFEOS/SecurityProtocols.md- **Testing** → skills/Development/TESTING.md, skills/Development/TestingPhilosophy.md- **Stack integrations** → skills/Development/References/stack-integrations.mddiff --git a/LifeOS/install/skills/Agents/ArtistContext.md b/LifeOS/install/skills/Agents/ArtistContext.mdindex 5bc937b0..b7cd854b 100755--- a/LifeOS/install/skills/Agents/ArtistContext.md+++ b/LifeOS/install/skills/Agents/ArtistContext.md@@ -31,8 +31,8 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Core Foundations-- **PAI/CoreStack.md** - Stack preferences and tooling-- **PAI/CONSTITUTION.md** - Constitutional principles+- **LIFEOS/CoreStack.md** - Stack preferences and tooling+- **LIFEOS/CONSTITUTION.md** - Constitutional principles### Visual Standards- **skills/Art/SKILL.md** - Art skill workflows and content typesdiff --git a/LifeOS/install/skills/Agents/ClaudeResearcherContext.md b/LifeOS/install/skills/Agents/ClaudeResearcherContext.mdindex 689294b0..53f8b816 100755--- a/LifeOS/install/skills/Agents/ClaudeResearcherContext.md+++ b/LifeOS/install/skills/Agents/ClaudeResearcherContext.md@@ -33,8 +33,8 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Core Foundations-- **PAI/CoreStack.md** - Stack preferences and tooling-- **PAI/CONSTITUTION.md** - Constitutional principles+- **LIFEOS/CoreStack.md** - Stack preferences and tooling+- **LIFEOS/CONSTITUTION.md** - Constitutional principles### Research Standards- **skills/Research/SKILL.md** - Research skill workflows and methodologiesdiff --git a/LifeOS/install/skills/Agents/CodexResearcherContext.md b/LifeOS/install/skills/Agents/CodexResearcherContext.mdindex b8f73174..0a24f3fb 100755--- a/LifeOS/install/skills/Agents/CodexResearcherContext.md+++ b/LifeOS/install/skills/Agents/CodexResearcherContext.md@@ -33,8 +33,8 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Core Foundations-- **PAI/CoreStack.md** - Stack preferences (TypeScript > Python!) and tooling-- **PAI/CONSTITUTION.md** - Constitutional principles+- **LIFEOS/CoreStack.md** - Stack preferences (TypeScript > Python!) and tooling+- **LIFEOS/CONSTITUTION.md** - Constitutional principles### Research Standards- **skills/Research/SKILL.md** - Research skill workflows and methodologiesdiff --git a/LifeOS/install/skills/Agents/DesignerContext.md b/LifeOS/install/skills/Agents/DesignerContext.mdindex 8525f5d6..3e61cbf0 100755--- a/LifeOS/install/skills/Agents/DesignerContext.md+++ b/LifeOS/install/skills/Agents/DesignerContext.md@@ -31,8 +31,8 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Core Foundations-- **PAI/CoreStack.md** - Stack preferences and tooling-- **PAI/CONSTITUTION.md** - Constitutional principles+- **LIFEOS/CoreStack.md** - Stack preferences and tooling+- **LIFEOS/CONSTITUTION.md** - Constitutional principles### Design Standards- **skills/Webdesign/SKILL.md** - Webdesign workflows, Claude Design orchestration, integration-into-app patternsdiff --git a/LifeOS/install/skills/Agents/EngineerContext.md b/LifeOS/install/skills/Agents/EngineerContext.mdindex 112cb6a9..98196354 100755--- a/LifeOS/install/skills/Agents/EngineerContext.md+++ b/LifeOS/install/skills/Agents/EngineerContext.md@@ -31,8 +31,8 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Core Foundations-- **PAI/CoreStack.md** - Stack preferences and tooling-- **PAI/CONSTITUTION.md** - Constitutional principles+- **LIFEOS/CoreStack.md** - Stack preferences and tooling+- **LIFEOS/CONSTITUTION.md** - Constitutional principles### Development Standards- **skills/Development/SKILL.md** - Development workflows and patterns@@ -47,7 +47,7 @@ Your prompt includes a `## Scope` section defining your time budget:Load these dynamically based on task keywords:- **Test/TDD** → skills/Development/TESTING.md, skills/Development/TestingPhilosophy.md-- **Security** → PAI/SecurityProtocols.md+- **Security** → LIFEOS/SecurityProtocols.md- **CLI testing** → skills/Development/References/cli-testing-standards.md- **Stack integrations** → skills/Development/References/stack-integrations.mddiff --git a/LifeOS/install/skills/Agents/GeminiResearcherContext.md b/LifeOS/install/skills/Agents/GeminiResearcherContext.mdindex e84a6e17..757e425f 100755--- a/LifeOS/install/skills/Agents/GeminiResearcherContext.md+++ b/LifeOS/install/skills/Agents/GeminiResearcherContext.md@@ -33,8 +33,8 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Core Foundations-- **PAI/CoreStack.md** - Stack preferences and tooling-- **PAI/CONSTITUTION.md** - Constitutional principles+- **LIFEOS/CoreStack.md** - Stack preferences and tooling+- **LIFEOS/CONSTITUTION.md** - Constitutional principles### Research Standards- **skills/Research/SKILL.md** - Research skill workflows and methodologiesdiff --git a/LifeOS/install/skills/Agents/GrokResearcherContext.md b/LifeOS/install/skills/Agents/GrokResearcherContext.mdindex 9f2a450a..f2dbe761 100755--- a/LifeOS/install/skills/Agents/GrokResearcherContext.md+++ b/LifeOS/install/skills/Agents/GrokResearcherContext.md@@ -33,8 +33,8 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Core Foundations-- **PAI/CoreStack.md** - Stack preferences and tooling-- **PAI/CONSTITUTION.md** - Constitutional principles+- **LIFEOS/CoreStack.md** - Stack preferences and tooling+- **LIFEOS/CONSTITUTION.md** - Constitutional principles### Research Standards- **skills/Research/SKILL.md** - Research skill workflows and methodologiesdiff --git a/LifeOS/install/skills/Agents/PerplexityResearcherContext.md b/LifeOS/install/skills/Agents/PerplexityResearcherContext.mdindex b9e911f0..903653e3 100644--- a/LifeOS/install/skills/Agents/PerplexityResearcherContext.md+++ b/LifeOS/install/skills/Agents/PerplexityResearcherContext.md@@ -33,8 +33,8 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Core Foundations-- **PAI/CoreStack.md** - Stack preferences and tooling-- **PAI/CONSTITUTION.md** - Constitutional principles+- **LIFEOS/CoreStack.md** - Stack preferences and tooling+- **LIFEOS/CONSTITUTION.md** - Constitutional principles### Research Standards- **skills/Research/SKILL.md** - Research skill workflows and methodologiesdiff --git a/LifeOS/install/skills/Agents/QATesterContext.md b/LifeOS/install/skills/Agents/QATesterContext.mdindex 65197776..2813c942 100755--- a/LifeOS/install/skills/Agents/QATesterContext.md+++ b/LifeOS/install/skills/Agents/QATesterContext.md@@ -31,8 +31,8 @@ Your prompt includes a `## Scope` section defining your time budget:## Required Knowledge (Pre-load from Skills)### Core Foundations-- **PAI/CoreStack.md** - Stack preferences and tooling-- **PAI/CONSTITUTION.md** - Constitutional principles (Article IX)+- **LIFEOS/CoreStack.md** - Stack preferences and tooling+- **LIFEOS/CONSTITUTION.md** - Constitutional principles (Article IX)### Testing Standards- **skills/Development/TESTING.md** - Testing standards and requirements@@ -82,7 +82,7 @@ These are already loaded via LifeOS or Development skill - reference, don't dupl## Browser Automation (Constitutional Requirement)-> **Note:** QATester is a DEPRECATED built-in Claude Code agent. Playwright is banned across PAI. For QA work, prefer invoking the **Interceptor** skill directly from the primary DA rather than spawning QATester. If QATester is spawned anyway, its built-in tool cannot be modified, but you (QATester) must treat screenshots/reports as advisory only and remind the caller that Interceptor is the supported path.+> **Note:** QATester is a DEPRECATED built-in Claude Code agent. Playwright is banned across LifeOS. For QA work, prefer invoking the **Interceptor** skill directly from the primary DA rather than spawning QATester. If QATester is spawned anyway, its built-in tool cannot be modified, but you (QATester) must treat screenshots/reports as advisory only and remind the caller that Interceptor is the supported path.**Interceptor is THE EXCLUSIVE TOOL for QA validation.**diff --git a/LifeOS/install/skills/Agents/REDESIGN-SUMMARY.md b/LifeOS/install/skills/Agents/REDESIGN-SUMMARY.mdindex d65fcb13..cfcc2c4d 100755--- a/LifeOS/install/skills/Agents/REDESIGN-SUMMARY.md+++ b/LifeOS/install/skills/Agents/REDESIGN-SUMMARY.md@@ -67,12 +67,12 @@ Example: `ArchitectContext.md`**Model**: opus## Required Knowledge (Pre-load from Skills)-- **PAI/CONSTITUTION.md** - Foundational principles-- **PAI/CoreStack.md** - Stack preferences+- **LIFEOS/CONSTITUTION.md** - Foundational principles+- **LIFEOS/CoreStack.md** - Stack preferences## Task-Specific Knowledge- **api** → skills/Development/References/APIDesign.md-- **security** → PAI/SecurityProtocols.md+- **security** → LIFEOS/SecurityProtocols.md```### 2. Simple Loader Reads Contextdiff --git a/LifeOS/install/skills/Apify/INTEGRATION.md b/LifeOS/install/skills/Apify/INTEGRATION.mdindex 5aff3fde..dbc9ad9d 100755--- a/LifeOS/install/skills/Apify/INTEGRATION.md+++ b/LifeOS/install/skills/Apify/INTEGRATION.md@@ -231,4 +231,4 @@ A: Use `debug-tweet-structure.ts` to inspect raw data, check console output.- ✅ 4 production-ready scripts- ✅ Comprehensive documentation-**This is now the standard for all Twitter operations in PAI.**+**This is now the standard for all Twitter operations in LifeOS.**diff --git a/LifeOS/install/skills/Art/SKILL.md b/LifeOS/install/skills/Art/SKILL.mdindex 87d645a3..c9ea4bd5 100644--- a/LifeOS/install/skills/Art/SKILL.md+++ b/LifeOS/install/skills/Art/SKILL.md@@ -1,6 +1,6 @@---name: Art-description: "Static visual content across 20+ formats via Flux, Nano Banana Pro (Gemini 3 Pro), and GPT-Image-2. Workflows: Essay, D3Dashboards, Visualize, Mermaid, TechnicalDiagrams, Taxonomies, Timelines, Frameworks, Comparisons, AnnotatedScreenshots, RecipeCards, Aphorisms, Maps, Stats, Comics, StyleMatchedThumbnail, YouTubeThumbnailChecklist, AdHocYouTubeThumbnail, CreatePAIPackIcon, LogoWallpaper, EmbossedLogoWallpaper, RemoveBackground. Output staged to ~/Downloads/ before project copy; --remove-bg returns transparent PNG; user customization dir overrides defaults (model/size flag details in body). USE WHEN art, illustration, diagram, flowchart, infographic, header image, blog social thumbnail, visualize, generate image, mermaid, architecture diagram, comic, icon, blog art, framework diagram, D3 chart, remove background, wallpaper. NOT FOR locked house-style YouTube/channel/video thumbnails (use _THUMBNAIL — it orchestrates Art's Generate/PickExpression/ThumbnailText tools), video or animation (use Remotion), or web UI design and integrated frontend layout (use Webdesign)."+description: "Static visual content across 20+ formats via Flux, Nano Banana Pro (Gemini 3 Pro), and GPT-Image-2. Workflows: Essay, D3Dashboards, Visualize, Mermaid, TechnicalDiagrams, Taxonomies, Timelines, Frameworks, Comparisons, AnnotatedScreenshots, RecipeCards, Aphorisms, Maps, Stats, Comics, StyleMatchedThumbnail, YouTubeThumbnailChecklist, AdHocYouTubeThumbnail, CreateLifeosPackIcon, LogoWallpaper, EmbossedLogoWallpaper, RemoveBackground. Output staged to ~/Downloads/ before project copy; --remove-bg returns transparent PNG; user customization dir overrides defaults (model/size flag details in body). USE WHEN art, illustration, diagram, flowchart, infographic, header image, blog social thumbnail, visualize, generate image, mermaid, architecture diagram, comic, icon, blog art, framework diagram, D3 chart, remove background, wallpaper. NOT FOR locked house-style YouTube/channel/video thumbnails (use _THUMBNAIL — it orchestrates Art's Generate/PickExpression/ThumbnailText tools), video or animation (use Remotion), or web UI design and integrated frontend layout (use Webdesign)."effort: medium---@@ -183,7 +183,7 @@ Route to the appropriate workflow based on the request.| Comics | Comic or sequential panels | `Workflows/Comics.md` || YouTubeThumbnailChecklist | YouTube thumbnail checklist; YouTube thumbnail (with existing assets) | `Workflows/YouTubeThumbnailChecklist.md` || AdHocYouTubeThumbnail | Ad-hoc YouTube thumbnail (generate from content) | `Workflows/AdHocYouTubeThumbnail.md` |-| CreatePAIPackIcon | LifeOS pack icon | `Workflows/CreateLifeosPackIcon.md` |+| CreateLifeosPackIcon | LifeOS pack icon | `Workflows/CreateLifeosPackIcon.md` |---@@ -335,7 +335,7 @@ User: "create icon for the skill system pack"→ Generates 1K image with --remove-bg for transparency→ Resizes to 256x256 RGBA PNG→ Outputs to ~/Downloads/ for preview-→ After approval, copies to ${PROJECTS_DIR}/PAI/Packs/icons/+→ After approval, copies to ${PROJECTS_DIR}/LIFEOS/Packs/icons/```## Gotchasdiff --git a/LifeOS/install/skills/Art/Workflows/CreateLifeosPackIcon.md b/LifeOS/install/skills/Art/Workflows/CreateLifeosPackIcon.mdindex 16a97ad3..cb115f1c 100644--- a/LifeOS/install/skills/Art/Workflows/CreateLifeosPackIcon.md+++ b/LifeOS/install/skills/Art/Workflows/CreateLifeosPackIcon.md@@ -7,11 +7,11 @@```bashcurl -s -X POST http://localhost:31337/notify \-H "Content-Type: application/json" \- -d '{"message": "Running the CreatePAIPackIcon workflow in the Art skill to generate pack icons"}' \+ -d '{"message": "Running the CreateLifeosPackIcon workflow in the Art skill to generate pack icons"}' \> /dev/null 2>&1 &```-Running **CreatePAIPackIcon** in **Art**...+Running **CreateLifeosPackIcon** in **Art**...---@@ -92,13 +92,13 @@ BACKGROUND: Dark (#0a0a0f) - will be removed for transparency.**Command:**```bashbun run ~/.claude/skills/Art/Tools/Generate.ts \- --workflow=CreatePAIPackIcon \+ --workflow=CreateLifeosPackIcon \--model nano-banana-pro \--prompt "[YOUR_PROMPT]" \--size 1K \--aspect-ratio 1:1 \--remove-bg \- --output ${PROJECTS_DIR}/PAI/Packs/icons/[PACK_NAME].png+ --output ${PROJECTS_DIR}/LIFEOS/Packs/icons/[PACK_NAME].png```**Flags explained:**@@ -112,10 +112,10 @@ bun run ~/.claude/skills/Art/Tools/Generate.ts \Check the generated icon:```bash# Verify file exists and size-ls -la ${PROJECTS_DIR}/PAI/Packs/icons/[PACK_NAME].png+ls -la ${PROJECTS_DIR}/LIFEOS/Packs/icons/[PACK_NAME].png# Check dimensions (requires imagemagick)-file ${PROJECTS_DIR}/PAI/Packs/icons/[PACK_NAME].png+file ${PROJECTS_DIR}/LIFEOS/Packs/icons/[PACK_NAME].png```**Verification checklist:**@@ -134,39 +134,39 @@ file ${PROJECTS_DIR}/PAI/Packs/icons/[PACK_NAME].png```bashbun run ~/.claude/skills/Art/Tools/Generate.ts \- --workflow=CreatePAIPackIcon \+ --workflow=CreateLifeosPackIcon \--model nano-banana-pro \--prompt "A stylized hook or fishing hook shape representing event hooks in software, simple flat icon design, 256x256 pixels. COLOR PALETTE: Primary electric blue (#4a90d9), Accent purple (#8b5cf6) sparingly. STYLE: Modern flat icon, simple enough to read at 64x64, no text, centered. BACKGROUND: Dark (#0a0a0f)." \--size 1K \--aspect-ratio 1:1 \--remove-bg \- --output ${PROJECTS_DIR}/PAI/Packs/icons/pai-hook-system.png+ --output ${PROJECTS_DIR}/LIFEOS/Packs/icons/pai-hook-system.png```### Example 2: Core Install Pack```bashbun run ~/.claude/skills/Art/Tools/Generate.ts \- --workflow=CreatePAIPackIcon \+ --workflow=CreateLifeosPackIcon \--model nano-banana-pro \--prompt "A download arrow pointing into a foundation/base structure representing core installation, simple flat icon design, 256x256 pixels. COLOR PALETTE: Primary electric blue (#4a90d9), Accent purple (#8b5cf6) sparingly. STYLE: Modern flat icon, simple enough to read at 64x64, no text, centered. BACKGROUND: Dark (#0a0a0f)." \--size 1K \--aspect-ratio 1:1 \--remove-bg \- --output ${PROJECTS_DIR}/PAI/Packs/icons/pai-core-install.png+ --output ${PROJECTS_DIR}/LIFEOS/Packs/icons/pai-core-install.png```### Example 3: Memory System Pack```bashbun run ~/.claude/skills/Art/Tools/Generate.ts \- --workflow=CreatePAIPackIcon \+ --workflow=CreateLifeosPackIcon \--model nano-banana-pro \--prompt "A brain with memory/data flowing in and out representing an AI memory system, simple flat icon design, 256x256 pixels. COLOR PALETTE: Primary electric blue (#4a90d9), Accent purple (#8b5cf6) sparingly. STYLE: Modern flat icon, simple enough to read at 64x64, no text, centered. BACKGROUND: Dark (#0a0a0f)." \--size 1K \--aspect-ratio 1:1 \--remove-bg \- --output ${PROJECTS_DIR}/PAI/Packs/icons/pai-memory-system.png+ --output ${PROJECTS_DIR}/LIFEOS/Packs/icons/pai-memory-system.png```---@@ -175,7 +175,7 @@ bun run ~/.claude/skills/Art/Tools/Generate.ts \All LifeOS pack icons go to:```-${PROJECTS_DIR}/PAI/Packs/icons/[PACK_NAME].png+${PROJECTS_DIR}/LIFEOS/Packs/icons/[PACK_NAME].png```**Naming convention:** Match the pack directory name exactly.@@ -199,7 +199,7 @@ If an icon needs to be regenerated:Before marking icon complete:-- [ ] **Exists** at `${PROJECTS_DIR}/PAI/Packs/icons/[PACK_NAME].png`+- [ ] **Exists** at `${PROJECTS_DIR}/LIFEOS/Packs/icons/[PACK_NAME].png`- [ ] **Format** is PNG with transparency- [ ] **Size** approximately 256x256- [ ] **Colors** use blue primary, purple accent@@ -213,7 +213,7 @@ Before marking icon complete:- `~/.claude/skills/_LIFEOS/Workflows/CreateRelease.md` - Release workflow (may include icon generation)-*Note: Previously referenced CreatePack.md, ValidatePack.md, and PAIIntegrityCheck.md have been removed.*+*Note: Previously referenced CreatePack.md, ValidatePack.md, and LifeosIntegrityCheck.md have been removed.*---diff --git a/LifeOS/install/skills/BrightData/SKILL.md b/LifeOS/install/skills/BrightData/SKILL.mdindex d36063ac..018926e7 100644--- a/LifeOS/install/skills/BrightData/SKILL.md+++ b/LifeOS/install/skills/BrightData/SKILL.md@@ -1,6 +1,6 @@---name: BrightData-description: "4-tier progressive scraping with automatic escalation: Tier 1 WebFetch, Tier 2 curl with Chrome headers, Tier 3 agent-browser (headless JS rendering), Tier 4 Bright Data MCP proxy (CAPTCHA, advanced bot detection, residential proxies). Two workflows: FourTierScrape for single URLs, Crawl for multi-page site mapping (light crawl up to 50 pages, Crawl API for full sites). Starts at Tier 1, escalates only when blocked — Tier 4 has usage costs. Output is markdown. Playwright is banned across PAI. USE WHEN Bright Data, scrape URL, web scraping, bot detection, crawl site, CAPTCHA, can't access, site blocking, extract page content, scrape whole site, spider domain, convert URL to markdown, getting blocked. NOT FOR simple public content (use WebFetch directly), social platform scraping with named actors (use Apify), parallel headless automation with persistent auth profiles (use Browser), or real-Chrome bot bypass with logged-in sessions and zero CDP fingerprint (use Interceptor)."+description: "4-tier progressive scraping with automatic escalation: Tier 1 WebFetch, Tier 2 curl with Chrome headers, Tier 3 agent-browser (headless JS rendering), Tier 4 Bright Data MCP proxy (CAPTCHA, advanced bot detection, residential proxies). Two workflows: FourTierScrape for single URLs, Crawl for multi-page site mapping (light crawl up to 50 pages, Crawl API for full sites). Starts at Tier 1, escalates only when blocked — Tier 4 has usage costs. Output is markdown. Playwright is banned across LifeOS. USE WHEN Bright Data, scrape URL, web scraping, bot detection, crawl site, CAPTCHA, can't access, site blocking, extract page content, scrape whole site, spider domain, convert URL to markdown, getting blocked. NOT FOR simple public content (use WebFetch directly), social platform scraping with named actors (use Apify), parallel headless automation with persistent auth profiles (use Browser), or real-Chrome bot bypass with logged-in sessions and zero CDP fingerprint (use Interceptor)."effort: medium---@@ -47,7 +47,7 @@ Progressive escalation, always starting at Tier 1 and stepping up only on failur1. **Tier 1: WebFetch** — fast, built-in.2. **Tier 2: curl with Chrome headers** — bypasses basic user-agent bot detection.-3. **Tier 3: agent-browser** — headless browser via the agent-browser Rust CLI daemon for JavaScript rendering. Playwright is banned across PAI.+3. **Tier 3: agent-browser** — headless browser via the agent-browser Rust CLI daemon for JavaScript rendering. Playwright is banned across LifeOS.4. **Tier 4: Bright Data MCP** — proxy service that handles CAPTCHA and advanced bot detection.Content is preserved in markdown at every tier. The Crawl workflow extends this to multiple pages — a light crawl loops the MCP batch scraper plus link extraction up to 50 pages, a full crawl uses the Bright Data Crawl API for entire sites.@@ -117,7 +117,7 @@ FourTierScrape executes the progressive escalation (WebFetch → Curl → agent-**Progressive Escalation Strategy:**1. **Tier 1: WebFetch** - Fast, simple, built-in Claude Code tool2. **Tier 2: Customized Curl** - Chrome-like browser headers to bypass basic bot detection-3. **Tier 3: agent-browser** - Headless browser automation via agent-browser Rust CLI daemon for JavaScript-heavy sites. Playwright is banned across PAI.+3. **Tier 3: agent-browser** - Headless browser automation via agent-browser Rust CLI daemon for JavaScript-heavy sites. Playwright is banned across LifeOS.4. **Tier 4: Bright Data MCP** - Professional scraping service that handles CAPTCHA and advanced bot detection**Key Features:**@@ -221,7 +221,7 @@ Skill Response:## Gotchas-- **4-tier escalation: WebFetch → curl → agent-browser → Bright Data proxy.** Always start at Tier 1 and escalate only when blocked. Playwright is banned across PAI.+- **4-tier escalation: WebFetch → curl → agent-browser → Bright Data proxy.** Always start at Tier 1 and escalate only when blocked. Playwright is banned across LifeOS.- **Bright Data proxy has usage costs.** Don't use Tier 4 for sites accessible via Tier 1-3.- **CAPTCHA-solving introduces latency.** Allow extra time for Tier 4 responses.- **Credentials in `~/.claude/.env`** — BRIGHTDATA_API_KEY.diff --git a/LifeOS/install/skills/BrightData/Workflows/FourTierScrape.md b/LifeOS/install/skills/BrightData/Workflows/FourTierScrape.mdindex bf40e7ea..a2993799 100755--- a/LifeOS/install/skills/BrightData/Workflows/FourTierScrape.md+++ b/LifeOS/install/skills/BrightData/Workflows/FourTierScrape.md@@ -107,7 +107,7 @@ curl -L -A "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (### Step 3: Tier 3 - Browser Automation (agent-browser)-**Description:** Use headless browser automation via agent-browser (Rust CLI daemon) to handle JavaScript-heavy sites. Playwright is banned across PAI.+**Description:** Use headless browser automation via agent-browser (Rust CLI daemon) to handle JavaScript-heavy sites. Playwright is banned across LifeOS.**Actions:**```bashdiff --git a/LifeOS/install/skills/CreateCLI/SKILL.md b/LifeOS/install/skills/CreateCLI/SKILL.mdindex 484abe14..5bbd01e3 100644--- a/LifeOS/install/skills/CreateCLI/SKILL.md+++ b/LifeOS/install/skills/CreateCLI/SKILL.md@@ -175,7 +175,7 @@ Generated CLIs follow LifeOS standards:Generated CLIs go to:- `~/.claude/LIFEOS/TOOLS/[cli-name]/` - Personal CLIs (like llcli)- `~/Projects/[project-name]/` - Project-specific CLIs-- `${PROJECTS_DIR}/PAI/Examples/clis/` - Example CLIs (PUBLIC repo)+- `${PROJECTS_DIR}/LIFEOS/Examples/clis/` - Example CLIs (PUBLIC repo)**SAFETY:** Always verify repository location before git operationsdiff --git a/LifeOS/install/skills/Evals/Scenarios/example-greeting.scenario.ts b/LifeOS/install/skills/Evals/Scenarios/example-greeting.scenario.tsindex df7ca43f..eb9d90ea 100644--- a/LifeOS/install/skills/Evals/Scenarios/example-greeting.scenario.ts+++ b/LifeOS/install/skills/Evals/Scenarios/example-greeting.scenario.ts@@ -1,7 +1,7 @@/*** example-greeting.scenario.ts*- * Minimum-viable scenario demonstrating PAIAgentAdapter + scenario.userSimulatorAgent+ * Minimum-viable scenario demonstrating LifeosAgentAdapter + scenario.userSimulatorAgent* + scenario.judgeAgent. The "agent under test" is a plain LifeOS-Inference call.** Run:@@ -10,14 +10,14 @@* *** API KEY BILLING WARNING **** @langwatch/scenario userSimulatorAgent and judgeAgent use @ai-sdk/anthropic* which bills ANTHROPIC_API_KEY directly, NOT the subscription. Running a- * scenario consumes API credit. The agent-under-test (PAIAgentAdapter) still+ * scenario consumes API credit. The agent-under-test (LifeosAgentAdapter) still* routes through Inference.ts subscription — only the sim + judge billing is* the API. Set EVALS_ALLOW_API_BILLING=1 to acknowledge and run.*/import { anthropic } from '@ai-sdk/anthropic';import scenario, { type ScenarioConfig } from '@langwatch/scenario';-import { PAIAgentAdapter } from '../Tools/LifeosAgentAdapter.ts';+import { LifeosAgentAdapter } from '../Tools/LifeosAgentAdapter.ts';if (process.env.EVALS_ALLOW_API_BILLING !== '1') {throw new Error(@@ -32,7 +32,7 @@ const config: ScenarioConfig = {description:'A user greets a general-purpose assistant. The assistant should respond politely, in English, and keep the response concise.',agents: [- new PAIAgentAdapter({+ new LifeosAgentAdapter({name: 'pai-assistant',systemPrompt: 'You are a concise, polite assistant. Keep replies under 40 words.',level: 'low',diff --git a/LifeOS/install/skills/Evals/Tools/LifeosAgentAdapter.ts b/LifeOS/install/skills/Evals/Tools/LifeosAgentAdapter.tsindex f12d8d3d..07cae2f7 100644--- a/LifeOS/install/skills/Evals/Tools/LifeosAgentAdapter.ts+++ b/LifeOS/install/skills/Evals/Tools/LifeosAgentAdapter.ts@@ -1,6 +1,6 @@#!/usr/bin/env bun/**- * PAIAgentAdapter — wraps LifeOS's Inference.ts as a scenario AgentAdapter.+ * LifeosAgentAdapter — wraps LifeOS's Inference.ts as a scenario AgentAdapter.** Lets scenario.run() drive a LifeOS agent in multi-turn simulations without* pulling in the ai-sdk Anthropic provider for the agent-under-test path@@ -10,19 +10,19 @@import { inference, type InferenceLevel } from '../../../LIFEOS/TOOLS/Inference.ts';import { AgentAdapter, AgentRole, type AgentInput, type AgentReturnTypes } from '@langwatch/scenario';-export interface PAIAgentAdapterOptions {+export interface LifeosAgentAdapterOptions {systemPrompt?: string;level?: InferenceLevel;timeout?: number;name?: string;}-export class PAIAgentAdapter extends AgentAdapter {+export class LifeosAgentAdapter extends AgentAdapter {override role = AgentRole.AGENT;override name: string;- private opts: Required<Omit<PAIAgentAdapterOptions, 'name'>>;+ private opts: Required<Omit<LifeosAgentAdapterOptions, 'name'>>;- constructor(options: PAIAgentAdapterOptions = {}) {+ constructor(options: LifeosAgentAdapterOptions = {}) {super();this.name = options.name ?? 'pai-agent';this.opts = {@@ -43,7 +43,7 @@ export class PAIAgentAdapter extends AgentAdapter {});if (!result.success) {- throw new Error(`PAIAgentAdapter inference failed: ${result.error ?? 'unknown error'}`);+ throw new Error(`LifeosAgentAdapter inference failed: ${result.error ?? 'unknown error'}`);}return result.output.trim();diff --git a/LifeOS/install/skills/Evals/Workflows/CompareModels.md b/LifeOS/install/skills/Evals/Workflows/CompareModels.mdindex 446c7e99..a58311a7 100755--- a/LifeOS/install/skills/Evals/Workflows/CompareModels.md+++ b/LifeOS/install/skills/Evals/Workflows/CompareModels.md@@ -115,8 +115,8 @@ Each run's `results.json` lands at `~/.claude/LIFEOS/MEMORY/STATE/Evals-Results/### Step 5: Collect ResultsResults stored in:-- `PAI/MEMORY/STATE/Evals-Results/<use-case>/models/<run-id>/`-- `PAI/MEMORY/STATE/Evals-Results/<use-case>/models/<run-id>/comparison.json`+- `LIFEOS/MEMORY/STATE/Evals-Results/<use-case>/models/<run-id>/`+- `LIFEOS/MEMORY/STATE/Evals-Results/<use-case>/models/<run-id>/comparison.json`### Step 6: Generate Comparison Reportdiff --git a/LifeOS/install/skills/Evals/Workflows/ComparePrompts.md b/LifeOS/install/skills/Evals/Workflows/ComparePrompts.mdindex 264206f6..7100b7cd 100755--- a/LifeOS/install/skills/Evals/Workflows/ComparePrompts.md+++ b/LifeOS/install/skills/Evals/Workflows/ComparePrompts.md@@ -140,7 +140,7 @@ This addresses the known bias where LLMs favor the first option presented.### Step 6: Collect ResultsResults stored in:-- `PAI/MEMORY/STATE/Evals-Results/<use-case>/comparisons/<comparison-name>/<run-id>.json`+- `LIFEOS/MEMORY/STATE/Evals-Results/<use-case>/comparisons/<comparison-name>/<run-id>.json`Results structure:```jsondiff --git a/LifeOS/install/skills/Evals/Workflows/CreateScenario.md b/LifeOS/install/skills/Evals/Workflows/CreateScenario.mdindex 4b34aa8d..2c4b0d93 100644--- a/LifeOS/install/skills/Evals/Workflows/CreateScenario.md+++ b/LifeOS/install/skills/Evals/Workflows/CreateScenario.md@@ -28,7 +28,7 @@ Ask for and confirm:```tsimport { anthropic } from '@ai-sdk/anthropic';import scenario, { type ScenarioConfig } from '@langwatch/scenario';- import { PAIAgentAdapter } from '../Tools/LifeosAgentAdapter.ts';+ import { LifeosAgentAdapter } from '../Tools/LifeosAgentAdapter.ts';const judgeModel = anthropic('claude-sonnet-4-6');@@ -36,7 +36,7 @@ Ask for and confirm:name: '<scenario-name>',description: '<what happens in plain English>',agents: [- new PAIAgentAdapter({+ new LifeosAgentAdapter({name: '<agent-name>',systemPrompt: '<system prompt for the agent under test>',level: 'medium',diff --git a/LifeOS/install/skills/Evals/Workflows/RunEval.md b/LifeOS/install/skills/Evals/Workflows/RunEval.mdindex 8d55d2f9..98245553 100755--- a/LifeOS/install/skills/Evals/Workflows/RunEval.md+++ b/LifeOS/install/skills/Evals/Workflows/RunEval.md@@ -48,7 +48,7 @@ bun run ~/.claude/skills/Evals/Tools/AlgorithmBridge.ts -s <use-case> --show-sat### Step 3: Collect ResultsResults are stored in:-- `PAI/MEMORY/STATE/Evals-Results/<use-case>/<run-id>/results.json` (per-run output)+- `LIFEOS/MEMORY/STATE/Evals-Results/<use-case>/<run-id>/results.json` (per-run output)- Use case directory: `UseCases/<use-case>/` (source of truth)### Step 5: Report Summarydiff --git a/LifeOS/install/skills/Evals/Workflows/RunScenario.md b/LifeOS/install/skills/Evals/Workflows/RunScenario.mdindex b5dd458b..5d3ef561 100644--- a/LifeOS/install/skills/Evals/Workflows/RunScenario.md+++ b/LifeOS/install/skills/Evals/Workflows/RunScenario.md@@ -26,7 +26,7 @@ Run a multi-turn agent scenario — simulated user drives N-turn conversation agbun run Tools/ScenarioRunner.ts --scenario Scenarios/<name>.scenario.ts```-3. **Inspect the output** in `PAI/MEMORY/STATE/Evals-Results/<scenario-id>/<run-id>/`:+3. **Inspect the output** in `LIFEOS/MEMORY/STATE/Evals-Results/<scenario-id>/<run-id>/`:- `run.json` — the full `EvalRun` with pass rates, pass@k, pass^k- `transcripts/trial_N.json` — per-trial `Trial` with `Transcript` + judge `GraderResult`diff --git a/LifeOS/install/skills/Evals/Workflows/ViewResults.md b/LifeOS/install/skills/Evals/Workflows/ViewResults.mdindex fd480070..cb82cf6c 100755--- a/LifeOS/install/skills/Evals/Workflows/ViewResults.md+++ b/LifeOS/install/skills/Evals/Workflows/ViewResults.md@@ -23,7 +23,7 @@ Per-run output (source of truth):~/.claude/LIFEOS/MEMORY/STATE/Evals-Results/<use-case>/<run-id>/results.json```-Each `results.json` contains the run summary, per-trial scores, grader outputs, and failure details. The `PAI/MEMORY/STATE/Evals-Results/` directory is the canonical store — query it with standard tools (`jq`, `rg`, `cat`).+Each `results.json` contains the run summary, per-trial scores, grader outputs, and failure details. The `LIFEOS/MEMORY/STATE/Evals-Results/` directory is the canonical store — query it with standard tools (`jq`, `rg`, `cat`).---@@ -102,4 +102,4 @@ There is no built-in CLI for trend analysis, regression detection, or cross-run## Done-Results inspected from `PAI/MEMORY/STATE/Evals-Results/<use-case>/<run-id>/results.json` and (optionally) suite saturation surfaced via `SuiteManager.ts`.+Results inspected from `LIFEOS/MEMORY/STATE/Evals-Results/<use-case>/<run-id>/results.json` and (optionally) suite saturation surfaced via `SuiteManager.ts`.diff --git a/LifeOS/install/skills/Hardening/SKILL.md b/LifeOS/install/skills/Hardening/SKILL.mdindex 0eb71844..ba2abb64 100644--- a/LifeOS/install/skills/Hardening/SKILL.md+++ b/LifeOS/install/skills/Hardening/SKILL.md@@ -48,7 +48,7 @@ All five satisfy the same intent: **strengthen the test of the test, the test of- **Testing Doctrine Rule #11** — names fast-check as the property-testing primitive (`LIFEOS/DOCUMENTATION/Testing/TestingDoctrine.md`).- **ISA format** — new `bun-property` ISC type with `property | generator | runs` columns (`LIFEOS/DOCUMENTATION/Isa/IsaFormat.md` § ISC Type Vocabulary).- **Algorithm v6.10.0 candidate** — VERIFY-phase Hardening gate at E4/E5; `PropertyAudit` as capability #20 (`LIFEOS/ALGORITHM/v6.10.0.md`).-- **System prompt** — Verification Is the Mechanism section at top (`PAI/LIFEOS_SYSTEM_PROMPT.md`).+- **System prompt** — Verification Is the Mechanism section at top (`LIFEOS/LIFEOS_SYSTEM_PROMPT.md`).- **BitterPillEngineering skill** — `AcceptanceTestMutation` is the mechanized form of BPE's "would a smarter model render this rule unnecessary" applied to ISCs.## Gotchasdiff --git a/LifeOS/install/skills/Hardening/Workflows/PropertyTest.md b/LifeOS/install/skills/Hardening/Workflows/PropertyTest.mdindex 5ec0c12e..95e7b61f 100644--- a/LifeOS/install/skills/Hardening/Workflows/PropertyTest.md+++ b/LifeOS/install/skills/Hardening/Workflows/PropertyTest.md@@ -38,7 +38,7 @@ If none apply, skip property testing — use `bun-test` example form for the ISC| 7 | **Model-based** | code matches trivial reference impl | `parseFrontmatter ≡ jsYaml.load + body-split` || 8 | **Metamorphic** | "if input grows, output should grow" | density-score is monotone in evidence count || 9 | **State-machine** | any legal sequence preserves invariants | ISA phase machine never goes backward except via Resume |-| 10 | **Oracle** | result matches trusted alternative | EffortRouter classifier vs deterministic rule table |+| 10 | **Oracle** | result matches trusted alternative | TheRouter classifier vs deterministic rule table |## Candidate detection — ten questionsdiff --git a/LifeOS/install/skills/Harvest/SKILL.md b/LifeOS/install/skills/Harvest/SKILL.mdnew file mode 100644index 00000000..057a9bac--- /dev/null+++ b/LifeOS/install/skills/Harvest/SKILL.md@@ -0,0 +1,59 @@+---+name: Harvest+description: "Mine a single piece of content (URL, YouTube video, article, raw text, or file) for anything genuinely useful to LifeOS, judged against the whole system — TELOS, the Algorithm, skills, hooks, memory, Pulse, routing, doctrine. Fetches it, extracts candidate ideas/techniques/patterns/tools/framings, tags each with a Prior Status (NEW/PARTIAL/DONE/REJECTED), ranks by usefulness × novelty × effort, and reports where each maps and how we would use it. Report-only; adopting anything is a separate approved step. USE WHEN harvest, harvest this, harvest <URL>, harvest <YouTube>, harvest this video, harvest this article, /harvest, /ha, mine this for the system, anything useful in this for us, what can LifeOS take from this, analyze this for LifeOS-usefulness, should we adopt anything from this. NOT FOR ingesting content into the Knowledge Archive (use _HARVEST), broad multi-source upgrade or bookmark scans (use Upgrade / pu), or general research synthesis (use Research)."+license: public+---++# Harvest++Take one piece of content and ask a single question: **is there anything in here worth pulling into LifeOS?** Read it, hold every candidate idea against what the system already is and already has, and report what is worth adopting, where it maps, and how we would use it. Report-only. Adoption is a separate, approved step.++## Workflow Routing++| Trigger | Workflow |+|---------|----------|+| `harvest <url>`, `harvest this`, `/harvest`, `/ha`, "mine this for the system", "anything useful in this for us" | `Workflows/Harvest.md` |++## Quick Reference++- **One input at a time.** A URL, a YouTube link, an article, a raw paste, or a file path.+- **Fetch first, then judge.** YouTube → `fabric -y <url>` for the transcript. Article → WebFetch or Research. File → Read. Raw text → use as-is.+- **Judge against the real system, not a guess of it.** Map each candidate to a concrete surface: an Algorithm phase or gate, a hook, a specific skill, the memory system, Pulse, routing/EFFORT_MODEL, ISA, or a doctrine file. If you can't name the surface, it isn't a harvest hit yet.+- **Prior Status is the honesty check.** NEW / PARTIAL (we have something close) / DONE (already implemented) / REJECTED (considered and declined). Cross-check before calling anything NEW.+- **Output is a ranked table plus an honest verdict.** Rank by usefulness × novelty × effort. If nothing is worth adopting, say so plainly — a clean "nothing here" beats manufactured findings.++## Relationship to neighbors++- **`_HARVEST`** ingests a signal into the Knowledge Archive (a note gets written). Harvest writes nothing; it evaluates content *for the system*.+- **`Upgrade` / `pu`** scans many sources (Anthropic releases, YouTube channels, GitHub, bookmarks) for upgrades. Harvest is the focused single-input cousin: you hand it one thing, it mines that one thing.+- **`Research`** answers a question from many sources. Harvest starts from a source you already have and asks what LifeOS should take from it.++## Gotchas++- **YouTube needs `fabric -y` first.** Never parse the YouTube page HTML — it's nav and JS. `fabric -y <url>` returns the transcript; analyze that.+- **Report-only. Never edit the system from inside a harvest.** The output is a proposal set. Changing an Algorithm file, a hook, a skill, or doctrine happens only after {{PRINCIPAL_NAME}} approves a specific item.+- **Name the surface or drop the finding.** "This is a cool idea" is not a harvest hit. "This maps to a new PostToolUse hook that would catch X" is. Vague usefulness gets cut.+- **Prior Status prevents re-surfacing solved work.** Before tagging NEW, check whether LifeOS already does it (grep skills/hooks, recall recent ISAs). Re-pitching something already built is the main failure mode.+- **Be honest about empty content.** A lot of content has nothing to harvest. Say that. Manufacturing three weak findings to look thorough is worse than one true "nothing here."+- **Not the Knowledge Archive.** If {{PRINCIPAL_NAME}} actually wants the content *saved* as a note, that's `_HARVEST`, not this.++## Examples++```+harvest https://youtu.be/VIDEO_ID+# → fabric -y transcript → extract candidates → map to LifeOS surfaces → ranked table + verdict++harvest https://someblog.com/post-on-agent-memory+# → WebFetch body → same analysis++harvest "long pasted idea about a new eval technique..."+# → analyze the text directly+```++## Execution Log++After completing the workflow, append a single JSONL entry:++```bash+echo '{"ts":"'$(date -u +%Y-%m-%dT%H:%M:%SZ)'","skill":"Harvest","workflow":"Harvest","input":"8_WORD_SUMMARY","status":"ok|error","duration_s":SECONDS}' >> ~/.claude/LIFEOS/MEMORY/SKILLS/execution.jsonl+```diff --git a/LifeOS/install/skills/Harvest/Workflows/Harvest.md b/LifeOS/install/skills/Harvest/Workflows/Harvest.mdnew file mode 100644index 00000000..a0a80c54--- /dev/null+++ b/LifeOS/install/skills/Harvest/Workflows/Harvest.md@@ -0,0 +1,77 @@+# Harvest Workflow++**Goal:** Turn one piece of content into a ranked, honest list of what LifeOS should take from it. Report-only.++## Step 1 — Detect input type++Classify the argument:++- `youtu.be/…` or `youtube.com/…` → **YouTube**+- Any other `http(s)://…` → **Article/URL**+- A path that exists on disk → **File**+- Anything else → **Raw text**++## Step 2 — Fetch the content++| Type | How |+|------|-----|+| YouTube | `fabric -y "<url>"` → transcript. Never scrape the page HTML. |+| Article/URL | `WebFetch` the URL for the body. If it's blocked or thin, escalate to the Research skill. |+| File | `Read` the file. |+| Raw text | Use the provided text directly. |++If the fetch fails or returns almost nothing, stop and say so — don't analyze an empty transcript.++## Step 3 — Extract candidates++Read the whole thing. Pull out every concrete, transferable element:++- **Ideas / framings** — a way of thinking about a problem LifeOS already has.+- **Techniques / patterns** — an algorithm, a workflow shape, a verification method, an eval design.+- **Tools** — a library, a CLI, an API, a service worth wiring in.+- **Prompts / phrasings** — a prompt structure or instruction that beats what we do now.+- **Warnings** — a failure mode or anti-pattern we should guard against.++Keep candidates concrete. "Be more rigorous" is not a candidate. "Use property-based tests where an ISC is a universal claim" is.++## Step 4 — Judge each candidate against LifeOS++For every candidate, answer three things:++1. **Where does it map?** Name the exact surface: an Algorithm phase or gate, a specific hook (`hooks/*.hook.ts`), a specific skill, the memory system, Pulse, routing / `EFFORT_MODEL`, ISA, or a doctrine file (system prompt, CLAUDE.md, OPERATIONAL_RULES). If you can't name a surface, it's not a hit — drop it.+2. **Prior Status** — be honest and check before claiming novelty:+ - **NEW** — LifeOS doesn't do this.+ - **PARTIAL** — we have something close; this sharpens or extends it.+ - **DONE** — already implemented (name where).+ - **REJECTED** — we've considered and declined this (name why, if known).+ Cross-check by recalling recent work and, when cheap, grepping `skills/`, `hooks/`, and the Algorithm.+3. **How would we use it?** One concrete sentence: the actual change we'd make.++## Step 5 — Rank++Score each surviving candidate by **usefulness × novelty × (inverse) effort**. High usefulness, genuinely NEW or a strong PARTIAL upgrade, low-to-moderate effort floats to the top. DONE and REJECTED items drop to a short "already covered" note, not the main table.++## Step 6 — Report++Output this shape:++```+## Harvest: <source>++<one line: what the content is, and the headline verdict — rich / thin / nothing>++| # | Candidate | Maps to | How we'd use it | Prior status | Recommended action |+|---|-----------|---------|-----------------|--------------|--------------------|+| 1 | … | … | … | NEW/PARTIAL | … |++**Already covered:** <one line each for DONE/REJECTED hits, if any>++**Verdict:** <the honest bottom line — what, if anything, is worth doing next>+```++Rules for the report:++- Lead with the verdict. If nothing is worth adopting, the table can be empty and the verdict says so.+- Every row names a real surface and a real action. No vague usefulness.+- Recommend, don't do. Adoption of any item is a separate step that needs {{PRINCIPAL_NAME}}'s explicit go-ahead.+- Keep it tight. A harvest is a filter, not an essay.diff --git a/LifeOS/install/skills/ISA/Workflows/Scaffold.md b/LifeOS/install/skills/ISA/Workflows/Scaffold.mdindex e48b2606..4ca97700 100644--- a/LifeOS/install/skills/ISA/Workflows/Scaffold.md+++ b/LifeOS/install/skills/ISA/Workflows/Scaffold.md@@ -58,7 +58,7 @@ Run the four-signal detector on the prompt:**Multi-literal:** if multiple candidates ("do X and Y by Z"), **first wins as `principal_stated_goal:`**; others demote to derived Constraints with `derived_from: principal_stated_goal compound` annotation.-**Classifier handshake:** `EffortRouter.hook.ts` may emit `GOAL_SIGNAL: <1|2|3|4|none>` in additionalContext. Trust as hint, re-validate via the detector above.+**Classifier handshake:** `TheRouter.hook.ts` may emit `GOAL_SIGNAL: <1|2|3|4|none>` in additionalContext. Trust as hint, re-validate via the detector above.When detection fires + min-content passes, write the four frontmatter fields:@@ -84,13 +84,13 @@ Distill what remains:### Step 3.5 — Density preflight (v6.5.0 — MANDATORY at E3+; v6.7.0 — EXTENDED to E1/E2 with permissive thresholds)-**Stage 2 of the density × tier gate.** Stage 1 (eligibility) ran in `EffortRouter.hook.ts`; this stage measures whether the prompt + recent conversation carry enough signal to scaffold the tier's required sections without speculation.+**Stage 2 of the density × tier gate.** Stage 1 (eligibility) ran in `TheRouter.hook.ts`; this stage measures whether the prompt + recent conversation carry enough signal to scaffold the tier's required sections without speculation.**v6.7.0 extension:** eligibility now extends to E1 and E2 with permissive thresholds. At E1, the section-fillability term is skipped (ISA at E1 is inline/optional — depending on the term would be circular); the score uses signals 1-6 (the prompt-derived signals) only.#### Stage 1 → Stage 2 handoff (how Scaffold reads INTERVIEW_ELIGIBLE)-`EffortRouter.hook.ts` emits a 4-line block into `additionalContext` on every UserPromptSubmit:+`TheRouter.hook.ts` emits a 4-line block into `additionalContext` on every UserPromptSubmit:```MODE: ALGORITHM | TIER: E4 | REASON: … | SOURCE: classifierdiff --git a/LifeOS/install/skills/Interceptor/SKILL.md b/LifeOS/install/skills/Interceptor/SKILL.mdindex e32d8029..d291cc7e 100644--- a/LifeOS/install/skills/Interceptor/SKILL.md+++ b/LifeOS/install/skills/Interceptor/SKILL.md@@ -1,7 +1,7 @@---name: Interceptordescription: "Real Chrome/Brave + macOS Computer Use from inside the browser — zero CDP fingerprint, real sessions, six verb trees (References/CommandReference.md; more triggers in routing table). Mandatory for visual deploy verification. Drive clickwork yourself, never narrate it. USE WHEN verify deploy, confirm UI, screenshot verification, computer use, macos automation, debug web, troubleshoot, visual check, console logs/errors, runtime/JS/react errors, mismatch warning, network traffic/log, HAR/pcapng export, hydration/blank-page debug, flash then blank/page broken, why is this not working/what's happening on the page, authenticated page, bot detection bypass, agent-browser failing, reproduce bug, drive native app, about to ask the operator to click/navigate/fill a form/log in/approve OAuth, OAuth consent flow, authorize an app, complete a web login, walk through a web UI, do this in your browser. NOT FOR batch headless automation (Browser), residential-proxy crawling (BrightData), or social actor scraping (Apify)."-version: 4.2.0+version: 4.3.0effort: medium---@@ -48,10 +48,10 @@ Headless browser tools speak CDP, which sites can fingerprint and block — so tInterceptor is a Chrome extension that operates through the actual browser UI plus an optional macOS bridge that extends the same control surface to native apps, OS-level input, and on-device VMs.**Tool:** `interceptor` CLI — Chrome/Brave extension that controls the real browser from inside, plus a macOS bridge that drives native apps, OS-level input, and full VM lifecycle.-**Repo:** https://github.com/Hacker-Valley-Media/slop-browser+**Repo:** https://github.com/Hacker-Valley-Media/Interceptor**Install:** `~/Projects/interceptor` (built from source — see `Workflows/Update.md`)**Chrome "Load unpacked" target:** `~/.claude/skills/Interceptor/Extension/` — a **pinned copy** (not a symlink) of upstream `extension/dist`, captured by `Tools/Pin.sh`; provenance recorded in `Extension/PINNED_FROM.txt` (source path, manifest version, content SHA256, timestamp). Chrome disables unpacked extensions on every manifest bump, so after any binary upgrade the copy must be **re-pinned and reloaded**. It does NOT auto-follow upstream.-**Pinned binary:** `0.16.9` — `interceptor --version` reports `0.16.9 (86e7eb6, 2026-06-12)`.+**Pinned binary:** `0.22.2` — `interceptor --version` reports `0.22.2 (580a7de, 2026-07-04)`. Upstream is now a **three-surface** control plane: **Browser** + **macOS** + **iOS** (drive an owned, Developer-Mode iPhone via an on-device XCUITest runner over WiFi — `interceptor ios *`).### Capabilities Overview — Six Verb Trees@@ -70,6 +70,20 @@ Each row is an independent capability class. Each one uses a different WebSocket**Why this matters in practice.** Hydration failures on Astro pages, blank-page after React mount, "cards flash and disappear" — all of these surface through `eval` reading the live DOM state and console captures, not through screenshots. A `screenshot` wedge does not block diagnosis; the page is still inspectable through every other verb tree.+### New surfaces & verbs (0.17 → 0.22.2)++The six browser verb trees above are still the core. What the jump from 0.16.9 added:++- **iOS** (`interceptor ios *`) — drive an owned, unlocked, Developer-Mode iPhone over WiFi via an on-device XCUITest runner (not WebDriverAgent). Verbs: `tree`, `find`, `click`, `type`, `scroll`, `screenshot`, `app launch|activate|terminate`. Setup is Xcode self-service or a no-Xcode `login` that re-signs the runner with your Apple ID.+- **`interceptor diagnose`** — one post-failure snapshot: daemon (with its real exec path), every connected context probed in parallel, monitor state. **Catches the daemon split-brain** — Chrome spawns one daemon binary while the CLI talks to another, previously a silent 15s timeout. Run it first when anything acts wedged.+- **`interceptor manifest`** — machine-readable specs for 50+ verbs (usage, flags, returns semantics). Discover the contract without scraping help text.+- **Per-agent tab groups** (`--group <label>` / `INTERCEPTOR_GROUP`) — pen each agent into its own colored, hard-isolated tab group so several agents share one browser with no cross-bleed. `interceptor group list|close <label>`. A second isolation layer alongside `--context`.+- **`interceptor save`** — pull raw bytes (Blob / ArrayBuffer / `blob:`) straight off a live page to disk without a downloads folder; returns a sha256.+- **`interceptor ocr`** / **`canvas ocr`** — offline Tesseract pixel OCR, bundled into the extension (no bridge, no macOS needed).+- **`interceptor macos cdp *`** — drive the web contents of Electron / Chromium desktop apps (Slack, VS Code, Notion, Descript) the same way as a browser tab.++**CLI contract (0.22.1):** arguments are now order-independent (`open --text-only <url>` parses correctly), and browser-only installs hide the macOS/iOS verbs (`--all-surfaces` / `INTERCEPTOR_ALL_SURFACES` overrides). Bare `interceptor` / `--help` print a concise capability card; use `help <cmd>` or `interceptor manifest` for the full contract.+### Why Interceptor?agent-browser (the Browser skill) uses CDP — sites can detect it. Interceptor is a Chrome extension that operates through the actual browser UI. No debugger, no automation flags, no separate browser instance. You stay logged in, you pass bot detection, the agent sees what you see. The optional macOS bridge extends the same control surface to native applications, OS-level input, and on-device VMs — that combination is what "Computer Use" means in this skill.@@ -168,7 +182,7 @@ Operating rule: if the user asks for native and `status` reports `mode: browser-Quick health check:```bash-interceptor --version # → "interceptor 0.16.9 (86e7eb6, 2026-06-12)"+interceptor --version # → "interceptor 0.22.2 (580a7de, 2026-07-04)"interceptor status # → daemon: running, bridge: running, mode: full|browser-onlyinterceptor status --verbose # → adds extension reachability (NO extension-build field; with 2+ contexts it nags "multiple extensions connected" even with --context)interceptor contexts # → list of connected browser contexts (multi-profile)@@ -318,6 +332,7 @@ Agent(subagent_type="general-purpose", prompt="|----------|---------|------|-------|| LaunchTestProfile | "test profile", "launch test profile", "isolated browser", "isolated browser profile", "separate Chrome window", "start interceptor-test" | `Workflows/LaunchTestProfile.md` | One-time setup + daily launch of the isolated Chrome profile via `--profile-directory`, extension load, context-ID naming || VerifyDeploy | "verify deploy", "check deploy", "confirm deploy", "deploy verification" | `Workflows/VerifyDeploy.md` | Open URL in real Chrome (via `--context interceptor-test`), structured read, check errors, evidence |+| ScrubFlow | "scrub flow", "record flow to video", "motion bug", "animation jank", "transition stutter", "flicker", "flow gallery", "catch motion a screenshot misses" | `Workflows/ScrubFlow.md` | Record a web flow to video, extract SSIM-scored frames (survey/scrub via `Tools/FrameScrub.ts`), catch motion/animation/flow bugs a still screenshot misses || Reproduce | "reproduce", "reproduce bug", "debug page", "check page", "blank screen" | `Workflows/Reproduce.md` | Open affected page BEFORE code analysis, capture console errors and network 404s || ReadAndExtract | "extract value", "read page", "pull a fact", "SPA state" | `Workflows/ReadAndExtract.md` | Compound read + SPA state extraction; right surface per task; mode-swap rule || DriveRichEditor | "drive Canva", "drive Docs", "drive Slides", "rich editor", "scene", "scene graph", "canvas-rendered" | `Workflows/DriveRichEditor.md` | Scene graph + dispatched-event recipes for canvas-rendered editors |@@ -339,14 +354,15 @@ Agent(subagent_type="general-purpose", prompt="## Examples- "Verify the blog deploy" → VerifyDeploy: preflight isolation gate, `interceptor open <url> --context "$INTERCEPTOR_TEST_CONTEXT_ID"`, `read --markdown`, capture via `Tools/Capture.sh`, report with evidence.+- "The menu animation looks off / does the checkout flow render clean" → ScrubFlow: record the flow to video, `bun Tools/FrameScrub.ts <recording> scrub --at <sec>`, Read the auto-flagged frame, cite the manifest. Motion/interaction ISCs require this or a flow-gallery, not a single still (Algorithm Rule 1).- "Why is this page blank after deploy?" → Reproduce: open the page FIRST, `eval --main` console-error capture, `net log` for failed requests, then code analysis.- "Record me approving this flow, then replay it nightly" → RecordFlow + ReplayFlow: `monitor start`, operator acts, `monitor export <sid> --plan`, replay the plan script later.## Gotchas- **`interceptor` dying instantly with rc=137 and ZERO output = invalid code signature, not a wedge.** The kernel SIGKILLs adhoc-signed binaries whose signature went stale (observed 2026-06-10 after a system event; both binaries affected). Diagnose: `cp` the binary to /tmp, `codesign -s - -f` the copy, run it — if the copy works, re-sign the real ones: `codesign -s - -f /opt/homebrew/bin/interceptor && codesign -s - -f /opt/homebrew/bin/interceptor-daemon`. BOTH must be re-signed — the CLI spawns `interceptor-daemon --standalone` and a still-broken daemon yields "daemon failed to start. Check /tmp/interceptor.log" with the log never created. *(2026-06-10.)*-- **Screenshot — how it actually works (0.16.9).** Route every capture through `Tools/Capture.sh`; the raw behavior below is what it wraps.- - **Default `interceptor screenshot` is the DOM-render path** (html-to-image, injected on demand via `executeScript`). It renders from the live DOM tree and does **NOT** require a foreground/visible tab — a backgrounded tab on another macOS Space is fine.+- **Screenshot — how it actually works (0.22.2).** Route every capture through `Tools/Capture.sh`; the raw behavior below is what it wraps.+ - **Default `interceptor screenshot` is the DOM-render path** — a **dependency-free native renderer since v0.18.3** (`html-to-image` was removed; injected on demand via `executeScript`). It renders from the live DOM tree and does **NOT** require a foreground/visible tab — a backgrounded tab on another macOS Space is fine, and it's fail-fast (no more full-timeout hang on a backgrounded tab).- **`--pixel` is the opt-out** → legacy `captureVisibleTab`. It captures the window's *active* tab, so to capture a specific background tab it briefly activates it and restores focus — **the visible flash is by design**. `--pixel` REQUIRES the window non-minimized and visible; minimized → fast honest failure. Full-page `--pixel` rate-limits strips at 1100ms (Chrome's 2/sec cap) and stitches in the service worker.- **Reliability is the default path, not a flag.** There is no "reliable mode" toggle. The robustness today is the in-extension minimized-window preflight (fails fast instead of hanging ~30s) plus the CLI's 45s screenshot timeout. The `cli/lib/screenshot-selfheal.ts` wrapper is **dormant/unwired** — do not cite it.- **`--save` writes to the CLI's current working directory** and returns `filePath` (omits `dataUrl`). It does NOT write to `/tmp/pai-screenshots/` — workflows `cd` there precisely because `--save` targets CWD. There is no `--output <path>` flag; positional path args are silently ignored. Per OPERATIONAL_RULES, review artifacts belong in `~/Downloads/`, pipeline intermediates in `/tmp/`; `Tools/Capture.sh` standardizes this.@@ -358,7 +374,7 @@ Agent(subagent_type="general-purpose", prompt="- **Bridge needs Sparkle.framework.** When rebuilding from source on Apple Silicon, the bridge won't load until `Sparkle.framework` is installed at `/usr/local/Frameworks/`. The running bridge is the `.app`-bundle binary at `~/.local/share/interceptor/interceptor-bridge.app/Contents/MacOS/interceptor-bridge` (LaunchAgent `com.interceptor.bridge`, plist `~/Library/LaunchAgents/com.interceptor.bridge.plist`), NOT `/usr/local/bin/interceptor-bridge` (stale copy). The Update workflow handles this; symptom of forgetting is `bridge: not running` with `dyld[*]: Library not loaded: @rpath/Sparkle.framework/...` in `/tmp/interceptor-bridge.stderr.log`. *(2026-05-03, bridge topology corrected 2026-06-17.)*- **Manifest version bump = manual extension reload + re-pin required.** Chrome does not auto-reload unpacked extensions. `~/.claude/skills/Interceptor/Extension/` is a pinned COPY, not a symlink — it does not auto-follow upstream. After a binary upgrade, re-pin via the Update workflow, then delete the existing extension card in `chrome://extensions` and Load Unpacked again from `~/.claude/skills/Interceptor/Extension/`. The extension `key` is deterministic so the extension ID stays stable across reloads.- **"native port disconnected" is NOT a screenshot error.** It's the daemon logging that Chrome's Native-Messaging stdio port dropped (extension SW recycled / Chrome closed); the daemon survives and falls through to its WebSocket transport. If neither WS nor relay is up, commands queue (cap 50) and time out. **Fix = reconnect the extension** (reload the tab / re-open the configured browser), not restarting the daemon.-- **"screenshot-runner.js could not load" / "html-to-image library not loaded" = per-frame injection failure.** The page disallows script injection (`chrome://`, Web Store, PDF viewer, strict-CSP frame), the tab navigated mid-inject, OR — most common after a binary upgrade — a **stale loaded extension** whose bundled `screenshot-runner.js` doesn't match the daemon. **Fix = reload/re-pin the extension** (Load Unpacked from `~/.claude/skills/Interceptor/Extension/`).+- **"screenshot-runner.js could not load" = per-frame injection failure.** (The old "html-to-image library not loaded" error is gone — v0.18.3 replaced the library with a native renderer.) The page disallows script injection (`chrome://`, Web Store, PDF viewer, strict-CSP frame), the tab navigated mid-inject, OR — most common after a binary upgrade — a **stale loaded extension** whose bundled runner doesn't match the daemon. **Fix = reload/re-pin the extension** (Load Unpacked from `~/.claude/skills/Interceptor/Extension/`).- **Daemon↔extension WebSocket can wedge in a half-alive state — try other verb trees BEFORE declaring Interceptor unusable.** Symptom: `status`/`contexts`/`tabs` answer (control-plane message types) while `screenshot`/`eval` hang at timeout (data-plane types). Each verb in the Capabilities Overview uses a different WebSocket message type, so a wedge on `screenshot` rarely affects `eval`, `net log`, `tree`, `read --markdown`, `monitor`, or `inspect`. Recovery ladder: (1) **swap the capture path** (pixel↔DOM-render — a different message type often unwedges) or substitute a verb from another capability class — `read --markdown` / `eval --main document.body.innerText` instead of `screenshot`, `net log` for failed requests; (2) one `pkill -f interceptor-daemon` + a single retry; (3) reload the extension (surface: *"Interceptor extension is wedged — please reload it from chrome://extensions/."*) and STOP. Only after all three fail, tell the operator verification cannot be captured — **never fall back to `screencapture` / `osascript`.** **The recurring mistake this catches: claiming "Interceptor is broken" after a single `screenshot` timeout when `eval` would have answered the question in one tool call.** *(2026-05-13, sharpened 2026-06-17.)*- **Dead-bridge self-heal (macOS `macos_*` paths only — browser screenshot does NOT need the bridge).** "Loaded" ≠ "running" — probe the process via `interceptor status`, not just `launchctl list`:```bash@@ -375,6 +391,13 @@ Agent(subagent_type="general-purpose", prompt="- **Local extract.ts customization is obsolete.** The pre-v0.13 patch that bumped slice limits to 10M is no longer needed — upstream's `withTruncationMarker` + `--full` flag + per-action `maxChars` does it correctly with explicit truncation markers (`... (truncated: showed X of Y chars ...)`).- **Stale binary silently routes to Default — the fallback incident (2026-05-23).** A rebuild that lands at `~/Projects/interceptor/dist/` but never gets copied into `/opt/homebrew/bin/` leaves the CLI at an old version. Old binaries do not recognize `--context` or the `contexts` subcommand — they accept the flag without error and proceed to route the command through whichever Chrome connection the daemon can find, which is normally the operator's Default profile. Symptom: agent calls `interceptor open <url> --context "$INTERCEPTOR_TEST_CONTEXT_ID"`, expects an isolated tab, gets a tab in the operator's working window. Detection: `interceptor --version` reports a version older than `0.16.0`, AND/OR `interceptor open --help` shows no `--context`-related flag, AND/OR `interceptor contexts` returns "unknown command". Mitigation: the **Preflight Isolation Gate** (above) hard-fails on version mismatch with exit code 4 — every workflow runs it as step zero. Recovery is `Workflows/Update.md` followed by `pkill -f interceptor-daemon` so the next call respawns the new daemon.+- **Upgrading the bridge from an iCloud-synced source repo — the full signing dance (2026-07-04, 0.16.9→0.22.2).** `~/Projects/interceptor` symlinks into `~/Library/Mobile Documents/com~apple~CloudDocs/`, and iCloud sync **strips the built `.app`'s code-signature envelope** (`codesign -v` → "code has no resources but signature indicates they must be present"). Copying that bundle into place propagates the break and the bridge SIGKILL-loops (`launchctl print` → `last exit reason = OS_REASON_CODESIGNING`). Fix, in order, on the LOCAL staged copy (`~/.local/share/interceptor/interceptor-bridge.app`): `xattr -cr` it → `codesign --force --deep --sign - .../Contents/Frameworks/Sparkle.framework` → `codesign --force --sign - --entitlements ~/Projects/interceptor/scripts/entitlements-bridge.plist` on **the MacOS binary, then the .app** (this is exactly build-bridge.sh's dev-signing fallback). Do NOT `codesign --deep` the whole app — it mis-signs nested Sparkle so `codesign -v` passes while the kernel still kills it.+- **`bash scripts/install.sh --chrome` re-clobbers a freshly-fixed bridge.** It chains into install-bridge.sh, which re-copies the broken iCloud bundle over your fixed one. Re-sign AFTER running it — or don't run it again once the bridge is signed.+- **launchd `job state = spawn failed` after repeated `kickstart -k`.** Rapid restart cycles throttle launchd into a failed state (`runs` climbs; the binary runs fine when launched directly). Recovery is `launchctl bootout "gui/$(id -u)/com.interceptor.bridge"` then a fresh `launchctl bootstrap "gui/$(id -u)" ~/Library/LaunchAgents/com.interceptor.bridge.plist` — NOT another kickstart.+- **Ad-hoc re-signing the bridge resets its TCC grants.** A new ad-hoc signature is a new code identity, so Accessibility / Screen Recording / Microphone drop to `denied` and Computer Use stops until re-granted (`interceptor macos trust --walkthrough`, or System Settings → Privacy & Security). The browser surface is unaffected (extension-based, no TCC). The notarized `Interceptor-Full-<v>.pkg` keeps a stable Developer-ID identity across Sparkle updates and sidesteps all of this — prefer it for the bridge when TCC churn hurts.+- **`interceptor diagnose` is the first move when anything's wedged (0.22.2+).** It flags the daemon **split-brain**: the socket daemon (what the CLI talks to) vs the NMH manifest path (what Chrome spawns). Fix by pointing the manifest `path` at the canonical binary — `jq '.path="/opt/homebrew/bin/interceptor-daemon"'` over `~/Library/Application Support/Google/Chrome/NativeMessagingHosts/com.interceptor.host.json` (+ the Brave one) — then `pkill -f interceptor-daemon` and run one active command (`interceptor contexts`) to respawn from the right place.+- **`Tools/Pin.sh` on bash 5.2+ — the tilde scrub was silently a no-op (fixed 2026-07-04).** `${SRC/#$HOME/~}` started tilde-expanding the replacement back to `/Users/<name>`, so `PINNED_FROM.txt` shipped an absolute home path and Pin.sh's own leak guard FATAL'd. Fixed to a quoted `~${SRC#$HOME}` form (`rel_home()`). If a re-pin FATALs on "absolute home path survived the scrub," check the bash version and that helper.+## Stealth VerificationPasses all major bot detection:diff --git a/LifeOS/install/skills/Interceptor/Tools/FrameScrub.ts b/LifeOS/install/skills/Interceptor/Tools/FrameScrub.tsnew file mode 100644index 00000000..934d07d1--- /dev/null+++ b/LifeOS/install/skills/Interceptor/Tools/FrameScrub.ts@@ -0,0 +1,98 @@+#!/usr/bin/env bun+/**+ * FrameScrub — the video-verification core mechanism.+ *+ * ScrubFlow records a web flow to <flow>.webm (MediaRecorder on the extension's+ * existing tab MediaStream — screencapture is banned in Interceptor). FrameScrub+ * turns that recording into VIEWABLE evidence in two modes:+ *+ * survey — N evenly-spaced frames across the whole clip (overview / gallery).+ * scrub — dense frames at F fps in a ±window around a suspect timestamp,+ * with a per-frame SSIM-to-previous score so sub-second motion+ * (a stuttering fade, a dropped transition, a flicker) is flagged+ * NUMERICALLY, not left to the model eyeballing near-identical PNGs.+ *+ * The manifest — frames + timestamps + change scores — is the artifact the+ * verify step consumes and the gate keys on (not the raw video path).+ *+ * Usage:+ * bun FrameScrub.ts <video> survey [--frames N]+ * bun FrameScrub.ts <video> scrub --at <sec> [--window <sec>] [--fps <n>]+ */+import { execFileSync, spawnSync } from "node:child_process";+import { mkdirSync, writeFileSync } from "node:fs";+import { join, basename } from "node:path";++function arg(flag: string, dflt: string): string {+ const i = process.argv.indexOf(flag);+ return i !== -1 && process.argv[i + 1] ? process.argv[i + 1] : dflt;+}+function sh(bin: string, args: string[]): string {+ return execFileSync(bin, args, { encoding: "utf8" });+}++const video = process.argv[2];+const mode = (process.argv[3] || "survey").replace(/^--/, "");+if (!video || video.startsWith("--")) {+ console.error("usage: bun FrameScrub.ts <video> <survey|scrub> [...]");+ process.exit(1);+}++const duration = parseFloat(+ sh("ffprobe", ["-v", "error", "-show_entries", "format=duration",+ "-of", "default=noprint_wrappers=1:nokey=1", video]).trim()+);+if (!isFinite(duration) || duration <= 0) { console.error(`bad duration: ${video}`); process.exit(1); }++const outDir = arg("--out", join("frames", `${basename(video).replace(/\.[^.]+$/, "")}-${mode}`));+mkdirSync(outDir, { recursive: true });++// Build the list of sample timestamps for the chosen mode.+let stamps: number[];+if (mode === "scrub") {+ const at = parseFloat(arg("--at", String(duration / 2)));+ const window = parseFloat(arg("--window", "1.5"));+ const fps = parseFloat(arg("--fps", "8"));+ const start = Math.max(0, at - window / 2);+ const end = Math.min(duration, at + window / 2);+ const n = Math.max(2, Math.round((end - start) * fps));+ stamps = Array.from({ length: n }, (_, i) => start + (i * (end - start)) / (n - 1));+} else {+ const frames = Math.max(1, parseInt(arg("--frames", "8"), 10));+ stamps = Array.from({ length: frames }, (_, i) => (duration * (i + 0.5)) / frames);+}++// Extract each frame.+const paths = stamps.map((ts, i) => {+ const p = join(outDir, `frame_${String(i).padStart(3, "0")}.png`);+ sh("ffmpeg", ["-y", "-loglevel", "error", "-ss", ts.toFixed(3), "-i", video,+ "-frames:v", "1", "-vf", "scale=640:-1", p]);+ return p;+});++// SSIM between consecutive frames → change score (1.0 = identical, lower = more motion).+function ssimPrev(a: string, b: string): number | null {+ // ffmpeg prints the SSIM line to STDERR — spawnSync captures both streams.+ const r = spawnSync("ffmpeg", ["-i", a, "-i", b, "-lavfi", "ssim", "-f", "null", "-"], { encoding: "utf8" });+ const m = (r.stderr || "").match(/All:([0-9.]+)/);+ return m ? Number(parseFloat(m[1]).toFixed(4)) : null;+}++const extracted = paths.map((path, i) => ({+ frame: i,+ path,+ timestamp_s: Number(stamps[i].toFixed(3)),+ ssim_to_prev: i === 0 ? null : ssimPrev(paths[i - 1], path),+}));++// Flag the biggest inter-frame change (the candidate motion anomaly).+let flagged: number | null = null, lowest = 1.1;+for (const f of extracted) if (f.ssim_to_prev !== null && f.ssim_to_prev < lowest) { lowest = f.ssim_to_prev; flagged = f.frame; }++const manifest = { video, mode, duration_s: Number(duration.toFixed(3)),+ frame_count: extracted.length, flagged_frame: flagged, min_ssim: flagged === null ? null : lowest, extracted };+const manifestPath = join(outDir, "manifest.json");+writeFileSync(manifestPath, JSON.stringify(manifest, null, 2));+console.log(`[${mode}] ${extracted.length} frames from ${video} → ${outDir}`);+if (mode === "scrub") console.log(`biggest change at frame ${flagged} (SSIM ${lowest.toFixed(4)}) — the model looks HERE first`);+console.log(`manifest: ${manifestPath}`);diff --git a/LifeOS/install/skills/Interceptor/Tools/Pin.sh b/LifeOS/install/skills/Interceptor/Tools/Pin.shindex 26528a11..57d46bb9 100755--- a/LifeOS/install/skills/Interceptor/Tools/Pin.sh+++ b/LifeOS/install/skills/Interceptor/Tools/Pin.sh@@ -20,6 +20,11 @@ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"DEST="$(cd "$SCRIPT_DIR/.." && pwd)/Extension"SRC="${INTERCEPTOR_SRC:-$HOME/Projects/interceptor}/extension/dist"+# Relativize a $HOME-rooted path to ~. Do NOT use ${x/#$HOME/~}: bash 5.2++# tilde-expands the replacement back to an absolute /Users path, which silently+# defeats the leak scrub below and trips the FATAL guard (2026-07-04).+rel_home() { case "$1" in "$HOME"/*) printf '~%s' "${1#"$HOME"}";; *) printf '%s' "$1";; esac; }+if [ ! -d "$SRC" ]; thenecho "FATAL: build dir not found: $SRC" >&2echo " Build first (Update workflow step 3), or set INTERCEPTOR_SRC." >&2@@ -27,8 +32,8 @@ if [ ! -d "$SRC" ]; thenfiecho "Pinning extension"-echo " from: ${SRC/#$HOME/~}"-echo " to: ${DEST/#$HOME/~}"+echo " from: $(rel_home "$SRC")"+echo " to: $(rel_home "$DEST")"mkdir -p "$DEST"# Copy build → Extension. Keep profile-data/ (runtime, gitignored); leave@@ -50,7 +55,7 @@ doneVERSION="$(grep '"version"' "$DEST/manifest.json" | head -1 | sed -E 's/.*"version": *"([^"]+)".*/\1/')"SHA="$(find "$DEST" -type f -not -name 'PINNED_FROM.txt' | sort | xargs shasum -a 256 | shasum -a 256 | cut -d' ' -f1)"cat > "$DEST/PINNED_FROM.txt" <<EOF-Pinned from: ${SRC/#$HOME/~}+Pinned from: $(rel_home "$SRC")Manifest version: $VERSIONContent SHA256: $SHAPinned at: $(date -u +%Y-%m-%dT%H:%M:%SZ)diff --git a/LifeOS/install/skills/Interceptor/Workflows/ScrubFlow.md b/LifeOS/install/skills/Interceptor/Workflows/ScrubFlow.mdnew file mode 100644index 00000000..f11a4420--- /dev/null+++ b/LifeOS/install/skills/Interceptor/Workflows/ScrubFlow.md@@ -0,0 +1,37 @@+# ScrubFlow — video verification for motion the eye misses++## What it does++Interceptor screenshots freeze one moment. A stuttering fade, a dropped transition, a menu that flickers on open, a skeleton state that never resolves — none of that shows up in a still. ScrubFlow captures the flow as a short video, then extracts frames the model can actually view, so motion bugs get caught before a claim of "works" ships.++Required by Algorithm Verification Rule 1: a **motion/interaction ISC** (animation, transition, drag, hover-state, scroll behavior, loading/skeleton state, or a multi-step flow) closes ONLY on a ScrubFlow gallery or a VerifyDeploy flow-gallery — never a single screenshot.++## The mechanism: `Tools/FrameScrub.ts`++Turns a recording into viewable, scored evidence. Two modes:++```bash+# survey — N evenly-spaced frames across the whole clip (overview)+bun Tools/FrameScrub.ts <recording> survey --frames 8++# scrub — dense frames at F fps in a ±window around a suspect moment,+# each SSIM-scored against the previous; the biggest-change frame is flagged+bun Tools/FrameScrub.ts <recording> scrub --at 4.2 --window 1.5 --fps 8+```++Output: PNG frames + a `manifest.json` (`{video, mode, frame_count, flagged_frame, min_ssim, extracted:[{frame, path, timestamp_s, ssim_to_prev}]}`). **Survey answers "does the flow broadly work"; scrub answers "does the animation at 4.2s render clean." The SSIM flag points the model at the frame with the most change so it looks at the motion, not twelve near-identical stills.**++Verify a motion ISC by opening the flagged frame (and its neighbors) with Read, then cite the manifest path — `SuccessClaimGate` accepts a `frames/…/manifest.json` as Interceptor-class evidence.++## Getting the recording++**Path A — bring your own (works today).** Any `.webm` / `.mov` / `.mp4` — a QuickTime capture, a Descript export, a screen recording you already have — feeds straight into FrameScrub. Fully functional now.++**Path B — auto-record the browser flow (next increment, designed not shipped).** Add a `MediaRecorder` to the extension's existing tab `MediaStream` (`offscreen.js` `startCapture()` already opens the stream for still capture; `captureFrame()` pulls one frame — recording taps the same stream). Emits `.webm` (MediaRecorder on Chrome is webm/vp8-vp9; mp4 muxing is inconsistent — do NOT assume mp4). `screencapture` stays banned; this records in-page with zero CDP fingerprint, consistent with Interceptor.++## Gotchas++- **Focused-tab requirement.** Chrome throttles tab capture when the tab is backgrounded — a backgrounded recording can yield frozen or garbage frames that then falsely pass the gate. ScrubFlow must record with the target tab foregrounded; if focus can't be guaranteed, downgrade to "recorded, not scrub-verified", never claim clean.+- **Cite the manifest, not the raw video.** "video.mp4 exists" is not proof it rendered right. The evidence is the frames the model viewed — the manifest.+- **webm, not mp4.** MediaRecorder emits webm. FrameScrub handles any container ffmpeg reads; just don't hardcode mp4 in Path B.+- **Scrub, don't just survey, for animation.** Even-spaced survey sampling of a 2s window can straddle a 0.4s stutter. Use scrub mode (dense fps) around the suspect timestamp for anything sub-second.diff --git a/LifeOS/install/skills/Interceptor/Workflows/Update.md b/LifeOS/install/skills/Interceptor/Workflows/Update.mdindex a3654cdf..60bd7795 100644--- a/LifeOS/install/skills/Interceptor/Workflows/Update.md+++ b/LifeOS/install/skills/Interceptor/Workflows/Update.md@@ -236,10 +236,11 @@ interceptor --versioninterceptor statusinterceptor status --verboseinterceptor contexts+interceptor diagnose --no-skills-hint # 0.22.2+: daemon exec path, per-context probe, split-brain checkinterceptor open "https://example.com"```-`status` reports both `daemon` and `bridge` lines (bridge shows "not running" if you skipped step 6 — that's fine for `--browser-only`). `open` should return tree + extracted text.+`status` reports both `daemon` and `bridge` lines (bridge shows "not running" if you skipped step 6 — that's fine for `--browser-only`). `open` should return tree + extracted text. **`diagnose` is the new must-run check** — it prints the daemon's real exec path and flags a **binary split-brain** (Chrome spawns one daemon binary while the CLI talks to another). If it reports a mismatch, point the NMH manifest `path` at `/opt/homebrew/bin/interceptor-daemon` and `pkill -f interceptor-daemon`. See SKILL.md Gotchas for the full bridge-signing / iCloud / launchd-throttle recovery sequence.## Notesdiff --git a/LifeOS/install/skills/Interceptor/Workflows/VerifyDeploy.md b/LifeOS/install/skills/Interceptor/Workflows/VerifyDeploy.mdindex 2dcbe4f8..ad34a933 100644--- a/LifeOS/install/skills/Interceptor/Workflows/VerifyDeploy.md+++ b/LifeOS/install/skills/Interceptor/Workflows/VerifyDeploy.md@@ -101,6 +101,8 @@ bash ~/.claude/skills/Interceptor/Tools/Capture.sh "<DEPLOY_URL>" --full`Capture.sh` re-runs the isolation gate, routes to the pinned context, prefers the DOM-render path (no foreground needed), and prints the absolute saved-image path on its only stdout line. Read that image to visually confirm rendering. Never call raw `interceptor screenshot` here — it loses the deny-Default guard and CWD-destination handling.+**Flow-gallery (optional, for multi-step flows).** One end-state screenshot proves the last page rendered, not the three screens before it — a broken state mid-flow (a failed validation, an empty intermediate step, a wrong redirect) never gets seen. For a multi-step flow (signup, checkout, vote, onboarding), capture an ORDERED gallery instead: `Capture.sh` at each step, keeping the shots in order with a step label (`01-landing`, `02-form-filled`, `03-confirm`, …). Read them in sequence and confirm every state, not just the end. This extends Probe D; it does not replace probes A–C. For bugs that only exist in *motion* (animation, transition, flicker), use `ScrubFlow` instead — a gallery of stills still can't see a stutter.+### 6. Report — the evidence bundleFull verification = ALL FOUR probes captured and clean (with the noise rules above). Mark the ISC `[x]` citing the bundle: DOM content confirmed + console clean (or noise-only) + network clean (or noise-only) + screenshot path.diff --git a/LifeOS/install/skills/Interview/Workflows/ContextCheckin.md b/LifeOS/install/skills/Interview/Workflows/ContextCheckin.mdindex 0cec672a..01868915 100644--- a/LifeOS/install/skills/Interview/Workflows/ContextCheckin.md+++ b/LifeOS/install/skills/Interview/Workflows/ContextCheckin.md@@ -192,7 +192,7 @@ curl -s -X POST http://localhost:31337/reload > /dev/null 2>&1 &```read freshness ⇒ pai_system_prompt 112d/90d (most stale across both surfaces)-Read PAI/LIFEOS_SYSTEM_PROMPT.md fully+Read LIFEOS/LIFEOS_SYSTEM_PROMPT.md fully```> "I read your context. **LIFEOS_SYSTEM_PROMPT** hasn't been touched in **112d** (threshold 90d). The Hard Prohibitions section says: *'Never self-rate responses or add unsolicited ratings. Never modify working features unprompted. Analysis means read-only…'* Still want all three of those, or has anything changed in how you want me to operate?"diff --git a/LifeOS/install/skills/LifeOS/SKILL.md b/LifeOS/install/skills/LifeOS/SKILL.mdindex c676d8ee..c9ee2ccf 100644--- a/LifeOS/install/skills/LifeOS/SKILL.md+++ b/LifeOS/install/skills/LifeOS/SKILL.md@@ -53,7 +53,7 @@ Default flow (`/lifeos-setup`): **Setup phase** (system integration) → transit- **No `version:` in SKILL.md.** Claude Code ignores it. Version lives in the release (tag + `LIFEOS_RELEASES/<version>/` + the `install.sh` fetch), not in the skill.- **`install.sh` is non-destructive by design.** It installs only the LifeOS skill and backs up only a prior LifeOS skill — never the user's other skills, hooks, or config. The whole point is "bolt on, don't take over."- **Hooks are installed imperatively, with permission.** A bare skill cannot auto-wire hooks; the setup workflow writes them into the user's harness explicitly, after showing what changes.-- **Config is `.toml`, never `.yaml`.** `PaiConfig.ts` reads TOML; the legacy `.yaml` template was retired 2026-06-19.+- **Config is `.toml`, never `.yaml`.** `LifeosConfig.ts` reads TOML; the legacy `.yaml` template was retired 2026-06-19.- **Cross-platform is solved at setup time, not statically.** The setup conversation detects the OS + harness and tailors hook commands and paths — don't assume macOS.## Examplesdiff --git a/LifeOS/install/skills/LifeOS/Tools/SeedPulse.ts b/LifeOS/install/skills/LifeOS/Tools/SeedPulse.tsindex 4b54fbfb..89395b8a 100755--- a/LifeOS/install/skills/LifeOS/Tools/SeedPulse.ts+++ b/LifeOS/install/skills/LifeOS/Tools/SeedPulse.ts@@ -15,7 +15,7 @@ import { existsSync } from "node:fs";import { join } from "node:path";import { detectDevTree } from "./InstallEngine";-const GENERATORS = ["GenerateTelosSummary.ts", "UpdatePaiState.ts"];+const GENERATORS = ["GenerateTelosSummary.ts", "UpdateLifeosState.ts"];function main(): void {const a = process.argv.slice(2);@@ -58,8 +58,8 @@ function main(): void {...process.env,LIFEOS_CONFIG_DIR: configDir,LIFEOS_DIR: join(configRoot, "LIFEOS"),- // GenerateTelosSummary resolves its TELOS dir via PaiConfig.paiUserDir(),- // which reads LIFEOS_CONFIG_PATH (NOT LIFEOS_DIR). UpdatePaiState resolves via+ // GenerateTelosSummary resolves its TELOS dir via LifeosConfig.paiUserDir(),+ // which reads LIFEOS_CONFIG_PATH (NOT LIFEOS_DIR). UpdateLifeosState resolves via// LIFEOS_DIR. Pass BOTH so both generators target the same install root —// otherwise a non-default config root mis-targets ~/.claude.LIFEOS_CONFIG_PATH: join(configRoot, "LIFEOS", "USER", "CONFIG", "LIFEOS_CONFIG.toml"),diff --git a/LifeOS/install/skills/LifeOS/Workflows/Interview.md b/LifeOS/install/skills/LifeOS/Workflows/Interview.mdindex 07918178..54c190f5 100644--- a/LifeOS/install/skills/LifeOS/Workflows/Interview.md+++ b/LifeOS/install/skills/LifeOS/Workflows/Interview.md@@ -19,7 +19,7 @@ Peer conversation, not a form. Ask one thing at a time, reflect it back, go deep2. **Principal identity** — name, pronunciation, timezone, hometown → `[principal]` in `LIFEOS_CONFIG.toml` and `PRINCIPAL/PRINCIPAL_IDENTITY.md`.3. **TELOS — current state** — mission, the people who matter, current projects, challenges, what's actually true right now. Write to `TELOS/`.4. **TELOS — ideal state** — goals (with metrics + dates where they have them), strategies, the destination. Current → ideal is the spine of LifeOS; get both halves.-5. **External sources (optional)** — the user can hand over existing material: notes, an old config, exports, URLs, a prior PAI/other-harness setup. Pull from each (read files, fetch URLs), extract identity / TELOS / project signal, and merge into the USER tree — `existsSync`-guarded, confirm before each write. This is the migration on-ramp: bring your context, don't retype it.+5. **External sources (optional)** — the user can hand over existing material: notes, an old config, exports, URLs, a prior LIFEOS/other-harness setup. Pull from each (read files, fetch URLs), extract identity / TELOS / project signal, and merge into the USER tree — `existsSync`-guarded, confirm before each write. This is the migration on-ramp: bring your context, don't retype it.6. **SeedPulse** — `bun Tools/SeedPulse.ts` → write `LIFEOS_STATE.json` and regenerate `PRINCIPAL_TELOS.md` from the captured TELOS so Pulse renders real rings + state on first open.## Closediff --git a/LifeOS/install/skills/LifeOS/install/install.sh b/LifeOS/install/skills/LifeOS/install/install.shindex 1d22d049..832c705e 100755--- a/LifeOS/install/skills/LifeOS/install/install.sh+++ b/LifeOS/install/skills/LifeOS/install/install.sh@@ -23,7 +23,7 @@set -euo pipefail# ─── Pinned release ──────────────────────────────────────────────-LIFEOS_VERSION="${LIFEOS_VERSION:-6.0.3}"+LIFEOS_VERSION="${LIFEOS_VERSION:-6.0.5}"LIFEOS_TAG="v${LIFEOS_VERSION}"# Repo owner/name are parameterized — set at publish time, never hard-coded here.LIFEOS_REPO="${LIFEOS_REPO:-danielmiessler/LifeOS}"diff --git a/LifeOS/install/skills/Prompting/Templates/README.md b/LifeOS/install/skills/Prompting/Templates/README.mdindex 76b5786e..21985907 100755--- a/LifeOS/install/skills/Prompting/Templates/README.md+++ b/LifeOS/install/skills/Prompting/Templates/README.md@@ -168,7 +168,7 @@ cd ~/.claudegit checkout v2.5.0# Or to just undo templating:rm -rf Templates/-git checkout v2.5.0 -- PAI/Prompting.md+git checkout v2.5.0 -- LIFEOS/Prompting.md```## Token Savingsdiff --git a/LifeOS/install/skills/Science/Methodology.md b/LifeOS/install/skills/Science/Methodology.mdindex ff3f8c20..ebd619ec 100755--- a/LifeOS/install/skills/Science/Methodology.md+++ b/LifeOS/install/skills/Science/Methodology.md@@ -1,6 +1,6 @@# Science Methodology - The Deep Dive-**This document elaborates on each phase of the scientific method as applied within PAI.**+**This document elaborates on each phase of the scientific method as applied within LifeOS.**The power of this methodology is its universality and its iteration speed. Apply it at micro-scale (TDD cycles) or macro-scale (product strategy). The pattern remains the same.diff --git a/LifeOS/install/skills/Upgrade/References/ExampleReport.md b/LifeOS/install/skills/Upgrade/References/ExampleReport.mdindex ec053c53..35e7fb9c 100644--- a/LifeOS/install/skills/Upgrade/References/ExampleReport.md+++ b/LifeOS/install/skills/Upgrade/References/ExampleReport.md@@ -9,7 +9,7 @@ User: "check for upgrades"[Agents run in parallel...]-# PAI Upgrade Report+# LifeOS Upgrade Report**Generated:** 2026-01-15 19:45:00 PST**Sources Processed:** 20 release notes parsed | 5 videos checked | 30 docs analyzed**Findings:** 3 techniques extracted | 4 content items skipped@@ -20,7 +20,7 @@ User: "check for upgrades"Everything interesting we found, ranked by how cool it is.-| # | Discovery | Source | Why It's Interesting | PAI Relevance |+| # | Discovery | Source | Why It's Interesting | LifeOS Relevance ||---|-----------|--------|---------------------|---------------|| 1 | PreToolUse hooks can inject reasoning context | claude-code v2.1.16 | Hooks can now return `additionalContext` that Claude reasons about before tool execution — this is a paradigm shift from binary block/allow to intelligent security | SecurityValidator could inject warnings instead of blocking, enabling context-aware security decisions || 2 | Native ${CLAUDE_SESSION_ID} variable | claude-code v2.1.16 | Session IDs are now first-class environment variables everywhere — no more extraction hacks | Session documentation workflows can drop manual ID extraction code |@@ -32,15 +32,15 @@ Everything interesting we found, ranked by how cool it is.### 🔴 CRITICAL — Integrate immediately-| # | Recommendation | Prior Status | Evidence | PAI Relevance | Effort | Files Affected |+| # | Recommendation | Prior Status | Evidence | LifeOS Relevance | Effort | Files Affected ||---|---------------|-------------|----------|---------------|--------|----------------|| 1 | Add PreToolUse additionalContext to security hooks | 🆕 NEW | `hooks/SecurityPipeline.hook.ts:42` returns binary deny/allow only | SecurityValidator currently hard-blocks commands — additionalContext enables reasoning-based security that adapts to context | Low | `hooks/SecurityValidator.hook.ts` |### 🟠 HIGH — Integrate this week-| # | Recommendation | Prior Status | Evidence | PAI Relevance | Effort | Files Affected |+| # | Recommendation | Prior Status | Evidence | LifeOS Relevance | Effort | Files Affected ||---|---------------|-------------|----------|---------------|--------|----------------|-| 2 | Replace session ID hacks with native ${CLAUDE_SESSION_ID} | 🔶 PARTIAL | `skills/_PAI/Workflows/DocumentSession.md:15` uses extraction hack | Session documentation workflows have manual extraction workarounds — native variable eliminates fragile code | Low | `skills/_PAI/Workflows/DocumentSession.md` |+| 2 | Replace session ID hacks with native ${CLAUDE_SESSION_ID} | 🔶 PARTIAL | `skills/_LIFEOS/Workflows/DocumentSession.md:15` uses extraction hack | Session documentation workflows have manual extraction workarounds — native variable eliminates fragile code | Low | `skills/_LIFEOS/Workflows/DocumentSession.md` |(MEDIUM and LOW tiers omitted — no items.)@@ -56,7 +56,7 @@ Everything interesting we found, ranked by how cool it is.**What It Is:** PreToolUse hooks can now return an additionalContext field that gets injected into the model's context before tool execution, enabling reasoning-based security rather than hard blocks.-**How It Helps PAI:** SecurityValidator.hook.ts currently blocks dangerous commands. With additionalContext, it can inject warnings Claude reasons about, enabling smarter security that adapts to context.+**How It Helps LifeOS:** SecurityValidator.hook.ts currently blocks dangerous commands. With additionalContext, it can inject warnings Claude reasons about, enabling smarter security that adapts to context.**The Technique:**```typescript@@ -73,20 +73,20 @@ return { decision: "allow", additionalContext: "WARNING: Protected file." };**What It Is:** Native environment variable ${CLAUDE_SESSION_ID} is now available in all hooks and commands, eliminating the need for custom session ID extraction or workaround code.-**How It Helps PAI:** Our session documentation workflows had manual session ID extraction hacks. Native substitution means cleaner code and reliable session tracking across all PAI workflows.+**How It Helps LifeOS:** Our session documentation workflows had manual session ID extraction hacks. Native substitution means cleaner code and reliable session tracking across all LifeOS workflows.**The Technique:**```bashecho "Session: ${CLAUDE_SESSION_ID}"```-**Applies To:** `skills/_PAI/Workflows/DocumentSession.md`+**Applies To:** `skills/_LIFEOS/Workflows/DocumentSession.md`---## 📊 Summary-| # | Technique | Source | Priority | PAI Component | Effort |+| # | Technique | Source | Priority | LifeOS Component | Effort ||---|-----------|--------|----------|---------------|--------|| 1 | PreToolUse Additional Context | claude-code v2.1.16 | 🔴 | SecurityValidator hook | Low || 2 | Session ID Substitution | claude-code v2.1.16 | 🟠 | DocumentSession workflow | Low |@@ -100,7 +100,7 @@ echo "Session: ${CLAUDE_SESSION_ID}"| MCP auto mode | claude-code v2.1.16 | ✅ DONE — already enabled by default | `settings.json:18` || Gemini 3 videos | YouTube | Not relevant to Claude-centric stack | — || Agent Experts video | YouTube | No concrete technique identified | — |-| SDK update v0.78 | GitHub | PAI uses CLI, not raw SDK | `CLAUDE.md:12` |+| SDK update v0.78 | GitHub | LifeOS uses CLI, not raw SDK | `CLAUDE.md:12` |## 🔍 Sources Processed30 Anthropic sources, 5 YouTube videos, 0 custom → 2 relevant findingsdiff --git a/LifeOS/install/skills/Upgrade/References/OutputFormat.md b/LifeOS/install/skills/Upgrade/References/OutputFormat.mdindex 83a2eda5..5983f748 100644--- a/LifeOS/install/skills/Upgrade/References/OutputFormat.md+++ b/LifeOS/install/skills/Upgrade/References/OutputFormat.md@@ -19,7 +19,7 @@## Header```markdown-# PAI Upgrade Report+# LifeOS Upgrade Report**Generated:** [timestamp]**Sources Processed:** [N] release notes | [N] videos | [N] docs | [N] GitHub queries**Findings:** [N] techniques extracted | [N] skipped@@ -31,7 +31,7 @@Ranked by interestingness, NOT implementation priority. A LOW-priority item can be Discovery #1 if it's the most "whoa" finding.-| # | Discovery | Source | Why It's Interesting | PAI Relevance |+| # | Discovery | Source | Why It's Interesting | LifeOS Relevance ||---|-----------|--------|----------------------|---------------|| 1 | [name] | [source] | [≤2 sentences] | [≤1 sentence] |@@ -49,13 +49,13 @@ Every row MUST carry a Prior Status tag with file:line evidence from Thread 0.- ✅ **DONE** — already implemented; goes to Skipped Content with evidence, NOT here### 🔴 CRITICAL — Integrate immediately-Fixes gaps, security issues, or unlocks capabilities PAI should already have.+Fixes gaps, security issues, or unlocks capabilities LifeOS should already have.-| # | Recommendation | Prior Status | Evidence | PAI Relevance | Effort | Files Affected |+| # | Recommendation | Prior Status | Evidence | LifeOS Relevance | Effort | Files Affected ||---|---------------|-------------|----------|---------------|--------|----------------|### 🟠 HIGH — Integrate this week-Significantly improves PAI capabilities or efficiency.+Significantly improves LifeOS capabilities or efficiency.### 🟡 MEDIUM — Integrate when convenientUseful capabilities or ecosystem alignment.@@ -80,7 +80,7 @@ Numbered to match Recommendations. One block per technique.**What It Is:** [≤2 sentences, concrete and specific — what the technique does, how it works, what capability it provides]-**How It Helps PAI:** [≤2 sentences, concrete and specific — which component improves, what gap it fills]+**How It Helps LifeOS:** [≤2 sentences, concrete and specific — which component improves, what gap it fills]**The Technique:**> [QUOTE or CODE BLOCK — actual content, not a summary]@@ -100,12 +100,12 @@ Numbered to match Recommendations. One block per technique.**Priority:** 🔴 | 🟠 | 🟡 | 🟢**What It Is:** [≤2 sentences]-**How It Helps PAI:** [≤2 sentences]+**How It Helps LifeOS:** [≤2 sentences]**Inspiration Techniques:**> [Specific architectural pattern from README or code]-**Applies To:** `[PAI file path]`, [component]+**Applies To:** `[LifeOS file path]`, [component]**Potential Integration:** [key insight to borrow — not a full implementation]```@@ -120,7 +120,7 @@ Numbered to match Recommendations. One block per technique.### [Theme Name] ([N] occurrences, [HIGH/MEDIUM/LOW] signal)**Root cause:** [structural issue]**Proposed fix:** [concrete change]-**Target:** [PAI files affected]+**Target:** [LifeOS files affected]**Evidence:**- [timestamp] [task] — "[Q2 quote]"```@@ -132,7 +132,7 @@ If no reflections yet:## 📊 Summary-| # | Technique | Source | Priority | PAI Component | Effort |+| # | Technique | Source | Priority | LifeOS Component | Effort ||---|-----------|--------|----------|---------------|--------|**Totals:** [N] Critical | [N] High | [N] Medium | [N] Low | [N] Skipped | [N] Internal@@ -158,10 +158,10 @@ One-line digest of source counts and routing.1. **Discoveries first, recommendations second, details third** — never reorder.2. **Discoveries ≠ Recommendations** — different orderings (interestingness vs priority).-3. **PAI Relevance is primary** in both Discoveries and Recommendations — explain WHY this matters for PAI.+3. **LifeOS Relevance is primary** in both Discoveries and Recommendations — explain WHY this matters for LifeOS.4. **Every Recommendation has a Prior Status tag with file:line evidence.** No exceptions.5. **Quote the source.** Every technique includes actual quoted content or code.-6. **Map to PAI.** Every technique names a specific PAI file or component.+6. **Map to LifeOS.** Every technique names a specific LifeOS file or component.7. **No watch/read recommendations.** Extract the technique; don't point to content.8. **Skip boldly.** Content with no extractable technique → Skipped, not diluted.9. **Numbered cross-references** are consistent across Discoveries, Recommendations, and Technique Details.diff --git a/LifeOS/install/skills/Upgrade/SKILL.md b/LifeOS/install/skills/Upgrade/SKILL.mdindex 7ba40cea..1cfedc50 100644--- a/LifeOS/install/skills/Upgrade/SKILL.md+++ b/LifeOS/install/skills/Upgrade/SKILL.md@@ -1,6 +1,6 @@---name: Upgrade-description: "Generate prioritized PAI upgrade recommendations via 4 parallel threads: Thread 0 (prior-work audit — reads current Algorithm, PATTERNS.yaml, hooks, settings, recent ISAs, and KNOWLEDGE to assign Prior Status tags), Thread 1 (user context — TELOS goals, active projects, PAI system state), Thread 2 (source collection — Anthropic releases, YouTube channels, GitHub trending, custom sources), Thread 3 (internal reflections — Algorithm execution Q1/Q2 patterns). Output format: Discoveries table ranked by interestingness, then tiered Recommendations (CRITICAL/HIGH/MEDIUM/LOW) each with Prior Status (NEW/PARTIAL/DISCUSSED/REJECTED/DONE), then full Technique Details with before/after code. Every recommendation cites file:line evidence from Thread 0 — already-implemented items go to Skipped, never re-surfaced. Workflows: Upgrade, MineReflections, AlgorithmUpgrade, ResearchUpgrade, FindSources, TwitterBookmarks. USE WHEN upgrade, system upgrade, check Anthropic, new Claude features, algorithm upgrade, PAI upgrade, check bookmarks, scan bookmarks, twitter bookmarks, X bookmarks, bookmarks for upgrades, what have I bookmarked, mine reflections."+description: "Generate prioritized LifeOS upgrade recommendations via 4 parallel threads: Thread 0 (prior-work audit — reads current Algorithm, PATTERNS.yaml, hooks, settings, recent ISAs, and KNOWLEDGE to assign Prior Status tags), Thread 1 (user context — TELOS goals, active projects, LifeOS system state), Thread 2 (source collection — Anthropic releases, YouTube channels, GitHub trending, custom sources), Thread 3 (internal reflections — Algorithm execution Q1/Q2 patterns). Output format: Discoveries table ranked by interestingness, then tiered Recommendations (CRITICAL/HIGH/MEDIUM/LOW) each with Prior Status (NEW/PARTIAL/DISCUSSED/REJECTED/DONE), then full Technique Details with before/after code. Every recommendation cites file:line evidence from Thread 0 — already-implemented items go to Skipped, never re-surfaced. Workflows: Upgrade, MineReflections, AlgorithmUpgrade, ResearchUpgrade, FindSources, TwitterBookmarks. USE WHEN upgrade, system upgrade, check Anthropic, new Claude features, algorithm upgrade, LifeOS upgrade, check bookmarks, scan bookmarks, twitter bookmarks, X bookmarks, bookmarks for upgrades, what have I bookmarked, mine reflections."effort: high---@@ -29,12 +29,12 @@ If this directory exists, load and apply any PREFERENCES.md, configurations, or# Upgrade-**Primary Purpose:** Generate prioritized upgrade recommendations for PAI by understanding the user's context and discovering what's new in the ecosystem.+**Primary Purpose:** Generate prioritized upgrade recommendations for LifeOS by understanding the user's context and discovering what's new in the ecosystem.The skill runs **four parallel agent threads** that converge into personalized recommendations:- **Thread 0** — Prior-Work Audit (Algorithm, PATTERNS.yaml, hooks, skills, recent ISAs, KNOWLEDGE, feedback memory)-- **Thread 1** — User Context (TELOS, projects, recent work, PAI state)+- **Thread 1** — User Context (TELOS, projects, recent work, LifeOS state)- **Thread 2** — Source Collection (Anthropic, YouTube, custom sources, GitHub trending)- **Thread 3** — Internal Reflections (algorithm-reflections.jsonl)@@ -67,11 +67,11 @@ Section order: Discoveries → Recommendations → Technique Details → Interna1. **Every output item is a TECHNIQUE** — a specific pattern, code snippet, configuration, or approach.2. **Quote or code-block the actual content** — show exactly what was said/written.-3. **Map to PAI components** — every technique connects to a specific file, skill, workflow, or system component.+3. **Map to LifeOS components** — every technique connects to a specific file, skill, workflow, or system component.4. **Verify Prior State (Thread 0 gate)** — Before emitting ANY recommendation, confirm against Thread 0 inventory: is it already in Algorithm / PATTERNS.yaml / hooks / SKILL files / KNOWLEDGE / prior ISAs? Assign a Prior Status emoji and cite evidence. Items that are ✅ DONE go to Skipped, not Recommendations.5. **Two mandatory description fields, ≤2 sentences each, concrete and specific:**- **What It Is:** the technique itself — what it does, how it works, what capability it provides- - **How It Helps PAI:** the specific benefit — which component improves, what gap it fills+ - **How It Helps LifeOS:** the specific benefit — which component improves, what gap it fills6. **Provide implementation** — show before/after code or specific steps.7. **Skip, don't dilute** — if content has no extractable technique, put it in Skipped Content with reason.@@ -109,12 +109,12 @@ Section order: Discoveries → Recommendations → Technique Details → Interna1. **Extract, Don't Summarize** — pull specific techniques, never just link to sources.2. **Quote the Source** — actual code, doc quotes, or transcript excerpts.-3. **PAI-Contextualized** — every technique maps to a specific PAI file, skill, or component.+3. **LifeOS-Contextualized** — every technique maps to a specific LifeOS file, skill, or component.4. **Explain "Why You"** — "this helps because your [X] currently [Y]".5. **TELOS-Connected** — reference user's goals and challenges when explaining relevance.6. **Skip Boldly** — if content has no extractable technique, skip it entirely.7. **Implementation-Ready** — provide actual code changes, not vague recommendations.-8. **Claude Code Freshness via claude-code-guide** — when discoveries involve Claude Code internals (hooks, settings, slash commands, MCP, agent types, keybindings, Agent SDK, Claude API), spawn `Agent(subagent_type="claude-code-guide")` to verify PAI's current references match the latest API surface.+8. **Claude Code Freshness via claude-code-guide** — when discoveries involve Claude Code internals (hooks, settings, slash commands, MCP, agent types, keybindings, Agent SDK, Claude API), spawn `Agent(subagent_type="claude-code-guide")` to verify LifeOS's current references match the latest API surface.## Anti-Patterns (What NOT to Output)@@ -127,9 +127,9 @@ These output patterns are **FAILURES**:| "Consider looking into MCP updates" | Recommendation without extraction | "MCP now supports [specific feature]: [docs quote]" || "This could be useful for your workflows" | Vague relevance | "This improves your Browser skill because [specific gap it fills]" || "Several videos covered AI agents" | Count without content | "[N] videos skipped — no extractable techniques" |-| "This helps because it improves things" | Vague benefit | "How It Helps PAI: SecurityValidator currently only blocks commands. additionalContext enables reasoning context before tool execution, making decisions more nuanced." |+| "This helps because it improves things" | Vague benefit | "How It Helps LifeOS: SecurityValidator currently only blocks commands. additionalContext enables reasoning context before tool execution, making decisions more nuanced." || "A new hook feature" | No description of what it IS | "What It Is: PreToolUse hooks can return additionalContext that gets injected into the model's context before execution, enabling reasoning-based decisions rather than binary blocks." |-| "Top 3 Actions" or flat recommendation list | No priority tiers | Recommendations section with 🔴/🟠/🟡/🟢 tiers, each with PAI Relevance column |+| "Top 3 Actions" or flat recommendation list | No priority tiers | Recommendations section with 🔴/🟠/🟡/🟢 tiers, each with LifeOS Relevance column || Recommendations at the bottom | Actionable items buried after technique dump | 🔥 Recommendations section appears SECOND, technique details third || **Recommending something already implemented** | Wastes user trust | Move to Skipped with file:line evidence || **Re-surfacing rejected ideas without new context** | Drift from prior decisions | Only re-recommend if reason has changed; say what changed |diff --git a/LifeOS/install/skills/Upgrade/Workflows/AlgorithmUpgrade.md b/LifeOS/install/skills/Upgrade/Workflows/AlgorithmUpgrade.mdindex c3719f4b..4b105733 100644--- a/LifeOS/install/skills/Upgrade/Workflows/AlgorithmUpgrade.md+++ b/LifeOS/install/skills/Upgrade/Workflows/AlgorithmUpgrade.md@@ -5,13 +5,13 @@```bashcurl -s -X POST http://localhost:31337/notify \-H "Content-Type: application/json" \- -d '{"message": "Running the Algorithm Upgrade workflow to analyze and propose improvements to the PAI Algorithm"}' \+ -d '{"message": "Running the Algorithm Upgrade workflow to analyze and propose improvements to the LifeOS Algorithm"}' \> /dev/null 2>&1 &```Running the **AlgorithmUpgrade** workflow in the **Upgrade** skill to propose Algorithm improvements...-**Dedicated self-improvement workflow for the PAI Algorithm.** Combines internal reflection mining with Algorithm spec analysis to produce concrete, section-targeted upgrade proposals.+**Dedicated self-improvement workflow for the LifeOS Algorithm.** Combines internal reflection mining with Algorithm spec analysis to produce concrete, section-targeted upgrade proposals.**Trigger:** "algorithm upgrade", "upgrade algorithm", "improve the algorithm", "algorithm improvements", "what should we fix in the algorithm"@@ -68,8 +68,8 @@ Reflections map to Algorithm sections. This is the routing table for where fixesThe algorithm changes frequently. Every upgrade analysis MUST start by reading and internalizing the current version — not from memory, not from assumptions.```-1. Read PAI/ALGORITHM/LATEST to get current version string (e.g., "v3.7.0")-2. Read PAI/ALGORITHM/v{VERSION}.md — the FULL spec, every line+1. Read LIFEOS/ALGORITHM/LATEST to get current version string (e.g., "v3.7.0")+2. Read LIFEOS/ALGORITHM/v{VERSION}.md — the FULL spec, every line3. Produce a structured digest:ALGORITHM DIGEST: v{VERSION}@@ -211,7 +211,7 @@ Before proposing Algorithm changes, verify that the Algorithm's Claude Code refe```Use Agent tool with subagent_type=claude-code-guide:-"The PAI Algorithm has a Platform Capabilities table referencing Claude Code features.+"The LifeOS Algorithm has a Platform Capabilities table referencing Claude Code features.Read the current Algorithm spec at ~/.claude/LIFEOS/ALGORITHM/v{VERSION}.md (get version from ~/.claude/LIFEOS/ALGORITHM/LATEST).Verify that:diff --git a/LifeOS/install/skills/Upgrade/Workflows/FindSources.md b/LifeOS/install/skills/Upgrade/Workflows/FindSources.mdindex b4435b1d..3252f76c 100644--- a/LifeOS/install/skills/Upgrade/Workflows/FindSources.md+++ b/LifeOS/install/skills/Upgrade/Workflows/FindSources.md@@ -19,7 +19,7 @@ Discover and evaluate new sources to add to upgrade monitoring.## Overview-This workflow helps identify new sources worth monitoring for PAI-relevant updates:+This workflow helps identify new sources worth monitoring for LifeOS-relevant updates:- YouTube channels creating relevant content- Blogs and newsletters covering AI development- GitHub repositories with useful patterns@@ -54,7 +54,7 @@ Search: "MCP server tutorial YouTube"```For each discovered channel, evaluate:-- Content relevance to PAI infrastructure+- Content relevance to LifeOS infrastructure- Update frequency (active vs dormant)- Content quality and depth- Unique perspective or expertise@@ -72,7 +72,7 @@ Search: "LLM engineering blog"```Evaluate each source for:-- Relevance to PAI goals+- Relevance to LifeOS goals- Technical depth- Update frequency- Signal-to-noise ratio@@ -92,7 +92,7 @@ Search: site:github.com AI agent frameworkLook for:- Active maintenance- Good documentation-- Patterns applicable to PAI+- Patterns applicable to LifeOS- TypeScript preferred (stack alignment)---@@ -103,7 +103,7 @@ For each potential source, score:| Criterion | Weight | Score (1-5) ||-----------|--------|-------------|-| Relevance to PAI | 30% | |+| Relevance to LifeOS | 30% | || Content Quality | 25% | || Update Frequency | 20% | || Unique Value | 15% | |@@ -127,7 +127,7 @@ For each potential source, score:### [Source Name]**Type:** YouTube / Blog / GitHub / Other**URL:** [url]-**Relevance:** [Why this matters for PAI]+**Relevance:** [Why this matters for LifeOS]**Content Focus:** [What they cover]**Update Frequency:** [How often they post]@@ -162,7 +162,7 @@ Edit `~/.claude/LIFEOS/USER/CUSTOMIZATIONS/SKILLS/Upgrade/youtube-channels.json`### For Other Sources:Currently, non-YouTube sources are monitored via the base `sources.json`.-To request additions to base Anthropic monitoring, note them for next PAI release.+To request additions to base Anthropic monitoring, note them for next LifeOS release.```---diff --git a/LifeOS/install/skills/Upgrade/Workflows/MineReflections.md b/LifeOS/install/skills/Upgrade/Workflows/MineReflections.mdindex 2720b933..4b9918db 100644--- a/LifeOS/install/skills/Upgrade/Workflows/MineReflections.md+++ b/LifeOS/install/skills/Upgrade/Workflows/MineReflections.md@@ -110,7 +110,7 @@ UPGRADE CANDIDATE: [Theme Name]- [timestamp] [task_description] — "[relevant Q2 quote]"Root cause: [What structural issue causes this pattern]Proposed fix: [Specific change to Algorithm, skill, hook, or system]- Target file(s): [Which PAI files would change]+ Target file(s): [Which LifeOS files would change]Effort estimate: [Instant/Fast/Standard/Extended]```diff --git a/LifeOS/install/skills/Upgrade/Workflows/ResearchUpgrade.md b/LifeOS/install/skills/Upgrade/Workflows/ResearchUpgrade.mdindex 28cdeec0..73c048f2 100644--- a/LifeOS/install/skills/Upgrade/Workflows/ResearchUpgrade.md+++ b/LifeOS/install/skills/Upgrade/Workflows/ResearchUpgrade.md@@ -22,7 +22,7 @@ Deep dive on a specific upgrade opportunity to understand implementation detailsWhen the Upgrade workflow discovers something interesting, use this workflow to:1. Research the feature across authoritative sources2. Understand implementation details and best practices-3. Map to the user's PAI architecture+3. Map to the user's LifeOS architecture4. Generate a detailed implementation plan---@@ -90,11 +90,11 @@ Compile findings into structured analysis:| **Limitations** | Known constraints or caveats || **Best Practices** | Recommended usage patterns |-### Step 4: Map to User's PAI+### Step 4: Map to User's LifeOSUsing the user context from the Upgrade workflow (or gather fresh if not available):-| PAI Component | Potential Impact |+| LifeOS Component | Potential Impact ||---------------|------------------|| Skills System | New capabilities, better patterns || Hooks System | New triggers, better event handling |@@ -125,10 +125,10 @@ Using the user context from the Upgrade workflow (or gather fresh if not availab### Limitations[What it can't do or edge cases]-## PAI Implementation+## LifeOS Implementation### Opportunity-[What this enables in your PAI setup]+[What this enables in your LifeOS setup]### Implementation Steps- [ ] Step 1: [specific action]diff --git a/LifeOS/install/skills/Upgrade/Workflows/Upgrade.md b/LifeOS/install/skills/Upgrade/Workflows/Upgrade.mdindex 52c734ad..fdea25ea 100644--- a/LifeOS/install/skills/Upgrade/Workflows/Upgrade.md+++ b/LifeOS/install/skills/Upgrade/Workflows/Upgrade.md@@ -22,7 +22,7 @@ Running the **Upgrade** workflow in the **Upgrade** skill to check for upgrades.Four parallel threads, then synthesize:0. **Thread 0 (MANDATORY):** Prior-Work Audit — inventory current Algorithm, PATTERNS.yaml, hooks, skills, recent ISAs, KNOWLEDGE, feedback memory.-1. **Thread 1:** User context (TELOS, projects, recent work, PAI state).+1. **Thread 1:** User context (TELOS, projects, recent work, LifeOS state).2. **Thread 2:** External sources (Anthropic, YouTube, custom, GitHub trending).3. **Thread 3:** Internal reflections (algorithm-reflections.jsonl).4. **Synthesize:** filter discoveries against Thread 0 inventory; assign Prior Status; emit deltas only.@@ -36,7 +36,7 @@ Thread 0 output gates synthesis. No recommendation may be emitted without a Prio### Step 0: Launch Thread 0 — Prior-Work Audit (MANDATORY)-Spawn 5 parallel agents (`subagent_type=Explore`) to inventory current PAI state. Each returns an inventory with file:line evidence.+Spawn 5 parallel agents (`subagent_type=Explore`) to inventory current LifeOS state. Each returns an inventory with file:line evidence.**Agent 0a — Algorithm & Capabilities**Read: `~/.claude/LIFEOS/ALGORITHM/LATEST` + the file it points to, `~/.claude/LIFEOS/ALGORITHM/capabilities.md`, `mode-detection.md`, `~/.claude/LIFEOS/DOCUMENTATION/Algorithm/AlgorithmSystem.md`.@@ -59,7 +59,7 @@ Extract: recent decisions affecting upgrades (rejected/deferred/completed), releReturn: inventory with paths; flag anything that would DENY a future recommendation.**Agent 0e — Skill Surface**-Scan: `~/.claude/skills/*/SKILL.md` (description fields), `~/.claude/skills/_PAI/TOOLS/*.ts`, `~/.claude/skills/CreateSkill/Tools/*.ts` (validators).+Scan: `~/.claude/skills/*/SKILL.md` (description fields), `~/.claude/skills/_LIFEOS/TOOLS/*.ts`, `~/.claude/skills/CreateSkill/Tools/*.ts` (validators).Extract: skill counts/categories, existence of Monitor/Advisor/PreCompact wrappers, CreateSkill description-length cap, ToolActivityTracker capture scope (diffs? stdout? git state?).Return: inventory with file:line evidence.@@ -73,7 +73,7 @@ Spawn 4 parallel agents (`subagent_type=general-purpose`):**Agent 2 — Recent Work:** read `~/.claude/LIFEOS/MEMORY/STATE/work.json` and recent `MEMORY/WORK/` dirs (last 7 days). Extract active projects, recurring patterns, open tasks, recent accomplishments.-**Agent 3 — PAI State:** list `~/.claude/skills/`, `~/.claude/hooks/`, read `~/.claude/settings.json`. Extract installed skills, active hooks, configuration highlights, obvious gaps or opportunities.+**Agent 3 — LifeOS State:** list `~/.claude/skills/`, `~/.claude/hooks/`, read `~/.claude/settings.json`. Extract installed skills, active hooks, configuration highlights, obvious gaps or opportunities.**Agent 4 — Tech Stack:** from PROJECTS.md and recent work, identify primary languages, frameworks, deployment targets, key integrations.@@ -83,7 +83,7 @@ Spawn 4 parallel agents (`subagent_type=general-purpose`):**Agent 1 — Anthropic Sources**Run: `bun ${LIFEOS_SKILL_DIR}/Tools/Anthropic.ts`.-For each finding (release notes, GitHub commits, doc updates), extract specific techniques: exact syntax/API/configuration, quoted documentation showing usage, which PAI component this improves, before/after code where applicable. Skip findings with no concrete technique. Do NOT return vague "new release available" entries.+For each finding (release notes, GitHub commits, doc updates), extract specific techniques: exact syntax/API/configuration, quoted documentation showing usage, which LifeOS component this improves, before/after code where applicable. Skip findings with no concrete technique. Do NOT return vague "new release available" entries.**Agent 2 — YouTube Channels**1. Load channel config: `bun ~/.claude/LIFEOS/TOOLS/LoadSkillConfig.ts ../youtube-channels.json`.@@ -104,7 +104,7 @@ Check `~/.claude/LIFEOS/USER/CUSTOMIZATIONS/SKILLS/Upgrade/` for additional sour--jq '.items[] | {name, stars, description, url, topics, created, language}'```4. Dedup against `../State/github-trending.json`.-5. For each NEW repo, read README (`gh api 'repos/OWNER/REPO/readme' --jq '.content' | base64 -d | head -500`). Assess PAI relevance. Extract specific techniques/architectures/patterns. Skip forks, low-quality, irrelevant.+5. For each NEW repo, read README (`gh api 'repos/OWNER/REPO/readme' --jq '.content' | base64 -d | head -500`). Assess LifeOS relevance. Extract specific techniques/architectures/patterns. Skip forks, low-quality, irrelevant.6. Save updated seen-list to `../State/github-trending.json`.7. Focus on INSPIRATION (architectural decisions, novel approaches), not just repo names.@@ -114,9 +114,9 @@ Return within 90s; reduce per_page to 3 if slow.Spawn `Agent(subagent_type="claude-code-guide", run_in_background: true)`:-Verify PAI's Claude Code references against the latest API surface. Check: hook event types, slash commands, agent/subagent types, settings.json fields, MCP integration, Agent SDK, Claude API. For each area, return current features, recent additions, deprecated items, and PAI staleness risk (LOW/MEDIUM/HIGH). Focus on changes affecting hooks, skills, or Algorithm. Return within 90s.+Verify LifeOS's Claude Code references against the latest API surface. Check: hook event types, slash commands, agent/subagent types, settings.json fields, MCP integration, Agent SDK, Claude API. For each area, return current features, recent additions, deprecated items, and LifeOS staleness risk (LOW/MEDIUM/HIGH). Focus on changes affecting hooks, skills, or Algorithm. Return within 90s.-Output feeds Step 5 (Filter and Score) as source type `Claude Code Guide` and is cross-referenced against current PAI files for staleness.+Output feeds Step 5 (Filter and Score) as source type `Claude Code Guide` and is cross-referenced against current LifeOS files for staleness.### Step 2b: Launch Thread 3 — Internal Reflection Mining@@ -169,7 +169,7 @@ Sort by priority and tier:- **🟡 MEDIUM** — score 14-21, relevance > 4.- **🟢 LOW** — score < 14, or relevance 3-4.-Each recommendation: short action name, PAI Relevance (primary framing — WHY it matters), effort (Low/Med/High), files affected.+Each recommendation: short action name, LifeOS Relevance (primary framing — WHY it matters), effort (Low/Med/High), files affected.### Step 7: Output Report@@ -182,14 +182,14 @@ Section order: Discoveries → Recommendations → Technique Details → Interna**Critical output rules:**1. Discoveries first, recommendations second, details third.2. Discoveries ≠ Recommendations — different orderings (interestingness vs priority).-3. PAI Relevance is primary in both tables.+3. LifeOS Relevance is primary in both tables.4. Every Recommendation has a Prior Status tag with file:line evidence.5. Quote the source (actual content or code).-6. Map every technique to a specific PAI file or component.+6. Map every technique to a specific LifeOS file or component.7. Numbered cross-references consistent across Discoveries → Recommendations → Technique Details.8. No watch/read recommendations — extract, don't point.9. Skip boldly — content with no technique → Skipped.-10. Two mandatory description fields, ≤2 sentences each: **What It Is** and **How It Helps PAI**.+10. Two mandatory description fields, ≤2 sentences each: **What It Is** and **How It Helps LifeOS**.### Step 8: Registry Update — Feed Discoveries into Algorithm@@ -204,9 +204,9 @@ For each CRITICAL/HIGH recommendation, evaluate against the gate:| Discovery Type | Integration Target | Action ||----------------|--------------------|--------|| New Claude Code command/skill | Algorithm Platform Capabilities table | Propose new row |-| Enhancement to existing PAI skill | Relevant SKILL.md description | Propose updated description with workflow guidance |+| Enhancement to existing LifeOS skill | Relevant SKILL.md description | Propose updated description with workflow guidance || Useful behavioral pattern | Algorithm Platform Capabilities (Techniques section) | Propose new technique row |-| Major new capability | New PAI skill | Propose scaffold via CreateSkill |+| Major new capability | New LifeOS skill | Propose scaffold via CreateSkill |Output:```markdowndiff --git a/LifeOS/install/skills/Webdesign/SKILL.md b/LifeOS/install/skills/Webdesign/SKILL.mdindex 1cc9e20e..aefb53b1 100644--- a/LifeOS/install/skills/Webdesign/SKILL.md+++ b/LifeOS/install/skills/Webdesign/SKILL.md@@ -111,7 +111,7 @@ Accumulate lessons here. Information density is highest in gotchas.- **DirectDesign is self-contained.** The aesthetic doctrine lives in `References/FrontendDesignPhilosophy.md` (mirrored from anthropics/skills MIT source). No runtime dependency on the upstream `frontend-design` Claude Code plugin being installed — DirectDesign works in any LifeOS environment.- **Native `/design` + `/design-sync` are the code-bound path now (CONFIRMED).** Anthropic's official docs (support.claude.com/en/articles/14604416) document both commands, GA on Pro/Max/Team/Enterprise as of June 2026. `/design-sync` does bidirectional codebase↔design-system sync — use it instead of the Interceptor handoff-bundle apparatus for anything code-bound. Still no public REST API or MCP server; the CLI commands are the programmatic surface. If they don't show up, run `/update`.- **The ClaudeDesign/Interceptor path (Path 3) is unproven and currently blocked.** It has never run end-to-end — every real run of this skill used DirectDesign. The `interceptor-test` profile is not logged into claude.ai, so `DriveClaudeDesign.ts` reaches the marketing wall, not the app. The tool targets controls by accessibility-tree heuristics (composer by `role=textbox`/contenteditable, send by `/send|submit/`, export by `/export/`), so a moved button is NOT the blocker — the missing auth and the native-CLI supersession are. Before trusting Path 3: log the test profile into claude.ai once, then do a single supervised run.-- **Real Chrome required.** Use the Interceptor skill — it is the only sanctioned browser automation in PAI. Claude Design's UI depends on claude.ai's full session state; CDP-based automation trips bot detection and drops session cookies.+- **Real Chrome required.** Use the Interceptor skill — it is the only sanctioned browser automation in LifeOS. Claude Design's UI depends on claude.ai's full session state; CDP-based automation trips bot detection and drops session cookies.- **Handoff bundles are directories, not single files.** A bundle contains `PROMPT.md`, optional `tokens.json`, `components/`, `assets/`, and framework-specific scaffolding. Treat the whole directory as the unit.- **`frontend-design` plugin auto-activates.** When the handoff bundle is fed to Claude Code, the plugin (already installed in the official marketplace) picks up the frontend work automatically — do NOT manually invoke it.- **Claude Design's design-system extraction runs during onboarding.** For a new codebase you want Claude Design to understand, run `ExtractDesignSystem` FIRST before `CreatePrototype` — otherwise Claude Design uses generic defaults and overrides your tokens.diff --git a/LifeOS/install/skills/Webdesign/Workflows/DirectDesign.md b/LifeOS/install/skills/Webdesign/Workflows/DirectDesign.mdindex 5d68dd7d..26ae38d4 100644--- a/LifeOS/install/skills/Webdesign/Workflows/DirectDesign.md+++ b/LifeOS/install/skills/Webdesign/Workflows/DirectDesign.md@@ -130,5 +130,5 @@ If `~/.claude/LIFEOS/USER/CUSTOMIZATIONS/SKILLS/Webdesign/PREFERENCES.md` exists- **Skipping Step 0** — losing the doctrine and reverting to AI defaults. Always read the philosophy file first.- **Skipping Step 1's explicit aesthetic declaration** — the model drifts into generic "modern clean" when the register isn't named on screen.- **Picking the same register every session** — convergence is the AI-slop signal. Vary deliberately.-- **Saying `verified` without an Interceptor screenshot** — that is a doctrine violation in PAI. The screenshot is the verification.+- **Saying `verified` without an Interceptor screenshot** — that is a doctrine violation in LifeOS. The screenshot is the verification.- **Maximalism without commitment** — half-committed maximalism reads as cluttered. If you choose maximalist, *commit*: more layers, more motion, more density. Same for any register at any pole.diff --git a/README.md b/README.mdindex 9bae4e24..b9559338 100644--- a/README.md+++ b/README.md@@ -8,8 +8,8 @@**The AI-Powered Life Operating System**-[](Releases/v6.0.0/)-[](Releases/v6.0.0/README.md)+[](Releases/v6.0.5/)+[](Releases/v6.0.5/README.md)[](https://github.com/danielmiessler/LifeOS/stargazers)[](./LICENSE)@@ -185,6 +185,13 @@ MIT License - see [LICENSE](LICENSE) for details.<br/>+**v6.0.5 (2026-07-04) — Rename in the Code, New Harvest Skill**+- **PAI→LifeOS rename reaches the code** — code identifiers and doc prose now read LifeOS throughout; runtime-critical paths and regexes were left byte-identical on purpose, so the prose is clean and nothing breaks.+- **New Harvest skill** — mine any URL, video, or article for what's genuinely useful to your LifeOS, ranked and mapped against your whole system. Report-only; adoption is a separate step.+- **Algorithm v6.24.0** — motion verification: an ISC about animation, transition, or a multi-step flow closes on a frame-scrub gallery, never a single screenshot.+- **Installer fix** — the bootstrap `install.sh` now fetches the version it advertises.+- [Full release notes](Releases/v6.0.5/README.md)+**v6.0.0 (2026-07-02) — One Skill, One Install**- **Skill-based distribution** — the whole system now ships as a single self-contained skill (`LifeOS/`): the orchestrator (SKILL.md + Workflows + Tools) plus a complete install payload (system prompt, Algorithm, 49 skills, hooks, agents, Pulse, statusline, USER + MEMORY scaffolds). One directory, one install.- **First release under the LifeOS name** — the project was PAI (Personal AI Infrastructure); this is the same system, renamed.diff --git a/Releases/v6.0.5/README.md b/Releases/v6.0.5/README.mdnew file mode 100644index 00000000..45478833--- /dev/null+++ b/Releases/v6.0.5/README.md@@ -0,0 +1,68 @@+<div align="center">++<img src="https://raw.githubusercontent.com/danielmiessler/LifeOS/main/images/lifeos-logo.png" alt="LifeOS" width="200">++# LifeOS 6.0.5++**The LifeOS rename lands in the code — plus a new Harvest skill.**++[](../../LifeOS/install/skills/)+[](../../LifeOS/install/LifeOS/ALGORITHM/)+[](../../LifeOS/install/LifeOS/PULSE/)++</div>++---++LifeOS 6.0.5 is a maintenance release that carries the PAI→LifeOS rename the rest of the way through the system, adds the new **Harvest** skill, and sharpens the Algorithm's verification doctrine. Same system as 6.0.0, cleaner throughout.++## What's new++### The rename reaches the code++6.0.0 renamed the project. 6.0.5 renames the *code* — class-by-class, deliberately. Code identifiers and documentation prose now read "LifeOS" throughout, while behavioral code (paths, regexes, labels the system depends on at runtime) was left byte-identical on purpose. A blind find-and-replace across running code is how you corrupt a working system; the rename was scoped so the prose is clean and nothing breaks.++### New skill — Harvest++**Harvest** mines a single piece of content — a URL, a YouTube video, an article, raw text — for anything genuinely useful to your LifeOS, judged against your whole system. It fetches the content, pulls out candidate ideas and techniques, tags each with a prior status (new / partial / done), ranks by usefulness, and reports where each one maps. It's report-only: adopting anything is always a separate, explicit step.++### Algorithm v6.24.0 — motion gets verified++Verification doctrine gains one clause: an ISC whose subject is *motion* — an animation, a transition, a drag, a multi-step flow — now closes only on a frame-scrub gallery, never a single screenshot. One still can't capture motion, so the doctrine stops pretending it can. Static renders still close on one screenshot; the rule is keyword-triggered so it doesn't tax every task.++### Installer fix++The bootstrap `install.sh` pinned the wrong release tarball. It now fetches the version it advertises. If you install from the one-liner, you get 6.0.5.++## What's different from 6.0.0++| | v6.0.0 | v6.0.5 |+|---|---|---|+| **Naming** | Renamed in docs and product | Renamed through code identifiers + prose |+| **Skills** | 49 | 50 (adds Harvest) |+| **Algorithm** | v6.23.0 | v6.24.0 (motion verification) |+| **Installer** | Pinned tarball could lag | Fetches the advertised version |++Everything 6.0.0 introduced is still here: one self-contained skill, install-by-prompt, full Pulse on first boot, the seven-phase Algorithm, the ISA primitive, structured memory. This release refines; it doesn't change what the system is.++## Install++**Give it to your AI.** Paste this into Claude Code and say **"install this"** — your AI does the whole setup.++```bash+curl -fsSL https://ourlifeos.ai/install.sh | bash+```++Prefer the terminal? Run the same command yourself. You'll need **Claude Code** and **bun**.++## Upgrading++Back up first — `cp -r ~/.claude ~/.claude-backup-$(date +%Y%m%d)` — then install. Your `USER/` customizations are never touched, and settings merge rather than overwrite.++---++<div align="center">++Same system, cleaner throughout.++</div>