You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs: sync README/CLAUDE.md/ROADMAP to post-Phase-1 + Stage-A state
Phase 1 (workspace wiring) is done and Stage-A health fixes landed, but the front-door docs still described the pre-wiring state. README status line corrected (workspaces wired; remote still a Phase-5 waiver); CLAUDE.md known-issues #1/#2 moved to Resolved citing HOK-01 + the in-package memories fix, status bumped to 'Phase 1 done; Health Pass in progress'; ROADMAP Phase 1 boxes ticked (ab8aad8) + Phase 2 threshold ticked (43155a8) + a P5 line to remove packages/*/.github before the remote. Root package.json gains a //buildOrder note (kernel-first order is load-bearing; pwsh smoke deliberately excluded from cross-platform verify).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: .claude/CLAUDE.md
+11-6Lines changed: 11 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -39,7 +39,7 @@ Operational consequences:
39
39
40
40
## Status — PROTOTYPE (bootstrapped 2026-06-10)
41
41
42
-
Phase 0 of 6 done. Pick up via `ROADMAP.md` (six phases: wiring → runtime quality → unified CLI → docs → npm/GitHub bootstrap → publish + retirement).
42
+
Phase 1 done (workspace wiring); Health Pass (dogfood-swarm) in progress; Phase 2 hook-threshold landed. Pick up via `ROADMAP.md` (six phases: wiring → runtime quality → unified CLI → docs → npm/GitHub bootstrap → publish + retirement).
43
43
44
44
## Source-of-truth rule (load-bearing)
45
45
@@ -69,17 +69,22 @@ Decompose-by-secrets (Parnas 1972) is right for N humans, operationally broken f
69
69
70
70
## Verification
71
71
72
-
-Per-package (until Phase 1 wires the root): `npm test` inside `packages/{kernel,memories,rules}` — all three have real suites.
72
+
-Root: `npm run verify` (build + per-package verify across kernel/memories/rules); `npm test` / `npm run build` also run at root. Per-package still works: `npm test` inside `packages/{kernel,memories,rules}` — all three have real suites (228 green as of Stage A).
73
73
- Hook: `apps/hook/smoke-test.ps1` (drives the hook with sample stdin JSON; also run it against the live copy after any hook change).
1.**Hook has no score threshold.** Design said below-threshold → silence; implementation injects top-5 regardless (observed: irrelevant claude-guardian/duel-system pointers on a memory-os prompt).
80
-
2.**Junk index entries** derived from prose lines: `memory-files`, `full-frame`, `see-also-…` (100+-char id). Root cause is in `packages/memories` parsing/index-gen, not the data.
81
-
3.**Weak keyword matching** on auto-extracted keywords; `ai-loadout overlaps` shows routing ambiguities. Hand-curated frontmatter keywords is the cheap fix.
82
-
4. One LONG_SUMMARY warning left in the store index (`newsletter-publishing-…`).
79
+
**Resolved (Stage A health pass):**
80
+
81
+
-~~**Hook has no score threshold.**~~**FIXED (HOK-01, commit `43155a8`)** — `apps/hook/loadout-hook.mjs` now applies a `HOOK_MIN_SCORE=0.3` floor, so below-threshold matches emit nothing (the design's silence behavior). The off-topic claude-guardian/duel-system pointers were the symptom.
82
+
-~~**Junk index entries** derived from prose lines (`memory-files`, `full-frame`, `see-also-…`).~~**FIXED in-package (commit `a4fa04f`)** — `packages/memories` parser/index-gen no longer turns prose citations into index entries, plus an `ID_TOO_LONG` validate rule. The live store/global index regenerates upstream via the Index Freshness Ritual (the fix is in the package; the data clears on the next regen).
83
+
84
+
**Open (Phase 2):**
85
+
86
+
1.**Weak keyword matching** on auto-extracted keywords; `ai-loadout overlaps` shows routing ambiguities. Hand-curated frontmatter keywords is the cheap fix.
87
+
2. One LONG_SUMMARY warning left in the store index (`newsletter-publishing-…`).
Copy file name to clipboardExpand all lines: README.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# memory-os
2
2
3
-
> **Prototype, 2026-06-10.** Consolidated Knowledge OS for the studio — folds `ai-loadout` (kernel) + `claude-memories` (MEMORY.md adapter) + `claude-rules` (CLAUDE.md adapter) + the runtime UserPromptSubmit pointer-injection hook into a single repo. Not yet wired as workspaces, not yet published, not yet on a remote.
3
+
> **Prototype, 2026-06-10.** Consolidated Knowledge OS for the studio — folds `ai-loadout` (kernel) + `claude-memories` (MEMORY.md adapter) + `claude-rules` (CLAUDE.md adapter) + the runtime UserPromptSubmit pointer-injection hook into a single repo. Wired as npm workspaces (Phase 1 done — `npm install` + `npm run build`/`test`/`verify` work at root). Not yet published; no remote yet (a deliberate Phase-5 waiver — see `.claude/CLAUDE.md`).
4
4
5
5
## Pickers start here
6
6
@@ -17,7 +17,7 @@ memory-os/
17
17
│ ├── memories/ # was @mcptoolshop/claude-memories (unpublished)
18
18
│ └── rules/ # was @mcptoolshop/claude-rules (unpublished)
19
19
├── apps/
20
-
│ └── hook/ # mirror of ~/.claude/loadout-hook/ (the LIVE one)
20
+
│ └── hook/ # workspace member; mirrors ~/.claude/loadout-hook/ (the LIVE one)
Goal: make the four trees install + build + test under one root.
17
17
18
-
-[] Root `package.json` with `workspaces: ["packages/*", "apps/*"]` — **npm workspaces** (studio standard; not pnpm/yarn — `workspace:*` protocol is NOT valid npm, depend by package name and let the workspace resolve it)
19
-
-[] One root `tsconfig.base.json` extended by each package
18
+
-[x] Root `package.json` with `workspaces: ["packages/*", "apps/*"]` — **npm workspaces** (studio standard; not pnpm/yarn — `workspace:*` protocol is NOT valid npm, depend by package name and let the workspace resolve it) — commit `ab8aad8`
19
+
-[x] One root `tsconfig.base.json` extended by each package — commit `ab8aad8`
20
20
-[ ]**Package names do not change in this phase.**`packages/kernel` keeps `@mcptoolshop/ai-loadout` (it is published under that name; renaming is a Phase 5 decision). `apps/hook`'s existing `"@mcptoolshop/ai-loadout"` dependency then resolves to the workspace copy automatically.
21
21
-[ ] Each package keeps its own `package.json`; versions follow the root version from Phase 5 onward
22
-
-[]`npm ci` at root → working install; `npm run build --workspaces` builds all four; `npm test --workspaces` green
22
+
-[x]`npm ci` at root → working install; root `build`/`test`/`verify` scripts run the three TS packages in order, all green (203 baseline → 228 after Stage A) — commit `ab8aad8`
23
23
-[ ] Sync check: `git diff --no-index apps/hook ~/.claude/loadout-hook` shows no drift (run `apps/hook/smoke-test.ps1` after any hook change)
24
24
25
25
Gate: green root build, all existing suites pass, hook still injects when driven with stdin JSON, mirror-vs-live diff clean.
@@ -28,7 +28,7 @@ Gate: green root build, all existing suites pass, hook still injects when driven
28
28
29
29
The hook went live 2026-06-10 and immediately produced field evidence. Fix the known defects before building more surface on top of them.
30
30
31
-
-[]**Score threshold in the hook.**The design said "below-threshold match → emit nothing"; the implementation takes top-5 regardless (`apps/hook/loadout-hook.mjs`filters only `manual` entries). Observed result: a memory-os prompt got claude-guardian and duel-system pointers. Add a minimum-score floor to the filter; calibrate against `~/.ai-loadout/usage.jsonl`+ a sample of real prompts.
31
+
-[x]**Score threshold in the hook.**(DONE — commit `43155a8`, HOK-01.) `apps/hook/loadout-hook.mjs`now applies a `HOOK_MIN_SCORE=0.3` floor alongside the `manual`-entry filter, so below-threshold matches emit nothing. Resolves the observed off-topic claude-guardian/duel-system pointers. (Calibration against accumulated `usage.jsonl`can still tune the floor later.)
32
32
-[ ]**Index hygiene at the source.** The generated index contains junk entries derived from prose lines that aren't topic refs — confirmed examples: `memory-files` (from a "- Memory files:" line), `full-frame` (from "Full frame: …"), `see-also-…` (a 100+-char id from a "See also:" line). Fix in `packages/memories`' parser/index-gen: skip refs whose derived name is empty/generic, and add a `validate` rule flagging ids > 60 chars. Then regenerate the store index + global copy and confirm the junk is gone.
33
33
-[ ]**Fix the 1 remaining LONG_SUMMARY entry** (`newsletter-publishing-…`, 159-char summary) — shorten its MEMORY.md line.
34
34
-[ ]**Keyword quality pass.** Weak matches come from generic auto-extracted keywords. Use `ai-loadout overlaps` to find routing ambiguities; hand-curate keywords (via frontmatter) for the worst offenders.
@@ -73,6 +73,7 @@ Goal: reserve the name, set up Trusted Publishing, create the GitHub repo.
73
73
-[ ] Create `mcp-tool-shop-org/memory-os` on GitHub (private at first; public at Phase 6 publish) — this closes the repo-first waiver
74
74
-[ ] Add remote, push everything to date
75
75
-[ ] CI workflow per `github-actions.md` rules: paths-gated, ubuntu-latest only, concurrency block, max 2 workflow files
76
+
- Remove `packages/*/.github/` (8 inert workflow files + 2 dependabot.yml) BEFORE adding the remote; author a single root CI per github-actions.md (max 2 workflows, paths-gated, one pages deploy).
76
77
77
78
## Phase 6 — First real publish + upstream retirement (1 session)
Copy file name to clipboardExpand all lines: package.json
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -10,6 +10,7 @@
10
10
"packages/*",
11
11
"apps/*"
12
12
],
13
+
"//buildOrder": "INTENTIONAL: kernel must build before memories and rules — they import the kernel's built dist. Do NOT 'simplify' build/test/verify to `--workspaces` (npm does not guarantee topo order) or the order breaks. The PowerShell hook smoke-test (apps/hook/smoke-test.ps1) is deliberately NOT in verify: it is Windows/rig-specific and would break Linux CI.",
13
14
"scripts": {
14
15
"build": "npm run build -w packages/kernel && npm run build -w packages/memories && npm run build -w packages/rules",
15
16
"test": "npm run test -w packages/kernel && npm run test -w packages/memories && npm run test -w packages/rules",
0 commit comments