diff --git a/.claude/memory/decisions.md b/.claude/memory/decisions.md index b12da8e..417e5ad 100644 --- a/.claude/memory/decisions.md +++ b/.claude/memory/decisions.md @@ -1639,3 +1639,9 @@ Supersedes [[BDR-030]]. - **Why**: machine pulled before fetch → chrome-extensions SKILL.md missing = doctor FAIL → `make update` (ends on doctor.sh) exits 1. User chose warn only 2026-11-22. - **Alternatives rejected**: keep FAIL (update red until `make plugin`). - **Reference**: 14bee52; tests TREE_OWNED_* + TREE_NAMES_ERREXIT_BROKEN_LOCK in lib/tests/doctor-vendored.test.sh; open LOW: lock key unvalidated in `_dv_tree_expectations` (TODO, 7e29279). + +## BDR-155 — Advisor once per main-loop run of plan/reflect-row skills; model-router prepends rule to skill body [accepted] (2026-11-24) +**Context**: User 2026-11-23: advisor called too rarely; wants it wherever main used to route to Fable (pre-BDR-150 best tier = plan/reflect rows). 7-day tally: 96 main runs of those skills, 65 advisor calls. +**Decision**: Main-loop run of skill whose model-router row = `plan`|`reflect` makes one advisor call on settled plan/diagnosis/fix, before execute or report. Call at point 1/2/3 counts. Only challenge-plan § SKIP + point 3 skips waive; other challenge guards (cosmetic /hotfix, audit/conservative modes, clean stop) still get call. Nested under plan/reflect run: none. Carrier: model-router mod prepends ADVISOR_NOTE to skill body (skill.prompt) on main loads (Skill call w/o agentId, typed slash), never sub-agent/preload. Rule text = `lib/effort-shift.md` § Advisor point 4 "Per run". Amends BDR-150: call point, never route. +**Alternatives**: Skill-result `context` (attachment channel, ignored per LRN-303); CLAUDE.global.md line (320/320 budget); per-skill body edits (55 rows, drift). +**Consequences**: ~140k input tokens per main call; harden/seo/geo/web-validate audit modes + cosmetic hotfix gain a call. Accepted gaps (shortcut comments register.ts): same-name sub-agent load mid main Skill call steals note; typed slash during in-flight Skill call loses it; concurrent main calls keep last marker. Behavioural tally deferred to 1-week re-measure. Commits d9f0f42, 1d69fce. diff --git a/.claude/memory/journal.md b/.claude/memory/journal.md index 0160957..13983ae 100644 --- a/.claude/memory/journal.md +++ b/.claude/memory/journal.md @@ -808,3 +808,6 @@ rules: ## 2026-11-23 - prompt-audit Opus 5.5: always-on ~14k tok (doctor), 5 small edits CLAUDE.global merged 38be889; olmind not found; slim gitflow/memory text = BDR-125 candidate. - advisor trigger before root-cause diagnosis / user-run commands (7b63507). Measured: unserved advisor blocks beside tool_use all re-served next msg, no lost calls; lever dropped. + +## 2026-11-24 +- advisor per-run note (d9f0f42, docs 1d69fce): mod prepends one-call rule on main plan/reflect skill loads; gates MET, sec PASS, verifier ECARTS(1)=AC6 live check pending /reload-plugins. BDR-155, LRN-306. diff --git a/.claude/memory/learnings.md b/.claude/memory/learnings.md index 5b3766c..b3198e6 100644 --- a/.claude/memory/learnings.md +++ b/.claude/memory/learnings.md @@ -2192,3 +2192,8 @@ Rule: when editing a doctrine file under structure locks, grep the test's lock s - **Context**: 2026-11-21/22 ship-feature modern-web-guidance. Dry run overlapped running executor → false reds; re-run after report = MET. Separate real red same run: row 10 `FAIL bun not on PATH` (see learnings line ~2009, fixed by `PATH="$HOME/.bun/bin:$PATH"` in oracle). - **Apply**: dry run only with no live executor (before first dispatch, or after its report). Red dry run during a dispatch → re-run after report before acting on it. - **Reference**: lib/verify-secure-loop.md § BEFORE THE FIRST DISPATCH; BDR-151 lever 4 (contract dry run). + +## LRN-306 — doctrine-citers captures unquoted section label over following words; close label with paren (2026-11-24) +**Pattern**: doctrine-citers T6 (lib/tests/doctrine-citers.test.sh:78) captures unquoted `§