@mindrian_os/cli 2.0.0-beta.3 → 2.0.0-beta.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1829) hide show
  1. package/.claude-plugin/plugin.json +21 -0
  2. package/.mcp.json +14 -0
  3. package/CHANGELOG.md +497 -0
  4. package/agents/analogy-query-fetcher.md +119 -0
  5. package/agents/brain-query.md +91 -0
  6. package/agents/competitor-watch-fetcher.md +94 -0
  7. package/agents/framework-runner.md +258 -0
  8. package/agents/grading.md +216 -0
  9. package/agents/grant-reviewer.md +191 -0
  10. package/agents/investor.md +141 -0
  11. package/agents/larry-extended.md +215 -0
  12. package/agents/meeting-perspective-extractor.md +94 -0
  13. package/agents/opportunity-scanner.md +105 -0
  14. package/agents/persona-analyst.md +201 -0
  15. package/agents/research.md +103 -0
  16. package/agents/reverse-salient-agent.md +42 -0
  17. package/agents/vault-section-reviewer.md +107 -0
  18. package/assets/banner-showcase.html +537 -0
  19. package/assets/fonts/BebasNeue-Regular.ttf +0 -0
  20. package/assets/fonts/Inter-Bold.ttf +0 -0
  21. package/assets/fonts/Inter-Regular.ttf +0 -0
  22. package/assets/logo.svg +10 -0
  23. package/bin/local-chain-recommender.cjs +256 -0
  24. package/bin/mindrian-brain-mcp-client.cjs +319 -0
  25. package/bin/mindrian-mcp-server.cjs +445 -0
  26. package/bin/mindrian-mcp-shim.cjs +100 -0
  27. package/bin/mindrian-tools.cjs +784 -0
  28. package/commands/act.md +529 -0
  29. package/commands/admin.md +439 -0
  30. package/commands/agentshield.md +49 -0
  31. package/commands/analyze-needs.md +78 -0
  32. package/commands/analyze-systems.md +73 -0
  33. package/commands/analyze-timing.md +98 -0
  34. package/commands/auto-explore.md +85 -0
  35. package/commands/beautiful-question.md +76 -0
  36. package/commands/bono.md +152 -0
  37. package/commands/brain-derive.md +137 -0
  38. package/commands/build-knowledge.md +121 -0
  39. package/commands/build-thesis.md +94 -0
  40. package/commands/causal.md +269 -0
  41. package/commands/challenge-assumptions.md +78 -0
  42. package/commands/compare-ventures.md +117 -0
  43. package/commands/correct-reference-now.md +88 -0
  44. package/commands/dashboard.md +144 -0
  45. package/commands/deck.md +117 -0
  46. package/commands/deep-grade.md +214 -0
  47. package/commands/diagnose.md +131 -0
  48. package/commands/diagnostics.md +195 -0
  49. package/commands/dial-memory-refresh.md +113 -0
  50. package/commands/diffusion.md +129 -0
  51. package/commands/discover.md +221 -0
  52. package/commands/doctor.md +271 -0
  53. package/commands/dogfood-flush.md +130 -0
  54. package/commands/dominant-designs.md +76 -0
  55. package/commands/eureka.md +315 -0
  56. package/commands/explain-decision.md +135 -0
  57. package/commands/explore-domains.md +78 -0
  58. package/commands/explore-futures.md +67 -0
  59. package/commands/explore-opportunity.md +172 -0
  60. package/commands/explore-trends.md +78 -0
  61. package/commands/export.md +128 -0
  62. package/commands/feynman-timeline-refresh.md +102 -0
  63. package/commands/file-meeting.md +1195 -0
  64. package/commands/find-analogies.md +369 -0
  65. package/commands/find-bottlenecks.md +108 -0
  66. package/commands/find-connections.md +111 -0
  67. package/commands/funding.md +114 -0
  68. package/commands/futures.md +128 -0
  69. package/commands/grade-grant.md +297 -0
  70. package/commands/grade.md +257 -0
  71. package/commands/graph.md +218 -0
  72. package/commands/hat-briefing.md +163 -0
  73. package/commands/heal.md +72 -0
  74. package/commands/help.md +176 -0
  75. package/commands/hmi-status.md +75 -0
  76. package/commands/ignite.md +229 -0
  77. package/commands/ingest-methodology.md +128 -0
  78. package/commands/intel-pipeline.md +133 -0
  79. package/commands/jtbd.md +262 -0
  80. package/commands/leadership.md +113 -0
  81. package/commands/lean-canvas.md +74 -0
  82. package/commands/macro-trends.md +88 -0
  83. package/commands/map-unknowns.md +76 -0
  84. package/commands/memory-cortex-reach.md +79 -0
  85. package/commands/memory.md +213 -0
  86. package/commands/models.md +200 -0
  87. package/commands/mos-reason.md +489 -0
  88. package/commands/mos.md +162 -0
  89. package/commands/mullins.md +155 -0
  90. package/commands/mva-brief.md +86 -0
  91. package/commands/mva-option.md +119 -0
  92. package/commands/mva-report.md +76 -0
  93. package/commands/new-project.md +633 -0
  94. package/commands/new-surface.md +116 -0
  95. package/commands/onboard.md +489 -0
  96. package/commands/operator.md +168 -0
  97. package/commands/opportunities.md +177 -0
  98. package/commands/organize.md +74 -0
  99. package/commands/persona.md +276 -0
  100. package/commands/pipeline.md +167 -0
  101. package/commands/present.md +125 -0
  102. package/commands/publish.md +227 -0
  103. package/commands/pws-brain.md +154 -0
  104. package/commands/qualify-opportunity.md +113 -0
  105. package/commands/query.md +70 -0
  106. package/commands/radar.md +110 -0
  107. package/commands/reanalyze.md +124 -0
  108. package/commands/research.md +467 -0
  109. package/commands/room.md +385 -0
  110. package/commands/rooms.md +682 -0
  111. package/commands/root-cause.md +77 -0
  112. package/commands/rs-experts.md +153 -0
  113. package/commands/rs-explain.md +134 -0
  114. package/commands/rs-fetch.md +119 -0
  115. package/commands/rs-thesis.md +131 -0
  116. package/commands/scenario-plan.md +80 -0
  117. package/commands/scheduled-tasks.md +308 -0
  118. package/commands/score-innovation.md +78 -0
  119. package/commands/scout.md +379 -0
  120. package/commands/setup.md +658 -0
  121. package/commands/show.md +71 -0
  122. package/commands/skill.md +108 -0
  123. package/commands/snapshot.md +179 -0
  124. package/commands/speakers.md +118 -0
  125. package/commands/splash.md +55 -0
  126. package/commands/stance.md +91 -0
  127. package/commands/status.md +109 -0
  128. package/commands/structure-argument.md +82 -0
  129. package/commands/suggest-next.md +141 -0
  130. package/commands/systems-thinking.md +224 -0
  131. package/commands/think-hats.md +86 -0
  132. package/commands/trending-to-absurd.md +151 -0
  133. package/commands/update.md +256 -0
  134. package/commands/user-needs.md +77 -0
  135. package/commands/validate.md +77 -0
  136. package/commands/value-proposition.md +116 -0
  137. package/commands/vault.md +330 -0
  138. package/commands/visualize.md +71 -0
  139. package/commands/whitespace.md +541 -0
  140. package/commands/wiki.md +96 -0
  141. package/data/ROOM.md +47 -0
  142. package/data/brain-census.generated.json +2617 -0
  143. package/data/brain-orchestration-projection.json +4973 -0
  144. package/data/brain-packet-schema.json +545 -0
  145. package/data/brain-surface-contract.json +32 -0
  146. package/data/capability-ledger.json +391 -0
  147. package/data/capability-map-registry.json +23 -0
  148. package/data/command-registry.json +2433 -0
  149. package/data/connector-coverage-ledger.json +1618 -0
  150. package/data/connector-out-of-spine-allowlist.json +71 -0
  151. package/data/connector-registry.json +3637 -0
  152. package/data/corpus-stats-source.json +11 -0
  153. package/data/corpus-stats.generated.json +10 -0
  154. package/data/cross-domain-analogues.json +15 -0
  155. package/data/deck-aliases.json +6 -0
  156. package/data/deck-styles.json +85 -0
  157. package/data/deployment-surfaces.json +69 -0
  158. package/data/dispatch-framework-map.json +18 -0
  159. package/data/doctor-modules.json +206 -0
  160. package/data/dual-graph-health-baseline.json +12 -0
  161. package/data/eureka-critic-tags.json +32 -0
  162. package/data/first-reward-surfaces.json +66 -0
  163. package/data/first-touch-surfaces.json +60 -0
  164. package/data/flagship-floor-set.json +37 -0
  165. package/data/framework-names.json +121 -0
  166. package/data/grant-rubric-fixtures/early-stage-pre-seed.json +18 -0
  167. package/data/grant-rubric-fixtures/early-stage-round-a.json +18 -0
  168. package/data/grant-rubric-fixtures/early-stage-seed.json +18 -0
  169. package/data/grant-rubric-fixtures/hybrid-seed-incentive.json +18 -0
  170. package/data/grant-rubric-fixtures/rd-fund.json +18 -0
  171. package/data/grant-rubric-fixtures/regional-innovation-incubators.json +18 -0
  172. package/data/grant-rubric-fixtures/technology-incubators.json +18 -0
  173. package/data/grant-rubric-fixtures/tnufa.json +167 -0
  174. package/data/grant-rubric-schema.json +33 -0
  175. package/data/harness-fixtures/converged-room/.context/ROOM.md +13 -0
  176. package/data/harness-fixtures/converged-room/.intelligence/ROOM.md +13 -0
  177. package/data/harness-fixtures/converged-room/.snapshots/ROOM.md +13 -0
  178. package/data/harness-fixtures/converged-room/MINTO.md +19 -0
  179. package/data/harness-fixtures/converged-room/STATE.md +73 -0
  180. package/data/harness-fixtures/converged-room/USER.md +23 -0
  181. package/data/harness-fixtures/converged-room/assets/ROOM.md +13 -0
  182. package/data/harness-fixtures/converged-room/business-model/CONTEXT.md +32 -0
  183. package/data/harness-fixtures/converged-room/business-model/ROOM.md +36 -0
  184. package/data/harness-fixtures/converged-room/competitive-analysis/CONTEXT.md +33 -0
  185. package/data/harness-fixtures/converged-room/competitive-analysis/ROOM.md +35 -0
  186. package/data/harness-fixtures/converged-room/financial-model/CONTEXT.md +30 -0
  187. package/data/harness-fixtures/converged-room/financial-model/ROOM.md +35 -0
  188. package/data/harness-fixtures/converged-room/funding/CONTEXT.md +41 -0
  189. package/data/harness-fixtures/converged-room/funding/ROOM.md +35 -0
  190. package/data/harness-fixtures/converged-room/legal-ip/CONTEXT.md +30 -0
  191. package/data/harness-fixtures/converged-room/legal-ip/ROOM.md +35 -0
  192. package/data/harness-fixtures/converged-room/market-analysis/CONTEXT.md +32 -0
  193. package/data/harness-fixtures/converged-room/market-analysis/ROOM.md +35 -0
  194. package/data/harness-fixtures/converged-room/opportunity-bank/CONTEXT.md +39 -0
  195. package/data/harness-fixtures/converged-room/opportunity-bank/ROOM.md +36 -0
  196. package/data/harness-fixtures/converged-room/problem-definition/CONTEXT.md +32 -0
  197. package/data/harness-fixtures/converged-room/problem-definition/ROOM.md +36 -0
  198. package/data/harness-fixtures/converged-room/references/ROOM.md +13 -0
  199. package/data/harness-fixtures/converged-room/references/SECTION-SCHEMA.md +213 -0
  200. package/data/harness-fixtures/converged-room/references/SUB-SCHEMAS.md +91 -0
  201. package/data/harness-fixtures/converged-room/solution-design/CONTEXT.md +36 -0
  202. package/data/harness-fixtures/converged-room/solution-design/ROOM.md +36 -0
  203. package/data/harness-fixtures/converged-room/strategy/CONTEXT.md +35 -0
  204. package/data/harness-fixtures/converged-room/strategy/ROOM.md +35 -0
  205. package/data/harness-fixtures/converged-room/team/ROOM.md +13 -0
  206. package/data/harness-fixtures/converged-room/team-execution/CONTEXT.md +36 -0
  207. package/data/harness-fixtures/converged-room/team-execution/ROOM.md +35 -0
  208. package/data/harness-manifest.json +74 -0
  209. package/data/harness-policies/CONTEXT.md +55 -0
  210. package/data/harness-policies/_schema.json +42 -0
  211. package/data/harness-policies/contract-parity-larry.json +63 -0
  212. package/data/harness-policies/gate-card-fire.json +13 -0
  213. package/data/harness-policies/gate-graph-derive-health.json +13 -0
  214. package/data/harness-policies/gate-shape-declaration.json +13 -0
  215. package/data/harness-policies/gate-tool-honesty.json +13 -0
  216. package/data/harness-policies/gate-worktree-hygiene.json +13 -0
  217. package/data/harness-policies/memory-write-policy.json +28 -0
  218. package/data/harness-policies/registry-drift.json +13 -0
  219. package/data/harness-policies/release-payload-ceiling.json +13 -0
  220. package/data/harness-policies/voice-backend-noun-free.json +13 -0
  221. package/data/harness-policies/voice-fork-as-card.json +13 -0
  222. package/data/harness-policies/voice-glyph-present.json +13 -0
  223. package/data/harness-policies/voice-hyphens-only.json +13 -0
  224. package/data/help-groups.json +236 -0
  225. package/data/hitl-shape-backfill.json +777 -0
  226. package/data/hitl-shape-declaration-fixtures/invalid-bad-shape.json +5 -0
  227. package/data/hitl-shape-declaration-fixtures/invalid-missing-why.json +4 -0
  228. package/data/hitl-shape-declaration-fixtures/invalid-ranker-contradiction.json +6 -0
  229. package/data/hitl-shape-declaration-fixtures/invalid-skill-gap.json +3 -0
  230. package/data/hitl-shape-declaration-fixtures/valid-multi-stage.json +7 -0
  231. package/data/hitl-shape-declaration-fixtures/valid-single-shape.json +5 -0
  232. package/data/hitl-shape-declaration-fixtures/valid-skill-exempt.json +5 -0
  233. package/data/hitl-shape-declaration-schema.json +34 -0
  234. package/data/hitl-stages-fixtures/bono.json +10 -0
  235. package/data/hitl-stages-fixtures/pipeline-1.json +9 -0
  236. package/data/hitl-stages-fixtures/pipeline-2.json +9 -0
  237. package/data/hitl-stages-fixtures/pipeline-3.json +10 -0
  238. package/data/hitl-stages-fixtures/research.json +10 -0
  239. package/data/hitl-stages-fixtures/rs-convergence.json +10 -0
  240. package/data/hitl-stages-fixtures/rs-family.json +11 -0
  241. package/data/hitl-stages-fixtures/rs-reverse-salient.json +10 -0
  242. package/data/hitl-stages-fixtures/trending-to-absurd.json +11 -0
  243. package/data/hitl-stages-schema.json +26 -0
  244. package/data/mcp-tool-connectors.json +464 -0
  245. package/data/mva-agent-prompts.json +31 -0
  246. package/data/mva-deck-template.html +15 -0
  247. package/data/mva-heuristic-keywords.json +35 -0
  248. package/data/orchestration-command-ledger.json +576 -0
  249. package/data/orchestration-unwired-allowlist.json +6 -0
  250. package/data/portfolio-ahp-matrix.json +16 -0
  251. package/data/publish-needs.json +76 -0
  252. package/data/render-coverage-registry.json +1152 -0
  253. package/data/research-sources.json +58 -0
  254. package/data/roadmap-type-chains.json +28 -0
  255. package/data/room-blueprints.json +156 -0
  256. package/data/subagent-dispatch-grants.json +150 -0
  257. package/hooks/hooks.json +493 -0
  258. package/hooks/run-hook.cmd +64 -0
  259. package/lib/__init__.py +0 -0
  260. package/lib/__pycache__/__init__.cpython-312.pyc +0 -0
  261. package/lib/agents/auto-explore-agent.cjs +1163 -0
  262. package/lib/agents/mva/brain-classic-traps.cjs +55 -0
  263. package/lib/agents/mva/brain-cross-domain.cjs +79 -0
  264. package/lib/agents/mva/brain-similar-ventures.cjs +93 -0
  265. package/lib/agents/mva/dashboard-graph-neighborhood.cjs +72 -0
  266. package/lib/agents/mva/index.cjs +42 -0
  267. package/lib/agents/mva/six-hats-red-black.cjs +137 -0
  268. package/lib/agents/mva/tavily-funding-scan.cjs +147 -0
  269. package/lib/agents/mva/test-all-six-agents.cjs +467 -0
  270. package/lib/agents/reverse-salient-agent.cjs +757 -0
  271. package/lib/agents/tension-hook-agent.cjs +586 -0
  272. package/lib/brain/ROOM.md +44 -0
  273. package/lib/brain/chain-recommender.cjs +784 -0
  274. package/lib/brain/curation-batch.cjs +519 -0
  275. package/lib/brain/framework-chain-slice.cjs +252 -0
  276. package/lib/brain/hypergraph-event-schema.cjs +184 -0
  277. package/lib/chat/chat-context.js +185 -0
  278. package/lib/chat/chat-panel.js +721 -0
  279. package/lib/chat/fabric-chat.cjs +288 -0
  280. package/lib/chat/generative-tools.js +219 -0
  281. package/lib/conversation/ROOM.md +39 -0
  282. package/lib/conversation/classifier-rules.json +38 -0
  283. package/lib/conversation/classifier.cjs +264 -0
  284. package/lib/conversation/operator-epistemic-cap.test.cjs +156 -0
  285. package/lib/conversation/operator.cjs +492 -0
  286. package/lib/conversation/operator.test.cjs +160 -0
  287. package/lib/copy/115-spec-strings.cjs +55 -0
  288. package/lib/core/__init__.py +0 -0
  289. package/lib/core/__nav-stub.cjs +14 -0
  290. package/lib/core/__pycache__/__init__.cpython-312.pyc +0 -0
  291. package/lib/core/__pycache__/rs-math.cpython-312.pyc +0 -0
  292. package/lib/core/__pycache__/rs_cache.cpython-312.pyc +0 -0
  293. package/lib/core/__pycache__/rs_corpus.cpython-312.pyc +0 -0
  294. package/lib/core/__pycache__/rs_corpus_exclude.cpython-312.pyc +0 -0
  295. package/lib/core/__pycache__/rs_hybrid.cpython-312.pyc +0 -0
  296. package/lib/core/__pycache__/rs_math.cpython-312.pyc +0 -0
  297. package/lib/core/__pycache__/rs_rooms.cpython-312.pyc +0 -0
  298. package/lib/core/abstraction-gate.cjs +133 -0
  299. package/lib/core/act-jtbd-blurb.cjs +231 -0
  300. package/lib/core/artifact-id.cjs +148 -0
  301. package/lib/core/asset-ops.cjs +151 -0
  302. package/lib/core/auto-commit-throttle.cjs +129 -0
  303. package/lib/core/bearer-token.cjs +199 -0
  304. package/lib/core/behavioral/observation-schema.cjs +86 -0
  305. package/lib/core/bono/cell-fanout.cjs +305 -0
  306. package/lib/core/bono/debate-composition.cjs +495 -0
  307. package/lib/core/bono/hat-governance.cjs +367 -0
  308. package/lib/core/bono/persona-research.cjs +288 -0
  309. package/lib/core/bono/reviewer-governance.cjs +331 -0
  310. package/lib/core/brain-client.cjs +2621 -0
  311. package/lib/core/brain-derivation-prompts.cjs +331 -0
  312. package/lib/core/brain-derivation-queue.cjs +535 -0
  313. package/lib/core/brain-derivation.cjs +740 -0
  314. package/lib/core/brain-md-schema.cjs +528 -0
  315. package/lib/core/brain-md-staleness.cjs +357 -0
  316. package/lib/core/brain-response-sanitize.cjs +396 -0
  317. package/lib/core/breakthrough/canary.cjs +134 -0
  318. package/lib/core/breakthrough/canary.test.cjs +136 -0
  319. package/lib/core/breakthrough/detectors.cjs +359 -0
  320. package/lib/core/breakthrough/detectors.test.cjs +333 -0
  321. package/lib/core/breakthrough/ethics-fence.cjs +129 -0
  322. package/lib/core/breakthrough/ethics-fence.test.cjs +178 -0
  323. package/lib/core/breakthrough/resurfacing.cjs +150 -0
  324. package/lib/core/breakthrough/resurfacing.test.cjs +233 -0
  325. package/lib/core/breakthrough/review-queue.cjs +168 -0
  326. package/lib/core/breakthrough/review-queue.test.cjs +160 -0
  327. package/lib/core/breakthrough/scanner-d17-d18.test.cjs +229 -0
  328. package/lib/core/breakthrough/scanner.cjs +435 -0
  329. package/lib/core/breakthrough/scanner.test.cjs +267 -0
  330. package/lib/core/breakthrough/schema.cjs +180 -0
  331. package/lib/core/breakthrough/schema.test.cjs +256 -0
  332. package/lib/core/breakthrough/scoring.cjs +293 -0
  333. package/lib/core/breakthrough/scoring.test.cjs +423 -0
  334. package/lib/core/breakthrough/verb-dispatch.cjs +230 -0
  335. package/lib/core/breakthrough/verb-dispatch.test.cjs +185 -0
  336. package/lib/core/breakthrough/voice-scaffold.cjs +249 -0
  337. package/lib/core/breakthrough/voice-scaffold.test.cjs +251 -0
  338. package/lib/core/bridge-writer.cjs +477 -0
  339. package/lib/core/cache-prune.cjs +314 -0
  340. package/lib/core/card-fire-gate.cjs +107 -0
  341. package/lib/core/card-fire-sidechannel.cjs +518 -0
  342. package/lib/core/chain-executor.cjs +939 -0
  343. package/lib/core/chain-retry.cjs +214 -0
  344. package/lib/core/chain-step-dispatcher.cjs +397 -0
  345. package/lib/core/chat-context-builder.cjs +253 -0
  346. package/lib/core/check-plugin-enabled.cjs +145 -0
  347. package/lib/core/close-loop-writer.cjs +492 -0
  348. package/lib/core/command-registration-check.cjs +246 -0
  349. package/lib/core/correlation-label-index.cjs +230 -0
  350. package/lib/core/correlation.cjs +112 -0
  351. package/lib/core/coverage-monitor.cjs +183 -0
  352. package/lib/core/coverage-rollup.cjs +232 -0
  353. package/lib/core/cross-room-aggregator.cjs +1127 -0
  354. package/lib/core/cross-room-store.cjs +292 -0
  355. package/lib/core/cross-room-triggers.cjs +222 -0
  356. package/lib/core/daily-briefing.cjs +438 -0
  357. package/lib/core/decision-axes.cjs +178 -0
  358. package/lib/core/decision-capture.cjs +618 -0
  359. package/lib/core/deck-design-rules.cjs +211 -0
  360. package/lib/core/deep-links.cjs +82 -0
  361. package/lib/core/directive-envelope.cjs +230 -0
  362. package/lib/core/directive-envelope.test.cjs +225 -0
  363. package/lib/core/dispatch-optimizer.cjs +354 -0
  364. package/lib/core/doc-text-extractor.cjs +133 -0
  365. package/lib/core/doctor/capability-ledger-module.cjs +170 -0
  366. package/lib/core/doctor/card-fire-health-module.cjs +159 -0
  367. package/lib/core/doctor/cascade-rooms-active-module.cjs +127 -0
  368. package/lib/core/doctor/cascade-rooms-module.cjs +184 -0
  369. package/lib/core/doctor/class-m-brain-smoke.cjs +479 -0
  370. package/lib/core/doctor/class-m-brain-smoke.test.cjs +448 -0
  371. package/lib/core/doctor/class-s-eureka-smoke.cjs +380 -0
  372. package/lib/core/doctor/deployment-surfaces-module.cjs +408 -0
  373. package/lib/core/doctor/deprecated-usage-module.cjs +155 -0
  374. package/lib/core/doctor/eureka-fts-health-module.cjs +236 -0
  375. package/lib/core/doctor/graph-derive-heal-retrofit-module.cjs +148 -0
  376. package/lib/core/doctor/graph-derive-health-module.cjs +486 -0
  377. package/lib/core/doctor/install-incomplete-module.cjs +320 -0
  378. package/lib/core/doctor/install-state-module.cjs +503 -0
  379. package/lib/core/doctor/mcp-surface-module.cjs +369 -0
  380. package/lib/core/doctor/mode-select-checkpoint-module.cjs +113 -0
  381. package/lib/core/doctor/plugin-enabled-state-module.cjs +86 -0
  382. package/lib/core/doctor/room-graph-density-module.cjs +181 -0
  383. package/lib/core/doctor/room-md-module.cjs +198 -0
  384. package/lib/core/doctor/shared.cjs +555 -0
  385. package/lib/core/doctor/stale-first-touch-copy-module.cjs +83 -0
  386. package/lib/core/doctor/statusline-visibility-module.cjs +295 -0
  387. package/lib/core/doctor/ui-compliance-module.cjs +223 -0
  388. package/lib/core/doctor/umbilical-module.cjs +486 -0
  389. package/lib/core/doctor/verify-surface-module.cjs +82 -0
  390. package/lib/core/doctor/voice-style-log-module.cjs +146 -0
  391. package/lib/core/domain-insight-sweep.cjs +224 -0
  392. package/lib/core/drift-baseline.cjs +362 -0
  393. package/lib/core/drift-runtime-reachability.cjs +283 -0
  394. package/lib/core/dual-path-detector.cjs +84 -0
  395. package/lib/core/dual-path-detector.test.cjs +334 -0
  396. package/lib/core/enrichment-queue.cjs +636 -0
  397. package/lib/core/eureka/ahp-weights.cjs +232 -0
  398. package/lib/core/eureka/analogy-fitness.cjs +326 -0
  399. package/lib/core/eureka/compression-meter.cjs +165 -0
  400. package/lib/core/eureka/embedding-classifier.cjs +226 -0
  401. package/lib/core/eureka/embedding-spine.cjs +563 -0
  402. package/lib/core/eureka/entity-classifier.cjs +232 -0
  403. package/lib/core/eureka/entity-extractor.cjs +356 -0
  404. package/lib/core/eureka/eureka-enable.cjs +228 -0
  405. package/lib/core/eureka/eureka-offer.cjs +225 -0
  406. package/lib/core/eureka/eureka-reach-runner.cjs +430 -0
  407. package/lib/core/eureka/explore-chain.cjs +834 -0
  408. package/lib/core/eureka/explored-artifact.cjs +456 -0
  409. package/lib/core/eureka/fts-index-lifecycle.cjs +265 -0
  410. package/lib/core/eureka/grade-grant-examine.cjs +544 -0
  411. package/lib/core/eureka/grade-grant.cjs +596 -0
  412. package/lib/core/eureka/hybrid-retrieve.cjs +256 -0
  413. package/lib/core/eureka/lateral-engine-adapter.cjs +118 -0
  414. package/lib/core/eureka/lexical-overlap.cjs +98 -0
  415. package/lib/core/eureka/online-pattern-query.cjs +142 -0
  416. package/lib/core/eureka/opportunity-harvest.cjs +752 -0
  417. package/lib/core/eureka/opportunity-statement.cjs +519 -0
  418. package/lib/core/eureka/portfolio-dimensions.cjs +255 -0
  419. package/lib/core/eureka/qualify-opportunity.cjs +607 -0
  420. package/lib/core/eureka/reasoning-mode.cjs +481 -0
  421. package/lib/core/eureka/report-html.cjs +368 -0
  422. package/lib/core/eureka/research-filing.cjs +547 -0
  423. package/lib/core/eureka/room-native-substrate.cjs +343 -0
  424. package/lib/core/eureka/tail-quadrant.cjs +177 -0
  425. package/lib/core/eureka/tri-modal-index.cjs +564 -0
  426. package/lib/core/eureka/vector-store.cjs +414 -0
  427. package/lib/core/eureka-critic.cjs +733 -0
  428. package/lib/core/eureka-deps-resolver.cjs +179 -0
  429. package/lib/core/expert-genesis.cjs +437 -0
  430. package/lib/core/expert-library.cjs +303 -0
  431. package/lib/core/exports-log.cjs +79 -0
  432. package/lib/core/feynman/ROOM.md +25 -0
  433. package/lib/core/feynman/dial-memory-renderer.cjs +279 -0
  434. package/lib/core/feynman/dial-memory-runner.cjs +173 -0
  435. package/lib/core/feynman/feynman-seed-writer.cjs +187 -0
  436. package/lib/core/feynman/timeline-renderer.cjs +197 -0
  437. package/lib/core/feynman/timeline-runner.cjs +281 -0
  438. package/lib/core/feynman-minto-invariants.cjs +609 -0
  439. package/lib/core/findings-wirer.cjs +360 -0
  440. package/lib/core/first-touch-version-stamper.cjs +113 -0
  441. package/lib/core/folder-memory-async.cjs +424 -0
  442. package/lib/core/folder-memory-shared.cjs +890 -0
  443. package/lib/core/folder-memory.cjs +546 -0
  444. package/lib/core/framework-chain-composer.cjs +583 -0
  445. package/lib/core/frontmatter-schemas.cjs +468 -0
  446. package/lib/core/fusion-router.cjs +540 -0
  447. package/lib/core/futures/causal-cue.cjs +91 -0
  448. package/lib/core/futures/orchestrator.cjs +1391 -0
  449. package/lib/core/futures/subsystem-render.cjs +164 -0
  450. package/lib/core/gate-relevance.cjs +278 -0
  451. package/lib/core/git-ops.cjs +141 -0
  452. package/lib/core/graph-backfill.cjs +562 -0
  453. package/lib/core/graph-candidate-producer.cjs +235 -0
  454. package/lib/core/graph-derivation.cjs +546 -0
  455. package/lib/core/graph-derive-classifier.cjs +352 -0
  456. package/lib/core/graph-ops.cjs +274 -0
  457. package/lib/core/graph-refine-loop.cjs +194 -0
  458. package/lib/core/graph-self-heal.cjs +289 -0
  459. package/lib/core/greeting-intent-detector.cjs +201 -0
  460. package/lib/core/grill-engine.cjs +459 -0
  461. package/lib/core/hat-persistence.cjs +274 -0
  462. package/lib/core/hsi-engine.cjs +439 -0
  463. package/lib/core/hsi-lsa.cjs +246 -0
  464. package/lib/core/hsi-spectral.cjs +554 -0
  465. package/lib/core/hsi-to-graph.test.cjs +168 -0
  466. package/lib/core/icm-forest.cjs +703 -0
  467. package/lib/core/ignite-branch-gate.cjs +66 -0
  468. package/lib/core/index.cjs +60 -0
  469. package/lib/core/insight-sensors.cjs +1000 -0
  470. package/lib/core/install-state.cjs +242 -0
  471. package/lib/core/integration-registry.cjs +232 -0
  472. package/lib/core/intel-pipeline.cjs +566 -0
  473. package/lib/core/intelligence-cascade.cjs +852 -0
  474. package/lib/core/issue-tree.cjs +269 -0
  475. package/lib/core/larry-thinness-acknowledgment.cjs +64 -0
  476. package/lib/core/larry-thinness-acknowledgment.test.cjs +97 -0
  477. package/lib/core/lazygraph-ops.cjs +1453 -0
  478. package/lib/core/lens-engine.cjs +434 -0
  479. package/lib/core/leverage-scan.cjs +218 -0
  480. package/lib/core/llm-name-suggester.cjs +194 -0
  481. package/lib/core/llm-name-suggester.test.cjs +132 -0
  482. package/lib/core/lru-cache.cjs +139 -0
  483. package/lib/core/mcp-dep-heal.cjs +475 -0
  484. package/lib/core/mcp-dep-heal.test.cjs +253 -0
  485. package/lib/core/mcp-profiles.cjs +185 -0
  486. package/lib/core/meeting-ops.cjs +54 -0
  487. package/lib/core/memory/governance-candidate-raiser.cjs +205 -0
  488. package/lib/core/memory/governance-candidate.cjs +95 -0
  489. package/lib/core/memory/reconcile-memory-runner.cjs +653 -0
  490. package/lib/core/memory-ops.cjs +641 -0
  491. package/lib/core/meter/gate-density-reader.cjs +112 -0
  492. package/lib/core/meter/transfer-reader.cjs +276 -0
  493. package/lib/core/meter/two-gauge.cjs +245 -0
  494. package/lib/core/methodology-ingest.cjs +346 -0
  495. package/lib/core/metrics/larryreach-loop-health.cjs +142 -0
  496. package/lib/core/migration-snapshot.cjs +287 -0
  497. package/lib/core/migration-snapshot.test.cjs +174 -0
  498. package/lib/core/migrations/ROOM.md +33 -0
  499. package/lib/core/migrations/phase-109-nodes-provenance.cjs +400 -0
  500. package/lib/core/migrations/phase-109-session-focus.cjs +99 -0
  501. package/lib/core/migrations/phase-160-nodes-bitemporal.cjs +168 -0
  502. package/lib/core/migrations/phase-160-nodes-bitemporal.test.cjs +140 -0
  503. package/lib/core/migrations/phase-162-section-nodes.cjs +156 -0
  504. package/lib/core/migrations/phase-222-ranker-weights.cjs +62 -0
  505. package/lib/core/migrations/phase-224-edge-review-status.cjs +87 -0
  506. package/lib/core/mindrian-brain-shim.test.cjs +221 -0
  507. package/lib/core/mode-select-sidechannel.cjs +259 -0
  508. package/lib/core/model-profiles.cjs +246 -0
  509. package/lib/core/mullins-scaffold.cjs +258 -0
  510. package/lib/core/mullins-scaffold.test.cjs +128 -0
  511. package/lib/core/mva-agent-contract.cjs +170 -0
  512. package/lib/core/mva-agent-contract.test.cjs +169 -0
  513. package/lib/core/mva-budget.cjs +75 -0
  514. package/lib/core/mva-budget.test.cjs +68 -0
  515. package/lib/core/mva-classifier.cjs +392 -0
  516. package/lib/core/mva-classifier.test.cjs +248 -0
  517. package/lib/core/mva-deck-builder.cjs +452 -0
  518. package/lib/core/mva-deck-builder.test.cjs +287 -0
  519. package/lib/core/mva-detect.smoke.test.cjs +209 -0
  520. package/lib/core/mva-dispatcher.cjs +110 -0
  521. package/lib/core/mva-dispatcher.test.cjs +216 -0
  522. package/lib/core/mva-option-router.cjs +414 -0
  523. package/lib/core/mva-option-router.test.cjs +483 -0
  524. package/lib/core/mva-orchestrator.cjs +365 -0
  525. package/lib/core/mva-orchestrator.test.cjs +916 -0
  526. package/lib/core/mva-progressive-renderer.cjs +194 -0
  527. package/lib/core/mva-progressive-renderer.test.cjs +157 -0
  528. package/lib/core/mva-rule-linter.cjs +458 -0
  529. package/lib/core/mva-rule-linter.test.cjs +484 -0
  530. package/lib/core/mva-state.cjs +159 -0
  531. package/lib/core/mva-telemetry.cjs +58 -0
  532. package/lib/core/mva-telemetry.test.cjs +196 -0
  533. package/lib/core/mva-vercel-deploy.cjs +168 -0
  534. package/lib/core/mva-vercel-deploy.test.cjs +239 -0
  535. package/lib/core/nav-dial.cjs +440 -0
  536. package/lib/core/navigation/ROOM.md +15 -0
  537. package/lib/core/navigation/abstraction-claim.cjs +185 -0
  538. package/lib/core/navigation/calibration-gate.cjs +284 -0
  539. package/lib/core/navigation/calibration-log.cjs +141 -0
  540. package/lib/core/navigation/confirm-node.cjs +73 -0
  541. package/lib/core/navigation/dashboard-helpers.cjs +145 -0
  542. package/lib/core/navigation/edges.cjs +1150 -0
  543. package/lib/core/navigation/evidence-claim.cjs +186 -0
  544. package/lib/core/navigation/explanation.cjs +48 -0
  545. package/lib/core/navigation/file-evidence-readback.cjs +242 -0
  546. package/lib/core/navigation/focus.cjs +155 -0
  547. package/lib/core/navigation/get-domains-for-trends.cjs +277 -0
  548. package/lib/core/navigation/governance.cjs +101 -0
  549. package/lib/core/navigation/grant-rubric.cjs +218 -0
  550. package/lib/core/navigation/graph-export.cjs +325 -0
  551. package/lib/core/navigation/ingestion.cjs +109 -0
  552. package/lib/core/navigation/insights-stale.test.cjs +127 -0
  553. package/lib/core/navigation/insights.cjs +574 -0
  554. package/lib/core/navigation/lens-nodes.cjs +315 -0
  555. package/lib/core/navigation/memory-artifacts.cjs +437 -0
  556. package/lib/core/navigation/memory-cortex-packet.cjs +274 -0
  557. package/lib/core/navigation/memory-events.cjs +811 -0
  558. package/lib/core/navigation/neighborhood.cjs +79 -0
  559. package/lib/core/navigation/packet.cjs +420 -0
  560. package/lib/core/navigation/planning-artifacts.cjs +219 -0
  561. package/lib/core/navigation/projections.cjs +295 -0
  562. package/lib/core/navigation/ranker-weights.cjs +133 -0
  563. package/lib/core/navigation/reasoning-write.cjs +211 -0
  564. package/lib/core/navigation/reconcile-guard.cjs +98 -0
  565. package/lib/core/navigation/reified-claim.cjs +287 -0
  566. package/lib/core/navigation/research-preflight.cjs +156 -0
  567. package/lib/core/navigation/room-birth.cjs +1213 -0
  568. package/lib/core/navigation/room-context.cjs +380 -0
  569. package/lib/core/navigation/room-home.cjs +142 -0
  570. package/lib/core/navigation/spine-events.cjs +548 -0
  571. package/lib/core/navigation/synthetic-expert.cjs +177 -0
  572. package/lib/core/navigation/transitions.cjs +253 -0
  573. package/lib/core/navigation/typed-claim.cjs +208 -0
  574. package/lib/core/navigation/typed-domain.cjs +249 -0
  575. package/lib/core/navigation/typed-entity.cjs +236 -0
  576. package/lib/core/navigation/typed-frame.cjs +257 -0
  577. package/lib/core/navigation/typed-open-question.cjs +130 -0
  578. package/lib/core/navigation/typed-opportunity.cjs +418 -0
  579. package/lib/core/navigation-engine-offer.cjs +776 -0
  580. package/lib/core/navigation-engine-shared.cjs +256 -0
  581. package/lib/core/navigation-engine.cjs +1696 -0
  582. package/lib/core/navigation.cjs +686 -0
  583. package/lib/core/nl-graph-queries.cjs +164 -0
  584. package/lib/core/node-insert-epistemic.test.cjs +212 -0
  585. package/lib/core/node-insert-overrides.test.cjs +273 -0
  586. package/lib/core/node-insert.cjs +274 -0
  587. package/lib/core/npm-cli-resolve.cjs +151 -0
  588. package/lib/core/npm-cli-resolve.test.cjs +153 -0
  589. package/lib/core/npm-install-lock.cjs +326 -0
  590. package/lib/core/npm-install-lock.test.cjs +379 -0
  591. package/lib/core/numeric/sklearn-stopwords-v1.json +325 -0
  592. package/lib/core/numeric/svd.cjs +377 -0
  593. package/lib/core/numeric/tfidf.cjs +241 -0
  594. package/lib/core/offer-presenter.cjs +406 -0
  595. package/lib/core/opportunity-extractor.cjs +183 -0
  596. package/lib/core/opportunity-ops.cjs +1423 -0
  597. package/lib/core/orchestration-candidate-lift.cjs +284 -0
  598. package/lib/core/part8-egress-guard.cjs +563 -0
  599. package/lib/core/part8-egress-guard.test.cjs +194 -0
  600. package/lib/core/part8-egress-ontology.cjs +174 -0
  601. package/lib/core/part8-egress-ontology.test.cjs +133 -0
  602. package/lib/core/persona-ops.cjs +692 -0
  603. package/lib/core/persona-override.cjs +327 -0
  604. package/lib/core/persona-taxonomy.cjs +328 -0
  605. package/lib/core/pinecone-inference.cjs +176 -0
  606. package/lib/core/pitch-feedback-schemas.cjs +303 -0
  607. package/lib/core/planning/artifact-brain-packet.cjs +212 -0
  608. package/lib/core/planning/reconcile-runner.cjs +347 -0
  609. package/lib/core/platform-gates.cjs +120 -0
  610. package/lib/core/platform.cjs +257 -0
  611. package/lib/core/proactive-intelligence.cjs +528 -0
  612. package/lib/core/problem-type-router.cjs +315 -0
  613. package/lib/core/publish-needs-default-lane.cjs +110 -0
  614. package/lib/core/ralph-loop-gate.cjs +48 -0
  615. package/lib/core/reader/ab-harness.cjs +177 -0
  616. package/lib/core/reader/decide-projection-reader.cjs +358 -0
  617. package/lib/core/reasoning-ops.cjs +639 -0
  618. package/lib/core/recipe-maps.cjs +442 -0
  619. package/lib/core/recovery/case-file.cjs +358 -0
  620. package/lib/core/recovery/controller.cjs +1008 -0
  621. package/lib/core/recovery/dispatcher.cjs +533 -0
  622. package/lib/core/recovery/result-semantics.cjs +488 -0
  623. package/lib/core/recovery/stage-envelope.cjs +338 -0
  624. package/lib/core/refusal-messaging.cjs +569 -0
  625. package/lib/core/refusal-messaging.test.cjs +220 -0
  626. package/lib/core/repo-version.cjs +134 -0
  627. package/lib/core/research-cache.cjs +165 -0
  628. package/lib/core/research-cache.test.cjs +137 -0
  629. package/lib/core/research-context-extractor.cjs +283 -0
  630. package/lib/core/research-corpus.cjs +814 -0
  631. package/lib/core/research-corpus.test.cjs +280 -0
  632. package/lib/core/research-filing-selector.cjs +189 -0
  633. package/lib/core/resolve-active-room.cjs +602 -0
  634. package/lib/core/resolve-brain-key.cjs +273 -0
  635. package/lib/core/resolve-umbilical-target.cjs +288 -0
  636. package/lib/core/resolve-vercel-key.cjs +107 -0
  637. package/lib/core/resolve-vercel-key.test.cjs +137 -0
  638. package/lib/core/reverse-salient-persona-suffix.cjs +115 -0
  639. package/lib/core/room-auto-create.cjs +318 -0
  640. package/lib/core/room-auto-create.test.cjs +198 -0
  641. package/lib/core/room-chooser.cjs +244 -0
  642. package/lib/core/room-classifier-strict-mode.cjs +235 -0
  643. package/lib/core/room-db.cjs +348 -0
  644. package/lib/core/room-discard-cascade.cjs +238 -0
  645. package/lib/core/room-discard-cascade.test.cjs +135 -0
  646. package/lib/core/room-name-validator.cjs +132 -0
  647. package/lib/core/room-name-validator.test.cjs +156 -0
  648. package/lib/core/room-naming-selector.cjs +357 -0
  649. package/lib/core/room-naming-selector.test.cjs +277 -0
  650. package/lib/core/room-open.cjs +259 -0
  651. package/lib/core/room-ops-async.cjs +92 -0
  652. package/lib/core/room-ops-shared.cjs +64 -0
  653. package/lib/core/room-ops-sync.cjs +70 -0
  654. package/lib/core/room-ops.cjs +32 -0
  655. package/lib/core/room-receipt-emit.cjs +63 -0
  656. package/lib/core/room-root.cjs +93 -0
  657. package/lib/core/room-skeleton-scaffold.cjs +669 -0
  658. package/lib/core/room-skeleton-scaffold.test.cjs +296 -0
  659. package/lib/core/room-type-detector.cjs +386 -0
  660. package/lib/core/rs-backend-dispatch.cjs +64 -0
  661. package/lib/core/rs-brain-substrate-prompts.cjs +129 -0
  662. package/lib/core/rs-brain-substrate.cjs +570 -0
  663. package/lib/core/rs-breakthrough-scorer.cjs +255 -0
  664. package/lib/core/rs-canon-violations.cjs +82 -0
  665. package/lib/core/rs-chain-feeder.cjs +381 -0
  666. package/lib/core/rs-commercial-assessor.cjs +280 -0
  667. package/lib/core/rs-corpus-quality-gate.cjs +62 -0
  668. package/lib/core/rs-differential-scorer.cjs +629 -0
  669. package/lib/core/rs-domain-analyzer.cjs +385 -0
  670. package/lib/core/rs-egress-prompts.cjs +113 -0
  671. package/lib/core/rs-egress-telemetry.cjs +225 -0
  672. package/lib/core/rs-egress-violations.cjs +53 -0
  673. package/lib/core/rs-engine.cjs +597 -0
  674. package/lib/core/rs-expert-brain-projection.cjs +280 -0
  675. package/lib/core/rs-expert-mapper.cjs +467 -0
  676. package/lib/core/rs-fetcher-academic.cjs +697 -0
  677. package/lib/core/rs-fetcher-experts.cjs +314 -0
  678. package/lib/core/rs-fetcher-industry.cjs +731 -0
  679. package/lib/core/rs-fetcher-patents.cjs +564 -0
  680. package/lib/core/rs-innovation-classifier.cjs +194 -0
  681. package/lib/core/rs-math.cjs +458 -0
  682. package/lib/core/rs-mind-map.cjs +656 -0
  683. package/lib/core/rs-neo4j-writer.cjs +388 -0
  684. package/lib/core/rs-nl-to-query.cjs +435 -0
  685. package/lib/core/rs-pinecone-bridge.cjs +344 -0
  686. package/lib/core/rs-preprocessor.cjs +350 -0
  687. package/lib/core/rs-query-matrix.cjs +316 -0
  688. package/lib/core/rs-query-to-text.cjs +438 -0
  689. package/lib/core/rs-sqlite-mirror.cjs +495 -0
  690. package/lib/core/rs-thesis-generator.cjs +188 -0
  691. package/lib/core/rs_cache.py +635 -0
  692. package/lib/core/rs_corpus.py +562 -0
  693. package/lib/core/rs_corpus_exclude.py +62 -0
  694. package/lib/core/rs_hybrid.py +589 -0
  695. package/lib/core/rs_math.py +287 -0
  696. package/lib/core/rs_rooms.py +196 -0
  697. package/lib/core/salient-governance.cjs +315 -0
  698. package/lib/core/scheduled-scanner.cjs +658 -0
  699. package/lib/core/scratchpad-ops.cjs +316 -0
  700. package/lib/core/seam-liveness.cjs +191 -0
  701. package/lib/core/seam-liveness.test.cjs +177 -0
  702. package/lib/core/section-8-trace-schema.cjs +138 -0
  703. package/lib/core/section-registry.cjs +167 -0
  704. package/lib/core/security/agentshield-adapters.test.cjs +104 -0
  705. package/lib/core/security/agentshield-run.cjs +343 -0
  706. package/lib/core/security/agentshield-scanner.cjs +314 -0
  707. package/lib/core/security/agentshield-scanner.test.cjs +259 -0
  708. package/lib/core/sensors/hat-scoping-table.cjs +103 -0
  709. package/lib/core/sensors/sensor-circularity.cjs +278 -0
  710. package/lib/core/sensors/sensor-content-relevance.cjs +407 -0
  711. package/lib/core/sensors/sensor-diffusion-adoption.cjs +230 -0
  712. package/lib/core/sensors/sensor-eureka.cjs +208 -0
  713. package/lib/core/sensors/sensor-expert-skill.cjs +293 -0
  714. package/lib/core/sensors/sensor-external-fact.cjs +184 -0
  715. package/lib/core/sensors/sensor-gate-approach.cjs +104 -0
  716. package/lib/core/sensors/sensor-jtbd-reweight.cjs +141 -0
  717. package/lib/core/sensors/sensor-lagging-component.cjs +115 -0
  718. package/lib/core/sensors/sensor-memory-cortex.cjs +111 -0
  719. package/lib/core/sensors/sensor-methodology-decision.cjs +131 -0
  720. package/lib/core/sensors/sensor-opportunity-harvest.cjs +195 -0
  721. package/lib/core/sensors/sensor-perspective-lock.cjs +174 -0
  722. package/lib/core/sensors/sensor-priority.cjs +183 -0
  723. package/lib/core/sensors/sensor-recency.cjs +151 -0
  724. package/lib/core/sensors/sensor-roadmap-type.cjs +421 -0
  725. package/lib/core/sensors/sensor-room-pick.cjs +238 -0
  726. package/lib/core/sensors/sensor-show-share.cjs +215 -0
  727. package/lib/core/sensors/sensor-temporal-blindness.cjs +123 -0
  728. package/lib/core/sensors/sensor-types.cjs +294 -0
  729. package/lib/core/sensors/sensor-url-ingest.cjs +234 -0
  730. package/lib/core/session-binding.cjs +208 -0
  731. package/lib/core/session-presence.cjs +404 -0
  732. package/lib/core/session-register.cjs +138 -0
  733. package/lib/core/session-state.cjs +144 -0
  734. package/lib/core/shallow-doc-parser.cjs +353 -0
  735. package/lib/core/shallow-doc-parser.test.cjs +226 -0
  736. package/lib/core/skill-activation-router.cjs +284 -0
  737. package/lib/core/skillopt-schemas.cjs +509 -0
  738. package/lib/core/stale-copy-scanner.cjs +190 -0
  739. package/lib/core/stance-state.cjs +153 -0
  740. package/lib/core/state-aware-router.cjs +78 -0
  741. package/lib/core/state-ops.cjs +80 -0
  742. package/lib/core/state-version.cjs +350 -0
  743. package/lib/core/statusline-cache.cjs +266 -0
  744. package/lib/core/statusline-liveness-gate.cjs +105 -0
  745. package/lib/core/surface-fence.cjs +127 -0
  746. package/lib/core/synthesizers/comparison-matrix.cjs +82 -0
  747. package/lib/core/synthesizers/convergence-map.cjs +107 -0
  748. package/lib/core/synthesizers/domain-hierarchy.cjs +138 -0
  749. package/lib/core/synthesizers/source-comparison.cjs +56 -0
  750. package/lib/core/synthesizers/tension-map.cjs +119 -0
  751. package/lib/core/synthetic-expert-behavior-gate.cjs +99 -0
  752. package/lib/core/synthetic-expert-construction-gate.cjs +170 -0
  753. package/lib/core/telemetry/schema.cjs +168 -0
  754. package/lib/core/telemetry/schema.test.cjs +124 -0
  755. package/lib/core/telemetry/validator.cjs +200 -0
  756. package/lib/core/telemetry/validator.test.cjs +188 -0
  757. package/lib/core/telemetry/writer.cjs +141 -0
  758. package/lib/core/telemetry/writer.test.cjs +331 -0
  759. package/lib/core/temporal/date-sync-gate.cjs +256 -0
  760. package/lib/core/temporal/date-sync-gate.test.cjs +191 -0
  761. package/lib/core/temporal/dual-stamp.cjs +172 -0
  762. package/lib/core/temporal/dual-stamp.test.cjs +172 -0
  763. package/lib/core/temporal/point-in-time.cjs +76 -0
  764. package/lib/core/temporal/point-in-time.test.cjs +169 -0
  765. package/lib/core/temporal/recency-decay.cjs +119 -0
  766. package/lib/core/temporal/recency-decay.test.cjs +140 -0
  767. package/lib/core/temporal/reference-now.cjs +281 -0
  768. package/lib/core/temporal/reference-now.test.cjs +225 -0
  769. package/lib/core/temporal/resolve-relative-time.cjs +116 -0
  770. package/lib/core/temporal/resolve-relative-time.test.cjs +138 -0
  771. package/lib/core/temporal/supersession.cjs +250 -0
  772. package/lib/core/temporal/supersession.test.cjs +103 -0
  773. package/lib/core/terminal-capability.cjs +88 -0
  774. package/lib/core/token-estimator.cjs +348 -0
  775. package/lib/core/tone-filter.cjs +147 -0
  776. package/lib/core/trending-to-absurd/orchestrator.cjs +341 -0
  777. package/lib/core/trending-to-absurd/stage7-roadmap.cjs +317 -0
  778. package/lib/core/trending-to-absurd/variance.cjs +169 -0
  779. package/lib/core/unknowns/bandit.cjs +332 -0
  780. package/lib/core/unknowns/corpus-adapter.cjs +327 -0
  781. package/lib/core/unknowns/dsp.cjs +356 -0
  782. package/lib/core/unknowns/edge-writer.cjs +211 -0
  783. package/lib/core/unknowns/iface.cjs +212 -0
  784. package/lib/core/unknowns/orchestrator.cjs +375 -0
  785. package/lib/core/unknowns/pattern-miner.cjs +214 -0
  786. package/lib/core/unknowns/rumsfeld-matrix.cjs +155 -0
  787. package/lib/core/unknowns/verdict.cjs +254 -0
  788. package/lib/core/update-path.cjs +57 -0
  789. package/lib/core/url-ingest.cjs +568 -0
  790. package/lib/core/user-archetype.cjs +284 -0
  791. package/lib/core/user-md-ops.cjs +578 -0
  792. package/lib/core/venture-shape-nudge.cjs +178 -0
  793. package/lib/core/venture-shape-nudge.test.cjs +266 -0
  794. package/lib/core/verb-reach-affinity.cjs +299 -0
  795. package/lib/core/visual-ops.cjs +692 -0
  796. package/lib/core/voice-transition-detector.cjs +125 -0
  797. package/lib/core/watched-sources.cjs +237 -0
  798. package/lib/core/write-lock.cjs +149 -0
  799. package/lib/graph/canvas-graph.js +467 -0
  800. package/lib/graph/constellation-config.cjs +299 -0
  801. package/lib/graph/graph-detail-panel.js +165 -0
  802. package/lib/hmi/ROOM.md +47 -0
  803. package/lib/hmi/across-session-memory.cjs +669 -0
  804. package/lib/hmi/agentshield-drift-gate.cjs +142 -0
  805. package/lib/hmi/brain-review-packet.cjs +221 -0
  806. package/lib/hmi/cortex-reach-adapter.cjs +271 -0
  807. package/lib/hmi/cross-room-memory.cjs +618 -0
  808. package/lib/hmi/decoy-tier.cjs +395 -0
  809. package/lib/hmi/depth-state.cjs +164 -0
  810. package/lib/hmi/dial-label-composer.cjs +410 -0
  811. package/lib/hmi/dial-presenter.cjs +508 -0
  812. package/lib/hmi/dial-reach-orchestrator.cjs +377 -0
  813. package/lib/hmi/dial-selector.cjs +239 -0
  814. package/lib/hmi/f1-pick-capture-cli.cjs +131 -0
  815. package/lib/hmi/f3-depth-capture-cli.cjs +77 -0
  816. package/lib/hmi/f4-scope-capture-cli.cjs +86 -0
  817. package/lib/hmi/f8-action-capture-cli.cjs +145 -0
  818. package/lib/hmi/f8-capture.test.cjs +77 -0
  819. package/lib/hmi/f9-ordered-capture-cli.cjs +138 -0
  820. package/lib/hmi/harvest-scope-state.cjs +202 -0
  821. package/lib/hmi/hats-persona-cache.cjs +142 -0
  822. package/lib/hmi/jtbd-classifier.cjs +219 -0
  823. package/lib/hmi/jtbd-state.cjs +263 -0
  824. package/lib/hmi/jtbd-taxonomy.json +402 -0
  825. package/lib/hmi/mindrian-ascii-logo.cjs +96 -0
  826. package/lib/hmi/part8-egress-gate.cjs +149 -0
  827. package/lib/hmi/reach-component-map.json +47 -0
  828. package/lib/hmi/reach-relevance-gate.cjs +147 -0
  829. package/lib/hmi/selector-dispatcher.cjs +1201 -0
  830. package/lib/hmi/selector-dispatcher.test.cjs +141 -0
  831. package/lib/hmi/selector-telemetry.cjs +269 -0
  832. package/lib/hmi/shape-f0-renderer.cjs +145 -0
  833. package/lib/hmi/shape-f1-fallback.cjs +80 -0
  834. package/lib/hmi/shape-f1-renderer.cjs +219 -0
  835. package/lib/hmi/shape-f2-renderer.cjs +132 -0
  836. package/lib/hmi/shape-f3-parity.test.cjs +64 -0
  837. package/lib/hmi/shape-f3-renderer.cjs +66 -0
  838. package/lib/hmi/shape-f4-parity.test.cjs +72 -0
  839. package/lib/hmi/shape-f4-renderer.cjs +72 -0
  840. package/lib/hmi/shape-f5-renderer.cjs +155 -0
  841. package/lib/hmi/shape-f6-plan-review-renderer.cjs +324 -0
  842. package/lib/hmi/shape-f6-renderer.cjs +144 -0
  843. package/lib/hmi/shape-f7-breakthrough-renderer.cjs +234 -0
  844. package/lib/hmi/shape-f7-breakthrough-renderer.test.cjs +233 -0
  845. package/lib/hmi/shape-f8-renderer.cjs +150 -0
  846. package/lib/hmi/shape-f8-renderer.test.cjs +70 -0
  847. package/lib/hmi/shape-f9-renderer.cjs +187 -0
  848. package/lib/hmi/shape-f9-renderer.test.cjs +80 -0
  849. package/lib/hmi/shape-g-renderer.cjs +219 -0
  850. package/lib/hmi/shape-h-renderer.cjs +222 -0
  851. package/lib/hmi/tier-check.cjs +63 -0
  852. package/lib/hmi/turn-text.cjs +268 -0
  853. package/lib/hmi/voice-color-mark.cjs +318 -0
  854. package/lib/hmi/voice-style-log.cjs +276 -0
  855. package/lib/import/PRECONDITIONS.md +41 -0
  856. package/lib/import/branding.cjs +210 -0
  857. package/lib/import/branding.test.cjs +235 -0
  858. package/lib/import/classifications-sync.cjs +104 -0
  859. package/lib/import/classifications-sync.test.cjs +129 -0
  860. package/lib/import/enricher.cjs +296 -0
  861. package/lib/import/enricher.test.cjs +273 -0
  862. package/lib/import/integration.test.cjs +376 -0
  863. package/lib/import/manifest.cjs +129 -0
  864. package/lib/import/manifest.schema.json +185 -0
  865. package/lib/import/manifest.test.cjs +123 -0
  866. package/lib/import/meeting-detector.cjs +92 -0
  867. package/lib/import/meeting-detector.test.cjs +100 -0
  868. package/lib/import/person-detector.cjs +229 -0
  869. package/lib/import/person-detector.test.cjs +149 -0
  870. package/lib/import/report.cjs +186 -0
  871. package/lib/import/report.test.cjs +186 -0
  872. package/lib/import/room-md-scaffolder.cjs +49 -0
  873. package/lib/import/router.cjs +224 -0
  874. package/lib/import/router.test.cjs +356 -0
  875. package/lib/import/run-all-tests.cjs +36 -0
  876. package/lib/import/smoke-test.cjs +213 -0
  877. package/lib/import/smoke-test.test.cjs +148 -0
  878. package/lib/import/undo.test.cjs +199 -0
  879. package/lib/import/vault-scanner.cjs +105 -0
  880. package/lib/import/vault-scanner.test.cjs +67 -0
  881. package/lib/lens-engine/correlation-resolver.cjs +174 -0
  882. package/lib/lens-engine/source-lens-driver.cjs +736 -0
  883. package/lib/mcp/adapter-client.cjs +103 -0
  884. package/lib/mcp/app-html/dashboard.html +316 -0
  885. package/lib/mcp/app-html/graph.html +428 -0
  886. package/lib/mcp/app-html/mindrian-platform.html +1841 -0
  887. package/lib/mcp/app-html/wiki.html +383 -0
  888. package/lib/mcp/app-views.cjs +322 -0
  889. package/lib/mcp/brain-composition-census.cjs +184 -0
  890. package/lib/mcp/brain-router.cjs +551 -0
  891. package/lib/mcp/capability-registry.cjs +62 -0
  892. package/lib/mcp/contract-version.cjs +59 -0
  893. package/lib/mcp/daemon-lifecycle.cjs +324 -0
  894. package/lib/mcp/gate-dedup.cjs +120 -0
  895. package/lib/mcp/gate-ledger.cjs +145 -0
  896. package/lib/mcp/gate-render.cjs +483 -0
  897. package/lib/mcp/hook-adapter-audit.cjs +199 -0
  898. package/lib/mcp/larry-context.cjs +42 -0
  899. package/lib/mcp/mcp-first-flag.cjs +147 -0
  900. package/lib/mcp/no-instructions.test.cjs +270 -0
  901. package/lib/mcp/pipeline-state.cjs +424 -0
  902. package/lib/mcp/prompts.cjs +421 -0
  903. package/lib/mcp/register-core-tools.cjs +78 -0
  904. package/lib/mcp/resources.cjs +359 -0
  905. package/lib/mcp/runtime-instructions.cjs +38 -0
  906. package/lib/mcp/session-catchup.cjs +349 -0
  907. package/lib/mcp/session-registry.cjs +113 -0
  908. package/lib/mcp/session-room.cjs +124 -0
  909. package/lib/mcp/sse-event-bus.cjs +98 -0
  910. package/lib/mcp/stop-gate-handler.cjs +589 -0
  911. package/lib/mcp/surface-detect.cjs +186 -0
  912. package/lib/mcp/tool-router.cjs +2115 -0
  913. package/lib/mcp/tools/chain.cjs +674 -0
  914. package/lib/mcp/tools/claim.cjs +180 -0
  915. package/lib/mcp/tools/context.cjs +92 -0
  916. package/lib/mcp/tools/dual-path.cjs +79 -0
  917. package/lib/mcp/tools/gate.cjs +392 -0
  918. package/lib/mcp/tools/graph-reason.cjs +130 -0
  919. package/lib/mcp/tools/graph.cjs +321 -0
  920. package/lib/mcp/tools/identity.cjs +174 -0
  921. package/lib/mcp/tools/room.cjs +449 -0
  922. package/lib/mcp/tools/sensors.cjs +450 -0
  923. package/lib/mcp/tools/status.cjs +183 -0
  924. package/lib/mcp/tools/stop-gate.cjs +103 -0
  925. package/lib/mcp/tools/views.cjs +382 -0
  926. package/lib/mcp/tree-watcher.cjs +199 -0
  927. package/lib/memory/.mindrian/auto-explore-mat-test-001.json +11 -0
  928. package/lib/memory/aaak-compress.cjs +403 -0
  929. package/lib/memory/aaak-compress.test.cjs +288 -0
  930. package/lib/memory/async-artifact-auto-commit.test.cjs +223 -0
  931. package/lib/memory/bearer-token.test.cjs +315 -0
  932. package/lib/memory/body-shape-coverage.test.cjs +268 -0
  933. package/lib/memory/brain-cache-lru.test.cjs +259 -0
  934. package/lib/memory/brain-client-query-shape.test.cjs +160 -0
  935. package/lib/memory/brain-cypher-chain-slice.test.cjs +368 -0
  936. package/lib/memory/brain-derivation-graceful-degradation.test.cjs +1019 -0
  937. package/lib/memory/brain-derivation-queue.test.cjs +553 -0
  938. package/lib/memory/brain-derivation.test.cjs +639 -0
  939. package/lib/memory/brain-derive-command.test.cjs +534 -0
  940. package/lib/memory/brain-derive-curation.test.cjs +243 -0
  941. package/lib/memory/brain-md-invariants-validator.test.cjs +704 -0
  942. package/lib/memory/brain-md-schema.test.cjs +467 -0
  943. package/lib/memory/brain-md-staleness.test.cjs +525 -0
  944. package/lib/memory/brain-server-resolution.test.cjs +314 -0
  945. package/lib/memory/brain-suggestion-template.test.cjs +200 -0
  946. package/lib/memory/chain-recommender-canonical.test.cjs +208 -0
  947. package/lib/memory/chain-recommender.test.cjs +233 -0
  948. package/lib/memory/chat-context.test.cjs +128 -0
  949. package/lib/memory/command-registry.test.cjs +220 -0
  950. package/lib/memory/connector-registry.test.cjs +94 -0
  951. package/lib/memory/correlation-label-index.test.cjs +119 -0
  952. package/lib/memory/correlation.test.cjs +253 -0
  953. package/lib/memory/cross-room-aggregator.test.cjs +909 -0
  954. package/lib/memory/curation-132-03-dedup-held-rename.test.cjs +251 -0
  955. package/lib/memory/curation-132-05-pseudonymize.test.cjs +205 -0
  956. package/lib/memory/curation-batch.test.cjs +213 -0
  957. package/lib/memory/dashboard-server.test.cjs +256 -0
  958. package/lib/memory/debouncer-drain-at-prompt.test.cjs +389 -0
  959. package/lib/memory/decision-capture.test.cjs +632 -0
  960. package/lib/memory/decision-capture.worker.cjs +70 -0
  961. package/lib/memory/doctor-deprecation-surface.test.cjs +188 -0
  962. package/lib/memory/dual-graph-health.test.cjs +485 -0
  963. package/lib/memory/explain-decision-command.test.cjs +521 -0
  964. package/lib/memory/explain-decision-footer.test.cjs +316 -0
  965. package/lib/memory/explored-materials-store.cjs +392 -0
  966. package/lib/memory/f-selector-ranker.test.cjs +593 -0
  967. package/lib/memory/feynman-minto-guardian.test.cjs +863 -0
  968. package/lib/memory/feynman-minto-invariants.test.cjs +554 -0
  969. package/lib/memory/feynman-prompts-drift.test.cjs +144 -0
  970. package/lib/memory/feynman-prompts.cjs +151 -0
  971. package/lib/memory/feynman-prompts.test.cjs +96 -0
  972. package/lib/memory/first-touch-version.test.cjs +198 -0
  973. package/lib/memory/folder-memory-quadruple.test.cjs +548 -0
  974. package/lib/memory/folder-memory.test.cjs +503 -0
  975. package/lib/memory/framework-chain-composer.test.cjs +549 -0
  976. package/lib/memory/frontmatter-schema-validator.test.cjs +344 -0
  977. package/lib/memory/guardian-onstop-reaches-user.test.cjs +396 -0
  978. package/lib/memory/heal-command.test.cjs +604 -0
  979. package/lib/memory/help-coverage.test.cjs +108 -0
  980. package/lib/memory/help-renderer.test.cjs +145 -0
  981. package/lib/memory/huji-run-one-async-parity.test.cjs +242 -0
  982. package/lib/memory/hypergraph-event-schema.test.cjs +116 -0
  983. package/lib/memory/index-artifact-transaction.test.cjs +333 -0
  984. package/lib/memory/lazygraph-rs-discoveries-view.test.cjs +122 -0
  985. package/lib/memory/local-chain-recommender.test.cjs +172 -0
  986. package/lib/memory/mcp-input-validation.test.cjs +240 -0
  987. package/lib/memory/mcp-server-brain-deps.test.cjs +270 -0
  988. package/lib/memory/mcp-stack-fallback.test.cjs +433 -0
  989. package/lib/memory/minto-debounce-consumer-census.test.cjs +567 -0
  990. package/lib/memory/minto-debouncer.test.cjs +407 -0
  991. package/lib/memory/minto-debouncer.worker.cjs +46 -0
  992. package/lib/memory/minto-migration-v88.test.cjs +265 -0
  993. package/lib/memory/minto-schema-v88.test.cjs +390 -0
  994. package/lib/memory/mos-status-renderer.test.cjs +631 -0
  995. package/lib/memory/narrative-schema.cjs +376 -0
  996. package/lib/memory/narrative-schema.test.cjs +209 -0
  997. package/lib/memory/nav-dial.test.cjs +414 -0
  998. package/lib/memory/navigation-engine-core.test.cjs +712 -0
  999. package/lib/memory/navigation-engine-offer.test.cjs +404 -0
  1000. package/lib/memory/navigation-hook-resolver.test.cjs +177 -0
  1001. package/lib/memory/navigation-invariants.test.cjs +483 -0
  1002. package/lib/memory/navigation-projections.test.cjs +241 -0
  1003. package/lib/memory/navigation-write-edge.test.cjs +206 -0
  1004. package/lib/memory/offer-closer.test.cjs +258 -0
  1005. package/lib/memory/offer-presenter.test.cjs +554 -0
  1006. package/lib/memory/on-stop-snapshot.test.cjs +404 -0
  1007. package/lib/memory/orchestration-projection.test.cjs +706 -0
  1008. package/lib/memory/packet-chain-hint.test.cjs +407 -0
  1009. package/lib/memory/packet-schema-validation.test.cjs +317 -0
  1010. package/lib/memory/palette-consistency.test.cjs +127 -0
  1011. package/lib/memory/pending-tension-store.cjs +453 -0
  1012. package/lib/memory/per-command-jtbd-derivation.test.cjs +130 -0
  1013. package/lib/memory/per-command-teaching.test.cjs +110 -0
  1014. package/lib/memory/post-compact-reinjection.test.cjs +854 -0
  1015. package/lib/memory/post-write-triple.test.cjs +317 -0
  1016. package/lib/memory/pre-compact-snapshot.test.cjs +495 -0
  1017. package/lib/memory/precommit-real-commit.test.cjs +301 -0
  1018. package/lib/memory/problem-type-router.test.cjs +656 -0
  1019. package/lib/memory/query-efficiency-telemetry.test.cjs +612 -0
  1020. package/lib/memory/recompile-room-references.test.cjs +392 -0
  1021. package/lib/memory/recompile-room-references.worker.cjs +42 -0
  1022. package/lib/memory/record-decision-dual-write.test.cjs +454 -0
  1023. package/lib/memory/render-v2-disposition.test.cjs +199 -0
  1024. package/lib/memory/room-classifier-strict-mode.test.cjs +430 -0
  1025. package/lib/memory/room-minto-hook.test.cjs +398 -0
  1026. package/lib/memory/rs-discovery-engine.test.cjs +323 -0
  1027. package/lib/memory/run-feynman-tests.cjs +2101 -0
  1028. package/lib/memory/security-trifecta.test.cjs +329 -0
  1029. package/lib/memory/selector-alias-map.test.cjs +172 -0
  1030. package/lib/memory/selector-decisions.test.cjs +417 -0
  1031. package/lib/memory/selector-miss.test.cjs +290 -0
  1032. package/lib/memory/session-start-brain-staleness.test.cjs +363 -0
  1033. package/lib/memory/session-start-triple-injection.test.cjs +514 -0
  1034. package/lib/memory/sessionstart-banner-formatter.cjs +318 -0
  1035. package/lib/memory/sessionstart-coordinator.test.cjs +446 -0
  1036. package/lib/memory/sessionstart-minto-banner.test.cjs +373 -0
  1037. package/lib/memory/skill-activation-router.test.cjs +465 -0
  1038. package/lib/memory/skill-vs-code-drift.test.cjs +257 -0
  1039. package/lib/memory/soft-alias.test.cjs +144 -0
  1040. package/lib/memory/spine-events-correlation.test.cjs +198 -0
  1041. package/lib/memory/stale-copy-scanner.test.cjs +294 -0
  1042. package/lib/memory/stamp-artifact-write.test.cjs +304 -0
  1043. package/lib/memory/state-aware-router.test.cjs +90 -0
  1044. package/lib/memory/statusline-active-room-write.test.cjs +245 -0
  1045. package/lib/memory/statusline-active-room.test.cjs +315 -0
  1046. package/lib/memory/statusline-minto-segment.test.cjs +292 -0
  1047. package/lib/memory/statusline-two-row.test.cjs +338 -0
  1048. package/lib/memory/suggest-next-workflow.test.cjs +176 -0
  1049. package/lib/memory/sync-async-entry-points.test.cjs +204 -0
  1050. package/lib/memory/terminal-capability.test.cjs +155 -0
  1051. package/lib/memory/test-bridge-writer-enhanced.cjs +452 -0
  1052. package/lib/memory/test-rs-brain-substrate-shape.cjs +529 -0
  1053. package/lib/memory/test-rs-brain-substrate.cjs +636 -0
  1054. package/lib/memory/test-rs-breakthrough-scorer.cjs +375 -0
  1055. package/lib/memory/test-rs-canon-violations.cjs +218 -0
  1056. package/lib/memory/test-rs-chain-feeder-core.cjs +344 -0
  1057. package/lib/memory/test-rs-chain-feeder-skill-spawn.cjs +297 -0
  1058. package/lib/memory/test-rs-commercial-assessor.cjs +385 -0
  1059. package/lib/memory/test-rs-differential-scorer.cjs +480 -0
  1060. package/lib/memory/test-rs-discovery-engine.cjs +648 -0
  1061. package/lib/memory/test-rs-domain-analyzer.cjs +492 -0
  1062. package/lib/memory/test-rs-egress-primitives.cjs +420 -0
  1063. package/lib/memory/test-rs-expert-mapper.cjs +547 -0
  1064. package/lib/memory/test-rs-explain-command.cjs +443 -0
  1065. package/lib/memory/test-rs-fetcher-academic.cjs +848 -0
  1066. package/lib/memory/test-rs-fetcher-experts.cjs +496 -0
  1067. package/lib/memory/test-rs-fetcher-industry.cjs +702 -0
  1068. package/lib/memory/test-rs-fetcher-patents.cjs +674 -0
  1069. package/lib/memory/test-rs-innovation-classifier.cjs +301 -0
  1070. package/lib/memory/test-rs-mind-map.cjs +646 -0
  1071. package/lib/memory/test-rs-neo4j-writer.cjs +518 -0
  1072. package/lib/memory/test-rs-nl-to-query.cjs +449 -0
  1073. package/lib/memory/test-rs-pinecone-bridge.cjs +282 -0
  1074. package/lib/memory/test-rs-preprocessor.cjs +433 -0
  1075. package/lib/memory/test-rs-query-matrix.cjs +391 -0
  1076. package/lib/memory/test-rs-query-to-text.cjs +551 -0
  1077. package/lib/memory/test-rs-sqlite-mirror.cjs +649 -0
  1078. package/lib/memory/test-rs-thesis-generator.cjs +360 -0
  1079. package/lib/memory/triple-context-formatter.cjs +473 -0
  1080. package/lib/memory/triple-context-formatter.test.cjs +442 -0
  1081. package/lib/memory/user-md-persona.test.cjs +565 -0
  1082. package/lib/memory/userpromptsubmit-integration.test.cjs +787 -0
  1083. package/lib/memory/validators/README.md +157 -0
  1084. package/lib/memory/validators/brain-md-invariants.cjs +475 -0
  1085. package/lib/memory/validators/brain-substrate-invariants.cjs +285 -0
  1086. package/lib/memory/validators/external-academic-invariants.cjs +249 -0
  1087. package/lib/memory/validators/external-industry-invariants.cjs +271 -0
  1088. package/lib/memory/validators/external-patents-invariants.cjs +266 -0
  1089. package/lib/memory/validators/minto-invariants.cjs +62 -0
  1090. package/lib/memory/validators/navigation-invariants.cjs +340 -0
  1091. package/lib/memory/validators/queue-health.cjs +95 -0
  1092. package/lib/memory/validators/snapshot-integrity.cjs +129 -0
  1093. package/lib/memory/validators/stale-lifecycle.cjs +116 -0
  1094. package/lib/memory/vault-section-minto-generator-atomic.test.cjs +556 -0
  1095. package/lib/memory/vault-section-minto-generator-atomic.worker.cjs +73 -0
  1096. package/lib/memory/workflow-layer-e2e.test.cjs +262 -0
  1097. package/lib/memory/write-lock-atomic.test.cjs +137 -0
  1098. package/lib/memory/write-lock-atomic.worker.cjs +55 -0
  1099. package/lib/parity/check-parity.cjs +83 -0
  1100. package/lib/presentation/presentation-server.cjs +101 -0
  1101. package/lib/presentation/presentation-watcher.cjs +123 -0
  1102. package/lib/quickview/hub-server.cjs +719 -0
  1103. package/lib/quickview/server.cjs +533 -0
  1104. package/lib/render/JTBD-PALETTES.md +145 -0
  1105. package/lib/render/ROOM.md +111 -0
  1106. package/lib/render/render-v2.cjs +532 -0
  1107. package/lib/render/render-v2.test.cjs +267 -0
  1108. package/lib/render/render.cjs +65 -0
  1109. package/lib/sessionstart/budget-compressor.cjs +130 -0
  1110. package/lib/sessionstart/contributor-interface.cjs +134 -0
  1111. package/lib/sessionstart/contributor-isolator.cjs +128 -0
  1112. package/lib/sessionstart/precedence-ladder.cjs +47 -0
  1113. package/lib/state/ROOM.md +46 -0
  1114. package/lib/state/state-md-parser.cjs +215 -0
  1115. package/lib/statusline/ROOM.md +38 -0
  1116. package/lib/statusline/banner-suppression.cjs +50 -0
  1117. package/lib/statusline/cockpit-renderer.cjs +443 -0
  1118. package/lib/statusline/cockpit-signals.cjs +312 -0
  1119. package/lib/statusline/cockpit-telemetry.cjs +152 -0
  1120. package/lib/statusline/ctx-window.cjs +135 -0
  1121. package/lib/statusline/governing-thought-truncator.cjs +45 -0
  1122. package/lib/statusline/next-move-cache.cjs +235 -0
  1123. package/lib/statusline/ratification-next.cjs +164 -0
  1124. package/lib/statusline/room-health-cache.cjs +200 -0
  1125. package/lib/statusline/surface-detect.cjs +85 -0
  1126. package/lib/statusline/two-row-renderer.cjs +207 -0
  1127. package/lib/statusline/version-resolver.cjs +81 -0
  1128. package/lib/ui/design-system.cjs +19 -0
  1129. package/lib/update-bootstrap.sh.template +145 -0
  1130. package/lib/vault/frontmatter-schema.cjs +297 -0
  1131. package/lib/vault/room-scanner.cjs +365 -0
  1132. package/lib/vault/wikilink-builder.cjs +231 -0
  1133. package/lib/vault/wikilink-builder.test.cjs +182 -0
  1134. package/lib/wiki/briefing.cjs +193 -0
  1135. package/lib/wiki/editor-dist/wiki-editor.css +1 -0
  1136. package/lib/wiki/editor-dist/wiki-editor.js +1327 -0
  1137. package/lib/wiki/graph-links.cjs +281 -0
  1138. package/lib/wiki/page-renderer.cjs +229 -0
  1139. package/lib/wiki/room-home.cjs +353 -0
  1140. package/lib/wiki/wiki-chat.cjs +81 -0
  1141. package/lib/wiki/wiki-export.cjs +364 -0
  1142. package/lib/wiki/wiki-layout.cjs +1143 -0
  1143. package/lib/wiki/wiki-search.cjs +142 -0
  1144. package/lib/wiki/wiki-server.cjs +748 -0
  1145. package/lib/wiki/wiki-watcher.cjs +105 -0
  1146. package/lib/workflow/ROOM.md +47 -0
  1147. package/lib/workflow/chain-source.cjs +179 -0
  1148. package/lib/workflow/command-resolver.cjs +155 -0
  1149. package/lib/workflow/command-resolver.test.cjs +235 -0
  1150. package/lib/workflow/cross-room-umbilical-closer.cjs +364 -0
  1151. package/lib/workflow/dial-close-reach.cjs +405 -0
  1152. package/lib/workflow/f-selector-ranker.cjs +1148 -0
  1153. package/lib/workflow/f1-pick-consumer.cjs +232 -0
  1154. package/lib/workflow/f3-depth-consumer.cjs +98 -0
  1155. package/lib/workflow/f4-scope-consumer.cjs +112 -0
  1156. package/lib/workflow/f8-consumer.test.cjs +82 -0
  1157. package/lib/workflow/f8-fanout-consumer.cjs +208 -0
  1158. package/lib/workflow/f9-consumer.test.cjs +71 -0
  1159. package/lib/workflow/f9-ordered-consumer.cjs +199 -0
  1160. package/lib/workflow/local-chain-recommender.cjs +330 -0
  1161. package/lib/workflow/memory-cascade-f9-adapter.cjs +273 -0
  1162. package/lib/workflow/memory-governance-closer.cjs +384 -0
  1163. package/lib/workflow/offer-closer.cjs +407 -0
  1164. package/lib/workflow/reach-hedge-ranker.cjs +809 -0
  1165. package/lib/workflow/reach-reject-reader.cjs +372 -0
  1166. package/lib/workflow/reconcile-f9-adapter.cjs +299 -0
  1167. package/lib/workflow/selector-decisions.cjs +478 -0
  1168. package/lib/workflow/session-binding-consumer.cjs +249 -0
  1169. package/npm-shrinkwrap.json +1544 -0
  1170. package/output-styles/destijl.md +67 -0
  1171. package/package.json +22 -4
  1172. package/pipelines/PWS_grading/01-deep-grade.md +48 -0
  1173. package/pipelines/PWS_grading/02-mullins.md +50 -0
  1174. package/pipelines/PWS_grading/03-build-thesis.md +60 -0
  1175. package/pipelines/PWS_grading/04-structure-argument.md +77 -0
  1176. package/pipelines/PWS_grading/CHAIN.md +79 -0
  1177. package/pipelines/analogy/01-decompose.md +80 -0
  1178. package/pipelines/analogy/02-abstract.md +87 -0
  1179. package/pipelines/analogy/03-search.md +135 -0
  1180. package/pipelines/analogy/04-transfer.md +101 -0
  1181. package/pipelines/analogy/05-validate.md +106 -0
  1182. package/pipelines/analogy/CHAIN.md +73 -0
  1183. package/pipelines/discovery/01-explore-domains.md +44 -0
  1184. package/pipelines/discovery/02-think-hats.md +50 -0
  1185. package/pipelines/discovery/03-analyze-needs.md +54 -0
  1186. package/pipelines/discovery/CHAIN.md +48 -0
  1187. package/pipelines/thesis/01-structure-argument.md +45 -0
  1188. package/pipelines/thesis/02-challenge-assumptions.md +48 -0
  1189. package/pipelines/thesis/03-build-thesis.md +54 -0
  1190. package/pipelines/thesis/CHAIN.md +48 -0
  1191. package/references/brain/causal-directives.md +91 -0
  1192. package/references/brain/causal-enrichment.cypher +165 -0
  1193. package/references/brain/command-triggers-schema.md +15 -0
  1194. package/references/brain/graph-architecture.md +317 -0
  1195. package/references/brain/query-patterns.md +504 -0
  1196. package/references/brain/room-hierarchy-schema.md +224 -0
  1197. package/references/brain/schema.md +86 -0
  1198. package/references/capability-radar/capabilities-index.md +269 -0
  1199. package/references/capability-radar/changelog-cache.md +95 -0
  1200. package/references/causal/causal-schema.md +103 -0
  1201. package/references/design/email-template-standard.md +169 -0
  1202. package/references/design/graph-visualization-standard.md +178 -0
  1203. package/references/design/newsletter-email-template.html +307 -0
  1204. package/references/document-generation.md +179 -0
  1205. package/references/hsi/HSI-TOOLS-REFERENCE.md +222 -0
  1206. package/references/import-config.md +141 -0
  1207. package/references/integrations/detection-patterns.md +101 -0
  1208. package/references/meeting/artifact-template.md +377 -0
  1209. package/references/meeting/cross-meeting-intelligence.md +216 -0
  1210. package/references/meeting/cross-relationship-patterns.md +202 -0
  1211. package/references/meeting/extraction-perspectives.md +225 -0
  1212. package/references/meeting/filing-protocol.md +222 -0
  1213. package/references/meeting/knowledge-typing.md +242 -0
  1214. package/references/meeting/live-join-interface.md +244 -0
  1215. package/references/meeting/section-mapping.md +192 -0
  1216. package/references/meeting/segment-classification.md +258 -0
  1217. package/references/meeting/speaker-profile-template.md +219 -0
  1218. package/references/meeting/summary-template.md +348 -0
  1219. package/references/meeting/transcript-patterns.md +226 -0
  1220. package/references/methodology/analyze-needs.md +135 -0
  1221. package/references/methodology/analyze-systems.md +121 -0
  1222. package/references/methodology/analyze-timing.md +149 -0
  1223. package/references/methodology/beautiful-question.md +109 -0
  1224. package/references/methodology/build-knowledge.md +161 -0
  1225. package/references/methodology/build-thesis-scored.md +60 -0
  1226. package/references/methodology/build-thesis.md +237 -0
  1227. package/references/methodology/causal-loop-diagrams.md +65 -0
  1228. package/references/methodology/challenge-assumptions.md +127 -0
  1229. package/references/methodology/diagnose.md +169 -0
  1230. package/references/methodology/dominant-designs.md +212 -0
  1231. package/references/methodology/explore-domains.md +147 -0
  1232. package/references/methodology/explore-futures.md +163 -0
  1233. package/references/methodology/explore-trends.md +129 -0
  1234. package/references/methodology/find-bottlenecks.md +131 -0
  1235. package/references/methodology/grade.md +211 -0
  1236. package/references/methodology/huji-stage-a-intake.md +246 -0
  1237. package/references/methodology/index.md +34 -0
  1238. package/references/methodology/leadership.md +200 -0
  1239. package/references/methodology/lean-canvas.md +116 -0
  1240. package/references/methodology/leverage-scan-signatures.md +83 -0
  1241. package/references/methodology/macro-trends.md +192 -0
  1242. package/references/methodology/map-unknowns.md +137 -0
  1243. package/references/methodology/mullins-7-domains.md +104 -0
  1244. package/references/methodology/problem-types.md +65 -0
  1245. package/references/methodology/root-cause.md +178 -0
  1246. package/references/methodology/rubric-huji.md +160 -0
  1247. package/references/methodology/sapphire-encoding.md +355 -0
  1248. package/references/methodology/scenario-plan.md +190 -0
  1249. package/references/methodology/score-innovation.md +154 -0
  1250. package/references/methodology/skillopt-judge-rubric.md +48 -0
  1251. package/references/methodology/skillopt-queries-rubric.md +60 -0
  1252. package/references/methodology/skillopt-refute-rubric.md +59 -0
  1253. package/references/methodology/skillopt-review-rubric.md +72 -0
  1254. package/references/methodology/skillopt-revise-rubric.md +48 -0
  1255. package/references/methodology/structure-argument.md +158 -0
  1256. package/references/methodology/systems-thinking.md +231 -0
  1257. package/references/methodology/think-hats.md +147 -0
  1258. package/references/methodology/triz-matrix.json +751 -0
  1259. package/references/methodology/triz-principles.md +501 -0
  1260. package/references/methodology/user-needs.md +199 -0
  1261. package/references/methodology/validate.md +163 -0
  1262. package/references/methodology/value-proposition.md +244 -0
  1263. package/references/opportunities/funding-lifecycle.md +103 -0
  1264. package/references/opportunities/grant-api-patterns.md +99 -0
  1265. package/references/opportunities/opportunity-template.md +84 -0
  1266. package/references/opportunities/tnufa-rubric.md +81 -0
  1267. package/references/personality/assessment-philosophy.md +72 -0
  1268. package/references/personality/lexicon.md +100 -0
  1269. package/references/personality/persona-chains.md +56 -0
  1270. package/references/personality/pws-lexicon-full.md +499 -0
  1271. package/references/personality/voice-dna.md +156 -0
  1272. package/references/personas/hat-perspectives.md +76 -0
  1273. package/references/personas/persona-template.md +63 -0
  1274. package/references/pipeline/act-output-contract.md +88 -0
  1275. package/references/pipeline/chains-index.md +39 -0
  1276. package/references/pws-profile-generation.md +79 -0
  1277. package/references/reasoning/reasoning-schema.md +143 -0
  1278. package/references/reasoning/reasoning-template.md +68 -0
  1279. package/references/reasoning/run-template.md +38 -0
  1280. package/references/research/RESEARCH_14_CLAUDE_CODE_SOURCE_ARCHITECTURE.md +209 -0
  1281. package/references/research/RESEARCH_15_V1.8_OPTIMIZATION_JTBD.md +375 -0
  1282. package/references/research/RESEARCH_16_NATIVE_FIRST_PLUGIN_ARCHITECTURE.md +575 -0
  1283. package/references/research/RESEARCH_17_MCP_UI_FRAMEWORKS.md +272 -0
  1284. package/references/security/agentshield-baseline.json +8 -0
  1285. package/references/security/cve-db.json +220 -0
  1286. package/references/taxonomy/TAXONOMY.md +192 -0
  1287. package/references/templates/MINTO.md +36 -0
  1288. package/references/user-research/2026-04-05-leah-lawrence-session.md +202 -0
  1289. package/references/vault-kit/README.md +35 -0
  1290. package/references/vault-kit/app.json +12 -0
  1291. package/references/vault-kit/appearance.json +12 -0
  1292. package/references/vault-kit/graph.json +35 -0
  1293. package/references/vault-kit/snippets/mindrian-destijl.css +297 -0
  1294. package/references/vault-kit/templates/new-artifact.md +37 -0
  1295. package/references/vault-kit/templates/new-meeting-note.md +35 -0
  1296. package/references/vault-kit/templates/new-team-profile.md +29 -0
  1297. package/references/vault-kit/templates/new-xref.md +35 -0
  1298. package/references/visual/ROOM.md +55 -0
  1299. package/references/visual/palette.json +54 -0
  1300. package/references/visual/symbol-system.md +151 -0
  1301. package/scripts/189-plurai-gate-check.cjs +88 -0
  1302. package/scripts/198-plurai-gate-check.cjs +118 -0
  1303. package/scripts/198-rollback-rehearsal.cjs +233 -0
  1304. package/scripts/83-scope-injection.test.cjs +648 -0
  1305. package/scripts/PYTHON_GATES.md +78 -0
  1306. package/scripts/__pycache__/compute-hsi.cpython-312.pyc +0 -0
  1307. package/scripts/__pycache__/detect-reverse-salients.cpython-312.pyc +0 -0
  1308. package/scripts/__pycache__/rs-engine.cpython-312.pyc +0 -0
  1309. package/scripts/act-command.cjs +518 -0
  1310. package/scripts/admin-brain-write.cjs +442 -0
  1311. package/scripts/admin-command-gate.cjs +178 -0
  1312. package/scripts/agentshield-scan-cli.cjs +226 -0
  1313. package/scripts/agentshield-sessionstart-scan.cjs +282 -0
  1314. package/scripts/analogy-fitness-report.cjs +266 -0
  1315. package/scripts/analyze-room +1079 -0
  1316. package/scripts/apply-teaching-content.cjs +298 -0
  1317. package/scripts/async-artifact-auto-commit.cjs +485 -0
  1318. package/scripts/audit-active-phase-resolver.cjs +160 -0
  1319. package/scripts/audit-body-shape-coverage.cjs +213 -0
  1320. package/scripts/auto-explore-drain.cjs +274 -0
  1321. package/scripts/auto-explore-fingerprint.cjs +354 -0
  1322. package/scripts/auto-explore-fire.cjs +359 -0
  1323. package/scripts/backfill-correlation-id.cjs +425 -0
  1324. package/scripts/backfill-hitl-shape.cjs +276 -0
  1325. package/scripts/backfill-hitl-shape.test.cjs +307 -0
  1326. package/scripts/backup-modifications +68 -0
  1327. package/scripts/banner +182 -0
  1328. package/scripts/brain-derivation-drain.cjs +291 -0
  1329. package/scripts/brain-derive-command.cjs +846 -0
  1330. package/scripts/brain-normalize-books.cypher +505 -0
  1331. package/scripts/brain-normalize-final.cypher +1355 -0
  1332. package/scripts/brain-normalize-problemtype.cypher +475 -0
  1333. package/scripts/brain-normalize-supplement.cypher +449 -0
  1334. package/scripts/brain-normalize-targeted.cypher +344 -0
  1335. package/scripts/brain-normalize-v194.cypher +61 -0
  1336. package/scripts/brain-normalize.cypher +530 -0
  1337. package/scripts/brain-response-sanitize-hook.cjs +165 -0
  1338. package/scripts/build-brain-census.cjs +957 -0
  1339. package/scripts/build-brain-packet-schema.cjs +225 -0
  1340. package/scripts/build-command-registry.cjs +587 -0
  1341. package/scripts/build-connector-registry.cjs +1331 -0
  1342. package/scripts/build-corpus-stats.cjs +408 -0
  1343. package/scripts/build-dist-bundles.cjs +495 -0
  1344. package/scripts/build-ecosystem-graph.cjs +490 -0
  1345. package/scripts/build-graph +1462 -0
  1346. package/scripts/build-graph-from-sqlite.cjs +97 -0
  1347. package/scripts/build-harness-manifest.cjs +1090 -0
  1348. package/scripts/build-jtbd-nudges +205 -0
  1349. package/scripts/build-new-surface.cjs +805 -0
  1350. package/scripts/build-orchestration-projection.cjs +1221 -0
  1351. package/scripts/build-render-coverage.cjs +637 -0
  1352. package/scripts/build-skill-mirrors.cjs +681 -0
  1353. package/scripts/cache-hitrate-report.cjs +216 -0
  1354. package/scripts/causal-to-graph.cjs +163 -0
  1355. package/scripts/check-abstraction-fixture-neutral.cjs +160 -0
  1356. package/scripts/check-admin-identity.cjs +212 -0
  1357. package/scripts/check-brain-tool-liveness.cjs +502 -0
  1358. package/scripts/check-card-fire.cjs +1809 -0
  1359. package/scripts/check-cirs-declaration.cjs +279 -0
  1360. package/scripts/check-deck-design.cjs +104 -0
  1361. package/scripts/check-dual-graph-health.cjs +645 -0
  1362. package/scripts/check-first-touch-drift.cjs +220 -0
  1363. package/scripts/check-flagship-floor.cjs +391 -0
  1364. package/scripts/check-framework-vocabulary-drift.cjs +563 -0
  1365. package/scripts/check-gate-seam.cjs +178 -0
  1366. package/scripts/check-graph-derive-health.cjs +208 -0
  1367. package/scripts/check-graph-export-typemap.cjs +118 -0
  1368. package/scripts/check-help-coverage.cjs +290 -0
  1369. package/scripts/check-hitl-stages.cjs +219 -0
  1370. package/scripts/check-hook-schema-compatibility.cjs +231 -0
  1371. package/scripts/check-hsi-deps +42 -0
  1372. package/scripts/check-kuzu-reintroduction.cjs +251 -0
  1373. package/scripts/check-onboard +43 -0
  1374. package/scripts/check-onboard-statusline.cjs +363 -0
  1375. package/scripts/check-palette-consistency.cjs +106 -0
  1376. package/scripts/check-pending-ambiguous.cjs +244 -0
  1377. package/scripts/check-pending-breakthrough.cjs +189 -0
  1378. package/scripts/check-pending-breakthrough.test.cjs +166 -0
  1379. package/scripts/check-pending-naming-decision.cjs +97 -0
  1380. package/scripts/check-plugin-path-anchoring.cjs +830 -0
  1381. package/scripts/check-publish-needs.cjs +126 -0
  1382. package/scripts/check-registry-drift.cjs +206 -0
  1383. package/scripts/check-release-payload-ceiling.cjs +269 -0
  1384. package/scripts/check-render-coverage.cjs +558 -0
  1385. package/scripts/check-research-isomorphism.cjs +446 -0
  1386. package/scripts/check-reward-before-investment.cjs +261 -0
  1387. package/scripts/check-room-blueprints.cjs +213 -0
  1388. package/scripts/check-schema-aliases.cjs +532 -0
  1389. package/scripts/check-shape-declaration.cjs +958 -0
  1390. package/scripts/check-shape-declaration.test.cjs +185 -0
  1391. package/scripts/check-skill-spec.cjs +312 -0
  1392. package/scripts/check-skill-vs-code-drift.cjs +178 -0
  1393. package/scripts/check-substrate.cjs +513 -0
  1394. package/scripts/check-tool-honesty.cjs +1601 -0
  1395. package/scripts/check-update +60 -0
  1396. package/scripts/check-version-and-sha.cjs +366 -0
  1397. package/scripts/check-voice-style.cjs +184 -0
  1398. package/scripts/check-worktree-hygiene.cjs +530 -0
  1399. package/scripts/classify-insight +59 -0
  1400. package/scripts/coherence-smoke-test.cjs +489 -0
  1401. package/scripts/collect-cold-install-evidence.cjs +411 -0
  1402. package/scripts/compute-bayesian-surprise.py +175 -0
  1403. package/scripts/compute-blindspot-mass.py +209 -0
  1404. package/scripts/compute-disruption-index.py +211 -0
  1405. package/scripts/compute-element-novelty.py +254 -0
  1406. package/scripts/compute-external-whitespace.py +563 -0
  1407. package/scripts/compute-hsi.py +947 -0
  1408. package/scripts/compute-meetings-intelligence +716 -0
  1409. package/scripts/compute-opportunity-state +17 -0
  1410. package/scripts/compute-state +393 -0
  1411. package/scripts/compute-team +1112 -0
  1412. package/scripts/compute-whitespace-embeddings.py +464 -0
  1413. package/scripts/compute-whitespace-gaps.py +562 -0
  1414. package/scripts/compute_topic_forest.py +684 -0
  1415. package/scripts/consolidate-pinecone.py +265 -0
  1416. package/scripts/context-monitor +943 -0
  1417. package/scripts/create-speaker-profile +311 -0
  1418. package/scripts/cross-room-detect.cjs +195 -0
  1419. package/scripts/csv-to-idea-graph.cjs +755 -0
  1420. package/scripts/ctxl-eval.cjs +846 -0
  1421. package/scripts/curation-132-03-dedup-held-rename.cjs +395 -0
  1422. package/scripts/curation-132-05-pseudonymize.cjs +189 -0
  1423. package/scripts/derive-verb-reach-affinity.cjs +507 -0
  1424. package/scripts/detect-reverse-salients.py +242 -0
  1425. package/scripts/diagnostics-command.cjs +345 -0
  1426. package/scripts/dial-memory-refresh-command.cjs +147 -0
  1427. package/scripts/discover-analogy-whitespace.py +433 -0
  1428. package/scripts/discover-hsi-whitespace.py +352 -0
  1429. package/scripts/discover-rs-whitespace.py +327 -0
  1430. package/scripts/discovery-cycle.cjs +625 -0
  1431. package/scripts/disposition-render-v2.cjs +229 -0
  1432. package/scripts/doctor-preflight-format.cjs +101 -0
  1433. package/scripts/doctor.cjs +4327 -0
  1434. package/scripts/dogfood-bridge/append-to-queue.sh +59 -0
  1435. package/scripts/dogfood-bridge/path-filter.cjs +86 -0
  1436. package/scripts/dogfood-derive.cjs +158 -0
  1437. package/scripts/dogfood-emit.cjs +126 -0
  1438. package/scripts/empathy-observation-emit.cjs +108 -0
  1439. package/scripts/enrichment-queue-append.cjs +157 -0
  1440. package/scripts/ensure-brain-baseline.cjs +117 -0
  1441. package/scripts/entity-extract.cjs +1135 -0
  1442. package/scripts/eureka-command.cjs +687 -0
  1443. package/scripts/eureka-critic-run.cjs +662 -0
  1444. package/scripts/eureka-portfolio-report.cjs +2038 -0
  1445. package/scripts/eureka-room-report.cjs +419 -0
  1446. package/scripts/explain-decision-command.cjs +499 -0
  1447. package/scripts/export-pinecone-embeddings.cjs +516 -0
  1448. package/scripts/extract-room-intelligence.cjs +714 -0
  1449. package/scripts/fetch-brain-baseline.cjs +190 -0
  1450. package/scripts/fetch-brain-baseline.py +360 -0
  1451. package/scripts/feynman-minto-guardian.cjs +672 -0
  1452. package/scripts/feynman-timeline-refresh-command.cjs +270 -0
  1453. package/scripts/file-asset +253 -0
  1454. package/scripts/fire-sensor-event.cjs +83 -0
  1455. package/scripts/first-install-router.cjs +968 -0
  1456. package/scripts/frontmatter-schema-validator.cjs +339 -0
  1457. package/scripts/fts-index-drain.cjs +221 -0
  1458. package/scripts/generate-chat-embed.cjs +179 -0
  1459. package/scripts/generate-deck.cjs +322 -0
  1460. package/scripts/generate-export.cjs +474 -0
  1461. package/scripts/generate-hub.cjs +2553 -0
  1462. package/scripts/generate-lobby.cjs +718 -0
  1463. package/scripts/generate-presentation.cjs +988 -0
  1464. package/scripts/generate-presentation.test.cjs +405 -0
  1465. package/scripts/generate-section-intelligence.cjs +330 -0
  1466. package/scripts/generate-snapshot.cjs +1410 -0
  1467. package/scripts/generate-standalone +159 -0
  1468. package/scripts/git-ops +211 -0
  1469. package/scripts/graph-heal-pipeline.cjs +321 -0
  1470. package/scripts/gsd-artifact-graph-hook.cjs +219 -0
  1471. package/scripts/gsd-graph-derive-drain.cjs +571 -0
  1472. package/scripts/gsd-graph-derive-sweep.cjs +195 -0
  1473. package/scripts/heal-command.cjs +1365 -0
  1474. package/scripts/hedge-refit-pipeline.cjs +207 -0
  1475. package/scripts/help-renderer.cjs +303 -0
  1476. package/scripts/hmi-compliance-poll.cjs +451 -0
  1477. package/scripts/hmi-status-command.cjs +510 -0
  1478. package/scripts/hooked-rescore-117.cjs +224 -0
  1479. package/scripts/hooks/pre-commit +533 -0
  1480. package/scripts/hooks/pre-commit-room-minto-guard.cmd +43 -0
  1481. package/scripts/hooks/pre-commit-room-minto-guard.sh +533 -0
  1482. package/scripts/hsi-to-graph.cjs +194 -0
  1483. package/scripts/huji-batch.cjs +821 -0
  1484. package/scripts/huji-eval.cjs +1158 -0
  1485. package/scripts/huji-intake.cjs +563 -0
  1486. package/scripts/huji-pin-smoketest.cjs +454 -0
  1487. package/scripts/huji-run-one-async.cjs +305 -0
  1488. package/scripts/huji-run-one.cjs +671 -0
  1489. package/scripts/install-pre-commit.sh +113 -0
  1490. package/scripts/intent-classifier +106 -0
  1491. package/scripts/intent-classifier.cjs +3620 -0
  1492. package/scripts/interpret-whitespace.cjs +691 -0
  1493. package/scripts/jtbd-command.cjs +810 -0
  1494. package/scripts/jtbd-update.cjs +299 -0
  1495. package/scripts/label-topic-forest.cjs +667 -0
  1496. package/scripts/learn-from-usage +168 -0
  1497. package/scripts/lib/__pycache__/ensure_ml_deps.cpython-312.pyc +0 -0
  1498. package/scripts/lib/ensure_ml_deps.py +97 -0
  1499. package/scripts/load-embeddings-into-neo4j.cjs +569 -0
  1500. package/scripts/memory-artifact-graph-hook.cjs +191 -0
  1501. package/scripts/memory-command.cjs +687 -0
  1502. package/scripts/memory-completion-detector.cjs +217 -0
  1503. package/scripts/memory-lifecycle.cjs +620 -0
  1504. package/scripts/memory-resume-nudge.cjs +233 -0
  1505. package/scripts/methodology-ingest-local.sh +36 -0
  1506. package/scripts/migrate-brain-mcp-from-http-to-stdio.cjs +190 -0
  1507. package/scripts/migrate-brain-mcp-from-http-to-stdio.test.cjs +242 -0
  1508. package/scripts/migrate-hats-to-roomdb.cjs +217 -0
  1509. package/scripts/migrate-lazygraph.cjs +250 -0
  1510. package/scripts/migrate-minto-schema-v88.cjs +296 -0
  1511. package/scripts/migrate-plugin-root-refs.cjs +168 -0
  1512. package/scripts/migrate-room-sections-v275.cjs +556 -0
  1513. package/scripts/migrate-rooms +417 -0
  1514. package/scripts/migrate-skill-frontmatter.cjs +472 -0
  1515. package/scripts/migrate-stale-user-settings.cjs +296 -0
  1516. package/scripts/migrate-telemetry-v1.cjs +384 -0
  1517. package/scripts/migrate-telemetry-v1.test.cjs +356 -0
  1518. package/scripts/minto-debouncer.cjs +428 -0
  1519. package/scripts/mos-status.cjs +622 -0
  1520. package/scripts/mva-detect.cjs +229 -0
  1521. package/scripts/mva-run.cjs +36 -0
  1522. package/scripts/on-agent-complete +163 -0
  1523. package/scripts/on-cwd-changed +149 -0
  1524. package/scripts/on-file-changed +68 -0
  1525. package/scripts/on-stop +617 -0
  1526. package/scripts/on-task-complete +194 -0
  1527. package/scripts/operator-command.cjs +858 -0
  1528. package/scripts/operator-update.cjs +308 -0
  1529. package/scripts/part8-egress-guard-hook.cjs +229 -0
  1530. package/scripts/pipeline-command.cjs +271 -0
  1531. package/scripts/post-compact +383 -0
  1532. package/scripts/post-update-activation.cjs +339 -0
  1533. package/scripts/post-write +283 -0
  1534. package/scripts/power-demo-prompt.md +621 -0
  1535. package/scripts/pre-compact +273 -0
  1536. package/scripts/preflight-auto-explore.cjs +314 -0
  1537. package/scripts/preflight-doctor.cjs +225 -0
  1538. package/scripts/preflight-release-drift.cjs +168 -0
  1539. package/scripts/preflight-tension-surface.cjs +414 -0
  1540. package/scripts/probe-brain-contract.cjs +502 -0
  1541. package/scripts/publish-ops +346 -0
  1542. package/scripts/query-efficiency-telemetry.cjs +364 -0
  1543. package/scripts/query-semantic-scholar.cjs +545 -0
  1544. package/scripts/reapply-modifications +49 -0
  1545. package/scripts/reassign-primary.cjs +125 -0
  1546. package/scripts/recompile-room-references.cjs +601 -0
  1547. package/scripts/release-beta-preflight.sh +69 -0
  1548. package/scripts/render-pdf +588 -0
  1549. package/scripts/render-viz +190 -0
  1550. package/scripts/research-speaker +239 -0
  1551. package/scripts/resolve-room +204 -0
  1552. package/scripts/restore-post-compact-context.cjs +320 -0
  1553. package/scripts/room-auto-create-nudge.cjs +136 -0
  1554. package/scripts/room-naming-selector.cjs +201 -0
  1555. package/scripts/room-registry +767 -0
  1556. package/scripts/rs-discovery-engine.cjs +725 -0
  1557. package/scripts/rs-engine.py +2073 -0
  1558. package/scripts/rs-experts-command.cjs +300 -0
  1559. package/scripts/rs-explain-command.cjs +323 -0
  1560. package/scripts/rs-fetch-command.cjs +170 -0
  1561. package/scripts/rs-thesis-command.cjs +203 -0
  1562. package/scripts/rs-vector-bridge.cjs +410 -0
  1563. package/scripts/run-harness.cjs +890 -0
  1564. package/scripts/scout-cadence-guard.cjs +323 -0
  1565. package/scripts/scout-cadence-runner.cjs +509 -0
  1566. package/scripts/scout-telemetry-aggregator.cjs +268 -0
  1567. package/scripts/sealed-walker.py +96 -0
  1568. package/scripts/seed-brain-commands.cjs +324 -0
  1569. package/scripts/self-update +105 -0
  1570. package/scripts/sentinel-deadline-monitor +241 -0
  1571. package/scripts/sentinel-health-check +198 -0
  1572. package/scripts/sentinel-snapshot +42 -0
  1573. package/scripts/serve-dashboard +103 -0
  1574. package/scripts/serve-dashboard-live +932 -0
  1575. package/scripts/serve-presentation +97 -0
  1576. package/scripts/serve-wiki +90 -0
  1577. package/scripts/session-end-presence.cjs +79 -0
  1578. package/scripts/session-start +1943 -0
  1579. package/scripts/sessionstart-coordinator.cjs +249 -0
  1580. package/scripts/sessionstart-npm-reconcile.cjs +111 -0
  1581. package/scripts/sessionstart-post-update-preflight.cjs +303 -0
  1582. package/scripts/sessionstart-reference-now-seed.cjs +137 -0
  1583. package/scripts/setup-hooks.sh +112 -0
  1584. package/scripts/skillopt-codereview.cjs +830 -0
  1585. package/scripts/skillopt-eval.cjs +519 -0
  1586. package/scripts/skillopt-funnel.cjs +1076 -0
  1587. package/scripts/skillopt-genqueries.cjs +571 -0
  1588. package/scripts/skillopt-inventory.cjs +319 -0
  1589. package/scripts/skillopt-merge.cjs +656 -0
  1590. package/scripts/skillopt-triggerloop.cjs +1126 -0
  1591. package/scripts/soft-alias-runner.cjs +116 -0
  1592. package/scripts/stamp-artifact-write.cjs +276 -0
  1593. package/scripts/stamp-firing-block.cjs +325 -0
  1594. package/scripts/state-write.cjs +97 -0
  1595. package/scripts/statusline-fallback-echo.cjs +297 -0
  1596. package/scripts/statusline-mos +116 -0
  1597. package/scripts/statusline-mos-dispatch +127 -0
  1598. package/scripts/suggest-next-command.cjs +416 -0
  1599. package/scripts/sweep-skill-descriptions.cjs +263 -0
  1600. package/scripts/sync-rooms-graph +264 -0
  1601. package/scripts/telemetry-command-invocation.cjs +120 -0
  1602. package/scripts/test-doctor-recovery.cjs +242 -0
  1603. package/scripts/test-fresh-install.md +140 -0
  1604. package/scripts/track-analytics +156 -0
  1605. package/scripts/transcribe-audio +148 -0
  1606. package/scripts/transcript-ingest.cjs +225 -0
  1607. package/scripts/update-icm-index +153 -0
  1608. package/scripts/v182-brain-optimize.cypher +1191 -0
  1609. package/scripts/validate-model-profiles +93 -0
  1610. package/scripts/vault-content-reformatter.cjs +581 -0
  1611. package/scripts/vault-export-orchestrator.cjs +400 -0
  1612. package/scripts/vault-footer-injector.cjs +315 -0
  1613. package/scripts/vault-import.cjs +839 -0
  1614. package/scripts/vault-integration-test.cjs +318 -0
  1615. package/scripts/vault-regenerate-all.cjs +216 -0
  1616. package/scripts/vault-regenerate-all.test.cjs +138 -0
  1617. package/scripts/vault-rules-generator.cjs +220 -0
  1618. package/scripts/vault-section-minto-generator.cjs +1642 -0
  1619. package/scripts/vault-section-minto-generator.integration.test.cjs +576 -0
  1620. package/scripts/vault-section-minto-generator.test.cjs +291 -0
  1621. package/scripts/vault-section-state-generator.cjs +385 -0
  1622. package/scripts/vault-welcome-generator.cjs +403 -0
  1623. package/scripts/vault-wikilink-injector.cjs +449 -0
  1624. package/scripts/verify-phase-132.cjs +338 -0
  1625. package/scripts/verify-release +744 -0
  1626. package/scripts/whitespace-command.cjs +831 -0
  1627. package/scripts/whitespace-to-brain.cjs +384 -0
  1628. package/scripts/whitespace-to-graph.cjs +220 -0
  1629. package/scripts/wikilink-batch.cjs +102 -0
  1630. package/scripts/wikilink-file.cjs +139 -0
  1631. package/scripts/write-bridge-artifacts.cjs +140 -0
  1632. package/scripts/write-scope-check +12 -0
  1633. package/scripts/write-scope-check.cjs +461 -0
  1634. package/scripts/write-whitespace-sections.cjs +483 -0
  1635. package/settings.json +7 -0
  1636. package/skills/act/SKILL.md +523 -0
  1637. package/skills/admin/SKILL.md +437 -0
  1638. package/skills/agentshield/SKILL.md +50 -0
  1639. package/skills/analyze-needs/SKILL.md +74 -0
  1640. package/skills/analyze-systems/SKILL.md +69 -0
  1641. package/skills/analyze-timing/SKILL.md +94 -0
  1642. package/skills/auto-explore/SKILL.md +84 -0
  1643. package/skills/beautiful-question/SKILL.md +72 -0
  1644. package/skills/bono/SKILL.md +146 -0
  1645. package/skills/brain-connector/SKILL.md +206 -0
  1646. package/skills/brain-derive/SKILL.md +140 -0
  1647. package/skills/build-knowledge/SKILL.md +118 -0
  1648. package/skills/build-thesis/SKILL.md +90 -0
  1649. package/skills/causal/SKILL.md +265 -0
  1650. package/skills/challenge-assumptions/SKILL.md +74 -0
  1651. package/skills/client-discovery-interview/SKILL.md +94 -0
  1652. package/skills/client-discovery-interview/discovery-scaffold.json +41 -0
  1653. package/skills/client-discovery-interview/question-bank.md +149 -0
  1654. package/skills/compare-ventures/SKILL.md +113 -0
  1655. package/skills/context-engine/SKILL.md +169 -0
  1656. package/skills/conversation-mode/SKILL.md +189 -0
  1657. package/skills/correct-reference-now/SKILL.md +86 -0
  1658. package/skills/dashboard/SKILL.md +142 -0
  1659. package/skills/deck/SKILL.md +113 -0
  1660. package/skills/deep-grade/SKILL.md +210 -0
  1661. package/skills/diagnose/SKILL.md +128 -0
  1662. package/skills/diagnostics/SKILL.md +193 -0
  1663. package/skills/dial-memory-refresh/SKILL.md +116 -0
  1664. package/skills/diffusion/SKILL.md +125 -0
  1665. package/skills/discover/SKILL.md +216 -0
  1666. package/skills/doctor/SKILL.md +269 -0
  1667. package/skills/dogfood-flush/SKILL.md +133 -0
  1668. package/skills/dominant-designs/SKILL.md +72 -0
  1669. package/skills/eureka/SKILL.md +313 -0
  1670. package/skills/explain-decision/SKILL.md +138 -0
  1671. package/skills/explore-domains/SKILL.md +74 -0
  1672. package/skills/explore-futures/SKILL.md +64 -0
  1673. package/skills/explore-opportunity/SKILL.md +168 -0
  1674. package/skills/explore-trends/SKILL.md +74 -0
  1675. package/skills/export/SKILL.md +126 -0
  1676. package/skills/feynman-timeline-refresh/SKILL.md +105 -0
  1677. package/skills/file-meeting/SKILL.md +1190 -0
  1678. package/skills/find-analogies/SKILL.md +360 -0
  1679. package/skills/find-bottlenecks/SKILL.md +104 -0
  1680. package/skills/find-connections/SKILL.md +108 -0
  1681. package/skills/funding/SKILL.md +110 -0
  1682. package/skills/futures/SKILL.md +124 -0
  1683. package/skills/grade/SKILL.md +252 -0
  1684. package/skills/grade-grant/SKILL.md +293 -0
  1685. package/skills/graph/SKILL.md +216 -0
  1686. package/skills/hat-briefing/SKILL.md +160 -0
  1687. package/skills/heal/SKILL.md +69 -0
  1688. package/skills/help/SKILL.md +172 -0
  1689. package/skills/hmi-status/SKILL.md +73 -0
  1690. package/skills/ignite/SKILL.md +225 -0
  1691. package/skills/ingest-methodology/SKILL.md +125 -0
  1692. package/skills/intel-pipeline/SKILL.md +128 -0
  1693. package/skills/intelligence-orchestrator/SKILL.md +262 -0
  1694. package/skills/jtbd/SKILL.md +261 -0
  1695. package/skills/larry-personality/SKILL.md +571 -0
  1696. package/skills/larry-personality/framework-chains.md +92 -0
  1697. package/skills/larry-personality/mode-engine.md +185 -0
  1698. package/skills/leadership/SKILL.md +109 -0
  1699. package/skills/lean-canvas/SKILL.md +70 -0
  1700. package/skills/macro-trends/SKILL.md +84 -0
  1701. package/skills/map-unknowns/SKILL.md +72 -0
  1702. package/skills/memory/SKILL.md +212 -0
  1703. package/skills/memory-cortex-reach/SKILL.md +80 -0
  1704. package/skills/models/SKILL.md +197 -0
  1705. package/skills/mos/SKILL.md +160 -0
  1706. package/skills/mos-deck-engine/SKILL.md +329 -0
  1707. package/skills/mos-reason/SKILL.md +484 -0
  1708. package/skills/mullins/SKILL.md +151 -0
  1709. package/skills/mullins-scaffold/SKILL.md +132 -0
  1710. package/skills/mullins-scaffold/scaffold.json +223 -0
  1711. package/skills/mva-brief/SKILL.md +87 -0
  1712. package/skills/mva-option/SKILL.md +120 -0
  1713. package/skills/mva-pipeline/SKILL.md +158 -0
  1714. package/skills/mva-report/SKILL.md +79 -0
  1715. package/skills/new-project/SKILL.md +629 -0
  1716. package/skills/new-surface/SKILL.md +112 -0
  1717. package/skills/onboard/SKILL.md +485 -0
  1718. package/skills/operator/SKILL.md +167 -0
  1719. package/skills/opportunities/SKILL.md +171 -0
  1720. package/skills/organize/SKILL.md +69 -0
  1721. package/skills/persona/SKILL.md +272 -0
  1722. package/skills/pipeline/SKILL.md +164 -0
  1723. package/skills/present/SKILL.md +123 -0
  1724. package/skills/publish/SKILL.md +224 -0
  1725. package/skills/pws-brain/SKILL.md +152 -0
  1726. package/skills/pws-methodology/SKILL.md +92 -0
  1727. package/skills/qualify-opportunity/SKILL.md +111 -0
  1728. package/skills/query/SKILL.md +68 -0
  1729. package/skills/radar/SKILL.md +106 -0
  1730. package/skills/reanalyze/SKILL.md +122 -0
  1731. package/skills/research/SKILL.md +462 -0
  1732. package/skills/room/SKILL.md +381 -0
  1733. package/skills/room-passive/SKILL.md +174 -0
  1734. package/skills/room-proactive/SKILL.md +344 -0
  1735. package/skills/rooms/SKILL.md +678 -0
  1736. package/skills/root-cause/SKILL.md +73 -0
  1737. package/skills/rs-experts/SKILL.md +151 -0
  1738. package/skills/rs-explain/SKILL.md +130 -0
  1739. package/skills/rs-fetch/SKILL.md +115 -0
  1740. package/skills/rs-thesis/SKILL.md +129 -0
  1741. package/skills/scenario-plan/SKILL.md +76 -0
  1742. package/skills/scheduled-tasks/SKILL.md +301 -0
  1743. package/skills/score-innovation/SKILL.md +74 -0
  1744. package/skills/scout/SKILL.md +370 -0
  1745. package/skills/setup/SKILL.md +654 -0
  1746. package/skills/show/SKILL.md +68 -0
  1747. package/skills/skill/SKILL.md +104 -0
  1748. package/skills/snapshot/SKILL.md +178 -0
  1749. package/skills/speakers/SKILL.md +116 -0
  1750. package/skills/splash/SKILL.md +54 -0
  1751. package/skills/stance/SKILL.md +89 -0
  1752. package/skills/status/SKILL.md +107 -0
  1753. package/skills/structure-argument/SKILL.md +78 -0
  1754. package/skills/suggest-next/SKILL.md +137 -0
  1755. package/skills/systems-thinking/SKILL.md +220 -0
  1756. package/skills/think-hats/SKILL.md +82 -0
  1757. package/skills/trending-to-absurd/SKILL.md +100 -0
  1758. package/skills/ui-system/SKILL.md +474 -0
  1759. package/skills/ui-system/design-system/M-OS-DESIGN-SYSTEM.md +273 -0
  1760. package/skills/ui-system/design-system/SPEC.md +72 -0
  1761. package/skills/ui-system/design-system/image-prompt-style.md +29 -0
  1762. package/skills/ui-system/design-system/mos-design-system.css +240 -0
  1763. package/skills/ui-system/rules/design-system.md +60 -0
  1764. package/skills/ui-system/rules/dual-palette.md +156 -0
  1765. package/skills/ui-system/rules/glyph-disambiguation.md +171 -0
  1766. package/skills/ui-system/rules/shape-f-zero-and-six.md +169 -0
  1767. package/skills/update/SKILL.md +254 -0
  1768. package/skills/user-needs/SKILL.md +73 -0
  1769. package/skills/validate/SKILL.md +73 -0
  1770. package/skills/value-proposition/SKILL.md +141 -0
  1771. package/skills/vault/SKILL.md +326 -0
  1772. package/skills/visualize/SKILL.md +69 -0
  1773. package/skills/whitespace/SKILL.md +539 -0
  1774. package/skills/wiki/SKILL.md +94 -0
  1775. package/templates/_base.html +20 -0
  1776. package/templates/chat-panel.html +205 -0
  1777. package/templates/constellation-chat-hooks.js +89 -0
  1778. package/templates/constellation.html +1272 -0
  1779. package/templates/destijl-base.css +268 -0
  1780. package/templates/discovery/discovery-brief-template.md +97 -0
  1781. package/templates/due-diligence.html +49 -0
  1782. package/templates/executive-summary.html +40 -0
  1783. package/templates/icm/CLAUDE.md +31 -0
  1784. package/templates/icm/GROUP-CLAUDE.md +33 -0
  1785. package/templates/icm/INDEX.md +26 -0
  1786. package/templates/import/stage-contracts/01-ingest.md +34 -0
  1787. package/templates/import/stage-contracts/02-classify.md +48 -0
  1788. package/templates/import/stage-contracts/03-route.md +42 -0
  1789. package/templates/import/stage-contracts/04-enrich.md +40 -0
  1790. package/templates/investment-thesis.html +25 -0
  1791. package/templates/meeting-report.html +361 -0
  1792. package/templates/presentation/dashboard.html +1150 -0
  1793. package/templates/presentation/deck.html +540 -0
  1794. package/templates/presentation/diagrams.html +437 -0
  1795. package/templates/presentation/graph.html +391 -0
  1796. package/templates/presentation/insights.html +548 -0
  1797. package/templates/presentation/wiki.html +533 -0
  1798. package/templates/profile.html +136 -0
  1799. package/templates/room-context/last-session.md +56 -0
  1800. package/templates/room-context/methodology-history.md +28 -0
  1801. package/templates/room-context/rejection-log.md +25 -0
  1802. package/templates/room-context/weekly-digest.md +54 -0
  1803. package/templates/room-skeleton/MINTO.md.tmpl +19 -0
  1804. package/templates/room-skeleton/ROOM.md.identity.tmpl +13 -0
  1805. package/templates/room-skeleton/ROOM.md.section.tmpl +33 -0
  1806. package/templates/room-skeleton/STATE.md.tmpl +33 -0
  1807. package/templates/room-skeleton/USER.md.tmpl +23 -0
  1808. package/templates/room-skeleton/references/.gitkeep +0 -0
  1809. package/templates/room-skeleton/references/SECTION-SCHEMA.md +213 -0
  1810. package/templates/room-skeleton/references/SUB-SCHEMAS.md +91 -0
  1811. package/templates/room-skeleton/section-contracts/.gitkeep +0 -0
  1812. package/templates/room-skeleton/section-contracts/business-model.md +32 -0
  1813. package/templates/room-skeleton/section-contracts/competitive-analysis.md +33 -0
  1814. package/templates/room-skeleton/section-contracts/financial-model.md +30 -0
  1815. package/templates/room-skeleton/section-contracts/funding.md +41 -0
  1816. package/templates/room-skeleton/section-contracts/legal-ip.md +30 -0
  1817. package/templates/room-skeleton/section-contracts/market-analysis.md +32 -0
  1818. package/templates/room-skeleton/section-contracts/opportunity-bank.md +39 -0
  1819. package/templates/room-skeleton/section-contracts/problem-definition.md +32 -0
  1820. package/templates/room-skeleton/section-contracts/solution-design.md +36 -0
  1821. package/templates/room-skeleton/section-contracts/strategy.md +35 -0
  1822. package/templates/room-skeleton/section-contracts/team-execution.md +36 -0
  1823. package/templates/shared.css +427 -0
  1824. package/templates/showcase/blueprint.html +432 -0
  1825. package/templates/showcase/library.html +571 -0
  1826. package/templates/showcase/narrative.html +361 -0
  1827. package/templates/showcase/overview.html +468 -0
  1828. package/templates/showcase/synthesis.html +473 -0
  1829. package/templates/signature-footer.html +34 -0
@@ -0,0 +1,2101 @@
1
+ #!/usr/bin/env node
2
+ 'use strict';
3
+
4
+ /**
5
+ * Phase 81-01 test runner for the Feynman-MINTO foundation work.
6
+ *
7
+ * Discovers and runs test files that belong to the Feynman-MINTO pipeline:
8
+ * - lib/memory/feynman-prompts.test.cjs
9
+ * - lib/memory/narrative-schema.test.cjs
10
+ * - scripts/vault-section-minto-generator.test.cjs
11
+ *
12
+ * Runs each in a child process so a module-level assertion failure in one
13
+ * file does not short-circuit the rest of the suite. Exits 0 on all pass,
14
+ * 1 on any failure. Mirrors the lib/import/run-all-tests.cjs pattern.
15
+ *
16
+ * Usage:
17
+ * MINTO_FROZEN_DATE=2026-04-14 node lib/memory/run-feynman-tests.cjs
18
+ */
19
+
20
+ const fs = require('node:fs');
21
+ const path = require('node:path');
22
+ const { spawnSync } = require('node:child_process');
23
+
24
+ // Defense-in-depth against browser-hijack during suite runs. Any test that
25
+ // ends up calling platform.openBrowser() will honor this and skip the real
26
+ // spawn while still exercising the localhost URL guard. Individual tests
27
+ // (e.g. dashboard-server.test.cjs) also set this locally; setting it at
28
+ // runner scope protects future tests that forget.
29
+ process.env.MINDRIAN_OPEN_BROWSER_DISABLE = '1';
30
+
31
+ const REPO_ROOT = path.resolve(__dirname, '..', '..');
32
+
33
+ const TEST_FILES = [
34
+ path.join(REPO_ROOT, 'lib', 'memory', 'feynman-prompts.test.cjs'),
35
+ path.join(REPO_ROOT, 'lib', 'memory', 'narrative-schema.test.cjs'),
36
+ path.join(REPO_ROOT, 'scripts', 'vault-section-minto-generator.test.cjs'),
37
+ // Phase 81-02 additions:
38
+ path.join(REPO_ROOT, 'lib', 'memory', 'feynman-prompts-drift.test.cjs'),
39
+ path.join(
40
+ REPO_ROOT,
41
+ 'scripts',
42
+ 'vault-section-minto-generator.integration.test.cjs'
43
+ ),
44
+ // Phase 81-04:
45
+ path.join(REPO_ROOT, 'scripts', 'vault-regenerate-all.test.cjs'),
46
+ // Phase 82-04: wiki artifact injection fixture-based tests.
47
+ path.join(REPO_ROOT, 'scripts', 'generate-presentation.test.cjs'),
48
+ // Phase 83-04: cross-session scope injection Tier 1 tests.
49
+ path.join(REPO_ROOT, 'scripts', '83-scope-injection.test.cjs'),
50
+ // Phase 83-05: hook dispatch scaffold smoke tests.
51
+ path.join(REPO_ROOT, 'test', '83-hook-dispatch.test.cjs'),
52
+ // Phase 83-06: filesystem write interception (Tier 1.5) tests.
53
+ path.join(REPO_ROOT, 'test', '83-write-scope-check.test.cjs'),
54
+ // Phase 83-07: mid-session intent classifier (Tier 2) tests.
55
+ path.join(REPO_ROOT, 'test', '83-intent-classifier.test.cjs'),
56
+ // Phase 83-08: honesty layer markdown test.
57
+ path.join(REPO_ROOT, 'test', '83-honesty-layer.test.cjs'),
58
+ // Phase 84-08: smart notebook co-pilot fixture-based test suite (15 live + 3 skip-gated).
59
+ path.join(REPO_ROOT, 'test', '84-smart-notebook-copilot.test.cjs'),
60
+ // Phase 85-04 (WIN-FIX-F-02): run-hook.cmd exit-code propagation regression fence.
61
+ path.join(REPO_ROOT, 'tests', 'test-run-hook-cmd.cjs'),
62
+ // Phase 85-08 (WIN-FIX-I): brain-client param schema regression (Finding I, v1.10.9).
63
+ path.join(REPO_ROOT, 'tests', 'test-brain-client-params.cjs'),
64
+ // Phase 85-09 (Finding J / LASZLO-001): self-update Windows failure family regression fence.
65
+ path.join(REPO_ROOT, 'tests', 'test-self-update-platform.cjs'),
66
+ // Phase 85-06 (WIN-FIX-H-02/H-03): cross-platform banner rendering regression fence.
67
+ path.join(REPO_ROOT, 'tests', 'test-session-start-banner.cjs'),
68
+ // Phase 87-00: cascade e2e acceptance gate fixture (exits 77 when env
69
+ // degraded; the runner below treats 77 as SKIPPED, not FAILED).
70
+ path.join(REPO_ROOT, 'test', 'fixtures', 'cascade-e2e', 'cascade-e2e.test.cjs'),
71
+ // Phase 87-02: atomic write-lock concurrency fence (20 forked workers,
72
+ // exactly 1 winner) -- proves fs.openSync('wx') TOCTOU fix.
73
+ path.join(REPO_ROOT, 'lib', 'memory', 'write-lock-atomic.test.cjs'),
74
+ // Phase 87-01: security trifecta (SEC-01 Cypher sanitization + SEC-02
75
+ // API key file permissions + SEC-03 HSI timeout 5000 -> 30000).
76
+ path.join(REPO_ROOT, 'lib', 'memory', 'security-trifecta.test.cjs'),
77
+ // Phase 87-01a: ROOM.md + MINTO.md pre-commit hook (SEC-04). Worktree-safe
78
+ // installer + .room-root sentinel scoping + symlink-safe walker + Windows
79
+ // .cmd companion + session-start self-heal.
80
+ path.join(REPO_ROOT, 'lib', 'memory', 'room-minto-hook.test.cjs'),
81
+ // Phase 87-08: live dashboard Node server (scripts/serve-dashboard-live).
82
+ // Covers openBrowser localhost guard, Stream-A chat-hide, MOS_BIND_ALL
83
+ // refusal, and /api/room/* endpoint integration.
84
+ path.join(REPO_ROOT, 'lib', 'memory', 'dashboard-server.test.cjs'),
85
+ // Phase 87-05: MCP input validation (CASCADE-03 + CASCADE-05). Proves
86
+ // SECTION_RE regex, safeResolveSection traversal guard, and
87
+ // opportunitySchema JSON-structure validation.
88
+ path.join(REPO_ROOT, 'lib', 'memory', 'mcp-input-validation.test.cjs'),
89
+ // Phase 87-06: indexArtifact transaction wrap (CASCADE-04). Proves
90
+ // BEGIN/COMMIT semantics via REAL mid-transaction rollback injection +
91
+ // distinct testLockReleaseAfterCommit (enqueueWrite finally).
92
+ path.join(REPO_ROOT, 'lib', 'memory', 'index-artifact-transaction.test.cjs'),
93
+ // Phase 87-04: sync/async entry-point split (CASCADE-06). Proves three
94
+ // new files exist, key-set parity between sync and async, every async
95
+ // export is an AsyncFunction, legacy shim emits MOS_DEP_ROOM_OPS_LEGACY,
96
+ // expanded-scope caller audit (scripts/ lib/ bin/ commands/ pipelines/
97
+ // agents/ skills/) finds zero bare room-ops imports.
98
+ path.join(REPO_ROOT, 'lib', 'memory', 'sync-async-entry-points.test.cjs'),
99
+ // Phase 87-07: Brain session cache (5-min TTL + pending-promise pattern
100
+ // for R-87-07-RACE concurrent-init guard, sha256 key hashing) + bounded
101
+ // LRU for 3 intelligence-cascade caches (CASCADE-06). Includes load-time
102
+ // smoke test that catches missing-method errors after the Map->LRU swap.
103
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-cache-lru.test.cjs'),
104
+ // Phase 87-09: BYO API chat Bearer + CSRF double-submit + Origin-bound
105
+ // tokens + Host DNS-rebinding guard + security headers + safeLogError
106
+ // zero-log (R-87-09-CSRF gaps 1-6). Spawns serve-dashboard-live on
107
+ // :3192 and exercises every guard via HTTP.
108
+ path.join(REPO_ROOT, 'lib', 'memory', 'bearer-token.test.cjs'),
109
+ // Phase 87-09: chat context builder -- 5 intent patterns (contradicts,
110
+ // converges, stakeholders, gaps, briefing) stay under the 5K token
111
+ // budget; empty stakeholders early-returns gracefully (R6 / Phase 84-05).
112
+ path.join(REPO_ROOT, 'lib', 'memory', 'chat-context.test.cjs'),
113
+ // Phase 88-00-B: Feynman-MINTO invariants validator (lib/core/
114
+ // feynman-minto-invariants.cjs). 21 fixture tests across 5 violation
115
+ // categories (existence, schema, freshness, coherence, atomicity).
116
+ // Single source of truth consumed by every Phase 88 downstream plan.
117
+ path.join(REPO_ROOT, 'lib', 'memory', 'feynman-minto-invariants.test.cjs'),
118
+ // Phase 88-00: frontmatter schema v88 extension (last_generated_at,
119
+ // last_artifact_write_seen_at, reasoning_health_score, flagged_weaknesses,
120
+ // decision_log). Tests generator populates them, preserves decision_log
121
+ // across regen, and narrative-schema validator accepts both old and new
122
+ // structural payload shapes plus validateDecisionLogEntry helper.
123
+ path.join(REPO_ROOT, 'lib', 'memory', 'minto-schema-v88.test.cjs'),
124
+ // Phase 88-00 Task 2: idempotent migration script that backfills the five
125
+ // v88 fields on existing Phase 81 MINTO files. Walks room tree, atomic
126
+ // openSync wx + rename writes, --dry-run, already-v88 skip.
127
+ path.join(REPO_ROOT, 'lib', 'memory', 'minto-migration-v88.test.cjs'),
128
+ // Phase 88-01: folder-memory.cjs unified read contract (readTriple +
129
+ // readDecisionLog + computeHealthScore) with sync + async entry points
130
+ // mirroring Phase 87-04. 15 fixture tests: fresh triple, partial-missing,
131
+ // invariant-violation stale, missing-timestamps stale, artifacts-newer
132
+ // stale, parse-failed stale, references extracted, identity-text strip,
133
+ // empty-dir graceful, decision-log 20-entry read, decision-log 21-entry
134
+ // permissive read, health-score perfect 1.0, health-score zero, async
135
+ // parity, key-set parity + AsyncFunction assertion.
136
+ path.join(REPO_ROOT, 'lib', 'memory', 'folder-memory.test.cjs'),
137
+ // Phase 88-02: minto-debouncer queue (10s coalesce window + atomic
138
+ // tmp+rename writes + write-lock composition). 12 tests: enqueue,
139
+ // coalesce (earliest-wins), distinct sections, window-expired append,
140
+ // drain olderThanMs, atomic write safety, 5-fork concurrent same-section,
141
+ // 5-fork concurrent distinct sections, peek idempotent, malformed JSON
142
+ // self-heal with stderr warning, CLI subcommand, drain wall-clock timeout.
143
+ path.join(REPO_ROOT, 'lib', 'memory', 'minto-debouncer.test.cjs'),
144
+ // Phase 88-03: ROOM.md references recompiler (deterministic, atomic,
145
+ // delimiter-preserving + mtime conflict detection). 10 tests: no
146
+ // markers + artifacts append, existing block replaced byte-identically
147
+ // outside markers, cross-section wikilinks deduped under Section links,
148
+ // prose wikilinks NOT stripped into auto-block, system files filtered,
149
+ // mtime conflict skip, 3-fork concurrent same-section, 20-artifact
150
+ // sub-200ms budget, empty-section placeholder, no-ROOM.md exit 2.
151
+ path.join(REPO_ROOT, 'lib', 'memory', 'recompile-room-references.test.cjs'),
152
+ // Phase 88-04-B: atomic write contract for vault-section-minto-generator
153
+ // (openSync 'wx' + fsync + invariants validate + acquireLock + rename).
154
+ // 7 tests: happy path JSON envelope, 5-fork concurrent race, mid-write
155
+ // crash preservation, invariant ERROR rejection with preservation,
156
+ // WARNING passthrough, reader safety under interleaved writes,
157
+ // fsync-before-rename ordering trace.
158
+ path.join(REPO_ROOT, 'lib', 'memory', 'vault-section-minto-generator-atomic.test.cjs'),
159
+ // Phase 88-04 Task 1: stamp-artifact-write helper. Stamps
160
+ // last_artifact_write_seen_at into the section's MINTO.md frontmatter,
161
+ // falls back to .mindrian/pending-stamps/<section>.json when MINTO is
162
+ // absent or malformed. 6 tests: happy-path stamp + key preservation,
163
+ // pending-stamps fallback, byte-identical body preservation, concurrent
164
+ // stamp race with single final timestamp, malformed frontmatter -> pending
165
+ // fallback, soft-fail on missing section dir.
166
+ path.join(REPO_ROOT, 'lib', 'memory', 'stamp-artifact-write.test.cjs'),
167
+ // Phase 88-04 Task 3: post-write triple-fire wiring. 9 tests covering
168
+ // section .md write -> queue+recompile+stamp, non-room write no-op,
169
+ // system files skip enqueue, .txt files skip, foreground wall-clock
170
+ // bound, soft-fail exit 0, backgrounded spawn visible in source, and
171
+ // Edit + MultiEdit tool-name matchers.
172
+ path.join(REPO_ROOT, 'lib', 'memory', 'post-write-triple.test.cjs'),
173
+ // Phase 88-05: UserPromptSubmit drain block in scripts/intent-classifier.
174
+ // 7 tests: all-old drains + pending-tier1 file, all-new no-op, mixed
175
+ // partition, empty queue no-op, 20-entry wall-clock bound, pending file
176
+ // append across drains, session-crash recovery on next hook.
177
+ path.join(REPO_ROOT, 'lib', 'memory', 'debouncer-drain-at-prompt.test.cjs'),
178
+ // Phase 241-02: minto-debounce-consumer-census. Closes finding F-0
179
+ // (.planning/debug/resolved/minto-debounce-consumer-dead-end.md), which
180
+ // corrects the RCA's own methodology error: an extension-scoped grep
181
+ // (scripts/intent-classifier.cjs) missed the real, extensionless
182
+ // UserPromptSubmit consumer (scripts/intent-classifier). 5 tests: a
183
+ // production census that walks directories (not extensions) proving a
184
+ // real enqueue producer and a real drain-and-act consumer exist, a
185
+ // vacuum-ban gate (zero production sites drain with a zero age floor),
186
+ // a reachability check (the consumer is genuinely dispatched from
187
+ // hooks/hooks.json, not merely wired), the full enqueue-to-drain-to-act
188
+ // cycle (RCA Test 2), and that cycle's mutation proof (restoring the
189
+ // retired vacuum breaks it; the real fix completes it).
190
+ path.join(REPO_ROOT, 'lib', 'memory', 'minto-debounce-consumer-census.test.cjs'),
191
+ // Phase 88-06: on-stop close-out triple snapshot. 8 tests covering
192
+ // 3-section snapshot shape, readTriple-parity entry shape, queue drain
193
+ // + stale surfacing, sentinel last_generated_at -> stale list, rapid
194
+ // single-section exit under 3000ms hook budget, Phase 84 STATE.md write
195
+ // preserved, atomic writes (no .tmp. leakage), and soft-fail on degraded
196
+ // fixture with no MINTO files.
197
+ path.join(REPO_ROOT, 'lib', 'memory', 'on-stop-snapshot.test.cjs'),
198
+ // Phase 88-07 Task 1: TRIPLE_CONTEXT formatter pure unit tests. 12 tests
199
+ // covering per-section block shape, empty/overflow decision_log rendering,
200
+ // null governing_thought placeholder, references overflow, budget cap with
201
+ // weakest-first elision (null score sorts first), token estimator,
202
+ // stale annotation, pending-tier1 footer, zero sections, env-override
203
+ // for SESSION_START_BUDGET_TOKENS, and SUMMARY baseline-measurement fence.
204
+ path.join(REPO_ROOT, 'lib', 'memory', 'triple-context-formatter.test.cjs'),
205
+ // Phase 88-07 Task 2: session-start TRIPLE_CONTEXT injection. 9 tests
206
+ // covering snapshot-present render, snapshot-missing readTriple fallback,
207
+ // no-active-room no-op, pending-tier1 footer, minto-stale footer,
208
+ // wall-clock budget, Phase 83 ordering (TRIPLE_CONTEXT after ACTIVE ROOM
209
+ // CONTEXT), soft-fail on degraded input, and env-override propagation to
210
+ // the subshell node invocation.
211
+ path.join(REPO_ROOT, 'lib', 'memory', 'session-start-triple-injection.test.cjs'),
212
+ // Phase 88-08: pre-compact triple snapshot. 8 tests covering 3-section
213
+ // snapshot shape, kind:"pre-compact" marker (distinguishes from 88-06
214
+ // session-snapshot.json), 25-section truncation to MAX_SECTIONS=20 with
215
+ // truncated:true + truncated_count:5, weakest-first ordering (highest
216
+ // reasoning_health_score elided first), atomic tmp+rename (no .tmp.
217
+ // leftovers), empty-room no-op (sections:{}), soft-fail on no-MINTO
218
+ // fixture, and 20-section wall-clock under 1800ms inside 2000ms hook
219
+ // budget.
220
+ path.join(REPO_ROOT, 'lib', 'memory', 'pre-compact-snapshot.test.cjs'),
221
+ // Phase 88-09: post-compact TRIPLE_CONTEXT re-injection. 9 tests
222
+ // covering snapshot-present render, snapshot-missing fallback to live
223
+ // readTriple (+ stderr "snapshot missing" log), malformed snapshot
224
+ // fallback, empty-snapshot no-block emission, minto-stale.json +
225
+ // pending-tier1-regen.json footers, 20-section wall-clock < 2500ms,
226
+ // soft-fail on degraded input (exit 0), and content byte-identity vs
227
+ // session-start emission given the same fixture inputs (same formatter
228
+ // contract).
229
+ path.join(REPO_ROOT, 'lib', 'memory', 'post-compact-reinjection.test.cjs'),
230
+ // Phase 88-10: decision-capture module. 12 fixture tests covering
231
+ // first write, append preservation, 20-entry cap + JSONL archive,
232
+ // archive partitioned by archived-entry YYYY-MM (not today), invalid
233
+ // entry rejection with MINTO unchanged, readDecisionLog on no-MINTO
234
+ // and no-field shapes, 3-fork concurrent race, post-write invariants
235
+ // validation, preserve-on-regen composition with 88-00 schema
236
+ // contract, and special-char section names.
237
+ path.join(REPO_ROOT, 'lib', 'memory', 'decision-capture.test.cjs'),
238
+ // Phase 88-11: record-decision dual-write. 8 fixture tests proving
239
+ // bin/mindrian-tools.cjs record-decision fires BOTH primary
240
+ // (proactive-intelligence .proactive-intelligence.json write; pre-88,
241
+ // unchanged) AND additive decision_log write (decision-capture.cjs;
242
+ // 88-10). Covers derivable section happy path, missing source-artifact
243
+ // skip, MINTO missing mismatch logging to decision-dual-write-errors.jsonl,
244
+ // both-succeed clean exit, per-call idempotency append, error log
245
+ // structural format, absolute-path source-artifact inside room, and
246
+ // outside-room artifact skip with stderr warning. Primary write is
247
+ // authoritative; dual-write never blocks or regresses primary behavior.
248
+ path.join(REPO_ROOT, 'lib', 'memory', 'record-decision-dual-write.test.cjs'),
249
+ // Phase 88-13: Feynman-MINTO guardian (scripts/feynman-minto-guardian.cjs)
250
+ // with validator registry + four seed validators (minto-invariants,
251
+ // snapshot-integrity, queue-health, stale-lifecycle). 16 tests: 10 core
252
+ // modes (session-start, on-stop, pre-commit, clean-tmp) + 3 registry
253
+ // (load + fail-open + id-collision) + 3 lifecycle validators
254
+ // (snapshot-integrity partial/empty/healthy, queue-health 500/1000
255
+ // ceilings, stale-lifecycle ghost pruning atomically from stale.json).
256
+ path.join(REPO_ROOT, 'lib', 'memory', 'feynman-minto-guardian.test.cjs'),
257
+ // Phase 241-01: guardian on-stop reaches the user (SC1, both legs).
258
+ // Closes finding F-1: the on-stop invariant report was discarded twice
259
+ // over (a >/dev/null redirect, and a 1-second hard kill). 4 tests: LEG A
260
+ // (systemMessage reaches scripts/on-stop's FINAL stdout JSON line) + its
261
+ // mutation proof (restoring the discard turns it red), LEG B (an
262
+ // injected slow validator still lands invariant-report.json and prunes
263
+ // a ghost stale.json entry) + its mutation proof (restoring timeout 1
264
+ // turns it red).
265
+ path.join(REPO_ROOT, 'lib', 'memory', 'guardian-onstop-reaches-user.test.cjs'),
266
+ // Phase 241-04: real-commit proof for the pre-commit guardian demotion
267
+ // (SC3, F-3). Drives an actual `git commit` in a scratch repo against the
268
+ // canonical installed hook (scripts/hooks/pre-commit-room-minto-guard.sh),
269
+ // never runPreCommit() as a function. 4 tests: the guard actually fires
270
+ // (anti-vacuity), advisory default lands a commit with enumerated
271
+ // violations + a counted WARN, MINTO_PRECOMMIT_STRICT=1 rejects the
272
+ // commit and nothing lands, a clean room still commits with zero
273
+ // violation output (false-positive guard). GUARDIAN_PRECOMMIT_STAGED is
274
+ // never assigned a path; the staged set always comes from a real
275
+ // `git diff --cached`.
276
+ path.join(REPO_ROOT, 'lib', 'memory', 'precommit-real-commit.test.cjs'),
277
+ // Phase 88.1-07: frontmatter schema validator (lib/core/frontmatter-
278
+ // schemas.cjs pure function + scripts/frontmatter-schema-validator.cjs
279
+ // PostToolUse hook). 10 fixture tests covering valid artifact, missing
280
+ // single required field, all required missing -> critical, malformed
281
+ // YAML (null) -> critical, ROOM.md missing name, STATE.md missing
282
+ // artifact_count, MINTO.md delegation to feynman-minto-invariants,
283
+ // unknown field -> warning, purity (no fs + BSL header + no dashes),
284
+ // empty {} frontmatter -> critical. Advisory not blocking (R2).
285
+ path.join(REPO_ROOT, 'lib', 'memory', 'frontmatter-schema-validator.test.cjs'),
286
+ // Phase 88.1-08: async artifact auto-commit throttle (lib/core/auto-
287
+ // commit-throttle.cjs pure module). 10 fixture tests covering empty
288
+ // ledger, recent entry throttle, stale entry no-throttle, per-path
289
+ // scope, updateLedger immutability, pruneOldEntries drop/keep
290
+ // semantics, THROTTLE_WINDOW_MS = 5000, purity (no fs), and 1000-
291
+ // entry prune performance < 5ms.
292
+ path.join(REPO_ROOT, 'lib', 'memory', 'async-artifact-auto-commit.test.cjs'),
293
+ // Phase 88.1-16: query-efficiency telemetry pure module
294
+ // (lib/core/token-estimator.cjs). 12 fixture tests covering estimateTokens
295
+ // (chars/4 ceil + graceful null/non-string), estimateRoomTokens (valid
296
+ // room, session cache, invalid-room null, non-.md skip), clearCache,
297
+ // ratio sanity, validateEventShape (8-field contract), classifyRatio
298
+ // (10x threshold), aggregateEvents (median/mean/top5 per-command).
299
+ // Defends the Canon Part 6 57x-efficiency claim by making it measurable.
300
+ path.join(REPO_ROOT, 'lib', 'memory', 'query-efficiency-telemetry.test.cjs'),
301
+ // v1.11.2: PostToolUse hook envelope shape regression fence
302
+ // (tests/test-hook-envelope-shape.cjs). 5 scenarios covering both .cjs
303
+ // PostToolUse hooks patched in v1.11.2 (frontmatter-schema-validator +
304
+ // async-artifact-auto-commit) plus a fence over the v1.10.19 reference
305
+ // fix (query-efficiency-telemetry). For each hook: silent path emits
306
+ // zero stdout bytes; message path either silent or emits a Claude Code
307
+ // 2.x compliant envelope (top-level keys subset of {continue, stopReason,
308
+ // suppressOutput, systemMessage, decision, reason, hookSpecificOutput};
309
+ // additionalContext NOT at root; if hookSpecificOutput present,
310
+ // hookEventName === 'PostToolUse'). Soft-fail invariant preserved (always
311
+ // exit 0). Bash post-write hook deferred to follow-up patch.
312
+ path.join(REPO_ROOT, 'tests', 'test-hook-envelope-shape.cjs'),
313
+ // Phase 95-02: bash post-write envelope shape + cascade side-channel
314
+ // (<roomDir>/.mindrian/last-cascade.json) atomic write fence. Mirrors the
315
+ // PostToolUse envelope contract from tests/test-hook-envelope-shape.cjs
316
+ // applied to the bash post-write hook (which v1.11.2 deferred). Stdout
317
+ // emits hookSpecificOutput.additionalContext one-liner only; cascade
318
+ // payload moves to LOCAL side-channel JSON per Canon Part 8.
319
+ path.join(REPO_ROOT, 'tests', 'test-cascade-side-channel.cjs'),
320
+ // Phase 95-03: room-proactive SKILL.md side-channel-reader contract +
321
+ // synthetic dry-run. Text-level fence catching accidental rollback to
322
+ // the OLD additionalContext-only detection contract that was load-
323
+ // bearing-broken since Phase 88.1-03 shipped. Negative-string list
324
+ // covers ALL 5 OLD framings (not just the line-80-92 literal); current
325
+ // lines 102-113 of pre-95-03 SKILL.md were ALSO carrying the OLD
326
+ // framing and are part of the rewrite scope, not the preserved range.
327
+ // Asserts the cool-UI render directive is present (cascade-finding
328
+ // render must NOT fall back to raw prose) and that the prose APPROVE/
329
+ // REJECT/DEFER flow at SKILL.md (current) lines 114-160 is preserved
330
+ // (F.0 selector deferred to Phase 88.2 / 97 per
331
+ // room/decisions/decision-phase-95-sequencing.md).
332
+ path.join(REPO_ROOT, 'tests', 'test-room-proactive-side-channel.cjs'),
333
+ // Phase 95.1-02: 7 RED test skeletons for the 6 new drift classes (B/C/
334
+ // D/E/F) plus the section-intelligence generator and the doctor self-
335
+ // compliance retrofit. Validation-architecture-first wave per 95.1-
336
+ // VALIDATION.md: tests land BEFORE production code (Wave 1) so each
337
+ // implementation lands as a RED -> GREEN transition, never as blind
338
+ // shipping. Existing bash post-write hook + Plan 95.1-01 fixture +
339
+ // Plan 95.1-03 generator make tests 3 + 6 GREEN today; tests 1, 2, 4,
340
+ // 5, 7 stay RED until Wave 1 plans 95.1-04..95.1-08 land.
341
+ // Per Pitfall 2 from 95.1-RESEARCH.md: every spawnSync sets
342
+ // MINDRIAN_ROOMS_HOME to a scratch dir so no test can leak into the
343
+ // user's real active room.
344
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-b.cjs'),
345
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-c.cjs'),
346
+ path.join(REPO_ROOT, 'tests', 'test-cascade-surface-e2e.cjs'),
347
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-e.cjs'),
348
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-f.cjs'),
349
+ // Phase 95.2-00: hermetic regression for atomic-swap install-cache recovery
350
+ // (DOCTOR-95.2-01..05, -08). 9 scenarios exercise all 4 MOS_TEST_FORCE_FAIL
351
+ // injection points (copy/verify/rename-old/commit) plus the missing-install
352
+ // class A eligibility renderer auto-fire (s7 spawns doctor in human-render
353
+ // mode and asserts [F.1 Next Move] + /mos:doctor --fix appear in stdout).
354
+ // Hermetic via MINDRIAN_PLUGIN_HOME env override.
355
+ path.join(REPO_ROOT, 'tests', 'test-doctor-atomic-swap.cjs'),
356
+ path.join(REPO_ROOT, 'tests', 'test-generate-section-intelligence.cjs'),
357
+ path.join(REPO_ROOT, 'tests', 'test-doctor-ui-self-compliant.cjs'),
358
+ // Phase 217 Plan-02 Wave-0 gates:
359
+ // the contract-parity test -> D-03 HARD-BLOCKING declaration completeness
360
+ // gate over every data/doctor-modules.json entry (exit 1 on any gap;
361
+ // proves its own bite via an in-memory negative case).
362
+ // the card-fire-health test -> D-05 hermetic fixture tests for the
363
+ // card-fire instrument-health module (absent/valid/malformed/stale log).
364
+ // the doc-parity test (Plan-07) -> D-04 regression guard: doctor.md flags vs
365
+ // parseArgs flags + the --fix class set vs data/doctor-modules.json
366
+ // fix_supported (hard-fail on doc drift; proves its own bite).
367
+ path.join(REPO_ROOT, 'tests', 'test-doctor-module-contract-parity.cjs'),
368
+ path.join(REPO_ROOT, 'tests', 'test-doctor-card-fire-health.cjs'),
369
+ path.join(REPO_ROOT, 'tests', 'test-doctor-doc-parity.cjs'),
370
+ // Phase 232.1 Plan-01 gates (the room-graph density read):
371
+ // scenarios 1-3 -> the D-04 read-only door. Scenario 2 is the load-bearing
372
+ // one: a byte-identical sqlite_master + mtimeMs regression pin proving
373
+ // openRoomDbReadOnlyForCaller never mutates the room.db it measures. The
374
+ // older openRoomDbForCaller runs 13 CREATE TABLE IF NOT EXISTS
375
+ // statements plus 5 migrations on EVERY open, so a census through it
376
+ // would silently migrate every registered room on first run
377
+ // (232.1-RESEARCH.md Pitfall 1, reproduced empirically).
378
+ // scenarios 4-8 -> the room-graph-density registry module: D-01/D-02 (one
379
+ // entry, zero engine change), D-03 (registry walk), D-05 (a room with no
380
+ // room.db, and a schema-less room.db, both report 0/0 and never throw),
381
+ // T-232.1-02 (a corrupt registry entry soft-fails that ONE room), and
382
+ // D-06 (a machine-checkable forbidden-word guard over the rendered
383
+ // detail: a count is a measurement, never a health claim).
384
+ path.join(REPO_ROOT, 'tests', 'test-232.1-room-graph-density.cjs'),
385
+ // Plan-02 (D-07, the room_state fold): 6 scenarios over roomDensityLine
386
+ // and its wiring into the status / get-state read branches. Scenario 3
387
+ // pins that the line reads the per-call activeRoomDir, never the frozen
388
+ // boot-time roomDir closure (the intern-w1-room-state-false-empty bug
389
+ // class); scenario 6 re-pins non-mutation through the ACTUAL MCP-facing
390
+ // path, against a room.db deliberately behind the migration chain so a
391
+ // wrong-door open is observable. Both were mutation-tested to confirm
392
+ // they fail when the wiring is wrong.
393
+ path.join(REPO_ROOT, 'tests', 'test-232.1-room-state-density.cjs'),
394
+ // Phase 233 Plan-01 gates (the graph-derive drain residual, RCA 4c + 4d):
395
+ // test-233-graph-derive-health -> 12 scenarios over the ONE shared
396
+ // detection signal and the class it feeds. Scenarios 1-2 are the
397
+ // load-bearing pair: a room with BELONGS_TO edges and ZERO cascade edges
398
+ // (the ~16-damaged-room shape) must report fail, and the same room with
399
+ // one cascade edge must report ok. Both are asserted against a REAL
400
+ // room.db seeded through the repo's own writers, never a mocked object,
401
+ // because this phase exists to close a false-success class (T-233-04).
402
+ // Scenarios 10-11 spawn doctor.cjs for real and then read the room's
403
+ // actual .mindrian/graph-derive-queue.json off disk, byte-comparing it
404
+ // across two --heal-room runs to pin idempotence.
405
+ // test-233-graph-derive-heal-retrofit -> 8 scenarios over the cadence:once
406
+ // auto-repair and the Tri-Polar nudge. Scenario 1 proves the retrofit
407
+ // touches ONLY what is broken (the healthy room's queue file is compared
408
+ // byte-for-byte before and after); scenario 5 pins the fix_supported:false
409
+ // export parity; scenarios 6-8 pin the Desktop/Cowork nudge as plain
410
+ // language with zero JSON or table characters.
411
+ path.join(REPO_ROOT, 'tests', 'test-233-graph-derive-health.cjs'),
412
+ path.join(REPO_ROOT, 'tests', 'test-233-graph-derive-heal-retrofit.cjs'),
413
+ // Phase 233 Plan-02 gates (the same RCA, items 4b + 4e):
414
+ // test-233-derivation-default-gate -> 10 scenarios over runDerivation's
415
+ // default deriveFn. The load-bearing one is scenario 2: it spies the REAL
416
+ // cached graph-candidate-producer exports object, so "the dead hosted
417
+ // transport was never reached" is a MEASURED call count of 0, not an
418
+ // inference from reading the control flow. Scenarios 7-8 pin that every
419
+ // injected-deriveFn caller (the drain, the backfill, every existing test)
420
+ // is untouched by either env var.
421
+ // test-233-drain-backfill-producer-parity -> 14 scenarios proving the
422
+ // headless drain and the in-session /mos:graph --derive backfill share ONE
423
+ // default producer. Proof A is source-level with the comment-stripping
424
+ // grep-gate-hygiene idiom (and A4 proves the stripper is honest rather
425
+ // than vacuous); proof B is LIVE: the shared classifier export is swapped
426
+ // for a recorder, both modules run their real default path over two
427
+ // byte-identical fixture rooms, and the resulting cascade edges are read
428
+ // back off both room.db files and compared as sets. A future edit that
429
+ // points one trigger at a different producer fails B1 or B2.
430
+ path.join(REPO_ROOT, 'tests', 'test-233-derivation-default-gate.cjs'),
431
+ path.join(REPO_ROOT, 'tests', 'test-233-drain-backfill-producer-parity.cjs'),
432
+ // Phase 88.1-04: statusline MINTO segment cache + format helpers
433
+ // (lib/core/statusline-cache.cjs). 10 fixture tests covering getCached
434
+ // on absent cache, setCached+getCached fresh hit, TTL expiry, graceful
435
+ // fallback on permission-denied, distinct-key isolation, atomic write
436
+ // (no partial observer), cache location contract, truncateGoverningThought
437
+ // short / long variants, and classifyHealth Canon Part 2 thresholds.
438
+ // Backs the 300ms render budget (CONTEXT R1) by keeping the warm path
439
+ // a single JSON parse.
440
+ path.join(REPO_ROOT, 'lib', 'memory', 'statusline-minto-segment.test.cjs'),
441
+ // Phase 88.1-05: /mos:status Shape E renderer (scripts/mos-status.cjs).
442
+ // 12 fixture tests covering healthy 3-section render, stale suffix,
443
+ // empty (no MINTO yet) placeholder, 80-char truncation, 10-section
444
+ // summary counts (filled/stale/median), --stale-only filter, <section>
445
+ // full-detail argument, missing-room graceful exit, Canon Part 8 no-
446
+ // network surface, Shape E zones (header/rows/summary/actions), and
447
+ // warm-cache vs cold-cache paths sharing the Plan 88.1-04 5s TTL cache.
448
+ path.join(REPO_ROOT, 'lib', 'memory', 'mos-status-renderer.test.cjs'),
449
+ // Phase 88.1-06: SessionStart MINTO banner formatter (lib/memory/
450
+ // sessionstart-banner-formatter.cjs). 10 fixture tests covering top-3
451
+ // by-mtime selection on a 5-section room, 2-section no-padding render,
452
+ // 0-section brand-only render, no-active-room silent empty, stale
453
+ // (stale: reason) suffix, empty governing_thought (no MINTO yet)
454
+ // placeholder, 60-char truncation with Unicode ellipsis, tight 200-
455
+ // token budget drops to 2 rows, very tight 50-token budget drops all
456
+ // rows, and dynamic version read from .claude-plugin/plugin.json
457
+ // (no hardcoded semver) so banner brand never drifts on release.
458
+ path.join(REPO_ROOT, 'lib', 'memory', 'sessionstart-minto-banner.test.cjs'),
459
+ // Phase 90-00: BRAIN.md schema validator (lib/core/brain-md-schema.cjs).
460
+ // 18 fixture tests across 5 violation categories (existence, schema,
461
+ // staleness, attribution, canon_boundary). Mirrors Phase 88-00-B
462
+ // invariants pattern: hand-written narrow-dialect YAML parser, frozen
463
+ // SEVERITY + CATEGORIES + STALENESS + STALE_REASON + REQUIRED_
464
+ // FRONTMATTER_FIELDS + OPTIONAL_SECTION_HEADINGS enums, parse-error
465
+ // fast return. Canon Part 8 boundary baked in at schema layer via
466
+ // conservative regex set (email / currency / quoted-person / meeting
467
+ // / SSN) with action_hint "canon_part8_review". Load-bearing contract
468
+ // for Plans 90-01 (derivation writer), 90-04 (readQuadruple), 90-05
469
+ // (registry-discoverable invariants), 90-09 (Phase 91 Navigation
470
+ // Engine interface spec).
471
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-md-schema.test.cjs'),
472
+ // Phase 90-01: Brain derivation core (lib/core/brain-derivation.cjs +
473
+ // lib/core/brain-derivation-prompts.cjs). 18 fixture tests across
474
+ // happy path, offline/timeout/rate-limit failure modes, schema gate
475
+ // rejection, concurrent writes, triple absent, null governing_thought
476
+ // sha256 sentinel, only_sections/dry_run options, schema()
477
+ // call-count invariant, atomic write tmpfile naming pattern, crash
478
+ // cleanup, deriveSection never-throws contract, three-surface CJS
479
+ // purity, and the LOAD-BEARING Canon Part 8 payload audits (Tests
480
+ // 13 + 14) that capture every outbound Brain cypher + pinecone
481
+ // search and assert every payload against the frozen allow-list
482
+ // regex set AND that dangerous user content ("Lawrence / 5M /
483
+ // revenue") NEVER leaks into any Brain call.
484
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-derivation.test.cjs'),
485
+ // Phase 90-02: Brain derivation queue (lib/core/brain-derivation-queue.cjs).
486
+ // 15 fixture tests covering enqueue (idempotent dedupe, replace on hash
487
+ // change, cross-section isolation, .mindrian dir autocreate), readQueue
488
+ // (missing file + malformed JSON self-heal), writeQueueAtomic (tmpfile +
489
+ // rename), concurrent write race (no corruption), SOFT_CAP=500 warning,
490
+ // HARD_CAP=1000 rejection, Canon Part 8 invariant audit (queue carries
491
+ // ONLY section + hash pairs + reason + timestamp; never governing_thought
492
+ // text), and drain (stale-queue-race guard via current-triple-hash
493
+ // comparison, brain-offline re-enqueue, maxEntries partition).
494
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-derivation-queue.test.cjs'),
495
+ // Phase 90-03 Task 1: BRAIN.md staleness computation (lib/core/brain-md-
496
+ // staleness.cjs). 13 fixture tests covering the 4 staleness signals
497
+ // (hash mismatch, age_exceeded, brain_graph_version_mismatch,
498
+ // brain_offline), precedence rules (hash-mismatch > age > version),
499
+ // recommended_action demotion when Brain offline (enqueue_regen ->
500
+ // enqueue_when_brain_online), BRAIN_STALE_AGE_DAYS env override with
501
+ // fallback on garbage, malformed-frontmatter -> parse_failed stale
502
+ // reason, and the LOAD-BEARING Canon Part 8 audit (Test 13) that runs
503
+ // 10 sections through computeBrainStaleness and asserts ZERO
504
+ // brain-client.query/search/smartSearch calls; isAvailable + schema
505
+ // are the ONLY allowed Brain touches during the scan.
506
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-md-staleness.test.cjs'),
507
+ // Phase 90-03 Task 2: scripts/session-start Phase 90-03 integration
508
+ // tests. 5 fixture tests spawning real bash session-start with BRAIN.md
509
+ // fixtures: mixed fresh/stale/absent annotation render, Brain-offline
510
+ // stale annotation with empty queue (no enqueue when we cannot drain),
511
+ // Brain-online stale -> enqueue lands + wall-clock < 5000ms,
512
+ // BRAIN_STALENESS_SKIP=1 feature flag suppression, and backward-compat
513
+ // for rooms with zero BRAIN.md (no "Brain derivation" noise lines).
514
+ path.join(REPO_ROOT, 'lib', 'memory', 'session-start-brain-staleness.test.cjs'),
515
+ // Phase 90-04: readQuadruple extends Phase 88-01 readTriple additively
516
+ // with a brain field parsed from BRAIN.md (lib/core/folder-memory.cjs +
517
+ // lib/core/folder-memory-async.cjs + lib/core/folder-memory-shared.cjs
518
+ // additive surface). 17 fixture tests: 5 parser-isolation cases for
519
+ // parseBrainMd (valid full struct, absent->null literal, malformed->
520
+ // emptyBrain parse_failed:true, 3-of-9 sections populated + 6 absent,
521
+ // unknown heading ignored for future-compat) + 12 integration cases
522
+ // (sync readQuadruple happy-path + brain absent + malformed + nonexistent
523
+ // path no-throw, async AsyncFunction constructor parity, sync/async deep
524
+ // equality, key-set parity with readTriple back-compat preserved,
525
+ // isQuadrupleFresh 5 cases covering brain null/fresh/stale plus
526
+ // brain_offline exemption and derivation-stale). Backward-compat
527
+ // critical: readTriple signature/return unchanged. OPTIONAL_SECTION_
528
+ // HEADINGS parity with brain-md-schema also asserted.
529
+ path.join(REPO_ROOT, 'lib', 'memory', 'folder-memory-quadruple.test.cjs'),
530
+ // Phase 90-05: BRAIN.md invariants validator (lib/memory/validators/
531
+ // brain-md-invariants.cjs). Phase 88-13 registry-compatible drop-in:
532
+ // {id, severity_map, validate, scope:'section'} + auto-discovered by
533
+ // guardian's validator loader. Wraps Plan 90-00 validateSchema as the
534
+ // schema check and adds three runtime checks: (A) staleness vs live
535
+ // triple (governing_thought_hash mismatch -> staleness/warning with
536
+ // action_hint 'enqueue_regen'), (B) brain_graph_version drift vs
537
+ // .mindrian/brain-schema-cache.json (-> staleness/warning), (C)
538
+ // cross-file Canon Part 8 body-text scan with 5-violation cap
539
+ // (canon_boundary/warning + action_hint 'canon_part8_review'). 15
540
+ // fixture tests + 1 shape test cover absence-is-valid, schema
541
+ // wrapping, attribution, staleness, drift, 4 canon leak patterns,
542
+ // cap, aggregation, parse-failure short-circuit, non-BRAIN.md not
543
+ // scanned, and Phase 88-13 guardian auto-discovery integration (real
544
+ // guardian on-stop spawn, invariant-report.json assertion). Zero
545
+ // guardian.cjs changes; zero new runtime deps; BSL 1.1.
546
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-md-invariants-validator.test.cjs'),
547
+ // Phase 90-07: /mos:brain-derive command dispatcher (scripts/brain-derive-
548
+ // command.cjs). 12 fixture tests covering the 4 invocation modes (single
549
+ // section, --all, --cross-room, --dry-run) plus graceful degradation
550
+ // paths (Brain offline from start, rate-limit mid-batch, invalid section,
551
+ // no active room, schema-gate rejection on one section) plus streaming
552
+ // progress on --all runs > 3 sections and the Shape E Action Report
553
+ // rendering contract (header/counts/per-section/NEXT). Mocks brain-
554
+ // client + brain-derivation via require.cache overrides (same pattern
555
+ // as Plan 90-01 and 90-02). Canon Part 8: dispatcher is a thin wrapper
556
+ // over deriveSection; all Canon boundaries enforced inside deriveSection
557
+ // + cross-room-aggregator; dispatcher adds zero net new Brain surface.
558
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-derive-command.test.cjs'),
559
+ // Phase 90-06: cross-room aggregator (lib/core/cross-room-aggregator.cjs).
560
+ // 18 fixture tests covering Phase 83 registry discovery, GUARDRAIL.md
561
+ // sealed-room skip (byte-for-byte reuse of Phase 83 contract), per-room
562
+ // brain_cross_room:false opt-out, out-of-scope absolute-path rejection
563
+ // (ALLOWED_ROOT under ~/MindrianRooms/), unreadable/timeout/self-
564
+ // exclusion skip reasons, three contradiction types (hash_divergence,
565
+ // framework_contradiction, problem_type_mismatch), max_rooms cap,
566
+ // registry-less and malformed-registry graceful fallback, 10-room
567
+ // wall-clock < 500ms, and the LOAD-BEARING Canon Part 8 payload audits
568
+ // (Tests 16-18): adversarial fixture with dangerous content ('Lawrence
569
+ // said $5M', emails, SSN, phone, 'meeting with') across 3 rooms; assert
570
+ // JSON.stringify(result) contains ZERO forbidden substrings, every
571
+ // detail_scalar field is primitive with strings <=40 chars and matching
572
+ // no forbidden regex, and brain-derivation.cjs cross_room_scan
573
+ // integration populates 'Flagged Contradictions (cross-room)' with
574
+ // slug-based entries only. Fourth Canon Part 8 tripwire (schema doc +
575
+ // prompt-builder allow-list + invariants body scan + this plan's
576
+ // sanitizeDetailScalar + JSON.stringify output audit).
577
+ path.join(REPO_ROOT, 'lib', 'memory', 'cross-room-aggregator.test.cjs'),
578
+ // Phase 90-08: graceful degradation end-to-end suite (third-line
579
+ // defense for Phase 90). 14 failure scenarios + 2 cross-cutting audits,
580
+ // four invariants per scenario: A no crash, B no partial/orphaned
581
+ // BRAIN.md, C user-visible status (reason or stderr), D retry path
582
+ // correct. Scenarios span Brain-offline permanent + intermittent,
583
+ // API quota exhaustion, mid-derivation timeout, schema drift mid-
584
+ // session, malformed Brain response, network partition, filesystem
585
+ // EACCES, ENOSPC on atomic rename, concurrent deriveSection race,
586
+ // Canon Part 8 regression under ordinary + timeout operation
587
+ // (dangerous fixture: Lawrence + 5M + revenue + emails + SSN + phone),
588
+ // cross-room aggregator under corrupt peer room, and concurrent
589
+ // session-start staleness scans (Plan 90-02 idempotency). Audit A1
590
+ // scans every BRAIN.md written during the suite against the frozen
591
+ // forbidden regex set (email / currency / quoted-person / meeting /
592
+ // SSN / phone); any match hard-fails the suite. Audit A2 sweeps
593
+ // every tmp root for BRAIN.md.tmp.*.brain orphans; any found hard-
594
+ // fails. Proves Canon Part 8 holds AS A FAILURE-MODE GUARANTEE.
595
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-derivation-graceful-degradation.test.cjs'),
596
+ // Phase 89.1a-03: Brain methodology substrate loader fixture suite.
597
+ // 14 scenarios: 6 adversarial (Canon Part 8 boundary), 3 happy-path
598
+ // (Mode A1/A2/A3), 3 cache/persistence (TTL + validator), 2 graceful
599
+ // degradation (Mode B1/B3). A1 cross-scenario cache sweep + A2 orphan
600
+ // tmpfile sweep at suite end. Inherits Phase 90-08 mock-via-require.cache
601
+ // + runScenario pattern byte-for-byte.
602
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-brain-substrate.cjs'),
603
+ // Phase 89.1-01: brain-client shape adapter + validator Check E
604
+ // embedding-or-score relaxation. 14 fixture scenarios:
605
+ // T1-9 (Task 1): pullFromBrain.adaptBrainSearchResponse translates
606
+ // live MCP {result:{hits:[]}} into legacy {matches:[]} with
607
+ // score-bearing entries (Pinecone searchRecords returns no values).
608
+ // Tests cover live shape, empty hits, legacy back-compat, malformed
609
+ // shape, sparse hit, loadSubstrate Mode A3 + cache landing,
610
+ // Canon Part 8 audit chokepoint preservation, Pitfall 1 quota
611
+ // fallback rejection, and graceful degradation on null response.
612
+ // T10-14 (Task 2): validator Check E embedding-or-score relaxation.
613
+ // Score-only valid, score-out-of-range critical, neither critical,
614
+ // legacy 1024-dim back-compat, canon_boundary on forbidden regex
615
+ // in score-only entry metadata.
616
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-brain-substrate-shape.cjs'),
617
+ // Phase 89.1-02: Domain analyzer fixture suite. 11 scenarios
618
+ // (1 happy + 4 edge + 4 adversarial + 2 determinism) + suite-end
619
+ // A1 sweep over every analyzer output against FORBIDDEN_PATTERNS +
620
+ // DANGEROUS_SUBSTRINGS. Asserts ExternalEgressViolation fires on
621
+ // adversarial substrate metadata. Inherits 89.1a-03 mock-via-
622
+ // require.cache pattern byte-for-byte.
623
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-domain-analyzer.cjs'),
624
+ // Phase 89.1-03: Query matrix fixture suite. 11 scenarios
625
+ // (1 happy + 4 edge + 4 adversarial + 2 determinism) + suite-end
626
+ // A1 sweep over every generated query string. Determinism fence:
627
+ // 5 invocations of identical input produce identical JSON.
628
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-query-matrix.cjs'),
629
+ // Phase 89.2-01: Shared egress primitives fixture suite. 8 scenarios
630
+ // + A1 forbidden-pattern sweep + A2 orphan tmpfile sweep. Covers the
631
+ // ExternalEgressViolation extracted class, FORBIDDEN_PATTERNS byte-for-byte
632
+ // re-export with require-time drift guard, auditQueryString +
633
+ // auditQueryObject chokepoint helpers, atomic telemetry ledger with
634
+ // sha256-hashed query_text (literal NEVER persists), per-source budget
635
+ // math over rolling 24h window, and graceful fs-error degradation.
636
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-egress-primitives.cjs'),
637
+ // Phase 89.2-02: Academic fetcher fixture suite. 20 scenarios total
638
+ // (12 fetcher + 6 validator + A1 forbidden-pattern sweep + A2
639
+ // FORBIDDEN_PATTERNS parity gate). Covers OpenAlex + arXiv + PubMed
640
+ // + Scopus + IEEE + Nature dispatch, dedup determinism, API-key
641
+ // graceful degradation, 429 rate-limit graceful, timeout graceful,
642
+ // malformed response graceful, per-source budget exhausted, 4
643
+ // adversarial Canon Part 8 scenarios proving ZERO captured URLs +
644
+ // ZERO telemetry on adversarial input, chokepoint exclusivity static
645
+ // grep (exactly 1 fetch( call site).
646
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-fetcher-academic.cjs'),
647
+ // Phase 89.2-03: Patents fetcher fixture suite. 17 scenarios total
648
+ // (11 fetcher + 6 validator + A1 sweep + A2 parity). Covers Google
649
+ // Patents + USPTO dispatch with pre-flight Canon Part 8 audit
650
+ // (Pattern 6 -- walks every query through chokepoint BEFORE source
651
+ // loop runs so adversarial inputs at any position produce ZERO
652
+ // captured URLs). PATENTS_SOURCES validator gate (Pattern 7) scopes
653
+ // Checks B/C/E/F to google_patents + uspto entries on the shared
654
+ // global ledger.
655
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-fetcher-patents.cjs'),
656
+ // Phase 89.2-04: Industry fetcher fixture suite. 17 scenarios total
657
+ // (11 fetcher + 6 validator + A1 sweep + A2 parity). Covers Tavily
658
+ // orchestration with TWO-LAYER auditQueryString chokepoint (Layer 1
659
+ // on user query, Layer 2 on each refined sub-query AFTER template
660
+ // substitution). 4 adversarial scenarios including 2 second-layer
661
+ // template-override attacks proving defense-in-depth. POST + body
662
+ // capture for body-payload audit. INDUSTRY_SOURCES = {tavily}
663
+ // validator gate.
664
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-fetcher-industry.cjs'),
665
+ // Phase 89.2-05: Experts post-processor fixture suite. 12 scenarios
666
+ // + A1 sweep. Post-processor (NO new egress surface); extracts
667
+ // deduped author records from academic fetcher papers[] output with
668
+ // composite-key dedup (name|orcid), standard h-index, and 3-layer
669
+ // public-email gate (PUBLIC_EMAIL_SOURCES allow-list = openalex only
670
+ // per kickoff section 15 Q4 + strict regex + FORBIDDEN_PATTERNS scan).
671
+ // 4 adversarial scenarios verify auditQueryObject defense-in-depth
672
+ // pre-return scrub.
673
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-fetcher-experts.cjs'),
674
+ // Phase 89.2-06 Task 1: Pinecone bridge standalone fixture suite. 4
675
+ // scenarios + A1 sweep. Covers strict 1024-dim Pinecone-direct vector
676
+ // retrieval via thin JSON-over-stdio CJS shim around existing
677
+ // rs_cache.py::fetch_all_from_namespace (resolves deferred-from-89.1
678
+ // strict-1024-dim item without touching Brain MCP). Mocks spawnSync
679
+ // via require.cache override. Cosine similarity identity (1.0) +
680
+ // anti-parallel (-1.0) + orthogonal (0.0) corner cases.
681
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-pinecone-bridge.cjs'),
682
+ // Phase 89.2-06 Task 2: Preprocessor fixture suite. 10 scenarios +
683
+ // A1 sweep. Phase 2 deterministic 5-field-per-document preprocessor
684
+ // (document_id + technical_terms[] + concepts[] + methods[] +
685
+ // relevance_score + boundary_flag). Covers source-aware text
686
+ // extraction (papers/patents abstract; industry signals signal),
687
+ // determinism (5 invocations byte-identical), boundary-flag
688
+ // heuristic, and 3 adversarial Canon Part 8 scenarios.
689
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-preprocessor.cjs'),
690
+ // Phase 89.2-06 Task 3: Differential scorer fixture suite. 10
691
+ // scenarios + A1 sweep. Phase 3 dual-floor filter
692
+ // (passes IFF diff > 0.3 AND lsa > 0.2 AND bert > 0.2; strict
693
+ // comparisons). LSA via embedded sklearn TfidfVectorizer + TruncatedSVD
694
+ // (DELIBERATE Canon Part 7 carve-out, documented in 3 locations);
695
+ // BERT via Pinecone-direct bridge. Two-mock pattern (spawnSync +
696
+ // rs-pinecone-bridge require.cache override) covers 4-cell graceful
697
+ // degradation matrix. 2 adversarial scenarios verify bridges are
698
+ // NEVER called when Layer 1 audit fires.
699
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-differential-scorer.cjs'),
700
+ // Phase 89.2-07 Task 1: Innovation classifier fixture suite. 8
701
+ // scenarios + A1 sweep. Phase 3 deterministic 3-enum classifier
702
+ // (structural_transfer / semantic_implementation / hybrid) on
703
+ // {diff, lsa, bert, passes} pair output. Strict > thresholds
704
+ // (lsa=0.3, bert=0.3); boundary at exact threshold falls to default
705
+ // fallback. Classification independent of passes. 2 adversarial
706
+ // Canon Part 8 scenarios.
707
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-innovation-classifier.cjs'),
708
+ // Phase 89.2-07 Task 2: Breakthrough scorer fixture suite. 10
709
+ // scenarios + A1 sweep. Phase 3 5-dimension 0-10 rubric
710
+ // (feasibility + market + magnitude + advantage + impact). Frozen
711
+ // DIMENSIONS array enforces deterministic dominant_dimension
712
+ // tie-break. Each dimension is a pure step function (no continuous
713
+ // interpolation). 2 adversarial Canon Part 8 scenarios.
714
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-breakthrough-scorer.cjs'),
715
+ // Phase 89.2-07 Task 3: Thesis generator fixture suite. 9 scenarios
716
+ // + A1 sweep. Phase 4 pure-template-fill (string concat, NOT
717
+ // template-literal interpolation) producing
718
+ // 'By applying X to Y, achieve Z because mechanism bridge_concept.'
719
+ // NO runtime LLM. Z-fallback ('novel insight') and bridge_concept
720
+ // fallback ('domain analogy') as frozen constants. 2 adversarial
721
+ // Canon Part 8 scenarios verify pre-input throw OR pre-return scrub.
722
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-thesis-generator.cjs'),
723
+ // Phase 89.3-01: rs-neo4j-writer (Aura Cypher writer; idempotent MERGE; rollback Cypher; Canon Part 8 defense)
724
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-neo4j-writer.cjs'),
725
+ // Phase 89.3-02: rs-sqlite-mirror (Tier 0 SQLite writer; INSERT OR REPLACE; rollback SQL; Canon Part 8 defense)
726
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-sqlite-mirror.cjs'),
727
+ // Phase 89.3-03: rs-mind-map (5-branch Cytoscape; Tier 0/1 read paths; Canon Part 8 audit on HTML)
728
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-mind-map.cjs'),
729
+ // Phase 89.3-04: rs-expert-mapper (Cypher MATCH+MERGE; Tier 0 graceful degradation; Canon Part 8 2-seam defense)
730
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-expert-mapper.cjs'),
731
+ // Phase 89.3-05: bridge-writer-enhanced (regression-tested; thesis + breakthrough_score frontmatter; Canon Part 8 audit on rendered output)
732
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-bridge-writer-enhanced.cjs'),
733
+ // Phase 89.4-01: rs-canon-violations (Canon Part 3 closed-vocabulary enforcement; CanonVerbViolation + CANONICAL_VERBS + validateVerb)
734
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-canon-violations.cjs'),
735
+ // Phase 89.4-02: rs-chain-feeder-core (lookupUpstream + emitChainMetadata; Brain FEEDS_INTO topology via existing chokepoint; Canon Part 8 audit at both entry points)
736
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-chain-feeder-core.cjs'),
737
+ // Phase 89.4-03: rs-chain-feeder-skill-spawn (5-rule deterministic table per kickoff section 6.4; first-match-wins; recommendSkillSpawn body wired in place)
738
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-chain-feeder-skill-spawn.cjs'),
739
+ // Phase 89.5-01: rs-commercial-assessor (deterministic 3-field commercial layer; frozen tables + Canon Part 8 input audit; NO runtime LLM)
740
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-commercial-assessor.cjs'),
741
+ // Phase 89.5-02: rs-nl-to-query (HARDEST Canon Part 8 surface in v1.11.0; buildBrainQueryFromNL chokepoint + 3-seam audit + 6+ adversarial fixtures)
742
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-nl-to-query.cjs'),
743
+ // Phase 89.5-03: rs-query-to-text (Larry-voiced NL explanation; frozen VOICE_TEMPLATES + deterministic FNV-1a kind detection + 2-seam audit)
744
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-query-to-text.cjs'),
745
+ // Phase 89.5-04: rs-discovery-engine (top-level orchestrator; chains 17 phase modules; Tier 0/Mode B graceful; Canon Part 8 input audit at gate)
746
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-discovery-engine.cjs'),
747
+ // Phase 89.5-05: rs-explain-command (end-to-end CLI smoke; bidirectional NL-Graph; 4 e2e scenarios + BSL header check + A1 sweep)
748
+ path.join(REPO_ROOT, 'lib', 'memory', 'test-rs-explain-command.cjs'),
749
+ // Phase 91-00: navigation-engine core (L5 Decision layer; decide(turn, ctx) composes 5 signals; tier-mode + RECOMMENDED gate + Section 4 staleness + Section 8 trace; 33 fixtures across shared helpers + decide() orchestration)
750
+ path.join(REPO_ROOT, 'lib', 'memory', 'navigation-engine-core.test.cjs'),
751
+ // Phase 91-01: USER.md persona durability (lib/core/persona-taxonomy.cjs
752
+ // frozen tables + Larry-to-Brain D-03 translation; lib/core/user-md-ops.cjs
753
+ // readUserMd / writeUserMdAtomic / detectPersonaUpdate / emptyUser; 22
754
+ // fixtures covering taxonomy invariants, atomic write under load,
755
+ // graceful malformed-fallback, update threshold + consecutive-turn rule,
756
+ // user_override bypass, cross-session persistence subprocess, and Canon
757
+ // Part 8 grep guard).
758
+ path.join(REPO_ROOT, 'lib', 'memory', 'user-md-persona.test.cjs'),
759
+ // Phase 91-02: UserPromptSubmit hook integration (scripts/intent-
760
+ // classifier.cjs Phase 91 navigation engine block). 12 fixture tests:
761
+ // happy path NAVIGATION DECISION emission, full injection shape with 6
762
+ // labeled fields + Why line on null values, 1200ms hard timeout
763
+ // fallback under MOS_NAV_TEST_SLEEP=5000ms, engine throw fallback
764
+ // (classifier byte-stable), atomic decision_trace persistence under 10
765
+ // rapid runs, 50-entry rotation (drop oldest 10 -> 41 on disk), session
766
+ // ID scoping (CLAUDE_SESSION_ID + sha256 fallback), Phase 83 mismatch
767
+ // warning preserved when engine returns Tier 0, per-turn quadruple
768
+ // cache observable via MOS_NAV_TEST_COUNTER, USER.md persona ->
769
+ // intent_persona.archetype mapping with absent-USER.md graceful path,
770
+ // Canon Part 8 source-scan (zero brain-client.query/search/smartSearch
771
+ // + zero fetch + zero shell-out curl), and cold/warm wall-clock budget
772
+ // with elapsed_ms field on every persisted trace entry.
773
+ path.join(REPO_ROOT, 'lib', 'memory', 'userpromptsubmit-integration.test.cjs'),
774
+ // Phase 91-03: skill-activation-router (lib/core/skill-activation-
775
+ // router.cjs). Composes navigation-engine.decide() output with legacy
776
+ // file-state + env activation. Engine precedence when fire_skill is
777
+ // set; legacy fallback when engine silent; mixed when only
778
+ // suppress_skills is populated. Canon Part 3 closed 10-verb
779
+ // vocabulary enforced (validateVerb + canonicalizeVerb); unknown
780
+ // verbs rejected with canon_part_3_unknown_verb_rejected trace note.
781
+ // Contradictory fire-vs-suppress resolved deterministically (fire
782
+ // wins; suppress entry for the fired skill is dropped). 15 router
783
+ // unit tests + 2 integration tests against scripts/intent-classifier.cjs
784
+ // end-to-end.
785
+ path.join(REPO_ROOT, 'lib', 'memory', 'skill-activation-router.test.cjs'),
786
+ // Phase 91-04: offer-presenter (lib/core/offer-presenter.cjs). Converts
787
+ // navigation-engine.decide() offer_next_step into a one-line grounded
788
+ // suggestion ("Offer: Because <reason>, try <command>.") with optional
789
+ // RECOMMENDED marker per Canon Part 3 Section 6 (Mode A + confidence
790
+ // >= 0.7 + verb match -- evaluated by the engine, respected here).
791
+ // Noise gates: max 1 offer per turn (one_offer_per_turn), suppress
792
+ // after 2 consecutive ignores (consecutive_ignores_threshold), grounding
793
+ // rule rejects empty/short/generic reasons (ungrounded_reason /
794
+ // generic_reason). Outcomes persist atomically to .mindrian/offer-
795
+ // history.json (Canon Part 4: every choice is graph data; LOCAL-only
796
+ // per Canon Part 8). 15 presenter unit tests + 2 integration tests
797
+ // through scripts/intent-classifier.cjs (engine offer rendered;
798
+ // ignore-loop reclassifies prior 'shown' to 'ignored' on next turn).
799
+ path.join(REPO_ROOT, 'lib', 'memory', 'offer-presenter.test.cjs'),
800
+ // Phase 91-05: /mos:explain-decision command (commands/explain-decision.md
801
+ // + scripts/explain-decision-command.cjs). User-facing audit surface for
802
+ // the Navigation Engine. Reads .mindrian/decision-traces/<session>.json
803
+ // (written by Plan 91-02) and renders human-readable trace output --
804
+ // header + body covering all 8 Section 8 brain_md_* fields plus all 5
805
+ // structural trace fields plus chosen_rationale. Default renders last
806
+ // 1 trace; --last N renders the N most recent (clamped to available);
807
+ // --session SESSIONID overrides default resolution. Default resolution
808
+ // chain: CLAUDE_SESSION_ID env -> .mindrian/current-session.json
809
+ // pointer -> most-recent trace file by mtime. Graceful fallbacks:
810
+ // absent file -> "No decisions recorded" advisory; malformed file ->
811
+ // "could not be parsed" advisory; both exit 0 so the command never
812
+ // throws on a fresh room. De Stijl glyph classifier maps tier_mode +
813
+ // weight_applied to check/warn/low. Canon Part 8 LOCAL-only: zero
814
+ // network surface (Test 11 source-scan parity with Plans 91-02 + 91-04).
815
+ path.join(REPO_ROOT, 'lib', 'memory', 'explain-decision-command.test.cjs'),
816
+ // Phase 94-09: /mos:explain-decision Action Footer (scripts/explain-
817
+ // decision-command.cjs renderTrace + empty-path emitter). Per QA
818
+ // handoff Section 3 FIX-8: pre-94-09 the rendered output ended with
819
+ // `---` separator and no Next: footer, violating the skills/ui-system/
820
+ // SKILL.md 4-zone Action Footer rule (Section 1 Zone 4 "NEVER omitted").
821
+ // 4 fixture tests: T1 last 5 lines contain literal 'Next:'; T2 footer
822
+ // contains at least 2 /mos: command refs (status / act / suggest-next
823
+ // per QA handoff verbatim suggestion); T3 non-regression -- the 9
824
+ // existing renderTrace markers (Tier Mode / BRAIN.md signal / Five-
825
+ // Signal Triangulation / Chosen rationale + closing `---` separator)
826
+ // are preserved before the footer; T4 graceful empty path -- the
827
+ // footer renders even when traces array is empty, so the user always
828
+ // gets a navigable next step. Canon Part 7 (Reuse Before Build):
829
+ // extends existing renderTrace + empty-path emitter with a tail
830
+ // append; no new module. Canon Part 3 (Tri-Context Decision Gate):
831
+ // footer offers verbs from the canonical 10-verb vocabulary
832
+ // (status -> Synthesize, act -> Run Methodology, suggest-next ->
833
+ // Free-Text / Spawn Sub-Agent); no new verbs introduced.
834
+ path.join(REPO_ROOT, 'lib', 'memory', 'explain-decision-footer.test.cjs'),
835
+ // Phase 91-07: problem-type-router (lib/core/problem-type-router.cjs).
836
+ // Parses BRAIN.md problemtype_classification + wicked_indicators bodies
837
+ // and returns 4-type routing recommendations (UDP / IDP / WDP /
838
+ // unknown) per locked decision D-08. Wicked escalation per Canon
839
+ // Appendix E rule R4 (wicked_score >= 8 -> soft-systems family).
840
+ // 24 fixture tests: parser (1-5), 4-type routing tables + verb
841
+ // traceability (6-10, 16-18), wicked detection + override (11-15),
842
+ // decide() integration (19-21), brain-client.isAvailable() upgrade
843
+ // from hard-coded false (Plan 91-02) to real scalar lookup (22-24).
844
+ // Canon Part 8 Section 9.3: only isAvailable allowed; query/search/
845
+ // smartSearch FORBIDDEN.
846
+ path.join(REPO_ROOT, 'lib', 'memory', 'problem-type-router.test.cjs'),
847
+ // Phase 91-08: framework-chain-composer (lib/core/framework-chain-
848
+ // composer.cjs). Parses BRAIN.md framework_chain_predictions section
849
+ // body (FEEDS_INTO edges authored by Phase 90-01 deriveSection),
850
+ // detects when the user just completed framework A (via reasoning
851
+ // governing_thought primary; mtime fallback), and proposes framework
852
+ // B as engine.offer_next_step with command = /mos:<slug>. Confidence
853
+ // gate: < 0.5 -> null (noise floor); >= 0.7 -> recommended_eligible
854
+ // flag set so offer-presenter can render RECOMMENDED marker per Plan
855
+ // 91-04 + Canon Part 3 Section 6. User override (turn 2 invokes
856
+ // different /mos: command) recorded as REJECTED chain suggestion in
857
+ // decision_trace + offer-history outcome=ignored (Canon Part 4: every
858
+ // choice is graph data). Canon Part 8: composer reads only LOCAL
859
+ // BRAIN.md body via readQuadruple.brain.sections; never queries Brain
860
+ // at engine time. 18 fixture tests: 15 pure-module (parser + completion
861
+ // detection + proposal + grounding + RECOMMENDED eligibility + tie-
862
+ // breaking) + 3 decide() integration (chain offer rendered, recommended
863
+ // eligibility surfaced, user override recorded).
864
+ path.join(REPO_ROOT, 'lib', 'memory', 'framework-chain-composer.test.cjs'),
865
+ // Phase 91-06: Larry dial (lib/core/nav-dial.cjs pure resolver +
866
+ // formatter; scripts/context-monitor integration). Statusline navigation
867
+ // indicator that renders three positions (Investigate | Blend | Insight)
868
+ // with the active position highlighted per Navigation Engine decision.
869
+ // 17 fixture tests: 12 pure-module (resolveDialPosition mapping across
870
+ // tier_0 / mode_b / mode_a weight bands, insight rationale detection,
871
+ // null + malformed graceful default, formatDialSegment Larry: prefix +
872
+ // 3-label render + < 60-char visible byte-budget, classifyHealth
873
+ // byte-identity with Plan 88.1-04 thresholds, sub-2ms warm-path perf)
874
+ // + 5 integration / canon audit (context-monitor renders dial when
875
+ // trace exists, context-monitor pre-91 byte-stable when no trace,
876
+ // spawned context-monitor wall-clock under cold-path budget, BSL 1.1
877
+ // header in nav-dial.cjs, Canon Part 8 source scan -- zero brain-client
878
+ // / fetch / curl / https references in dial source).
879
+ path.join(REPO_ROOT, 'lib', 'memory', 'nav-dial.test.cjs'),
880
+ // Phase 91-09: navigation-invariants validator (lib/memory/validators/
881
+ // navigation-invariants.cjs). Drop-in registry-compatible validator for
882
+ // the Phase 88-13 Feynman-MINTO guardian. Converts five silent Phase 91
883
+ // failure modes into first-class health signals at session-start /
884
+ // on-stop / pre-commit:
885
+ // INV-1 trace_missing_field any of 8 Section 8 brain_md_*
886
+ // fields absent from a persisted
887
+ // decision_trace -> error.
888
+ // INV-2 recommended_in_wrong_mode RECOMMENDED rendered in mode_b
889
+ // or tier_0 (Canon Part 3 Section 6
890
+ // requires mode_a) -> error.
891
+ // INV-3 weight_clamp_breach brain_md_weight_applied outside
892
+ // [0.0, 1.0] -> error.
893
+ // INV-4 trace_file_malformed decision-traces/*.json that fails
894
+ // JSON.parse -> error; sibling files
895
+ // continue to be scanned.
896
+ // INV-5 unknown_verb_passed fire_skill not in CANONICAL_VERBS
897
+ // (Canon Part 3 frozen 10-verb
898
+ // vocabulary) -> warning. Graceful
899
+ // when shared module unavailable.
900
+ // 16 tests: validator shape contract, severity_map coverage, INV-1..
901
+ // INV-5 positive + negative paths, session_file_absent info, registry
902
+ // integration via guardian on-stop + GUARDIAN_VALIDATORS_DIR, fail-open
903
+ // inheritance from Phase 88-13 (malformed sibling does NOT prevent
904
+ // navigation-invariants), Canon Part 8 source scan (zero network
905
+ // surface; brain-client / fetch / smartSearch all forbidden), BSL 1.1
906
+ // header. scope='room' per Phase 88-13 scope-mode dispatch (navigation
907
+ // is cross-section). Zero guardian.cjs edits required (extensibility
908
+ // promise of the Phase 88-13 registry contract is honored).
909
+ path.join(REPO_ROOT, 'lib', 'memory', 'navigation-invariants.test.cjs'),
910
+ // Phase 94-01: statusline active-room read contract. lib/core/folder-
911
+ // memory.cjs getCurrentRoom() reads STATE.md frontmatter current_room
912
+ // field; scripts/context-monitor consumes it as the canonical source so
913
+ // /mos:rooms switches propagate to the bottom-of-screen indicator on
914
+ // the next prompt cycle (Lawrence reproducer fence). 8 fixture tests:
915
+ // missing STATE.md null path, STATE.md without frontmatter null path,
916
+ // frontmatter without current_room null path, happy-path triple shape,
917
+ // malformed YAML graceful null path, no-caching switch reproducer,
918
+ // quote / whitespace stripping across 5 variants, end-to-end context-
919
+ // monitor stdout substring contains the switched-room slug. Canon
920
+ // Part 7 (reuse readQuadruple's frontmatter parser; no new YAML lib).
921
+ // Canon Part 4 (statusline is read-only derived view; STATE.md
922
+ // frontmatter remains canonical write surface).
923
+ path.join(REPO_ROOT, 'lib', 'memory', 'statusline-active-room.test.cjs'),
924
+ // Quick 260723-ad9: the WRITE half of the Phase 94-01 contract. room-registry
925
+ // create/set-active + compute-state populate and preserve current_room.
926
+ path.join(REPO_ROOT, 'lib', 'memory', 'statusline-active-room-write.test.cjs'),
927
+ // Phase 94-02: rs-discovery-engine thesis-merge handoff fence. Producer
928
+ // scripts/rs-discovery-engine.cjs Phase 4 Synthesis loop folds theses[i]
929
+ // into breakthroughs[i] before writerPayload selection (success branch),
930
+ // and the empty-fallback envelope carries thesis: 'no_thesis' sentinel
931
+ // (deviation from plan locked-decision object stub; consumer
932
+ // validateRequiredFields requires non-empty string per rs-sqlite-mirror
933
+ // line 121-130). 3 fixture tests: success-path merge, empty-path stub,
934
+ // E2E tier 0 sqlite row write. Canon Part 7 (compose existing
935
+ // thesisGenerator output without touching consumer schema authority).
936
+ // Canon Part 4 (RSDiscovery write surface unblocked).
937
+ path.join(REPO_ROOT, 'lib', 'memory', 'rs-discovery-engine.test.cjs'),
938
+ // Phase 94-03: canonical Brain MCP server-name resolution fence. v1.11.0
939
+ // QA found Brain unreachable from /mos:* commands because plugin command
940
+ // frontmatter declared 3 inconsistent server-name prefixes (mcp__neo4j-
941
+ // brain__, mcp__mindrian-brain__, mcp__pinecone-brain__) while .mcp.json
942
+ // declared only `mindrian-os`. Plan 94-03 selects QA Option A: standardize
943
+ // on `mindrian-brain` across all 10 affected commands + document the
944
+ // user-side .mcp.json snippet in docs/install/BRAIN-SETUP.md. 5 fixture
945
+ // tests: T1 every brain reference in allowed-tools uses canonical
946
+ // prefix, T2 zero mcp__neo4j-brain__ references remain, T3 zero
947
+ // mcp__pinecone-brain__ references remain, T4 BRAIN-SETUP.md exists
948
+ // with mindrian-brain + mcpServers substrings, T5 frontmatter-schema-
949
+ // validator runnable smoke. Canon Part 7 (cheapest sweep; no alias
950
+ // system, no auto-detect). Canon Part 8 (Brain query chokepoint
951
+ // unchanged; only the resolved server name standardizes).
952
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-server-resolution.test.cjs'),
953
+ // Phase 94-04: mcp-server-brain dependency + drift fence. v1.11.0 P0
954
+ // ship-blocker: bundled mcp-server-brain/ cannot start because npm
955
+ // install never runs in that subdirectory and required env vars
956
+ // (SUPABASE_URL, MINDRIAN_BRAIN_KEY, etc.) are silently absent. Plan
957
+ // 94-04 ships three layers of safety: T1 install.sh post-install hook
958
+ // (cd mcp-server-brain && npm install) wrapped in package.json
959
+ // existence guard for Tier 0 graceful skip; T2 .env.brain.template
960
+ // lists all 7 required env vars (SUPABASE_URL / SUPABASE_KEY /
961
+ // MINDRIAN_BRAIN_KEY / NEO4J_URI / NEO4J_USERNAME / NEO4J_PASSWORD /
962
+ // PINECONE_API_KEY) one per line with comments; T3 scripts/session-
963
+ // start emits a yellow WARN line when MINDRIAN_BRAIN_KEY is set but
964
+ // canonical 'mindrian-brain' is absent from .mcp.json (this repo) OR
965
+ // the user's personal .mcp.json (loud yellow signal beats silent
966
+ // tier_0 fallback); T4 docs/install/BRAIN-SETUP.md gains a
967
+ // 'Bundled mcp-server-brain (optional/legacy)' section noting that
968
+ // v1.11.2 deprecates the bundled server in favor of users pointing
969
+ // 'mindrian-brain' at their own Neo4j MCP (Plan 94-03 Option A).
970
+ // Canon Part 7 (extends existing chokepoints install.sh + session-
971
+ // start; no new orchestration). Canon Part 8 (drift check is LOCAL-
972
+ // only: env var existence + .mcp.json file inspection; zero network
973
+ // surface added).
974
+ path.join(REPO_ROOT, 'lib', 'memory', 'mcp-server-brain-deps.test.cjs'),
975
+ // Phase 94-05: mcp-stack fallback chain fixture suite. v1.11.0 P0
976
+ // architectural ship-blocker: per the user-approved plan amendment
977
+ // (commit 66a1a34), rs-fetcher-industry is the TRUE Tavily-only gap
978
+ // (one source, TAVILY_API_KEY required). T1 industry happy paid path
979
+ // (opts.tavily injection seam returns paid envelope); T2 native
980
+ // fallback (no key, opts.webSearch returns native envelope); T3
981
+ // cache fallback (no key, no webSearch, opts.cacheReader returns
982
+ // cache envelope); T4 all-tiers-down empty results, never throws;
983
+ // T5 envelope shape uniformity across academic + patents + experts
984
+ // with backward-compat domain keys (papers / patents / experts)
985
+ // preserved alongside results; T6 lib/core/section-8-trace-schema.cjs
986
+ // exports web_research_tier per Phase 91 forward-additive invariant;
987
+ // T7 commands/research.md body removes the "Requires Brain MCP"
988
+ // hard-stop and "Then stop." directive that blocks fresh installs.
989
+ // Canon Part 4 (tier transitions become graph data via web_research_
990
+ // tier edge); Part 7 (extends Phase 89.2 fetchers with envelope
991
+ // wrap; reuses Anthropic native WebSearch + WebFetch instead of
992
+ // building a new client); Part 8 (WebSearch + WebFetch are public-
993
+ // domain SIGNAL queries; existing brain-client chokepoint untouched;
994
+ // no new Brain endpoints).
995
+ path.join(REPO_ROOT, 'lib', 'memory', 'mcp-stack-fallback.test.cjs'),
996
+ // Phase 94-06: room classifier strict-mode fence. Lawrence Aronhime's
997
+ // 2026-04-28 38-min live test with 2 rooms loaded
998
+ // (core-power-isolation + curriculum-redesign-fall-2026) had four
999
+ // utterances resolve to the WRONG room because the classifier ran a
1000
+ // similarity heuristic only and core-power-isolation had high token
1001
+ // overlap with everything. Plan 94-06 inserts a strict-mode override
1002
+ // at the top of the room-resolution path: numeric ('8', 'switch to 2')
1003
+ // -> registry position; explicit slug ('curriculum-redesign-fall-2026',
1004
+ // '/mos:rooms <slug>') -> exact slug match; quoted exact name
1005
+ // ('"Beta"', '"Curriculum Redesign Fall 2026"') -> name OR slug exact.
1006
+ // Each match emits a Section-8 trace edge `routing_source: 'strict_mode'`
1007
+ // per Canon Part 4. 6 fixture tests: T1 numeric, T2 explicit slug,
1008
+ // T3 quoted name, T4 routing_source assertion + STRICT_MODE_ROUTING_
1009
+ // SOURCE constant export, T5 fallthrough regression fence (no strict-
1010
+ // mode pattern -> null, similarity heuristic unchanged), T6 Lawrence
1011
+ // reproducer (3 strict + 1 known-deferred to v1.11.3 for natural-
1012
+ // language 'the curriculum room'). Canon Part 3 (10-verb vocabulary
1013
+ // preserved; strict-mode is a routing override, not a new verb).
1014
+ // Canon Part 4 (override emits graph edge). Canon Part 7 (extends
1015
+ // existing scripts/intent-classifier.cjs without introducing a new
1016
+ // classifier file).
1017
+ path.join(REPO_ROOT, 'lib', 'memory', 'room-classifier-strict-mode.test.cjs'),
1018
+ // Phase 94.1-01: /mos:heal command orchestrator fence. The /mos:heal
1019
+ // command wraps the 10-step room wiring heal recipe dog-fooded on the
1020
+ // mindrianOS room on 2026-04-29 (recipe at ~/MindrianRooms/mindrianOS/
1021
+ // methodology/2026-04-29-v1-11-0-room-wiring-heal-process.md). This
1022
+ // fixture is the v1.11.1 GA closing artifact: any user upgrading from
1023
+ // v1.10.x to v1.11.x can self-heal their room without manual
1024
+ // intervention. 6 fixture tests: T1 dry-run on degraded fixture
1025
+ // (10-step plan, zero mutation), T2 full heal post-conformance
1026
+ // (8 canonical sections + every section ROOM.md + STATE.md +
1027
+ // .mindrian/room.db nodes COUNT > 0 + root STATE.md regenerated +
1028
+ // backup populated), T3 heal-log envelope shape (one entry per step;
1029
+ // 10 keys per entry; summary present), T4 backup created (timestamp
1030
+ // YYYYMMDD-HHMMSS pattern + pre-heal STATE.md verbatim), T5
1031
+ // mega-section graceful degradation (FEYNMINTO-01 budget rejection
1032
+ // logged not thrown; tier-0 fallback + continue), T6 idempotence
1033
+ // (heal twice; second run zero error_* statuses). Canon Part 7
1034
+ // (Reuse Before Build): wraps existing scripts/migrate-lazygraph.cjs
1035
+ // + scripts/vault-section-state-generator.cjs + scripts/vault-section-
1036
+ // minto-generator.cjs + scripts/compute-state without net-new
1037
+ // methodology. Canon Part 4 (Every Choice Is Graph Data): heal-log.json
1038
+ // captures the full cascade. Canon Part 8 (Graph Boundary): heal is
1039
+ // LOCAL-only; brain-derivation-queue is read but NEVER drained inside
1040
+ // heal (drain deferred to v1.12 candidate plan).
1041
+ path.join(REPO_ROOT, 'lib', 'memory', 'heal-command.test.cjs'),
1042
+ // Phase 99-01: conversation operator state machine (lib/conversation/
1043
+ // operator.cjs). Foundational deliverable for Phase 99 conversation
1044
+ // operator state machine + downstream consumers (Phase 100 JTBD
1045
+ // classifier, Phase 102 renderer, Phase 95.1 polling, Sprites
1046
+ // Workspace v2.0). 12 scenarios covering the validation architecture
1047
+ // dimensions from 99-RESEARCH.md: cold-start default (D-04), resume
1048
+ // from disk (D-05/D-06), schema_version-first ordering (D-06), valid
1049
+ // transitions (D-08), invalid-transition rejection without partial
1050
+ // write (D-09), DECISION_GATE -> previous (D-08), history bounded at
1051
+ // 50 with drop-oldest (D-26), atomic write rollback when rename
1052
+ // throws (D-07), frame budget getCurrent < 2ms / transition < 10ms
1053
+ // (D-23/D-24), Canon Part 8 grep audit on operator.cjs source
1054
+ // (D-22), OPERATOR_TRANSITION edge graceful skip when graph absent,
1055
+ // and OPERATOR_TRANSITION edge written when graph exists with
1056
+ // properties.trigger + timestamp + methodology (Canon Part 4 + D-21).
1057
+ // Self-contained: copies fixtures from test/fixtures/conversation-
1058
+ // operator/ to os.tmpdir() so committed fixtures are never mutated.
1059
+ // Zero new runtime dependencies (Phase 87 invariant).
1060
+ path.join(REPO_ROOT, 'tests', 'test-operator-state.cjs'),
1061
+ // Phase 102-01: renderer contract regression fence. 12 IIFE
1062
+ // assertions covering the 5-operator round-trip via the v2
1063
+ // destructured API (JUST_TALK is the explicit suppress case via
1064
+ // operator gate; the other 4 compose normally), undefined / null
1065
+ // operator do not crash, unknown operator strings are tolerated
1066
+ // (Phase 102 deliberately drops the 99-03 throw so upstream callers
1067
+ // can route arbitrary strings without try/catch wrappers), envelope
1068
+ // shape stable (exactly 2 keys: rendered + contract; no _stub leak),
1069
+ // mode passthrough (A / B / tier-0 + arbitrary unchanged), tier
1070
+ // passthrough (0 / 1 / 2 / 3 + arbitrary unchanged), and OPERATORS
1071
+ // export frozen + equals 5 canonical names. Replaces the Phase 99-03
1072
+ // stub fence at the same registration slot; Plan 102-01 evolves the
1073
+ // renderer signature from positional 4-arg to a destructured single-
1074
+ // arg API per CONTEXT D-10 and RESEARCH §2.
1075
+ path.join(REPO_ROOT, 'lib', 'render', 'render-v2.test.cjs'),
1076
+ // Phase 99-05: /mos:operator command. Tests show/history/set/reset
1077
+ // subcommands, --json paths, Tier 0 fallback, UI Ruling System self-
1078
+ // compliance (12-glyph + 5-color + 4-zone + Shape E + Shape F.1 + Shape
1079
+ // F.4), Canon Part 8 audit (zero Brain queries), frame budget (50
1080
+ // invocations < 500ms mean), and commands/operator.md frontmatter scan.
1081
+ // Depends on Phase 99-01 lib/conversation/operator.cjs at runtime;
1082
+ // integration tests skip-as-fail until 99-01 lands in the merged tree.
1083
+ path.join(REPO_ROOT, 'tests', 'test-operator-command.cjs'),
1084
+ // Phase 99-02: heuristic NL classifier for the conversation operator state
1085
+ // machine. Five gates: T1 corpus accuracy >= 80% on the 50-message hand-
1086
+ // labeled fixture under test/fixtures/conversation-operator/classifier-
1087
+ // corpus.json (D-25); T2 frame budget mean < 8ms on a 200-char benchmark
1088
+ // (D-23 corollary, 5ms target with CI headroom); T3 tier-0 fallback when
1089
+ // classifier-rules.json is missing (Decision #8 -- spawn fresh node child
1090
+ // because module cache hides reload); T4 validate-cross-check between
1091
+ // classifier candidate_op + suggested_trigger and operator.cjs validate()
1092
+ // (every classifier output is operationally consistent with the state
1093
+ // machine); T5 boundary conditions (empty input, /mos:operator and
1094
+ // /mos:status target_op:null markers, /mos:room beats general /mos:
1095
+ // METHODOLOGY due to JSON-array ordering, AskUserQuestion -> DECISION_GATE
1096
+ // 1.0, EXPLORE_CAPTURE + "let's file this" -> BUILD_ROOM per D-08, null
1097
+ // input -> tier-0). Canon Part 8 (LOCAL only): zero Brain queries, zero
1098
+ // external requires, pure local string matching. Canon Part 7 (Reuse
1099
+ // Before Build): externalized lexicon JSON tunable without code edits.
1100
+ path.join(REPO_ROOT, 'tests', 'test-operator-classifier.cjs'),
1101
+ // Phase 99-04: operator-aware hooks integration. 12 scenarios covering
1102
+ // SessionStart resume hint when state.current === 'BUILD_ROOM' AND
1103
+ // state.context.active_section is set (D-18); UserPromptSubmit
1104
+ // classifier-driven transitions per D-11/D-12 (heuristic threshold 0.6);
1105
+ // PostToolUse AskUserQuestion -> DECISION_GATE with decision_gate_pending
1106
+ // set (D-20); active-room guard mirroring Phase 95 cascade-side-channel
1107
+ // pattern (D-22 + Decision #15); sealed-room invariant (Phase 84-07 /
1108
+ // Decision #15); envelope schema strict per Phase 95 BASH-95-01
1109
+ // (top-level allowlist; additionalContext only inside hookSpecificOutput);
1110
+ // frame budget < 250ms mean per spawnSync invocation (50ms script + spawn
1111
+ // cost); hook never blocks on malformed stdin / missing hook_event_name /
1112
+ // missing registry / throwing classifier (defensive catch-all). Canon
1113
+ // Part 8: zero Brain queries. Self-contained: each test creates its own
1114
+ // tmp dir and tears it down via fs.rmSync in finally. Zero new runtime
1115
+ // dependencies (Phase 87 invariant).
1116
+ path.join(REPO_ROOT, 'tests', 'test-operator-hooks.cjs'),
1117
+ // Phase 100-03: per-room JTBD state I/O at .mindrian/jtbd-state.json.
1118
+ // 9 assertion classes covering round-trip identity, atomic tmp+rename
1119
+ // (no orphans across many writes), history bounded at 50 with FIFO
1120
+ // drop-oldest, 24h staleness rule (entered_at + expires_at branches),
1121
+ // manual override expires_at = entered_at + 24h, manual block on auto
1122
+ // write (auto_blocked_by_manual history row, current unchanged), per-
1123
+ // room isolation (two tmpdirs, zero cross-leakage on jtbd + history +
1124
+ // path), graceful errors (missing dir + corrupt JSON + bad opts return
1125
+ // null/no-op without throw), and Canon Part 8 source audit (zero
1126
+ // forbidden tokens in lib/hmi/jtbd-state.cjs). Self-contained: every
1127
+ // test makes a fresh tmp room and tears it down in finally. Zero new
1128
+ // runtime dependencies (Phase 87 invariant).
1129
+ path.join(REPO_ROOT, 'tests', 'test-jtbd-state-io.cjs'),
1130
+ // Phase 100-01: JTBD taxonomy schema validation. 13 canonical entries
1131
+ // (12 first-class + explore fallback), each with detector + verb table
1132
+ // per RESEARCH §2.
1133
+ path.join(REPO_ROOT, 'tests', 'test-jtbd-taxonomy.cjs'),
1134
+ // Phase 100-02: heuristic JTBD classifier (no LLM). Three weighted strata
1135
+ // (token cues 0.5, operator affinity 0.3, recency 0.2). Confidence
1136
+ // threshold 0.6 mirrors Phase 99 classifier. Frame budget < 5ms.
1137
+ path.join(REPO_ROOT, 'tests', 'test-jtbd-classifier.cjs'),
1138
+ // Phase 100-04 (wave 2 stub): /mos:jtbd command. Filled when 100-04 ships.
1139
+ path.join(REPO_ROOT, 'tests', 'test-jtbd-command.cjs'),
1140
+ // Phase 103-04: /mos:memory command (HMI-103-03). 12 assertion classes
1141
+ // covering 6 subcommands (overview / query / cross-room / resume / park /
1142
+ // complete) + opt-out gate + Cowork warning + 95.1 UI compliance + Zone 1
1143
+ // header pattern. Hermetic via MINDRIAN_ROOMS_HOME tmp root + Brain stub
1144
+ // injected via cross-room-memory __setBrainClient seam. Tests Mode A/B
1145
+ // tier-awareness + Phase 101 graceful fallback (Shape G -> Shape E note,
1146
+ // Shape F.6 -> F.1 fallback).
1147
+ path.join(REPO_ROOT, 'tests', 'test-memory-command.cjs'),
1148
+ // Phase 100-04 (wave 2 stub): UI Ruling System self-compliance. Filled when 100-04 ships.
1149
+ path.join(REPO_ROOT, 'tests', 'test-jtbd-ui-self-compliant.cjs'),
1150
+ // Phase 100-05 (wave 2 stub): hook integration. Filled when 100-05 ships.
1151
+ path.join(REPO_ROOT, 'tests', 'test-jtbd-hook-integration.cjs'),
1152
+ // Phase 101-01: Shape F.6 (JTBD-aware Next Move) renderer. JTBD signal
1153
+ // selects which verbs render; F.1's keyboard layer is reused. 7-assertion
1154
+ // IIFE harness covers happy path, fallthrough (jtbd null/unknown/<3 verbs),
1155
+ // taxonomy missing graceful, and 12-glyph audit.
1156
+ path.join(REPO_ROOT, 'tests', 'test-shape-f6.cjs'),
1157
+ // Phase 101-02: Shape G (Comparison Matrix) renderer. Render-only in v1;
1158
+ // interactive table picking deferred to v1.15.x. 7-assertion suite covers
1159
+ // valid_matrix, degenerate_fallthrough, cell_clamping, criterion_clamping,
1160
+ // glyph_audit, zone4_present, zone1_dimensions.
1161
+ path.join(REPO_ROOT, 'tests', 'test-shape-g.cjs'),
1162
+ // Phase 101-03: Shape H (Timeline / Roadmap) renderer. Horizontal time
1163
+ // axis + ■ milestone markers + label rows. ASCII-art only, 12-glyph
1164
+ // compliance, Canon Part 3 Rule 2 error envelope on empty/reversed dates.
1165
+ path.join(REPO_ROOT, 'tests', 'test-shape-h.cjs'),
1166
+ // Phase 101-04: selector-dispatcher single integration point. Discriminates
1167
+ // F.6 returns ({ zones, contract } | { fallthrough } | { error }) and routes
1168
+ // fallthroughs to F.1 fallback. 9 assertions cover happy paths, fallthroughs,
1169
+ // pass-through shapes, malformed payload no-throw, and Free-Text defense.
1170
+ path.join(REPO_ROOT, 'tests', 'test-selector-dispatcher.cjs'),
1171
+ // Phase 101-05: Mode A/B/Tier 0 graceful degradation across F.6 + G + H.
1172
+ // Mode A renders RECOMMENDED markers (Brain reachable, confidence >= 0.7);
1173
+ // Mode B suppresses markers + renders "Brain unreachable" warning; Tier 0
1174
+ // renders hardcoded minimal option set.
1175
+ path.join(REPO_ROOT, 'tests', 'test-shape-f6-mode-b.cjs'),
1176
+ // Phase 88.2 Wave-0: 6 selector-block stubs (5 sub-shapes F.1-F.5 +
1177
+ // telemetry). Filled by 88.2-01..03 plans which replace stubs with real
1178
+ // bodies WITHOUT changing registered paths below.
1179
+ path.join(REPO_ROOT, 'tests', 'test-shape-f1.cjs'),
1180
+ path.join(REPO_ROOT, 'tests', 'test-shape-f2.cjs'),
1181
+ path.join(REPO_ROOT, 'tests', 'test-shape-f3.cjs'),
1182
+ path.join(REPO_ROOT, 'tests', 'test-shape-f4.cjs'),
1183
+ path.join(REPO_ROOT, 'tests', 'test-shape-f5.cjs'),
1184
+ path.join(REPO_ROOT, 'tests', 'test-selector-telemetry.cjs'),
1185
+ // Phase 88.2-04: operator-aware dispatcher integration. F.1..F.5 sub-shape
1186
+ // dispatch + JUST_TALK refuse (render_v2_compaction_violation) + telemetry
1187
+ // emission opt-in (Canon Part 8 fs_scope guard) + AskUserQuestion structural-
1188
+ // marker trailer. 19 assertions; sits beside Phase 101-04's 9-test contract.
1189
+ path.join(REPO_ROOT, 'tests', 'test-selector-dispatcher-88-2-04.cjs'),
1190
+ // Phase 88.2-00 Wave-0: telemetry dual-surface stub. Plan 88.2-03 populates with
1191
+ // real assertions (JSONL primary + memory_event mirror via 4 new EVENT_TYPES).
1192
+ path.join(REPO_ROOT, 'tests', 'test-selector-telemetry-dual-surface.cjs'),
1193
+ // Phase 88.2-05: F.0 Mini Decision Gate renderer + REJECTED_BECAUSE edge contract.
1194
+ // 16 node:test assertions covering 3-verb closed-vocab, persona-AGNOSTIC,
1195
+ // border_style:'single', parent_decision_id pass-through, and graceful-fail
1196
+ // edge helper writing eventType 'selector_rejection_captured' via Phase 109.
1197
+ path.join(REPO_ROOT, 'tests', 'test-shape-f0.cjs'),
1198
+ // Phase 88.2-05: dispatcher F.0 integration. F_SUBSHAPES extended with 'F.0';
1199
+ // dispatch case routes to renderShapeF0; JUST_TALK refuse inheritance verified;
1200
+ // closed-vocab carve-out preserved; AskUserQuestion trailer attached.
1201
+ path.join(REPO_ROOT, 'tests', 'test-selector-dispatcher-88-2-05.cjs'),
1202
+ // Phase 88.2-06: decoy-tier dispatcher (Tier 0/1/2 + 5 perturbation axes
1203
+ // round-robin + topic-coverage backstop + decoy_opt_out preference) plus
1204
+ // F.6 Plan Review Round renderer at the collision-safe path
1205
+ // lib/hmi/shape-f6-plan-review-renderer.cjs (R1 invariant -- Phase 101-01
1206
+ // shape-f6-renderer.cjs sha256 byte-equal pre/post). Dispatcher F_SUBSHAPES
1207
+ // extended with 'F.6'; explicit requestedShape:'F.6' routes to the new
1208
+ // plan-review renderer; umbrella 'F' branch unchanged.
1209
+ path.join(REPO_ROOT, 'tests', 'test-decoy-tier.cjs'),
1210
+ path.join(REPO_ROOT, 'tests', 'test-shape-f6-plan-review.cjs'),
1211
+ path.join(REPO_ROOT, 'tests', 'test-selector-dispatcher-88-2-06.cjs'),
1212
+ // Phase 104 Wave-0: 3 per-command JTBD declaration stubs. Filled by
1213
+ // plans 104-02 (declarations + coverage) + 104-03 (backward-compat fence).
1214
+ path.join(REPO_ROOT, 'tests', 'test-command-jtbd-declarations.cjs'),
1215
+ path.join(REPO_ROOT, 'tests', 'test-command-jtbd-coverage.cjs'),
1216
+ path.join(REPO_ROOT, 'tests', 'test-command-jtbd-backward-compat.cjs'),
1217
+ // Phase 102-00 Wave-0: 5 render-v2 contract stubs. Plan 102-01 swaps in
1218
+ // the assertion bodies WITHOUT changing the registered paths below.
1219
+ // Mapping to RENDER-102-* requirement IDs:
1220
+ // test-render-v2-signature.cjs -> RENDER-102-01 import surface
1221
+ // test-render-v2-compaction.cjs -> RENDER-102-02 operator-aware compaction
1222
+ // test-render-v2-jtbd-zone4.cjs -> RENDER-102-03 JTBD-aware Zone 4
1223
+ // test-render-v2-provenance.cjs -> RENDER-102-04 _provenance envelope
1224
+ // test-render-v2-color-overlay.cjs -> RENDER-102-05 5-color overlay
1225
+ // Phase 99-03 import surface (lib/render/render-v2.test.cjs above) remains
1226
+ // the byte-stability fence per RENDER-102-06.
1227
+ path.join(REPO_ROOT, 'tests', 'test-render-v2-signature.cjs'),
1228
+ path.join(REPO_ROOT, 'tests', 'test-render-v2-compaction.cjs'),
1229
+ path.join(REPO_ROOT, 'tests', 'test-render-v2-jtbd-zone4.cjs'),
1230
+ path.join(REPO_ROOT, 'tests', 'test-render-v2-provenance.cjs'),
1231
+ path.join(REPO_ROOT, 'tests', 'test-render-v2-color-overlay.cjs'),
1232
+ // Phase 121.5-04 Sub-plan E: render-v2 disposition CI gate. Asserts the
1233
+ // audit verdict HOLDS, the allowlist matches the canonical agent-surface
1234
+ // set, ROOM.md uses "current" linguistic discipline, and the Phase 102
1235
+ // VALIDATION/VERIFICATION pair has closed (out of draft + record exists).
1236
+ // Pairs with the operator-facing audit at scripts/disposition-render-v2.cjs.
1237
+ path.join(REPO_ROOT, 'lib', 'memory', 'render-v2-disposition.test.cjs'),
1238
+ // Phase 103 - Memory Continuity Layer (within-session + across-session + cross-room)
1239
+ path.join(REPO_ROOT, 'tests', 'test-across-session-memory.cjs'),
1240
+ path.join(REPO_ROOT, 'tests', 'test-cross-room-memory.cjs'),
1241
+ path.join(REPO_ROOT, 'tests', 'test-cross-room-memory-schema-leak.cjs'),
1242
+ path.join(REPO_ROOT, 'tests', 'test-memory-command.cjs'),
1243
+ path.join(REPO_ROOT, 'tests', 'test-memory-hook-integration.cjs'),
1244
+ // Phase 105 - HMI Compliance Polling
1245
+ path.join(REPO_ROOT, 'tests', 'test-hmi-poll-primitive.cjs'),
1246
+ path.join(REPO_ROOT, 'tests', 'test-hmi-status-command.cjs'),
1247
+ path.join(REPO_ROOT, 'tests', 'test-hmi-poll-hook.cjs'),
1248
+ path.join(REPO_ROOT, 'tests', 'test-hmi-compliance-e2e.cjs'),
1249
+ // Phase 106-00: Wave 0 statusline visibility test stubs (10 stubs).
1250
+ // Each stub exits 0 with the canonical Wave 0 message; downstream plans
1251
+ // (106-01..106-05) replace stubs with real tests as their owning plan
1252
+ // lands. Registry membership ensures the full suite always sees Phase 106
1253
+ // tests from Wave 0 onward.
1254
+ path.join(REPO_ROOT, 'tests', 'test-stale-settings-migration.cjs'),
1255
+ path.join(REPO_ROOT, 'tests', 'test-context-monitor-d02-broadcast.cjs'),
1256
+ path.join(REPO_ROOT, 'tests', 'test-statusline-glyph-isolation.cjs'),
1257
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-g.cjs'),
1258
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-g-fix.cjs'),
1259
+ path.join(REPO_ROOT, 'tests', 'test-statusline-banner-suppression.cjs'),
1260
+ path.join(REPO_ROOT, 'tests', 'test-fallback-echo-compose.cjs'),
1261
+ path.join(REPO_ROOT, 'tests', 'test-fallback-echo-30day.cjs'),
1262
+ path.join(REPO_ROOT, 'tests', 'test-onboarding-gate.cjs'),
1263
+ path.join(REPO_ROOT, 'tests', 'test-surface-detect.cjs'),
1264
+ // Phase 108-00: Wave 0 graph-memory-schema-reconciliation test stubs (7 stubs).
1265
+ // Each stub exits 0 with the canonical Wave 0 message; downstream plans
1266
+ // (108-01..108-06) replace stubs with real tests as their owning plan
1267
+ // lands. test-part-9-invariant.cjs is a CROSS-PHASE dependency - remains
1268
+ // a stub through all of Phase 108; lights up only after Phase 109 ships
1269
+ // the nodes.review_status column. Registry membership ensures the full
1270
+ // suite always sees Phase 108 tests from Wave 0 onward. Mapping:
1271
+ // test-reconciliation-table-completeness.cjs -> 108-01 (D-01 nodes + edges)
1272
+ // test-provenance-contract-schema.cjs -> 108-02 (D-02 contract)
1273
+ // test-truth-state-taxonomy.cjs -> 108-03 (D-03 8 states)
1274
+ // test-aliases-yaml-schema.cjs -> 108-04 (D-04 YAML)
1275
+ // test-precommit-hook-aliases.cjs -> 108-05 (D-05 hook)
1276
+ // test-canon-crossref-completeness.cjs -> 108-06 (D-06 cross-refs)
1277
+ // test-part-9-invariant.cjs -> 108-09 (Phase 109 dep)
1278
+ path.join(REPO_ROOT, 'tests', 'test-reconciliation-table-completeness.cjs'),
1279
+ path.join(REPO_ROOT, 'tests', 'test-provenance-contract-schema.cjs'),
1280
+ path.join(REPO_ROOT, 'tests', 'test-truth-state-taxonomy.cjs'),
1281
+ path.join(REPO_ROOT, 'tests', 'test-aliases-yaml-schema.cjs'),
1282
+ path.join(REPO_ROOT, 'tests', 'test-precommit-hook-aliases.cjs'),
1283
+ path.join(REPO_ROOT, 'tests', 'test-canon-crossref-completeness.cjs'),
1284
+ path.join(REPO_ROOT, 'tests', 'test-part-9-invariant.cjs'),
1285
+ // Phase 109-01 regression: the nodes-provenance migration drops + recreates
1286
+ // every view/trigger that references `nodes` around the table rebuild. Seeds
1287
+ // a room.db with an rs_discoveries-style view (+ a second view + a trigger),
1288
+ // runs the migration, asserts no throw + views/trigger still work + idempotent
1289
+ // re-run. Guards against the phase-109-migration-view-drop-collision bug
1290
+ // (migration used to crash openRoomDb for any room.db carrying the Phase-89
1291
+ // rs_discoveries view: "error in view rs_discoveries: no such table: main.nodes").
1292
+ path.join(REPO_ROOT, 'tests', 'test-navigation-migration-views.cjs'),
1293
+ // Phase 109 SQL Context-Memory Navigation Spine: the 15 test suites that the
1294
+ // Plan 109-00 Task 4 registration originally specified but that a later refactor
1295
+ // dropped from this array before main HEAD (the originals ran via direct
1296
+ // `node tests/test-*.cjs` and `bash tests/run-all.sh` throughout the phase).
1297
+ // Re-registered by Plan 109-12 (bookkeeping reconciliation). Mapping:
1298
+ // test-navigation-acceptance.cjs -> 109-10 (NAV-109-09 load-bearing acceptance gate; zero non-SQLite reads)
1299
+ // test-navigation-focus.cjs -> 109-02 (NAV-109-01 session_focus + auto-focus cascade)
1300
+ // test-navigation-neighborhood.cjs -> 109-04 (NAV-109-02 recursive-CTE ranking correctness)
1301
+ // test-navigation-perf-10k.cjs -> 109-04 (NAV-109-02 perf: cold p95 <200ms / warm <50ms)
1302
+ // test-navigation-memory-events.cjs -> 109-03 (NAV-109-03 closed-15 event enum + findRecentChanges)
1303
+ // test-navigation-insights.cjs -> 109-05 (NAV-109-04 7 insight primitives + templated explanations)
1304
+ // test-navigation-chokepoint-hook.cjs -> 109-06 (NAV-109-05 no direct room-db.cjs imports outside allow-list)
1305
+ // test-navigation-packet-builder.cjs -> 109-07 (NAV-109-06 buildBrainPacket shape per D-06)
1306
+ // test-navigation-packet-part8-leak.cjs -> 109-07 (NAV-109-06 Part 8 JSON.stringify leak tripwires)
1307
+ // test-brain-ingestion-part-9-invariant.cjs -> 109-08 (NAV-109-07 storeBrainSuggestions proposed-only + invariant SQL = 0)
1308
+ // test-room-home-vs-brain-derivation-regression.cjs -> 109-09 (NAV-109-08 getRoomHomeView + Phase 90 deriveSection regression fence)
1309
+ // test-canon-part-9-ratification.cjs -> 109-11 (NAV-109-09 Canon Part 9 structural assertions)
1310
+ // test-navigation-migration-idempotent.cjs -> 109-01 (migration twice = no-op; 12-column nodes schema)
1311
+ // test-navigation-migration-backfill.cjs -> 109-01 (properties JSON backfill + status_aliases mapping)
1312
+ // test-navigation-migration-coexistence.cjs -> 109-01 (navigation API + assumptions.validity coexist mid-migration)
1313
+ path.join(REPO_ROOT, 'tests', 'test-navigation-acceptance.cjs'),
1314
+ path.join(REPO_ROOT, 'tests', 'test-navigation-focus.cjs'),
1315
+ path.join(REPO_ROOT, 'tests', 'test-navigation-neighborhood.cjs'),
1316
+ path.join(REPO_ROOT, 'tests', 'test-navigation-perf-10k.cjs'),
1317
+ path.join(REPO_ROOT, 'tests', 'test-navigation-memory-events.cjs'),
1318
+ path.join(REPO_ROOT, 'tests', 'test-navigation-insights.cjs'),
1319
+ path.join(REPO_ROOT, 'tests', 'test-navigation-chokepoint-hook.cjs'),
1320
+ path.join(REPO_ROOT, 'tests', 'test-navigation-packet-builder.cjs'),
1321
+ path.join(REPO_ROOT, 'tests', 'test-navigation-packet-part8-leak.cjs'),
1322
+ path.join(REPO_ROOT, 'tests', 'test-brain-ingestion-part-9-invariant.cjs'),
1323
+ path.join(REPO_ROOT, 'tests', 'test-room-home-vs-brain-derivation-regression.cjs'),
1324
+ path.join(REPO_ROOT, 'tests', 'test-canon-part-9-ratification.cjs'),
1325
+ path.join(REPO_ROOT, 'tests', 'test-navigation-migration-idempotent.cjs'),
1326
+ path.join(REPO_ROOT, 'tests', 'test-navigation-migration-backfill.cjs'),
1327
+ path.join(REPO_ROOT, 'tests', 'test-navigation-migration-coexistence.cjs'),
1328
+ // Phase 89-07 Wave 0 (graph-native HARD RULE; ReverseSalientAgent dual-surface).
1329
+ path.join(REPO_ROOT, 'tests', 'test-reverse-salient-agent.cjs'),
1330
+ path.join(REPO_ROOT, 'tests', 'test-reverse-salient-cascade-emit.cjs'),
1331
+ path.join(REPO_ROOT, 'tests', 'test-reverse-salient-f0-integration.cjs'),
1332
+ path.join(REPO_ROOT, 'tests', 'test-reverse-salient-persona.cjs'),
1333
+ path.join(REPO_ROOT, 'tests', 'test-reverse-salient-telemetry.cjs'),
1334
+ // Phase 116-00 Wave 0 (graph-native HARD RULE; unresolved-tension-hook dual-surface
1335
+ // telemetry mirror per memory feedback_reverse_salient_agent_graph_native.md rule 3).
1336
+ // 5 stubs RED in Wave 0; flip GREEN as 116-01 (detection), 116-02 (F.1 surface),
1337
+ // 116-03 (decay state machine), 116-04 (telemetry + release) modules land.
1338
+ path.join(REPO_ROOT, 'tests', 'test-tension-hook-detection.cjs'),
1339
+ path.join(REPO_ROOT, 'tests', 'test-tension-hook-f1-integration.cjs'),
1340
+ path.join(REPO_ROOT, 'tests', 'test-tension-hook-decay.cjs'),
1341
+ path.join(REPO_ROOT, 'tests', 'test-tension-hook-telemetry.cjs'),
1342
+ path.join(REPO_ROOT, 'tests', 'test-tension-hook-rendering.cjs'),
1343
+ // Phase 117-00 Wave 0 (graph-native HARD RULE; auto-explore-domains dual-surface
1344
+ // telemetry mirror per memory feedback_reverse_salient_agent_graph_native.md rule 3).
1345
+ // 12 stubs RED in Wave 0; flip GREEN as 117-01 (detection), 117-02 (compose),
1346
+ // 117-03 (F.1 surface + HSI schema + BQ template), 117-04 (sanitizer + LOCAL-only routing),
1347
+ // 117-05 (telemetry + brain-canon-drift + release) modules land.
1348
+ // Section 5 Validation Architecture (6 stubs):
1349
+ path.join(REPO_ROOT, 'tests', 'test-auto-explore-event-types.cjs'),
1350
+ path.join(REPO_ROOT, 'tests', 'test-auto-explore-fingerprint.cjs'),
1351
+ path.join(REPO_ROOT, 'tests', 'test-explored-materials-store.cjs'),
1352
+ path.join(REPO_ROOT, 'tests', 'test-auto-explore-fire.cjs'),
1353
+ path.join(REPO_ROOT, 'tests', 'test-auto-explore-compose.cjs'),
1354
+ path.join(REPO_ROOT, 'tests', 'test-auto-explore-f1-integration.cjs'),
1355
+ // Section 8 Brain Substrate enrichment (6 net-new stubs from Brain Cypher 2026-05-06):
1356
+ path.join(REPO_ROOT, 'tests', 'test-auto-explore-canonical-order.cjs'),
1357
+ path.join(REPO_ROOT, 'tests', 'test-cross-domain-formula.cjs'),
1358
+ path.join(REPO_ROOT, 'tests', 'test-finding-hsi-schema.cjs'),
1359
+ path.join(REPO_ROOT, 'tests', 'test-f1-bq-template.cjs'),
1360
+ path.join(REPO_ROOT, 'tests', 'test-detection-routing-local-only.cjs'),
1361
+ path.join(REPO_ROOT, 'tests', 'test-brain-canon-drift-event.cjs'),
1362
+ // Phase 122-01 Wave 0 (workflow layer -- framework <-> command registry).
1363
+ // Stubs RED-of-design until their owning plan lands: command-resolver fills
1364
+ // in 122-03; command-registry fills in 122-02. Both stay at this registered
1365
+ // path; the downstream plan swaps the implementation in without moving it.
1366
+ path.join(REPO_ROOT, 'lib', 'workflow', 'command-resolver.test.cjs'),
1367
+ path.join(REPO_ROOT, 'lib', 'memory', 'command-registry.test.cjs'),
1368
+ // Phase 157-04: the orchestration-projection generator + --check 3-mode
1369
+ // taxonomy (STALE / UN-WIRED / UN-RANKED). Mirrors the connector/command
1370
+ // -registry test registration so the Feynman runner exercises the projection
1371
+ // --check (BOG-11) on every run.
1372
+ path.join(REPO_ROOT, 'lib', 'memory', 'orchestration-projection.test.cjs'),
1373
+ // Phase 157-05: the adversarial Part 8 boundary scan over the projection +
1374
+ // generator + analogue seed + unwired-allowlist (BOG-09 / BOG-10). Proves
1375
+ // zero user-content fields by construction (field allowlist + tier sweep +
1376
+ // planted-secret forbidden-value tripwire + zero-live-Brain grep gate).
1377
+ path.join(REPO_ROOT, 'tests', 'test-orchestration-projection-part8-boundary.cjs'),
1378
+ // Phase 122-03: the chain recommender (recommendFrameworkChain via FEEDS_INTO).
1379
+ path.join(REPO_ROOT, 'lib', 'memory', 'chain-recommender.test.cjs'),
1380
+ // Phase 122-04: the navigation-hook surgical edit (framework-chain-composer
1381
+ // routed through the resolver) + the suggest-next integration test.
1382
+ path.join(REPO_ROOT, 'lib', 'memory', 'navigation-hook-resolver.test.cjs'),
1383
+ path.join(REPO_ROOT, 'lib', 'memory', 'suggest-next-workflow.test.cjs'),
1384
+ // Phase 122-05: the workflow-layer end-to-end test (frontmatter -> registry
1385
+ // --check -> resolver.composeWorkflow(acceptance example) -> the degrade case
1386
+ // -> validateChainAutonomy stop-point) + the Canon Part 8 zero-Brain-mutation
1387
+ // grep sweep.
1388
+ path.join(REPO_ROOT, 'lib', 'memory', 'workflow-layer-e2e.test.cjs'),
1389
+ // Phase 110-00: Brain Context Packet Contract Wave 0 substrate (4 stubs filled by Plans 110-01 / 110-04 / 110-05).
1390
+ // test-brain-packet-schema-check.cjs -> 110-01 (PACKET-110-01 + -02: the --check schema tripwire)
1391
+ // test-brain-packet-validation-per-job.cjs -> 110-05 (PACKET-110-03 + -04 + -07 + -08: 12-job in/out + privacy + dual-path)
1392
+ // test-brain-packet-part8-invariant-per-job.cjs -> 110-05 (PACKET-110-06 round-trip + D-11(d) adversarial sweep)
1393
+ // test-brain-packet-precommit-hook.cjs -> 110-04 (PACKET-110-05 D-08 layer-2 hook)
1394
+ path.join(REPO_ROOT, 'tests', 'test-brain-packet-schema-check.cjs'),
1395
+ path.join(REPO_ROOT, 'tests', 'test-brain-packet-validation-per-job.cjs'),
1396
+ path.join(REPO_ROOT, 'tests', 'test-brain-packet-part8-invariant-per-job.cjs'),
1397
+ path.join(REPO_ROOT, 'tests', 'test-brain-packet-precommit-hook.cjs'),
1398
+ // Phase 123 (install-lifecycle-harness) block.
1399
+ // Plan 123-01: release.sh semver bump algebra + two-commit form + dirty-repo guard + Step 9.5 rename.
1400
+ // Tests A-E (semver assertions) GREEN immediately; Tests F/G (release.sh
1401
+ // structural) RED until Plan 123-01 Task 2 rewrites release.sh -- intended RED->GREEN.
1402
+ // Plan 123-02: install-state record + data/deployment-surfaces.json manifest +
1403
+ // active-plugin-root.cjs topology classification. Tests 1+4+6 (topology /
1404
+ // Canon Part 8 / early-write ordering) GREEN after Task 1; Tests 2+3
1405
+ // (record write hermetic / idempotent re-run) GREEN after Task 2;
1406
+ // Test 5 (manifest schema) GREEN after Task 3.
1407
+ // Plan 123-03: doctor classes I (install-state + topology + 6-way version-
1408
+ // of-record consistency) + J (deployment-surface manifest reconciliation)
1409
+ // + aggressive --fix (legacy migration backup-verify-remove; never
1410
+ // touches a dev-clone) + Bug-7 fix (marketplace-cache topology is
1411
+ // HEALTHY, not drift). Tests RED until Task 2 lands class I + class J
1412
+ // in scripts/doctor.cjs -- intended RED->GREEN.
1413
+ // Plan 123-04: doctor --acceptance (release-gate-as-a-command) -- 5-point
1414
+ // pre-tag checklist + 7-point full checklist + --light-npx opt-in; wired
1415
+ // into release.sh as hard aborts (Step 6.6 pre-tag, Step 9.6 post-publish);
1416
+ // scripts/release-beta-smoke.sh retired. Tests RED until Task 2 lands
1417
+ // --acceptance in scripts/doctor.cjs AND Task 3 wires release.sh + deletes
1418
+ // release-beta-smoke.sh -- intended RED->GREEN.
1419
+ // Plan 123-05: cache-prune helper (HARNESS-123-13) + doc/test sweep
1420
+ // (HARNESS-123-14). 6 hermetic scenarios for pruneMarketplaceCache
1421
+ // (active + N most-recent kept; corrupt installed_plugins.json -> skip;
1422
+ // dryRun -> no mutation; belt+suspenders active-dir protection; Canon
1423
+ // Part 8 grep clean). Tests GREEN after Task 1 lands
1424
+ // lib/core/cache-prune.cjs.
1425
+ // Plan 123-07: resolve-brain-key.cjs (HARNESS-123-15) + brain-client.cjs
1426
+ // getApiKey() delegation (HARNESS-123-16). 9 hermetic scenarios cover
1427
+ // order (env -> ~/.mindrian.env -> CWD .env -> not-found), SEC-02
1428
+ // POSIX 0o077 reject, Canon Part 8 zero-network grep, the brain-client
1429
+ // delegation spy, brain-client preconditions, and the FLAG-3
1430
+ // env-aware-home structural assertion. rbk.1-6 + rbk.9 GREEN after
1431
+ // Task 1; rbk.7 + rbk.8 GREEN after Task 2 (brain-client rewire).
1432
+ path.join(REPO_ROOT, 'tests', 'test-release-bump-algebra.cjs'),
1433
+ path.join(REPO_ROOT, 'tests', 'test-install-state-record.cjs'),
1434
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-i.cjs'),
1435
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-j.cjs'),
1436
+ path.join(REPO_ROOT, 'tests', 'test-doctor-acceptance.cjs'),
1437
+ // Debug session doctor-class-a-drift-topology-blind-false-positive (2026-05-31):
1438
+ // class A install-missing drift branch made topology-aware so the SessionStart
1439
+ // preflight banner no longer false-fires on marketplace-cache installs; the
1440
+ // legacy/dev recovery path is preserved + cross-gate (--json vs --install-state)
1441
+ // consistency is asserted. 3 hermetic scenarios.
1442
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-a-topology-drift.cjs'),
1443
+ // Debug session intern-w1-statusline-room-mismatch (2026-07-11): class H
1444
+ // (install-incomplete-module.cjs check()/fix()) never received the same
1445
+ // topology-awareness fix class A/I got above -- it false-positived
1446
+ // 'install incomplete' on every healthy marketplace-cache-only install
1447
+ // and its --fix wrote a broken user-level statusLine override at the
1448
+ // hardcoded legacy INSTALL_DIR. Also covers the Class G Step 3 widening
1449
+ // (tests the EFFECTIVE resolved statusline command, not always the
1450
+ // plugin's own file) needed so the self-heal's re-check can catch its
1451
+ // own self-inflicted breakage. 4 hermetic scenarios, exercised via the
1452
+ // real CLI end-to-end (post-Phase-217 registry dispatch).
1453
+ path.join(REPO_ROOT, 'tests', 'test-doctor-class-h-topology-blind.cjs'),
1454
+ path.join(REPO_ROOT, 'tests', 'test-cache-prune.cjs'),
1455
+ path.join(REPO_ROOT, 'tests', 'test-resolve-brain-key.cjs'),
1456
+ // Phase 124-00: FEYNMAN.md Temporal Awareness Wave 0 substrate (4 stubs filled by Plans 124-01 / 124-02 / 124-04).
1457
+ // test-feynman-timeline-renderer.cjs -> 124-01 (TEMPORAL-124-02 + -04 + -05 + -07: renderer unit + D-05 template + thresholds + section scoping)
1458
+ // test-feynman-timeline-empty-state.cjs -> 124-01 (TEMPORAL-124-04: empty-state placeholder)
1459
+ // test-feynman-timeline-runner.cjs -> 124-02 (TEMPORAL-124-01 + -03 + -08 + -09: sentinel-bounded merge + body byte-identical + watermark + idempotent + memory_event + EVENT_TYPES +2)
1460
+ // test-feynman-timeline-canon-part-9-invariant.cjs -> 124-04 (TEMPORAL-124-10: forbidden-substring sweep + fs-instrument allow-list)
1461
+ path.join(REPO_ROOT, 'tests', 'test-feynman-timeline-renderer.cjs'),
1462
+ path.join(REPO_ROOT, 'tests', 'test-feynman-timeline-empty-state.cjs'),
1463
+ path.join(REPO_ROOT, 'tests', 'test-feynman-timeline-runner.cjs'),
1464
+ path.join(REPO_ROOT, 'tests', 'test-feynman-timeline-canon-part-9-invariant.cjs'),
1465
+ // Phase 121.5 terminal-coherence-capstone (multi-plan; SessionStart Coordinator is Plan 00).
1466
+ // sessionstart-coordinator.test.cjs -> Plan 121.5-00 (D-13..D-16 coordinator + 9 injector refactor)
1467
+ // Aggregator: tests/run-all-121.5.sh. Additional 121.5-* test suites are
1468
+ // already registered above this block (palette-consistency / statusline-two-row /
1469
+ // terminal-capability / help-renderer / help-coverage); the SessionStart
1470
+ // Coordinator suite lands here per the Plan 121.5-00 Task 3 contract.
1471
+ path.join(REPO_ROOT, 'lib', 'memory', 'sessionstart-coordinator.test.cjs'),
1472
+ // Phase 125 F-Selector Ranker (8 plans: Plan 00 writeEdge through Plan 07 miss).
1473
+ // navigation-write-edge.test.cjs -> Plan 125-00 (writeEdge primitive)
1474
+ // navigation-projections.test.cjs -> Plan 125-01 (projection helpers)
1475
+ // brain-cypher-chain-slice.test.cjs -> Plan 125-02 (Brain Cypher slice)
1476
+ // packet-chain-hint.test.cjs -> Plan 125-03 (packet builder ext)
1477
+ // packet-schema-validation.test.cjs -> Plan 125-04 (schema superset)
1478
+ // f-selector-ranker.test.cjs -> Plan 125-05 + 125-07 D8 label tests (34 tests)
1479
+ // selector-decisions.test.cjs -> Plan 125-06 (D7 decisions + decay; 17 tests)
1480
+ // selector-miss.test.cjs -> Plan 125-07 (D8 miss capture; 10 tests)
1481
+ // Aggregator: tests/run-all-125.sh.
1482
+ path.join(REPO_ROOT, 'lib', 'memory', 'navigation-write-edge.test.cjs'),
1483
+ path.join(REPO_ROOT, 'lib', 'memory', 'navigation-projections.test.cjs'),
1484
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-cypher-chain-slice.test.cjs'),
1485
+ path.join(REPO_ROOT, 'lib', 'memory', 'packet-chain-hint.test.cjs'),
1486
+ path.join(REPO_ROOT, 'lib', 'memory', 'packet-schema-validation.test.cjs'),
1487
+ path.join(REPO_ROOT, 'lib', 'memory', 'f-selector-ranker.test.cjs'),
1488
+ path.join(REPO_ROOT, 'lib', 'memory', 'selector-decisions.test.cjs'),
1489
+ path.join(REPO_ROOT, 'lib', 'memory', 'selector-miss.test.cjs'),
1490
+ // Phase 104.1 (per-command-teaching-content) block. RED-by-design until
1491
+ // Plan 02 lands the 86 teaching strings; the jtbd-derivation suite is
1492
+ // GREEN immediately after Plan 01 Task 1.
1493
+ // per-command-teaching.test.cjs -> 104.1-01 Task 2 (RED today; GREEN after Plan 02)
1494
+ // per-command-jtbd-derivation.test.cjs -> 104.1-01 Task 3 (GREEN immediately)
1495
+ // Aggregator: tests/run-all-104.1.sh. Documented at
1496
+ // .planning/phases/104.1-per-command-teaching-content/104.1-01-PLAN.md.
1497
+ path.join(REPO_ROOT, 'lib', 'memory', 'per-command-teaching.test.cjs'),
1498
+ path.join(REPO_ROOT, 'lib', 'memory', 'per-command-jtbd-derivation.test.cjs'),
1499
+ // ---------- Phase 118 ----------
1500
+ // 30-Second MVA + Reward-Before-Investment Rule. Plans 00-06 ship the
1501
+ // pipeline; Plan 06 ships the rule + linter + Dror 2.0 harness.
1502
+ // Aggregator: tests/run-all-118.sh.
1503
+ // Plan 118-00 (UserPromptSubmit detection):
1504
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-classifier.test.cjs'),
1505
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-detect.smoke.test.cjs'),
1506
+ // Plan 118-01 (dispatch architecture):
1507
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-agent-contract.test.cjs'),
1508
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-budget.test.cjs'),
1509
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-dispatcher.test.cjs'),
1510
+ // Plan 118-02 (six MVA agents -- aggregate runner for all 6):
1511
+ path.join(REPO_ROOT, 'lib', 'agents', 'mva', 'test-all-six-agents.cjs'),
1512
+ // Plan 118-03 (progressive streaming + orchestrator + telemetry):
1513
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-progressive-renderer.test.cjs'),
1514
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-telemetry.test.cjs'),
1515
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-orchestrator.test.cjs'),
1516
+ // Plan 118-04 (Feynman deck + Vercel deploy):
1517
+ path.join(REPO_ROOT, 'lib', 'core', 'resolve-vercel-key.test.cjs'),
1518
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-vercel-deploy.test.cjs'),
1519
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-deck-builder.test.cjs'),
1520
+ // Plan 118-05 (footer routing + operator helper):
1521
+ path.join(REPO_ROOT, 'lib', 'conversation', 'operator.test.cjs'),
1522
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-option-router.test.cjs'),
1523
+ // Plan 118-06 (rule-linter + Dror 2.0 acceptance harness):
1524
+ path.join(REPO_ROOT, 'lib', 'core', 'mva-rule-linter.test.cjs'),
1525
+ path.join(REPO_ROOT, 'tests', 'test-mva-dror-harness.cjs'),
1526
+ // Phase 119-00 Wave 1 (Room-as-Receipt Invariant; D-01 + D-04 + D-06 telemetry mirror).
1527
+ // test-room-auto-create-event-types.cjs -> 119-00 Task 1 (EVENT_TYPES floor + 3 new strings)
1528
+ // venture-shape-nudge.test.cjs -> 119-00 Task 1 (D-02 nudge detector + D-01 invariant)
1529
+ // room-auto-create.test.cjs -> 119-00 Task 2 (slug + scaffold + registry + memory_event)
1530
+ // test-room-auto-create-fingerprint-integration.cjs -> 119-00 Task 3 (sibling hook + nudge shim)
1531
+ // Mirrors the Phase 117-00 + Phase 124-02 additive-tail-append registration precedent.
1532
+ path.join(REPO_ROOT, 'tests', 'test-room-auto-create-event-types.cjs'),
1533
+ path.join(REPO_ROOT, 'lib', 'core', 'venture-shape-nudge.test.cjs'),
1534
+ path.join(REPO_ROOT, 'lib', 'core', 'room-auto-create.test.cjs'),
1535
+ path.join(REPO_ROOT, 'tests', 'test-room-auto-create-fingerprint-integration.cjs'),
1536
+ // Phase 119-02 Wave 1 extension (Room-as-Receipt Invariant; D-05 skeleton scaffold +
1537
+ // Larry thinness-acknowledgment voice line + Canon decision 15 ICM Layer 0 everywhere).
1538
+ // larry-thinness-acknowledgment.test.cjs -> 119-02 Task 1 (THINNESS_VOICE_LINE verbatim + detector)
1539
+ // room-skeleton-scaffold.test.cjs -> 119-02 Task 2 (scaffold unit tests; reentrancy + Part 8/9 invariants)
1540
+ // test-room-skeleton-scaffold-integration.cjs -> 119-02 Task 2 (end-to-end placeholder-room scaffold scenarios)
1541
+ // test-119-02-auto-explore-fire-wiring.cjs -> 119-02 Task 3 (REVISION 2026-05-16: scaffoldRoomSkeleton call
1542
+ // site wired into scripts/auto-explore-fire.cjs;
1543
+ // closes Blocker 1+4 phantom wiring)
1544
+ // Aggregator: tests/test-119-02-scaffold.sh (the 6-gate shell harness).
1545
+ path.join(REPO_ROOT, 'lib', 'core', 'larry-thinness-acknowledgment.test.cjs'),
1546
+ path.join(REPO_ROOT, 'lib', 'core', 'room-skeleton-scaffold.test.cjs'),
1547
+ path.join(REPO_ROOT, 'tests', 'test-room-skeleton-scaffold-integration.cjs'),
1548
+ path.join(REPO_ROOT, 'tests', 'test-119-02-auto-explore-fire-wiring.cjs'),
1549
+ // Phase 119-01 Wave 2 extension (Room-as-Receipt Invariant; D-03 + D-06 retroactive-naming
1550
+ // F.1 selector + discard cascade + LLM-name-suggester + tri-surface adaptation):
1551
+ // llm-name-suggester.test.cjs -> 119-01 Task 1 (HAIKU_MODEL_ID + FALLBACK +
1552
+ // suggest happy/sad + Canon Part 8 grep tripwire +
1553
+ // EVENT_TYPES floor with +1 room_discard_partial_failure)
1554
+ // room-name-validator.test.cjs -> 119-01 Task 2 (four rejection classes +
1555
+ // Windows-reserved defense-in-depth)
1556
+ // room-discard-cascade.test.cjs -> 119-01 Task 2 (transactional discard +
1557
+ // partial-failure recovery via rooms-meta.db)
1558
+ // room-naming-selector.test.cjs -> 119-01 Task 3 (orchestrator + F1_OPTION_LABELS
1559
+ // + DECISION_PATHS + tri-surface envelope)
1560
+ // test-room-naming-selector-integration.cjs -> 119-01 Task 4 (mva-orchestrator hook + e2e shim spawn)
1561
+ // Aggregator: tests/test-119-01-scaffold.sh (the 7-gate shell harness).
1562
+ path.join(REPO_ROOT, 'lib', 'core', 'llm-name-suggester.test.cjs'),
1563
+ path.join(REPO_ROOT, 'lib', 'core', 'room-name-validator.test.cjs'),
1564
+ path.join(REPO_ROOT, 'lib', 'core', 'room-discard-cascade.test.cjs'),
1565
+ path.join(REPO_ROOT, 'lib', 'core', 'room-naming-selector.test.cjs'),
1566
+ path.join(REPO_ROOT, 'tests', 'test-room-naming-selector-integration.cjs'),
1567
+ // Phase 120-00 Wave 1: 4 breakthrough pattern detectors + Breakthrough graph schema.
1568
+ // test-breakthrough-event-types.cjs -> 120-00 Task 1 (EVENT_TYPES floor + 6 new strings;
1569
+ // round-trip via navigation.logMemoryEvent)
1570
+ // test-breakthrough-edge-types.cjs -> 120-00 Task 1 (ALLOWED_EDGE_TYPES floor + DERIVED_FROM;
1571
+ // round-trip via navigation.writeEdge)
1572
+ // lib/core/breakthrough/detectors.test.cjs -> 120-00 Task 2 (DETECTOR_THRESHOLDS verbatim + 4
1573
+ // detectors + classifyFireTier + Canon Part 8 invariant)
1574
+ // lib/core/breakthrough/schema.test.cjs -> 120-00 Task 3 (writeBreakthrough + validateProvenance;
1575
+ // D-20 HARD FLOOR atomic-transaction invariant)
1576
+ // Aggregator: tests/test-120-00-scaffold.sh (the 9-gate shell harness).
1577
+ path.join(REPO_ROOT, 'tests', 'test-breakthrough-event-types.cjs'),
1578
+ path.join(REPO_ROOT, 'tests', 'test-breakthrough-edge-types.cjs'),
1579
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'detectors.test.cjs'),
1580
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'schema.test.cjs'),
1581
+ // Phase 120-01 Wave 2: F.7 Breakthrough Surface selector + 5-component scoring formula.
1582
+ // shape-f7-breakthrough-renderer.test.cjs -> 120-01 Task 1 (closed-vocab 5 verbs verbatim
1583
+ // + D-10 mandatory-dismiss invariant +
1584
+ // D-20 HARD FLOOR provenance refusal)
1585
+ // scoring.test.cjs -> 120-01 Task 3 (SCORING_WEIGHTS verbatim
1586
+ // + RECENCY_HALF_LIFE_DAYS verbatim + the
1587
+ // 5-component formula + Laplace prior +
1588
+ // D-19 dismissal-rate canary + Canon Part 8
1589
+ // source-grep + em-dash HARD RULE)
1590
+ // selector-dispatcher additive F.7 branch is verified by tests/test-120-01-scaffold.sh
1591
+ // Gates 1 + 2 (already on disk; no separate
1592
+ // dispatcher unit-test file landed in Plan 120-01).
1593
+ // Aggregator: tests/test-120-01-scaffold.sh (the 8-gate shell harness).
1594
+ path.join(REPO_ROOT, 'lib', 'hmi', 'shape-f7-breakthrough-renderer.test.cjs'),
1595
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'scoring.test.cjs'),
1596
+ // Phase 120-02 Wave 2: session-start scanner + resurfacing + canary +
1597
+ // verb-dispatch consumer. Wires Plan 120-00 detectors + Plan 120-01 F.7 +
1598
+ // D-13..D-15 resurfacing rules + D-19 canary + 5-verb dispatch.
1599
+ // resurfacing.test.cjs -> 120-02 Task 1 (D-13..D-15 predicates;
1600
+ // SEVEN_DAY_COOLDOWN_MS verbatim; D-13 BOTH-
1601
+ // condition lock; Canon Part 8 source-grep)
1602
+ // canary.test.cjs -> 120-02 Task 1 (D-19 constants verbatim;
1603
+ // computeDismissalRate + isThrottled +
1604
+ // emitThrottleEvent; D19_MIN_SAMPLE floor;
1605
+ // per-kind isolation)
1606
+ // verb-dispatch.test.cjs -> 120-02 Task 2 (5-verb to 3-event lock;
1607
+ // Confirm/Dismiss/File-as-decision emitters;
1608
+ // D-09 FILED_AS_DECISION edge bridge;
1609
+ // D-13 artifact_ids_at_dismiss baseline)
1610
+ // scanner.test.cjs -> 120-02 Task 3 (scanForBreakthroughs +
1611
+ // surfaceBreakthrough; D-16 silence; D-13..
1612
+ // D-15 resurfacing filter; D-19 throttle
1613
+ // filter; D-20 writeBreakthrough contract;
1614
+ // D-20 third structural enforcement point)
1615
+ // check-pending-breakthrough.test.cjs -> 120-02 Task 3 session-start hook
1616
+ // (no-active-room / D-16 silence / happy-path
1617
+ // F.7 surfaced / corrupt-room degrade / hooks
1618
+ // .json wiring)
1619
+ // tests/test-breakthrough-d20-end-to-end.cjs -> 120-02 Task 3 LOAD-BEARING
1620
+ // D-20 invariant: every breakthrough_surfaced
1621
+ // pairs with >= 1 DERIVED_FROM edge; batch
1622
+ // invariant returns zero orphan-provenance
1623
+ // Breakthroughs; surface refusal emits
1624
+ // breakthrough_surface_blocked telemetry.
1625
+ // Aggregator: tests/test-120-02-scaffold.sh (the 8-gate shell harness).
1626
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'resurfacing.test.cjs'),
1627
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'canary.test.cjs'),
1628
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'verb-dispatch.test.cjs'),
1629
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'scanner.test.cjs'),
1630
+ path.join(REPO_ROOT, 'scripts', 'check-pending-breakthrough.test.cjs'),
1631
+ path.join(REPO_ROOT, 'tests', 'test-breakthrough-d20-end-to-end.cjs'),
1632
+ // Phase 120-03 Wave 2: D-17 voice scaffold + D-18 4-tier ethics fence + SOFT_BAND
1633
+ // review queue + Larry skill update. The conversational + ethical-enforcement
1634
+ // layer that converts the math-detected breakthrough into honest, evidence-backed
1635
+ // Larry voice. Aggregator: tests/test-120-03-scaffold.sh (the 9-gate harness).
1636
+ // voice-scaffold.test.cjs -> 120-03 Task 1 (composeBreakthrough
1637
+ // VoiceLine + auditVoiceLine + the
1638
+ // 4 D-17 rule predicates + frozen
1639
+ // constants verbatim)
1640
+ // ethics-fence.test.cjs -> 120-03 Task 2 (classifyEthicsBand
1641
+ // + 4 frozen threshold constants +
1642
+ // queueForReview happy path +
1643
+ // memory_event mirror)
1644
+ // review-queue.test.cjs -> 120-03 Task 2 (openReviewQueue +
1645
+ // .rooms/breakthrough-review-queue.db
1646
+ // schema + insertReviewCandidate +
1647
+ // listPendingReviews + graceful EACCES
1648
+ // fallback)
1649
+ // scanner-d17-d18.test.cjs -> 120-03 Task 3 (scanner integration
1650
+ // of voice-scaffold + ethics-fence;
1651
+ // F.7 renderer voice_line slot; D-17
1652
+ // violator -> structural default)
1653
+ // tests/test-breakthrough-d17-voice-audit.cjs -> 120-03 Task 1 (D-17 audit catalog
1654
+ // end-to-end: 8-candidate matrix +
1655
+ // per-rule violator/valid pairs)
1656
+ // tests/test-breakthrough-d18-ethics-fence.cjs -> 120-03 Task 2 (D-18 4-band end-to-end:
1657
+ // SOFT_BAND queue + memory_event; no
1658
+ // breakthrough_surfaced from SOFT_BAND)
1659
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'voice-scaffold.test.cjs'),
1660
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'ethics-fence.test.cjs'),
1661
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'review-queue.test.cjs'),
1662
+ path.join(REPO_ROOT, 'lib', 'core', 'breakthrough', 'scanner-d17-d18.test.cjs'),
1663
+ path.join(REPO_ROOT, 'tests', 'test-breakthrough-d17-voice-audit.cjs'),
1664
+ path.join(REPO_ROOT, 'tests', 'test-breakthrough-d18-ethics-fence.cjs'),
1665
+ // Phase 121-00 (Wave 1, Foundation): unified trajectory-telemetry writer
1666
+ // chokepoint + frozen v1 schema + Canon Part 8 emit-time validator. The
1667
+ // architectural ancestor is lib/core/mva-telemetry.cjs (Phase 118); this
1668
+ // module consolidates the 4 piecemeal writers (mva, query-efficiency,
1669
+ // selector, navigation-bypass) into ONE emit() entry point with
1670
+ // ISO-week rotation (events-YYYY-WNN.jsonl) and a per-row schema_version
1671
+ // (Number 1). schema.test.cjs (2 cases) asserts EVENT_TYPES frozen at 15
1672
+ // + ALLOWED_FIELDS shape. validator.test.cjs (7 cases) asserts the
1673
+ // Canon Part 8 constitutional gate: unknown_event + unknown_field + 7
1674
+ // adversarial forbidden-pattern rejections (Cypher / email / phone /
1675
+ // brain host URL / absolute path / raw hex / free-text prose). The
1676
+ // sha256-in-dedicated-field sanity case confirms hash-class fields are
1677
+ // NOT false-flagged. writer.test.cjs (10 cases) asserts the chokepoint
1678
+ // contract end-to-end: export surface, telemetryDir under HOME,
1679
+ // isoWeekFilename zero-padding, telemetryFile composition, emit() JSONL
1680
+ // shape (schema_version=1 Number + ISO-8601 timestamp + session_id +
1681
+ // payload), throws on unknown event, throws on Part 8 forbidden pattern,
1682
+ // recursive mkdir + silent fs-error swallow, two emits 5ms apart in
1683
+ // same ISO-week file, all lines JSON.parseable with no BOM.
1684
+ path.join(REPO_ROOT, 'lib', 'core', 'telemetry', 'schema.test.cjs'),
1685
+ path.join(REPO_ROOT, 'lib', 'core', 'telemetry', 'validator.test.cjs'),
1686
+ path.join(REPO_ROOT, 'lib', 'core', 'telemetry', 'writer.test.cjs'),
1687
+ // Phase 121-01 Task 1 (Wave 1, atomic cutover): the one-time idempotent
1688
+ // migration script that merges the 4 piecemeal telemetry sources
1689
+ // (mva.jsonl, selector.jsonl, navigation-bypass.jsonl,
1690
+ // query-efficiency.jsonl) into the unified events-YYYY-WNN.jsonl stream
1691
+ // produced by writer.cjs. 8 fixture tests cover: empty source dir
1692
+ // no-op, legacy-shape normalization to command_invocation, mva
1693
+ // timestamp-order + schema_version=1 (Number), source rename to
1694
+ // *.pre-v121.bak, sha256-fingerprint idempotence on re-run, mixed-week
1695
+ // ISO split (W19/W20), Canon Part 8 forbidden-pattern quarantine
1696
+ // without abort, stdout summary JSON shape. Hermetic per-test
1697
+ // tmpdir + HOME swap; mirrors writer.test.cjs scaffolding.
1698
+ path.join(REPO_ROOT, 'scripts', 'migrate-telemetry-v1.test.cjs'),
1699
+ // Phase 121-02 Task 1..4 (Wave 2, capture-point wire-ins): 4 integration
1700
+ // test files each verify that a high-signal capture point routes its
1701
+ // emit through lib/core/telemetry/writer.cjs into the unified
1702
+ // events-YYYY-WNN.jsonl stream. D-04 selector_pick (88.2/125 ranker) +
1703
+ // D-05 tension_engagement (Phase 116) + D-06 auto_explore_decision
1704
+ // (Phase 117) + D-07 breakthrough_dismissed (Phase 120 + ethics_tier +
1705
+ // voice_audit_pass). 4 tests per file (16 total); each asserts the
1706
+ // event lands with correct ALLOWED_FIELDS shape, non-blocking semantics
1707
+ // (telemetry validation failure does NOT crash the shipping behavior),
1708
+ // and that user-initiated state transitions are captured while
1709
+ // system-driven transitions (decay, throttle, skip) are excluded.
1710
+ path.join(REPO_ROOT, 'tests', 'test-121-02-selector-pick-capture.cjs'),
1711
+ path.join(REPO_ROOT, 'tests', 'test-121-02-tension-engagement-capture.cjs'),
1712
+ path.join(REPO_ROOT, 'tests', 'test-121-02-auto-explore-capture.cjs'),
1713
+ path.join(REPO_ROOT, 'tests', 'test-121-02-breakthrough-dismissed-capture.cjs'),
1714
+ // Phase 121-03 Task 1..4 (Wave 2, secondary D-09 capture points): 3 integration
1715
+ // tests + 1 drowning-protection fixture. D-09 ships three lower-signal but
1716
+ // broader-sweep emit surfaces: empathy audit observation CLI harness +
1717
+ // Phase 119 room-as-receipt helper module + PostToolUse /mos:* broad sweep
1718
+ // (100% sampling, type-discriminator-isolated bucket). The drowning-protection
1719
+ // fixture proves the type discriminator works: 100 command_invocation events
1720
+ // + 10 selector_pick events to a tmpdir, type-filter isolates them so SEED-002
1721
+ // consumers can drop the bucket without losing the high-signal stream.
1722
+ path.join(REPO_ROOT, 'tests', 'test-121-03-empathy-observation.cjs'),
1723
+ path.join(REPO_ROOT, 'tests', 'test-121-03-room-receipt-emit.cjs'),
1724
+ path.join(REPO_ROOT, 'tests', 'test-121-03-command-invocation-hook.cjs'),
1725
+ path.join(REPO_ROOT, 'tests', 'test-121-03-drowning-protection.cjs'),
1726
+ // Phase 127.1 brain-graphrag-collapse-pinecone-neo4j-hnsw (Wave 0 harness scaffold + Wave 1/2/3 outputs)
1727
+ // Surface 1 -> Plan 127.1-01 produces embedding-manifest.fixture.json (12,401 byte-identical SHA256 pairs).
1728
+ // Surface 2 -> Plan 127.1-02 produces index-config.fixture.json (SHOW INDEXES dim=1024 cosine ONLINE).
1729
+ // query-embedder -> Plan 127.1-03 produces mcp-server-brain/lib/query-embedder.cjs (server-side e5-large query embedding; hermetic, mocked transport).
1730
+ // Surface 3 -> Plan 127.1-04 produces overlap-baseline + overlap-neo4j fixtures (BLOCKING gate >= 0.80).
1731
+ // Aggregator: tests/run-all-127.sh. RED-by-design until consumer plans land the fixtures.
1732
+ path.join(REPO_ROOT, 'tests', '127.1-embedding-integrity.test.cjs'),
1733
+ path.join(REPO_ROOT, 'tests', '127.1-index-config.test.cjs'),
1734
+ path.join(REPO_ROOT, 'tests', '127.1-query-embedder.test.cjs'),
1735
+ path.join(REPO_ROOT, 'tests', '127.1-graphrag-overlap.test.cjs'),
1736
+ // Phase 127.3 jtbd-auto-anchor-fix (Plan 00 chokepoint extraction):
1737
+ // tests/test-resolve-active-room-canonical.cjs -- 12 hermetic scenarios
1738
+ // on lib/core/resolve-active-room.cjs (rar.1..rar.12; both legacy +
1739
+ // current registry shapes, env override, sealed/archived rejection,
1740
+ // Canon Part 8 + Part 9 source-grep tripwires).
1741
+ // The shell-based 127.3 tests (test-jtbd-auto-anchor-empirical.sh +
1742
+ // test-127.3-sibling-sweep.sh) are NOT registered here -- this runner
1743
+ // is CJS-only (spawnSync('node', [file])); they run via
1744
+ // tests/run-all-127.3.sh instead, per 127.3-PATTERNS.md.
1745
+ path.join(REPO_ROOT, 'tests', 'test-resolve-active-room-canonical.cjs'),
1746
+ // Phase 129 spine-repair-memory-event (the backward arc: every spine surface
1747
+ // journals a memory_event via navigation.cjs; SQL is the local mind). 5 suites
1748
+ // mapped to their plans (mirrors the Phase 124 / Phase 125 additive-tail block):
1749
+ // test-129-spine-substrate.cjs -> 129-01 Wave 1 substrate: 5 net-new
1750
+ // canonical event types (spine_read / jtbd_transitioned /
1751
+ // operator_transitioned / workflow_stage / suggestion_surfaced) + FOLLOWS_FROM
1752
+ // as the 8th cascade edge + 60s idempotency in logEvent + spine-events.cjs
1753
+ // roomDir-taking helper API.
1754
+ // test-129-read-surface-events.cjs -> 129-02 Wave 2 read surfaces:
1755
+ // mos-status / memory / suggest-next emit spine_read + suggestion_surfaced.
1756
+ // test-129-state-transition-events.cjs-> 129-03 Wave 2 state transitions:
1757
+ // jtbd / operator transitions emit jtbd_transitioned + operator_transitioned
1758
+ // (+ OPERATOR_TRANSITION edge through the chokepoint).
1759
+ // test-129-workflow-stage-events.cjs -> 129-04 Wave 2 workflow surfaces:
1760
+ // act / pipeline emit workflow_stage entered + completed (FOLLOWS_FROM chain).
1761
+ // test-129-spine-acceptance.cjs -> 129-05 Wave 3 release gate: the
1762
+ // instrumented proactive-loop acceptance test (zero non-SQLite reads outside
1763
+ // the two cache files + exact memory_event count + dedupe + the next status
1764
+ // render reads the just-emitted events + FOLLOWS_FROM linkage). Mirrors the
1765
+ // Phase 109 tests/test-navigation-acceptance.cjs fs-instrument precedent.
1766
+ // Aggregator: tests/run-all-129.sh.
1767
+ path.join(REPO_ROOT, 'tests', 'test-129-spine-substrate.cjs'),
1768
+ path.join(REPO_ROOT, 'tests', 'test-129-read-surface-events.cjs'),
1769
+ path.join(REPO_ROOT, 'tests', 'test-129-state-transition-events.cjs'),
1770
+ path.join(REPO_ROOT, 'tests', 'test-129-workflow-stage-events.cjs'),
1771
+ path.join(REPO_ROOT, 'tests', 'test-129-spine-acceptance.cjs'),
1772
+ // Phase 129.5 truth-machine-activation (the human-confirms-truth lever made
1773
+ // live: confirmNode is the single APPROVE-to-promote door; an agent-attributed
1774
+ // confirm is REJECTED; audit nodes are exempt per the Canon Part 9 v1.5
1775
+ // carve-out). 2 suites mapped to their plans:
1776
+ // test-129.5-confirm-node.cjs -> 129.5-02 confirmNode chokepoint +
1777
+ // human-attribution guard (AGENT_IDENTITIES REJECT on confirm/validate of
1778
+ // truth-claim nodes) + resolveByUser USER.md navigator-identity resolver.
1779
+ // test-129.5-truth-machine.cjs -> 129.5-03 release gate: the instrumented
1780
+ // acceptance test. A USER.md-attributed APPROVE through the selector
1781
+ // dispatcher promotes proposed->confirmed via navigation.confirmNode AND
1782
+ // confirmedFacts returns it; an agent-attributed confirm is REJECTED and
1783
+ // the node stays proposed; a status_promoted memory_event is emitted on
1784
+ // promotion; audit nodes (created_by=system) are exempt. Mirrors the
1785
+ // Phase 109/129 fs-instrument precedent (USER.md is the single allow-listed
1786
+ // non-room.db read).
1787
+ // Aggregator: tests/run-all-129.5.sh.
1788
+ path.join(REPO_ROOT, 'tests', 'test-129.5-confirm-node.cjs'),
1789
+ path.join(REPO_ROOT, 'tests', 'test-129.5-truth-machine.cjs'),
1790
+ // Phase 130 lens-engine-skeleton (the single architectural rotate() engine +
1791
+ // the cognitive-family migration onto room.db; the lens family is the moat
1792
+ // surface for v1.14.0 domain/source/framework/trend migrations). 4 suites
1793
+ // mapped to their plans:
1794
+ // test-130-lens-substrate.cjs -> 130-01 INFORMS + REJECTED_BECAUSE edge
1795
+ // enum + lens-nodes.cjs HatState / lens_finding node chokepoint.
1796
+ // test-130-lens-engine.cjs -> 130-02 rotate() engine + 5-family
1797
+ // registry + serial/parallel/single modes + the 3 pure synthesizers + the
1798
+ // 5 lens memory_event types.
1799
+ // test-130-cognitive-migration.cjs -> 130-03 hat-persistence room.db rewrite
1800
+ // + one-shot backfill + the 4 thin lens-engine command clients +
1801
+ // persona-ops loop delegation + tension-map dedup.
1802
+ // test-130-lens-engine-e2e.cjs -> 130-04 release gate: 8 instrumented
1803
+ // E2E tests (6 cognitive-family serial/parallel/single/consume + round-trip
1804
+ // + backfill, 2 engine-contract rejection-as-data + persona-aware framing),
1805
+ // all through navigation.cjs with the Phase 109/129 fs-instrument zero-leak
1806
+ // gate (USER.md the single allow-listed non-SQLite read).
1807
+ // Aggregator: tests/run-all-130.sh.
1808
+ path.join(REPO_ROOT, 'tests', 'test-130-lens-substrate.cjs'),
1809
+ path.join(REPO_ROOT, 'tests', 'test-130-lens-engine.cjs'),
1810
+ path.join(REPO_ROOT, 'tests', 'test-130-cognitive-migration.cjs'),
1811
+ path.join(REPO_ROOT, 'tests', 'test-130-lens-engine-e2e.cjs'),
1812
+ // Phase 130.5 shared-corpus-cache-cjs-fetcher-substrate (the ONE external-corpus
1813
+ // module + shared TTL cache that 131 consumes, 134 reuses, and
1814
+ // rs-discovery-engine migrates onto; built once). The substrate unit suites live
1815
+ // at the module sites (lib/core/research-corpus.test.cjs +
1816
+ // lib/core/research-cache.test.cjs); the migration regression registers here:
1817
+ // test-130.5-corpus-migration.cjs -> 130.5-03 rs-discovery-engine repointed off
1818
+ // the private fetcherAcademic path onto fetchCorpus + the shared
1819
+ // research-cache. Byte-identical fixture regression (full downstream bundle
1820
+ // old-vs-new) + cache-hit-on-repeat (count_run2 < count_run1) + Canon Part 8
1821
+ // preserved (planted forbidden flat_query rejects pre-egress, zero fetch).
1822
+ // Aggregator: tests/run-all-130.5.sh.
1823
+ path.join(REPO_ROOT, 'tests', 'test-130.5-corpus-migration.cjs'),
1824
+ // Phase 135 offer-resolver-and-reliable-next-move-closer (the offer loop:
1825
+ // the resolver emits one calibrated offer or null via an abstention triple,
1826
+ // the presenter grounds it, and the F.1 closer fires it through
1827
+ // AskUserQuestion to a typed decision edge). SC coverage: SC1/SC3/SC6
1828
+ // (resolver + abstention) + SC2/SC9 (zero non-SQLite leak, Part 8 boundary)
1829
+ // + SC1/SC4/SC6 (end-to-end production wiring guard) + SC5/SC6/SC7/SC8
1830
+ // (closer wiring + wikilink-on-accept + backoff persistence + cross-surface).
1831
+ // 4 suites mapped to their plans:
1832
+ // navigation-engine-offer.test.cjs -> 135-02 resolver body + abstention
1833
+ // triple (rank-first, SC2 graph + SC4 MD-aware, grounded [[wikilink]] reason).
1834
+ // offer-closer.test.cjs -> 135-03 F.1 closer wiring + decision-edge
1835
+ // persistence + reject->shouldExclude backoff loop closure (SC6/SC7).
1836
+ // test-135-resolver-no-leak.cjs -> 135-01 fs-instrument zero-leak on the
1837
+ // resolver decide() path (USER.md the single allow-listed non-SQLite read).
1838
+ // test-135-decide-wiring-e2e.cjs -> 135-01 dark-loop regression guard: the
1839
+ // REAL decide() path on a DECISION_GATE turn emits offer_next_step non-null
1840
+ // with a real [[section]] reason (never an undefined-valued wikilink) +
1841
+ // defined scope, plus a JUST_TALK null negative control.
1842
+ // Aggregator: tests/run-all-135.sh.
1843
+ path.join(REPO_ROOT, 'lib', 'memory', 'navigation-engine-offer.test.cjs'),
1844
+ path.join(REPO_ROOT, 'lib', 'memory', 'offer-closer.test.cjs'),
1845
+ path.join(REPO_ROOT, 'tests', 'test-135-resolver-no-leak.cjs'),
1846
+ path.join(REPO_ROOT, 'tests', 'test-135-decide-wiring-e2e.cjs'),
1847
+ // Phase 130.7 correlation-id-contract-dual-graph-ci-gates (Wave 1: the
1848
+ // name-based, embedding-INDEPENDENT correlation_id hashing chokepoint + the
1849
+ // one-time idempotent Brain backfill + the LOCAL correlation_labels index
1850
+ // Plan 02's no-fork canonical pick consumes). 2 suites mapped to their tasks:
1851
+ // correlation.test.cjs -> 130.7-01 Task 1: determinism +
1852
+ // embedding-independence (arity-2 + ignored 3rd arg, the key_invariant) +
1853
+ // label-sensitivity + trim normalization + 28-name collision fixture +
1854
+ // golden version pin.
1855
+ // correlation-label-index.test.cjs -> 130.7-01 Task 2: serialize/parse
1856
+ // round-trip incl. a cross-label-duplicate name with per-label degree;
1857
+ // empty/malformed body returns {} without throwing; stable section key.
1858
+ // chain-recommender-canonical.test.cjs -> 130.7-02 Task 1: recommendCanonical
1859
+ // Targets one canonical tuple per query, no cross-label fork.
1860
+ // local-chain-recommender.test.cjs / spine-events-correlation.test.cjs ->
1861
+ // 130.7-02 Tasks 2/3: aggregate-by-correlation_id + memory_event refs.
1862
+ // dual-graph-health.test.cjs -> 130.7-03 Task 1 + Task 3: the report-only/
1863
+ // baseline fail-closed CI gate (records a baseline, fails on regression not
1864
+ // pre-existing debt, fails-closed on inconclusive, M3 recommender no-fork,
1865
+ // post-132 flip stubbed) PLUS the Part 8 phase-wide forbidden-pattern sweep
1866
+ // over all 8 130.7 code paths.
1867
+ // brain-derive-curation.test.cjs -> 130.7-03 Task 2: the three /mos:brain-derive
1868
+ // curation surfaces (--review-anchors / --orphan-census / --cross-label-dups).
1869
+ // Aggregator: tests/run-all-130.7.sh.
1870
+ path.join(REPO_ROOT, 'lib', 'memory', 'correlation.test.cjs'),
1871
+ path.join(REPO_ROOT, 'lib', 'memory', 'correlation-label-index.test.cjs'),
1872
+ path.join(REPO_ROOT, 'lib', 'memory', 'chain-recommender-canonical.test.cjs'),
1873
+ path.join(REPO_ROOT, 'lib', 'memory', 'local-chain-recommender.test.cjs'),
1874
+ path.join(REPO_ROOT, 'lib', 'memory', 'spine-events-correlation.test.cjs'),
1875
+ path.join(REPO_ROOT, 'lib', 'memory', 'dual-graph-health.test.cjs'),
1876
+ path.join(REPO_ROOT, 'lib', 'memory', 'brain-derive-curation.test.cjs'),
1877
+ // Phase 131 research-as-graph-aware-workflow (the source-lens family PILOT:
1878
+ // /mos:research becomes the canonical 7-stage workflow step other methodologies
1879
+ // dispatch, with typed EvidenceClaim nodes + INFORMS / CONTRADICTS / SUPERSEDES /
1880
+ // REJECTED_BECAUSE cascade edges; the template for the v1.14.0 fan-out to the 13
1881
+ // remaining research surfaces). 6 suites mapped to their plans:
1882
+ // test-131-substrate.cjs -> 131-01 CONTRADICTS + SUPERSEDES edge enum
1883
+ // (additive) + research_filed / research_rejected / research_deferred events +
1884
+ // evidence-claim.cjs writeEvidenceClaim (LOCKED Phase 136 schema) +
1885
+ // research-preflight.cjs getResearchPreflight batched 8-input read +
1886
+ // navigation.cjs re-exports.
1887
+ // test-131-context-extractor.cjs -> 131-02 Stage 1+2+3 extractContext (ONE
1888
+ // batched pre-flight read + Body Shape A summary + context-derived lens_set).
1889
+ // test-131-source-lens-driver.cjs -> 131-03 Stage 3-4 runSourceLens (the source
1890
+ // family activated on the 130 lens-engine + weighted-by-context mode + the
1891
+ // 130.5 corpus consume; dedup + tier/relevance rank; zero Python).
1892
+ // test-131-findings-wirer.cjs -> 131-04 Stage 6 F.1 filing selector (mirrors
1893
+ // selector-dispatcher) + Stage 7 wireAccept/wireReject/wireDefer (local-node-id
1894
+ // for local targets; REAL correlation_id for teaching-graph targets).
1895
+ // test-131-isomorphism.cjs -> 131-05 check-research-isomorphism CI guard
1896
+ // (typed-node + typed-edge contract + zero-Python directive gate).
1897
+ // test-131-e2e.cjs -> 131-06 release gate: 5 instrumented E2E
1898
+ // tests (standalone / build-thesis chain-back / user-needs different-lens +
1899
+ // REAL correlation_id / rejection-as-data / dedup+cache), all driving the FULL
1900
+ // pipeline through navigation.cjs with the Phase 109/129/130 fs-instrument
1901
+ // zero-leak gate (USER.md + the 130.5 research-cache the allow-listed reads).
1902
+ // Aggregator: tests/run-all-131.sh.
1903
+ path.join(REPO_ROOT, 'tests', 'test-131-substrate.cjs'),
1904
+ path.join(REPO_ROOT, 'tests', 'test-131-context-extractor.cjs'),
1905
+ path.join(REPO_ROOT, 'tests', 'test-131-source-lens-driver.cjs'),
1906
+ path.join(REPO_ROOT, 'tests', 'test-131-findings-wirer.cjs'),
1907
+ path.join(REPO_ROOT, 'tests', 'test-131-isomorphism.cjs'),
1908
+ path.join(REPO_ROOT, 'tests', 'test-131-e2e.cjs'),
1909
+ // Phase 132 dual-graph-correlation-hypergraph-reformat (Wave 1: the shared
1910
+ // curation-batch runner + the hypergraph event-node SCHEMA substrate + the
1911
+ // write-time 130.7-contract guard, all MACHINERY built + tested on FIXTURES;
1912
+ // ZERO live Brain writes in this plan). 2 suites mapped to their tasks:
1913
+ // curation-batch.test.cjs -> 132-01 Task 1: the reusable
1914
+ // curation-batch runner -- makeBatch stamps created_by on every forward
1915
+ // write, REJECTS any batch with empty rollbackCyphers (the reversibility
1916
+ // contract), assertRollbackPath ties each rollback to its forward
1917
+ // created_by selector, scanBatchForUserContent proves the Canon Part 8
1918
+ // no-user-content shape, and execute() runs a write-time pre-flight probe
1919
+ // (assertCorrelationContractPresent) that refuses to mutate unless the
1920
+ // Phase 130.7 correlation_id contract is present in the live graph --
1921
+ // asserted via an injected fake runner (no live Brain). dry-run stays
1922
+ // creds-free + ungated. Transport REUSED from the admin-brain-write
1923
+ // neo4j-driver pattern (zero new deps).
1924
+ // hypergraph-event-schema.test.cjs -> 132-01 Task 2: the frozen 5-event-type
1925
+ // contract (Authorship/Illustration/Contradiction/Motivation/Evolution)
1926
+ // with each type's connected roles + the additive reify Cypher builder
1927
+ // (zero DELETE/REMOVE/DETACH/DROP per Part 7) + EVENT_INSTANCE_MIN floor.
1928
+ // Aggregator: tests/run-all-132.sh.
1929
+ path.join(REPO_ROOT, 'lib', 'memory', 'curation-batch.test.cjs'),
1930
+ path.join(REPO_ROOT, 'lib', 'memory', 'hypergraph-event-schema.test.cjs'),
1931
+ // Plan 132-03 (re-baselined): the dedup-collapse + held-name-rename machinery
1932
+ // curation-132-03-dedup-held-rename.test.cjs -> 132-03: the GENERIC pass
1933
+ // machinery the orchestrator runs later snapshot-first against the TINY
1934
+ // live worklist (1 dedup pair 6831/22816 + 14 held name>80 nodes).
1935
+ // pickCanonical (most-edged + 130.7 LABEL_PRIORITY tiebreak); dedup yields
1936
+ // keeper correlation_id via computeCorrelationId (reused, no re-hash) +
1937
+ // migrate-incoming-edges + :Archived/REPLACED_BY (reversible-delete only,
1938
+ // Part 7) + snapshotRequired (node-merge is not created_by-reversible);
1939
+ // held rename recomputes correlation_id + 3-property curated-v1 backfill +
1940
+ // clears the held marker (fully created_by-reversible). Both route through
1941
+ // the 132-01 makeBatch runner; ZERO live writes; fixtures only.
1942
+ path.join(REPO_ROOT, 'lib', 'memory', 'curation-132-03-dedup-held-rename.test.cjs'),
1943
+ // Plan 132-05 (re-baselined to the RELEASE GATE): the pseudonymize BUILDER
1944
+ // (6 internal-team :Person nodes matched by the mindrian_internal:true FLAG,
1945
+ // never a real-name literal; Aronhime public persona excluded; name_pre_pseudonym
1946
+ // stored before overwrite for the created_by=batch-5 reversible rollback; Part 8
1947
+ // scanBatchForUserContent clean) PLUS the Phase 132 RELEASE GATE assertion that
1948
+ // scripts/verify-phase-132.cjs INVOKES (never reimplements) the Phase 130.7
1949
+ // dual-graph health gate + runs the brain-boundary-scan over the phase-132 batch
1950
+ // builders, fail-closed (blocked-on-130.7) when the gate is absent. The live
1951
+ // pseudonymize WRITE is DEFERRED to v1.14.0 (deferred-items.md); ZERO live writes.
1952
+ path.join(REPO_ROOT, 'lib', 'memory', 'curation-132-05-pseudonymize.test.cjs'),
1953
+ // Quick task 260602-rgx: /mos:help selector-menu lane contract regression. Locks
1954
+ // the 4 invariants of the Shape F drill-down selector over data/help-groups.json:
1955
+ // (1) every group declares a lane in {start, methodology, explore, view}; (2) the 4
1956
+ // lanes cover every non-admin command EXACTLY once (full coverage + no dup, with the
1957
+ // non-admin set derived from commands/*.md visibility frontmatter minus
1958
+ // deprecated_aliases, mirroring scripts/check-help-coverage.cjs); (3) no
1959
+ // visibility:admin command (admin, dogfood-flush) and no deprecated_aliases key
1960
+ // appears in any group; (4) scripts/help-renderer.cjs text view exits 0 and prints a
1961
+ // /mos:<cmd> line for every non-admin command. Canon Part 7 (mirrors the existing
1962
+ // coverage check rather than inventing a second visibility convention) + Part 8
1963
+ // (filesystem only, zero network surface).
1964
+ path.join(REPO_ROOT, 'tests', 'test-help-selector-lanes.cjs'),
1965
+ // Quick task 260602-dsc: /mos:help De Stijl CARD view structure test
1966
+ // (scripts/help-renderer.cjs renderHelpCards). Locks the card-view contract:
1967
+ // (1) color mode carries a DS 24-bit truecolor escape AND prints a /mos:<cmd>
1968
+ // + its help_jtbd one-liner for every non-admin command + all 4 lane labels;
1969
+ // (2) ascii mode (useColor=false) carries ZERO ANSI escapes yet prints the
1970
+ // same per-command /mos:<cmd> + jtbd + 4 lane labels; (3) neither mode prints a
1971
+ // visibility:admin command (admin, dogfood-flush) or a deprecated_aliases key.
1972
+ // Non-admin set mirrors scripts/check-help-coverage.cjs (Canon Part 7 -- one
1973
+ // visibility convention); filesystem only, zero network (Canon Part 8).
1974
+ path.join(REPO_ROOT, 'tests', 'test-help-cards-render.cjs'),
1975
+ // Quick task 20260702-help-coverage-gate: the born-listed /mos:help coverage
1976
+ // gate contract. Locks: (1) the gate is green on the live backfilled manifest;
1977
+ // (2-6) over an isolated fixture tree, the SAME check() catches a missing
1978
+ // user-facing command, a ghost (grouped name with no file), a deprecated:true
1979
+ // command NOT born-listed in deprecated_aliases, and a deprecated command that
1980
+ // leaked into a group; (7) scripts/install-pre-commit.sh wires the gate (the
1981
+ // 121.5-07 gate had shipped un-wired, which let a 13-command drift go RED
1982
+ // silently). Part 7 (one gate over fixtures, not a fork) + Part 8 (LOCAL only).
1983
+ path.join(REPO_ROOT, 'tests', 'test-help-coverage-gate.cjs'),
1984
+ // Phase 223 (jtbd intelligence pipeline + governed double-fan bono): two
1985
+ // born-wired surfaces sharing one close-the-loop graph-write spine. The five
1986
+ // per-plan proof legs the tests/run-all-223.sh aggregator also gates
1987
+ // (223-VALIDATION test-infrastructure contract):
1988
+ // hat-governance -> Req 1 governed seams + heterogeneity + CR-01 no-thenable
1989
+ // part8-egress -> persona research SIGNAL->LOCAL, egress-guard gated
1990
+ // close-loop -> Req 4 D-01 dual store (.md first) + D-02 proposed edges
1991
+ // supersedes-chain -> Req 2 walker + D-04 NULL review_status
1992
+ // intel-pipeline -> Req 3 dry-run + 3 gate halts + quality-low HALT
1993
+ path.join(REPO_ROOT, 'tests', 'test-223-hat-governance.cjs'),
1994
+ path.join(REPO_ROOT, 'tests', 'test-223-part8-egress.cjs'),
1995
+ path.join(REPO_ROOT, 'tests', 'test-223-close-loop.cjs'),
1996
+ path.join(REPO_ROOT, 'tests', 'test-223-supersedes-chain.cjs'),
1997
+ path.join(REPO_ROOT, 'tests', 'test-223-intel-pipeline.cjs'),
1998
+ // Phase 224 (graph-derivation harness): normal prose writes now derive
1999
+ // proposed CONVERGES/INFORMS edges through the navigation chokepoint,
2000
+ // disclosed-not-guessed when the encoder is missing. The eight per-plan proof
2001
+ // legs the tests/run-all-224.sh aggregator also gates (224-VALIDATION test-
2002
+ // infrastructure contract: new tests register here alongside the aggregator):
2003
+ // migration -> D-05 edges.review_status column + writeEdge enum upsert
2004
+ // classifier -> D-01 CONVERGES/INFORMS-only score-to-edge-type layer
2005
+ // encoder-skip -> D-04 disclose-not-guess (derivation_skipped marker)
2006
+ // per-write-derive-> Req 1 cascade Step 2b enqueue + detached spawn
2007
+ // cost-bound -> Req 6 O(n) new-vs-existing pair count
2008
+ // backfill-idempotent -> Req 2 score-based deriver swap + Ralph re-run invariant
2009
+ // resolver-fallback -> Req 3 canonical resolveWriteRoom fallback
2010
+ // proposed-only -> Req 4 no auto-confirm (edge column + claim node)
2011
+ path.join(REPO_ROOT, 'tests', 'test-224-migration.cjs'),
2012
+ path.join(REPO_ROOT, 'tests', 'test-224-classifier.cjs'),
2013
+ path.join(REPO_ROOT, 'tests', 'test-224-encoder-skip.cjs'),
2014
+ path.join(REPO_ROOT, 'tests', 'test-224-per-write-derive.cjs'),
2015
+ path.join(REPO_ROOT, 'tests', 'test-224-cost-bound.cjs'),
2016
+ path.join(REPO_ROOT, 'tests', 'test-224-backfill-idempotent.cjs'),
2017
+ path.join(REPO_ROOT, 'tests', 'test-224-resolver-fallback.cjs'),
2018
+ path.join(REPO_ROOT, 'tests', 'test-224-proposed-only.cjs'),
2019
+ // Phase 225 (zero-score no-match gate + WAL advisory): gap-closure on Phase
2020
+ // 194's shipped substrate. The three proof legs the tests/run-all-225.sh
2021
+ // aggregator also gates (SKIP-safe via run_if):
2022
+ // zero-score-gate -> REQ-1/REQ-2 proving_case_2 FIRE + 4 legitimate-silence
2023
+ // legs + consumer-compatibility trace proof (never reuses corpus[0] best.name)
2024
+ // gate-degrade -> REQ-3 poisoned binding/trace -> exit-0 silence (83-07 never-block)
2025
+ // wal-advisory -> REQ-4 doctor never-block WARN on SQLite<3.51.3 + live co-session
2026
+ path.join(REPO_ROOT, 'tests', 'test-225-zero-score-gate.cjs'),
2027
+ path.join(REPO_ROOT, 'tests', 'test-225-gate-degrade.cjs'),
2028
+ path.join(REPO_ROOT, 'tests', 'test-225-wal-advisory.cjs'),
2029
+ // CR-01 fix regression (code review, post-225-03): the zero-score gate's default
2030
+ // answer must union with, never replace, a session's prior multi-room bound set.
2031
+ path.join(REPO_ROOT, 'tests', 'test-225-answer-narrowing.cjs'),
2032
+ // Phase 226 (eureka reasoning-mode fallback, SEED-058): the encoder-free
2033
+ // /mos:eureka fallback. The eight D1-D8 legs the tests/run-all-226.sh aggregator
2034
+ // also gates (SKIP-safe via run_if), registered here per the 224-VALIDATION
2035
+ // test-infra contract so the D1 fabricated-number tripwire and the Part 9
2036
+ // banked-false posture check are permanent, not one-time review:
2037
+ // null-legs -> D1/G-1 REQ-1 fabricated-number prohibition (the hardest gate)
2038
+ // rubric-parity -> D3/G-2 REQ-2 analogy bar not relaxed encoder-free
2039
+ // field-contract -> D4/G-5 REQ-3 four-key byte-parity output shape
2040
+ // degrade-cause -> D7 REQ-6/8 honest cause named, no speculative trigger
2041
+ // mode-disclosure -> D6/G-4 REQ-5 mode label across md + json + html
2042
+ // posture -> D5/G-3 REQ-4 banked-false + zero opportunity nodes + upgrade delta
2043
+ // pair-cap -> D8/G-6 REQ-7 bounded fan-out end to end
2044
+ // rejection-replay -> D3 REQ-2 the 212 junk classes stay rejected encoder-free
2045
+ path.join(REPO_ROOT, 'tests', 'test-226-null-legs.cjs'),
2046
+ path.join(REPO_ROOT, 'tests', 'test-226-rubric-parity.cjs'),
2047
+ path.join(REPO_ROOT, 'tests', 'test-226-field-contract.cjs'),
2048
+ path.join(REPO_ROOT, 'tests', 'test-226-degrade-cause.cjs'),
2049
+ path.join(REPO_ROOT, 'tests', 'test-226-mode-disclosure.cjs'),
2050
+ path.join(REPO_ROOT, 'tests', 'test-226-posture.cjs'),
2051
+ path.join(REPO_ROOT, 'tests', 'test-226-pair-cap.cjs'),
2052
+ path.join(REPO_ROOT, 'tests', 'test-226-rejection-replay.cjs'),
2053
+ // Phase 227 Plan-01, Requirement 1 (session-start mode-selection Decision
2054
+ // Gate firing checkpoint): a scripted doctor check now detects a silent
2055
+ // lane-pick skip. Covers the warn path (silent skip), the ok path (normal
2056
+ // recording), the D-05 turn-1 false-positive guard, never-throw on a
2057
+ // corrupt store, and the doctor-modules.json registry contract.
2058
+ path.join(REPO_ROOT, 'tests', 'test-227-mode-select-checkpoint.cjs'),
2059
+ // Phase 227 Plan-05, Requirement 3 (frontdoor-restraint regression floor):
2060
+ // four structural/static assertions replaying ignite-frontdoor-bypassed-
2061
+ // methodology-overfire.md's Test 4 scenario (an explore-invitation in a
2062
+ // fresh context), proving the 2026-06-24 fix (commit 7868dfbb) still
2063
+ // holds without a live human tester session.
2064
+ path.join(REPO_ROOT, 'tests', 'test-227-frontdoor-restraint.cjs'),
2065
+ ];
2066
+
2067
+ // Exit code convention for child tests:
2068
+ // 0 -> PASS
2069
+ // 77 -> SKIPPED (POSIX test-infra-broken; e.g. missing python3, missing
2070
+ // scripts/classify-insight). Must NOT count as failure.
2071
+ // other (including 1) -> FAIL.
2072
+ let failed = 0;
2073
+ let skipped = 0;
2074
+ for (const t of TEST_FILES) {
2075
+ const rel = path.relative(REPO_ROOT, t);
2076
+ if (!fs.existsSync(t)) {
2077
+ process.stderr.write('MISS ' + rel + ' (file does not exist)\n');
2078
+ failed += 1;
2079
+ continue;
2080
+ }
2081
+ const res = spawnSync(process.execPath, [t], { stdio: 'inherit' });
2082
+ if (res.status === 0) {
2083
+ process.stdout.write('PASS ' + rel + '\n');
2084
+ } else if (res.status === 77) {
2085
+ process.stdout.write('SKIP ' + rel + ' (exit 77, env degraded)\n');
2086
+ skipped += 1;
2087
+ } else {
2088
+ process.stderr.write('FAIL ' + rel + ' (exit ' + res.status + ')\n');
2089
+ failed += 1;
2090
+ }
2091
+ }
2092
+
2093
+ const total = TEST_FILES.length;
2094
+ const passed = total - failed - skipped;
2095
+ process.stdout.write(
2096
+ '\nFeynman test runner: ' +
2097
+ passed + '/' + total + ' passed, ' +
2098
+ skipped + ' skipped, ' +
2099
+ failed + ' failed\n'
2100
+ );
2101
+ process.exit(failed === 0 ? 0 : 1);