oh-my-second-brain 0.8.3 → 0.9.0

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 (214) hide show
  1. package/.claude-plugin/marketplace.json +2 -2
  2. package/.claude-plugin/plugin.json +2 -1
  3. package/.codex-plugin/plugin.json +1 -1
  4. package/CHANGELOG-assets.md +9 -1
  5. package/CHANGELOG-cli.md +9 -0
  6. package/CHANGELOG-kernel.md +11 -0
  7. package/CHANGELOG-mcp.md +10 -0
  8. package/CHANGELOG-vendors.md +8 -0
  9. package/CHANGELOG.md +13 -1
  10. package/README.ko.md +34 -100
  11. package/README.md +35 -101
  12. package/assets/claude/CLAUDE.md +16 -20
  13. package/assets/codex/AGENTS.md +14 -9
  14. package/assets/codex/rules/oms.md +11 -12
  15. package/assets/hermes/SOUL.md +11 -13
  16. package/assets/hermes-manifest.json +1 -1
  17. package/assets/skills/doctor/SKILL.md +10 -9
  18. package/assets/skills/search/SKILL.md +9 -20
  19. package/assets/skills/status/SKILL.md +3 -9
  20. package/assets/skills/template/SKILL.md +29 -0
  21. package/assets/skills/write/SKILL.md +20 -14
  22. package/core/AGENTS.md +41 -104
  23. package/dist/cli/args.d.ts +3 -2
  24. package/dist/cli/args.js +31 -17
  25. package/dist/cli/args.js.map +1 -1
  26. package/dist/cli/audit.d.ts +0 -1
  27. package/dist/cli/audit.js +45 -80
  28. package/dist/cli/audit.js.map +1 -1
  29. package/dist/cli/doctor-lint.d.ts +1 -1
  30. package/dist/cli/doctor-lint.js +23 -65
  31. package/dist/cli/doctor-lint.js.map +1 -1
  32. package/dist/cli/host-commands.d.ts +7 -7
  33. package/dist/cli/host-commands.js +102 -25
  34. package/dist/cli/host-commands.js.map +1 -1
  35. package/dist/cli/linkify.d.ts +2 -3
  36. package/dist/cli/linkify.js +9 -9
  37. package/dist/cli/linkify.js.map +1 -1
  38. package/dist/cli/oms.js +15 -19
  39. package/dist/cli/oms.js.map +1 -1
  40. package/dist/cli/setup-command.d.ts +4 -9
  41. package/dist/cli/setup-command.js +28 -132
  42. package/dist/cli/setup-command.js.map +1 -1
  43. package/dist/cli/usage.js +24 -11
  44. package/dist/cli/usage.js.map +1 -1
  45. package/dist/kernel/capture/safe.d.ts +43 -97
  46. package/dist/kernel/capture/safe.js +288 -517
  47. package/dist/kernel/capture/safe.js.map +1 -1
  48. package/dist/kernel/contracts/index.d.ts +3 -138
  49. package/dist/kernel/contracts/index.js +22 -340
  50. package/dist/kernel/contracts/index.js.map +1 -1
  51. package/dist/kernel/conventions/frontmatter.js +5 -4
  52. package/dist/kernel/conventions/frontmatter.js.map +1 -1
  53. package/dist/kernel/conventions/lint.js +4 -1
  54. package/dist/kernel/conventions/lint.js.map +1 -1
  55. package/dist/kernel/conventions/note-exclude.d.ts +9 -2
  56. package/dist/kernel/conventions/note-exclude.js +105 -14
  57. package/dist/kernel/conventions/note-exclude.js.map +1 -1
  58. package/dist/kernel/conventions/report.d.ts +0 -51
  59. package/dist/kernel/conventions/report.js +36 -204
  60. package/dist/kernel/conventions/report.js.map +1 -1
  61. package/dist/kernel/conventions/write-contract.d.ts +11 -25
  62. package/dist/kernel/conventions/write-contract.js +42 -78
  63. package/dist/kernel/conventions/write-contract.js.map +1 -1
  64. package/dist/kernel/conventions/write-protocol.d.ts +1 -10
  65. package/dist/kernel/conventions/write-protocol.js +1 -1
  66. package/dist/kernel/conventions/write-protocol.js.map +1 -1
  67. package/dist/kernel/doctor/service.d.ts +2 -4
  68. package/dist/kernel/doctor/service.js +12 -12
  69. package/dist/kernel/doctor/service.js.map +1 -1
  70. package/dist/kernel/engine/axes/store.js +3 -3
  71. package/dist/kernel/engine/axes/store.js.map +1 -1
  72. package/dist/kernel/engine/embed/sync.js +12 -6
  73. package/dist/kernel/engine/embed/sync.js.map +1 -1
  74. package/dist/kernel/engine/graph/builder.d.ts +19 -64
  75. package/dist/kernel/engine/graph/builder.js +241 -461
  76. package/dist/kernel/engine/graph/builder.js.map +1 -1
  77. package/dist/kernel/engine/graph/explore.d.ts +4 -4
  78. package/dist/kernel/engine/graph/explore.js +0 -0
  79. package/dist/kernel/engine/graph/explore.js.map +1 -1
  80. package/dist/kernel/engine/graph/node.d.ts +29 -93
  81. package/dist/kernel/engine/graph/node.js +87 -234
  82. package/dist/kernel/engine/graph/node.js.map +1 -1
  83. package/dist/kernel/engine/linkify/suggest.d.ts +0 -9
  84. package/dist/kernel/engine/linkify/suggest.js +0 -11
  85. package/dist/kernel/engine/linkify/suggest.js.map +1 -1
  86. package/dist/kernel/engine/linkify/types.d.ts +1 -3
  87. package/dist/kernel/engine/mcp/facade.d.ts +3 -3
  88. package/dist/kernel/engine/mcp/facade.js +95 -327
  89. package/dist/kernel/engine/mcp/facade.js.map +1 -1
  90. package/dist/kernel/engine/mcp/types.d.ts +2 -2
  91. package/dist/kernel/engine/tracer.js +7 -3
  92. package/dist/kernel/engine/tracer.js.map +1 -1
  93. package/dist/kernel/graph/cache.d.ts +1 -84
  94. package/dist/kernel/graph/cache.js +5 -438
  95. package/dist/kernel/graph/cache.js.map +1 -1
  96. package/dist/kernel/graph/explore.d.ts +32 -24
  97. package/dist/kernel/graph/explore.js +32 -101
  98. package/dist/kernel/graph/explore.js.map +1 -1
  99. package/dist/kernel/harness/surface-registry.js +9 -7
  100. package/dist/kernel/harness/surface-registry.js.map +1 -1
  101. package/dist/kernel/index.d.ts +0 -4
  102. package/dist/kernel/index.js +0 -4
  103. package/dist/kernel/index.js.map +1 -1
  104. package/dist/kernel/install/hosts.d.ts +1 -0
  105. package/dist/kernel/install/hosts.js +1 -0
  106. package/dist/kernel/install/hosts.js.map +1 -1
  107. package/dist/kernel/install/pointer.d.ts +28 -0
  108. package/dist/kernel/install/pointer.js +232 -0
  109. package/dist/kernel/install/pointer.js.map +1 -0
  110. package/dist/kernel/link/link.d.ts +4 -2
  111. package/dist/kernel/link/link.js +6 -4
  112. package/dist/kernel/link/link.js.map +1 -1
  113. package/dist/kernel/link/workflow.d.ts +17 -7
  114. package/dist/kernel/link/workflow.js +66 -56
  115. package/dist/kernel/link/workflow.js.map +1 -1
  116. package/dist/kernel/runtime/assets.d.ts +3 -14
  117. package/dist/kernel/runtime/assets.js +9 -37
  118. package/dist/kernel/runtime/assets.js.map +1 -1
  119. package/dist/kernel/search/morning-test-fixtures.js +22 -27
  120. package/dist/kernel/search/morning-test-fixtures.js.map +1 -1
  121. package/dist/kernel/setup/documents.d.ts +25 -14
  122. package/dist/kernel/setup/documents.js +10 -111
  123. package/dist/kernel/setup/documents.js.map +1 -1
  124. package/dist/kernel/setup/service.d.ts +16 -35
  125. package/dist/kernel/setup/service.js +16 -91
  126. package/dist/kernel/setup/service.js.map +1 -1
  127. package/dist/kernel/templates/axes.d.ts +29 -0
  128. package/dist/kernel/templates/axes.js +45 -0
  129. package/dist/kernel/templates/axes.js.map +1 -0
  130. package/dist/kernel/templates/canonical.d.ts +8 -0
  131. package/dist/kernel/templates/canonical.js +193 -0
  132. package/dist/kernel/templates/canonical.js.map +1 -0
  133. package/dist/kernel/templates/defaults.d.ts +17 -0
  134. package/dist/kernel/templates/defaults.js +127 -0
  135. package/dist/kernel/templates/defaults.js.map +1 -0
  136. package/dist/kernel/templates/doctor.d.ts +40 -0
  137. package/dist/kernel/templates/doctor.js +226 -0
  138. package/dist/kernel/templates/doctor.js.map +1 -0
  139. package/dist/kernel/templates/extract.d.ts +31 -0
  140. package/dist/kernel/templates/extract.js +136 -0
  141. package/dist/kernel/templates/extract.js.map +1 -0
  142. package/dist/kernel/templates/index.d.ts +19 -0
  143. package/dist/kernel/templates/index.js +11 -0
  144. package/dist/kernel/templates/index.js.map +1 -0
  145. package/dist/kernel/templates/migration.d.ts +63 -0
  146. package/dist/kernel/templates/migration.js +733 -0
  147. package/dist/kernel/templates/migration.js.map +1 -0
  148. package/dist/kernel/templates/naming.d.ts +10 -0
  149. package/dist/kernel/templates/naming.js +47 -0
  150. package/dist/kernel/templates/naming.js.map +1 -0
  151. package/dist/kernel/templates/note-index.d.ts +33 -0
  152. package/dist/kernel/templates/note-index.js +125 -0
  153. package/dist/kernel/templates/note-index.js.map +1 -0
  154. package/dist/kernel/templates/paths.d.ts +29 -0
  155. package/dist/kernel/templates/paths.js +132 -0
  156. package/dist/kernel/templates/paths.js.map +1 -0
  157. package/dist/kernel/templates/policy.d.ts +59 -0
  158. package/dist/kernel/templates/policy.js +308 -0
  159. package/dist/kernel/templates/policy.js.map +1 -0
  160. package/dist/kernel/templates/resolver.d.ts +18 -0
  161. package/dist/kernel/templates/resolver.js +598 -0
  162. package/dist/kernel/templates/resolver.js.map +1 -0
  163. package/dist/kernel/templates/transaction.d.ts +8 -0
  164. package/dist/kernel/templates/transaction.js +452 -0
  165. package/dist/kernel/templates/transaction.js.map +1 -0
  166. package/dist/kernel/templates/types.d.ts +368 -0
  167. package/dist/kernel/{ontology → templates}/types.js.map +1 -1
  168. package/dist/kernel/update/update.js +1 -1
  169. package/dist/kernel/update/update.js.map +1 -1
  170. package/dist/mcp/link-tools.d.ts +3 -4
  171. package/dist/mcp/link-tools.js +3 -18
  172. package/dist/mcp/link-tools.js.map +1 -1
  173. package/dist/mcp/server.js +383 -219
  174. package/dist/mcp/server.js.map +1 -1
  175. package/dist/vendors/claude/claude-hooks.js +24 -6
  176. package/dist/vendors/claude/claude-hooks.js.map +1 -1
  177. package/dist/vendors/claude/hook/post-tool-use.d.ts +2 -11
  178. package/dist/vendors/claude/hook/post-tool-use.js +48 -81
  179. package/dist/vendors/claude/hook/post-tool-use.js.map +1 -1
  180. package/docs/architecture.md +45 -0
  181. package/docs/conventions.md +64 -0
  182. package/docs/install.md +41 -141
  183. package/docs/verified-target.md +41 -0
  184. package/package.json +5 -3
  185. package/core/ontology/concepts/inbox.yaml +0 -4
  186. package/core/ontology/concepts/literature.yaml +0 -27
  187. package/core/ontology/concepts/term.yaml +0 -12
  188. package/core/ontology/schemas/README.md +0 -55
  189. package/core/ontology/schemas/concept.schema.yaml +0 -70
  190. package/core/ontology/schemas/note.schema.yaml +0 -40
  191. package/core/ontology/taxonomy.yaml +0 -14
  192. package/dist/kernel/conventions/validate.d.ts +0 -24
  193. package/dist/kernel/conventions/validate.js +0 -88
  194. package/dist/kernel/conventions/validate.js.map +0 -1
  195. package/dist/kernel/engine/conventions/vault-lint.d.ts +0 -112
  196. package/dist/kernel/engine/conventions/vault-lint.js +0 -213
  197. package/dist/kernel/engine/conventions/vault-lint.js.map +0 -1
  198. package/dist/kernel/engine/linkify/apply.d.ts +0 -56
  199. package/dist/kernel/engine/linkify/apply.js +0 -65
  200. package/dist/kernel/engine/linkify/apply.js.map +0 -1
  201. package/dist/kernel/ontology/active.d.ts +0 -7
  202. package/dist/kernel/ontology/active.js +0 -41
  203. package/dist/kernel/ontology/active.js.map +0 -1
  204. package/dist/kernel/ontology/loader.d.ts +0 -2
  205. package/dist/kernel/ontology/loader.js +0 -54
  206. package/dist/kernel/ontology/loader.js.map +0 -1
  207. package/dist/kernel/ontology/resolver.d.ts +0 -2
  208. package/dist/kernel/ontology/resolver.js +0 -23
  209. package/dist/kernel/ontology/resolver.js.map +0 -1
  210. package/dist/kernel/ontology/types.d.ts +0 -47
  211. package/dist/kernel/setup/axis.d.ts +0 -36
  212. package/dist/kernel/setup/axis.js +0 -232
  213. package/dist/kernel/setup/axis.js.map +0 -1
  214. /package/dist/kernel/{ontology → templates}/types.js +0 -0
@@ -1,25 +1,24 @@
1
1
  # Oh My Second Brain for Codex
2
2
 
3
- Use Oh My Second Brain when the user asks to set up, validate, capture into, retrieve from, or inspect an Obsidian/Markdown vault governed by `vault/.oms/`.
3
+ Use Oh My Second Brain for an Obsidian/Markdown vault governed by user-owned template controls in `.oms/`.
4
4
 
5
5
  ## Core rule
6
6
 
7
- Oh My Second Brain is a convention harness, not a content generator. The user owns the ontology in `vault/.oms/`; agents must use the declared folder axis, frontmatter/property axes, wikilinks, and retrieval lenses before reading or writing notes.
7
+ Actual Obsidian Markdown templates own note shape and body scaffolding. The user-owned ontology remains active: template policy records note/field meaning and policy, while taxonomy records folder/link meaning and placement. `.obsidian/types.json` is read-only type authority; `.oms/types.json` is derived and must never be hand-edited.
8
8
 
9
9
  ## Command mapping
10
10
 
11
- | User intent | Preferred Oh My Second Brain surface |
11
+ | User intent | Preferred surface |
12
12
  |---|---|
13
- | adopt a vault | `oms setup --vault <path>` |
13
+ | inspect and adopt templates | `oms setup --vault <path> --dry-run`, then `--yes --approved-digest <digest>` |
14
14
  | install host integration | `oms install --runtime codex --vault <path> --yes` |
15
- | uninstall host integration | `oms uninstall --runtime codex --yes` |
16
- | validate notes | `$oms-doctor` or `oms doctor --vault <path>` |
17
- | write a vault note | use `$oms-write` / MCP `oms_write` (`create`, `append`, or `update`) |
18
- | retrieve knowledge | use `$oms-search` / MCP `oms_search`, loading full notes only when needed |
15
+ | diagnose or repair | `$oms-doctor` or `oms doctor --vault <path>` |
16
+ | write a note | `$oms-write` / MCP `oms_write` with a stable `templateId` |
17
+ | retrieve knowledge | `$oms-search` / MCP `oms_search`; discover IDs with `op: "templates"` |
19
18
 
20
19
  ## Safety
21
20
 
22
- - Never delete vault notes or `vault/.oms/` during uninstall.
23
- - Capture must stay inside the configured vault and target Markdown files only.
24
- - If required frontmatter is missing, ask for it; do not invent user-owned ontology values.
25
- - Route ambiguous captures to inbox when the ontology cannot decide.
21
+ - Never delete vault notes or `.oms/` during uninstall.
22
+ - Never use direct file tools for vault notes or managed templates.
23
+ - Never invent required values or self-approve a repair digest.
24
+ - `status` and search are read-only; mutation requires a verified target.
@@ -1,18 +1,16 @@
1
- # Oh My Second Brain Convention Shim — Hermes
1
+ # Oh My Second Brain — Hermes
2
2
 
3
- <!-- Add this as a context file in your Hermes session to activate Oh My Second Brain conventions. -->
3
+ This vault uses user-owned template conventions in `.oms/`.
4
4
 
5
- ## Vault Convention (Oh My Second Brain)
5
+ Before vault work:
6
+ - Actual Obsidian `.md` templates own note shape and body scaffolding.
7
+ - `.obsidian/types.json` is read-only type authority.
8
+ - The user-owned ontology remains active: `.oms/template-policy.json` records note/field meaning and policy; `.oms/taxonomy.yaml` records folder/link meaning and placement.
9
+ - `.oms/types.json` is derived and must never be hand-edited.
10
+ - Humans and agents use identical stable `templateId` rules.
6
11
 
7
- This vault is governed by Oh My Second Brain conventions stored in `.oms/`.
12
+ **Write:** Use the `write` skill and MCP `oms_write`; never direct file tools for vault notes or managed templates. Notes use `op: "note"`. Template changes use `op: "template"`, dry-run first, then exact reviewed `approvalDigest`.
8
13
 
9
- **Before working with vault notes:**
10
- - Run `oms doctor` to validate notes against the convention (exits 0, non-blocking).
11
- - Read `.oms/taxonomy.yaml` for folder-to-concept bindings.
12
- - Read `.oms/concepts/*.yaml` for field declarations and lenses.
14
+ **Retrieve:** Use `search`, discover IDs through `op: "templates"`, and filter by template, declared fields, folder, or links.
13
15
 
14
- **Write:** Use the `write` skill. Call MCP `oms_write`. Do not use host Write/Edit for vault `.md` files.
15
-
16
- **Retrieve:** Use the `search` skill or follow the retriever persona — identify purpose, match lens, project lens fields only.
17
-
18
- > **v0 native install:** `oms install --runtime hermes` installs the `write`, `search`, `link`, `distill`, `status`, and `doctor` skills and registers Oh My Second Brain MCP in `~/.hermes/config.yaml`. Use Oh My Second Brain MCP tools for vault operations and CLI commands for lifecycle.
16
+ **Maintain:** `status` is read-only. `doctor` diagnoses and performs explicit repairs. Hermes installs the same seven write, search, link, distill, status, doctor, and tool-less template skills.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oms",
3
- "version": "0.8.3",
3
+ "version": "0.9.0",
4
4
  "description": "Oh My Second Brain convention layer for Obsidian vaults — Hermes skill bundle and MCP adapter.",
5
5
  "_note": "oms install writes ~/.hermes/config.yaml mcp_servers.oms and installs skills under ~/.hermes/skills/knowledge-management/oms/."
6
6
  }
@@ -1,23 +1,24 @@
1
1
  ---
2
2
  name: doctor
3
- description: Diagnose vault convention and index problems, then run explicit repairs.
3
+ description: Diagnose template authority and index problems, then run explicit repairs.
4
4
  mcp_tool: oms_doctor
5
5
  mcp_args:
6
- op: "audit"
6
+ op: "validate"
7
7
  ---
8
8
 
9
9
  # doctor
10
10
 
11
- Diagnose vault problems and perform the requested repair.
12
-
13
- ## Use when
14
-
15
- Use this skill when a vault has convention violations, an unhealthy graph or semantic index, or stale generated state that needs correction. Use `status` instead when inspection alone is required.
11
+ Diagnose vault template and derived-index state, then run only the named repair.
16
12
 
17
13
  ## Usage
18
14
 
19
15
  ```text
20
- /doctor <audit|validate|build-graph|cleanup|sync-embeddings>
16
+ /doctor <validate|regenerate-types|backfill-defaults|audit|build-graph|cleanup|sync-embeddings>
21
17
  ```
22
18
 
23
- `audit` and `validate` inspect notes against their declared concept schemas. `build-graph`, `cleanup`, and `sync-embeddings` are repair operations and may write generated graph or semantic-index state. Review the diagnosis, then invoke only the repair needed.
19
+ - `validate` is read-only. It reports policy/projection/source-signature drift, migration marker state, managed source exclusions, and unresolved legacy notes.
20
+ - `regenerate-types` recomputes the derived `.oms/types.json` from actual templates, policy, taxonomy, and read-only Obsidian types.
21
+ - `backfill-defaults` updates exactly one explicit note with stable template identity while preserving unrelated frontmatter and body bytes.
22
+ - `build-graph`, `cleanup`, and `sync-embeddings` repair derived indexes.
23
+
24
+ Every note/control repair requires a verified target. Run a dry-run, review the receipt, then submit its exact `approvalDigest`; never self-approve or repair all notes implicitly.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: search
3
- description: Retrieve vault knowledge through declared retrieval lenses.
3
+ description: Retrieve vault knowledge through resolved template axes.
4
4
  aliases: [retrieve]
5
5
  mcp_tool: oms_search
6
6
  mcp_args:
@@ -10,11 +10,7 @@ mcp_args:
10
10
 
11
11
  # search
12
12
 
13
- Retrieve notes and declared fields for a vault question. A lens is a vault-declared retrieval view, not an ad-hoc query filter: it identifies which fields matter for a purpose such as synthesis or audit.
14
-
15
- ## Use when
16
-
17
- Use this skill to find and assemble relevant vault knowledge without changing the vault.
13
+ Retrieve vault knowledge without changing the vault.
18
14
 
19
15
  ## Usage
20
16
 
@@ -22,20 +18,13 @@ Use this skill to find and assemble relevant vault knowledge without changing th
22
18
  /search <query>
23
19
  ```
24
20
 
25
- Choose the declared lens that matches the request, return only that lens's fields, and group results by concept or folder. Search may combine the live note, frontmatter, and wikilink graph with available semantic candidates; graph results remain available when the semantic index is unavailable.
26
-
27
- ## Axes
28
-
29
- `query` scores text, so it reaches a note only where the words are actually written. A request that names a kind — a person, a meeting, a project — belongs on an axis instead: an entity note is titled with its subject and then seldom repeats it, which is precisely what text scoring cannot find.
30
-
31
- Put the request on an axis whenever it names a kind, a declared property, or a relationship:
32
-
33
- - `axes.field.<key>` filters on a frontmatter property declared by the vault contract. The value may be a scalar, a list of scalars (matching any of them), or a predicate object — `in`, `contains`, `containsAll`, `between`, `gte`/`gt`/`lte`/`lt`, `from`/`to`.
34
- - `axes.folder` scopes to a top-level folder. It takes the folder's own name, not the concept name derived from it.
35
- - `axes.link` follows the wikilink graph to reach the notes that reference an entity rather than the one describing it. It matches on filename alone: a bare title is enough, and a surrounding folder path or `.md` extension is ignored rather than narrowing the match.
21
+ Plain `query` is projection-independent lexical retrieval and remains available when no embedding provider is configured. Template-managed source files are never returned as notes.
36
22
 
37
- Axes intersect, so a kind and a folder can be combined to narrow a single query. An axis filter is also a complete query by itself: omit `query` to enumerate a whole kind instead of searching inside it. Axis queries match lexically, so pair them with `query` or a `lex` sub-query; asking for `vec` or `hyde` retrieval alongside an axis returns nothing and says so.
23
+ Use `oms_search { op: "templates" }` to discover stable template IDs and declared axes. Typed queries use the same derived projection as writes:
38
24
 
39
- Discover axes rather than guessing them. A successful query returns `facets` — the axis keys this vault actually uses, each with its observed values and their counts — and `op: "concepts"` reports the fields every concept declares. Which properties exist is a per-vault contract, so read it before filtering on it.
25
+ - `axes.template` selects one stable template identity.
26
+ - `axes.field.<key>` filters a field declared by that template; values may be scalars, scalar lists, or supported predicate objects.
27
+ - `axes.folder` scopes physical placement.
28
+ - `axes.link` follows observed wikilinks.
40
29
 
41
- A rejected axis is not a failed call. The response returns `available: false` with a `reason` naming the key it refused, and comes back with `hits` and `facets` both empty — so recover by querying again without that axis and reading the facets that call returns, never by retrying the same guess. `concept` is derived from a note's folder rather than stored as a property, so scope it with `axes.folder` or with `op: "context"` — `axes.field.concept` is always refused.
30
+ Axes intersect. They require a current `.oms/types.json` projection and fail loudly on an undeclared field or stale signature; remove the typed axis or run template diagnosis rather than guessing. Vector or HyDE retrieval also fails loudly without configured embedding provider and model.
@@ -1,22 +1,16 @@
1
1
  ---
2
2
  name: status
3
- description: Report read-only vault health, statistics, and index state.
3
+ description: Report read-only template, graph, and semantic-index health.
4
4
  mcp_tool: oms_status
5
5
  mcp_args: {}
6
6
  ---
7
7
 
8
8
  # status
9
9
 
10
- Report the current state of a vault without changing it.
11
-
12
- ## Use when
13
-
14
- Use this skill to inspect vault health and statistics before deciding whether maintenance is needed.
15
-
16
- ## Usage
10
+ Report vault health without changing files.
17
11
 
18
12
  ```text
19
13
  /status
20
14
  ```
21
15
 
22
- Report note counts, semantic-index availability and freshness, and graph-cache status. Status is observational only: it never rebuilds an index, repairs notes, or writes vault files.
16
+ Show resolved template count, current projection/input signature, managed template-source exclusions, template diagnosis state, and graph/semantic-index availability. A malformed or missing projection is reported as invalid with an actionable doctor operation. Status never regenerates controls, rebuilds caches, repairs notes, or writes the vault.
@@ -0,0 +1,29 @@
1
+ ---
2
+ name: template
3
+ description: Design, migrate, and safely apply vault-resident Obsidian templates through the derived OMS contract.
4
+ ---
5
+
6
+ # template
7
+
8
+ Turn the user's natural-language note design into an actual Obsidian Markdown template and the smallest matching policy change. People and agents follow the same template contract; never introduce personas.
9
+
10
+ ## Authority
11
+
12
+ - The actual `.md` template owns frontmatter order/default scaffolding and body shape.
13
+ - `.obsidian/types.json` is read-only property-type authority.
14
+ - The user-owned ontology remains active: `.oms/template-policy.json` owns note/field `intent` plus BaseContract inheritance, requiredness, formats, allowed values, naming, stable identity, and bindings.
15
+ - `.oms/taxonomy.yaml` owns folder/link `intent`, note placement, and global axes.
16
+ - `.oms/types.json` is derived state. Never edit it directly.
17
+
18
+ Use an existing stable `templateId` when updating or moving a template. A path or digest change never creates a new identity. New OMS-managed templates default to `<templateFolder>/<templateId>.md`; registered existing templates keep their explicitly verified `sourcePath`.
19
+
20
+ ## Workflow
21
+
22
+ 1. Read `oms_search { op: "templates" }` and the user's requested shape. Do not guess existing IDs or fields.
23
+ 2. Draft the exact Markdown and policy/taxonomy intent. Preserve unknown frontmatter, policy extensions, body bytes, and Obsidian property types.
24
+ 3. Call `oms_write { op: "template", ..., dryRun: true }` for create, update, reclassify, or relocate-folder.
25
+ 4. Show the proposal, paths, diagnostics, and `approvalDigest` to the user.
26
+ 5. Apply only after the caller explicitly approves that exact digest. Submit the same request with `dryRun: false` and `approvedDigest`.
27
+ 6. Report the server-verified receipt and postconditions.
28
+
29
+ Reject unsupported expressions, unsafe paths, unresolved legacy mappings, stale signatures, and identity changes. Never self-approve, silently fall back to a legacy Concept reader, or directly mutate managed template/control files.
@@ -1,30 +1,36 @@
1
1
  ---
2
2
  name: write
3
- description: Write a vault note through the Oh My Second Brain kernel contract.
3
+ description: Write vault notes and manage Obsidian templates through the guarded template contract.
4
4
  mcp_tool: oms_write
5
5
  mcp_args:
6
- op: "create"
7
- notePath: "$1"
6
+ op: "note"
7
+ mode: "create"
8
+ templateId: "$1"
8
9
  body: "$2"
9
10
  ---
10
11
 
11
12
  # write
12
13
 
13
- Write, append to, or update a vault note through MCP `oms_write`. Do not use host Write/Edit for vault `.md` files.
14
+ Use MCP `oms_write` for every vault-note or managed-template mutation. Do not use host Write/Edit for vault Markdown.
14
15
 
15
- ## Use when
16
+ ## Notes
16
17
 
17
- Use this skill for every vault-note mutation.
18
-
19
- ## Usage
18
+ Translate the user's natural-language note kind into a stable ID returned by `oms_search { op: "templates" }`; never guess an ID.
20
19
 
21
20
  ```text
22
- /write <create|append|update> <vault-relative-note-path> [body]
21
+ /write <template-id> [body]
23
22
  ```
24
23
 
25
- Use `op` with `create`, `append`, or `update`. The kernel owns `.oms` and returns one status:
24
+ For create, call `op: "note"` with `mode`, `templateId`, and body/frontmatter; placement and naming derive the path. For append/update, pass `notePath` without `templateId`; OMS resolves the persisted `frontmatter.template`. The actual Obsidian template supplies frontmatter shape and body scaffolding; OMS applies the vault-wide base defaults and policy.
25
+
26
+ ## Templates
27
+
28
+ Template creation, updates, reclassification, and template-folder relocation use `op: "template"` with `mode: "create" | "update" | "reclassify" | "relocate-folder"`.
29
+
30
+ 1. Submit `dryRun: true` with current input and source signatures.
31
+ 2. Show the resulting proposal and `approvalDigest`.
32
+ 3. Apply only with `dryRun: false` and that exact caller-approved digest.
33
+
34
+ Never self-approve, hand-edit the derived `.oms/types.json`, or directly edit a managed template.
26
35
 
27
- - `ask` — fill the missing or invalid fields and call `write` again
28
- - `inbox` — tell the user; do not invent a folder
29
- - `written` — done
30
- - `rejected` — fix `violations` or `reason` and call `write` again
36
+ Responses are `ask`, `written`, or `rejected`. Resolve named violations and retry; never invent missing required values.
package/core/AGENTS.md CHANGED
@@ -1,112 +1,49 @@
1
1
  # Oh My Second Brain Vault Convention — SSOT for Host Agents
2
2
 
3
- This file is the authoritative reference a host agent (Claude Code, Codex, Hermes, or any
4
- other) reads when working inside a vault managed by Oh My Second Brain. It explains the convention model so
5
- the agent understands *why* knowledge is organized the way it is — not just *where*.
6
-
7
- ---
8
-
9
- ## What is a Convention?
10
-
11
- An Oh My Second Brain **convention** is declarative semantic data the **user owns**. It lives in
12
- `vault/.oms/` (copied there by `oms setup`; Oh My Second Brain ships the defaults in `core/ontology/`).
13
- The user edits it freely. Oh My Second Brain enforces whatever is declared — it does not impose structure.
14
-
15
- The convention has four building blocks:
16
-
17
- ---
18
-
19
- ## 1. Concept
20
-
21
- A **concept** is a note-type. Each concept carries:
22
-
23
- | Field | Purpose |
24
- |----------|---------|
25
- | `concept` | Identifier (e.g. `literature`). |
26
- | `intent` | One sentence: *what this knowledge is FOR.* |
27
- | `folder` | The vault folder where notes of this type live. |
28
- | `fields` | List of frontmatter keys the concept declares. |
29
- | `lenses` | Named retrieval views (optional). |
30
-
31
- > "The folder itself is information — every folder declares its intent."
32
- > Rather than pattern-matching a directory listing, a host agent reads the declared `intent`
33
- > to understand *why* knowledge lives in a given folder.
34
-
35
- ---
36
-
37
- ## 2. Field
38
-
39
- A **field** is one frontmatter key — the smallest unit of convention. Each field declares:
40
-
41
- | Property | Meaning |
42
- |------------|---------|
43
- | `name` | The frontmatter key (kebab-case, e.g. `source-url`). |
44
- | `type` | One of `string`, `url`, `date`, `list`, `number`, `boolean`. |
45
- | `required` | Whether the key must be present and non-empty. |
46
- | `intent` | Semantic purpose: *what this field is FOR.* |
47
- | `normalize` | Optional: `kebab`, `lower`, or `trim` — applied at validation. |
48
- | `immutable` | Advisory: once written, should not change (v0: no-op, forward-compat). |
49
- | `enum` | Optional closed vocabulary for string fields; values outside it are lint violations. |
50
-
51
- Users grow their convention field-by-field. There is no mandatory field list.
52
-
53
- ---
54
-
55
- ## 3. Lens
56
-
57
- A **lens** is a pre-declared, named retrieval view. It is NOT a query filter — it is a
58
- concept's declaration of which fields matter for a specific retrieval purpose.
59
-
60
- Example: a `synthesis` lens on `literature` surfaces `title` and `source-url`, because those
61
- are the fields needed when synthesizing across references. A host agent uses the active lens
62
- to know which frontmatter to surface during retrieval.
63
-
64
- ---
65
-
66
- ## 4. Taxonomy
67
-
68
- The **taxonomy** binds folders to concepts and gives each folder a declared `intent`.
69
-
70
- ```yaml
71
- version: 1
72
- folders:
73
- references:
74
- intent: "Processed external sources the user has read and synthesized."
75
- concept: literature
76
- inbox:
77
- intent: "Unprocessed captures awaiting triage."
78
- concept: inbox
79
- ```
80
-
81
- A folder may bind to one concept, multiple concepts (list), or `null` (not yet assigned). A folder binding may set `agentWritable: true`; paired with `routingLawStrict: true`, notes in that folder must carry `created_by`. Top-level `exclude` entries are vault-relative globs skipped by audit/lint scans.
82
-
83
- ---
84
-
85
- ## Enforcement Posture
86
-
87
- | Setting | Value | Meaning |
88
- |---------|-------|---------|
89
- | `onViolation` | `warn` | Violations are logged but never block writes (v0 is non-blocking). |
90
- | `additionalProperties` | `preserve` | Frontmatter keys not declared in the concept are left untouched. |
91
-
92
- Oh My Second Brain enforces what the user declared; it does not touch anything else.
93
-
94
- ---
3
+ This file defines the end-user vault convention for host agents (Claude Code, Codex,
4
+ Hermes, and others). All convention data and its meaning remain vault-owned.
5
+
6
+ ## Four Separate Authorities
7
+
8
+ These authorities do not overlap:
9
+
10
+ 1. **Markdown templates — shape and body.** Actual vault Markdown templates own
11
+ frontmatter-key scaffolding, default literals, and note body shape. Do not infer
12
+ semantic meaning from a template's defaults.
13
+ 2. **Ontology policy — note and field meaning.** `.oms/template-policy.json` owns
14
+ `intent` for notes and frontmatter fields. It is the note/field portion of the
15
+ semantic ontology, not template shape or type authority.
16
+ 3. **Taxonomy — placement and folder/link ontology.** `.oms/taxonomy.yaml` owns note
17
+ placement and the folder/link portion of the semantic ontology, expressed through
18
+ folder and link `intent`. Authored folder intents surface on the derived
19
+ `folder-ontology` axis.
20
+ 4. **Obsidian types — type authority.** `.obsidian/types.json` is the read-only type
21
+ authority. `.oms/types.json` is derived output, never an independent authority.
22
+
23
+ ## Operating Boundaries
24
+
25
+ - Treat the verified target note and its applicable vault template as the write
26
+ boundary. Write only after verifying that target; never use a destination merely
27
+ because a template default suggests it.
28
+ - Read ontology and taxonomy to understand declared meaning and placement. Do not
29
+ overwrite them as a side effect of writing a note.
30
+ - Read `.obsidian/types.json` without modifying it. Do not edit derived
31
+ `.oms/types.json` as a source of truth.
32
+ - Preserve unknown frontmatter fields and their values. The convention constrains only
33
+ what the user declared.
95
34
 
96
35
  ## User Ownership
97
36
 
98
- 1. `oms setup` scans the vault's existing top-level folders and creates `vault/.oms/`.
99
- 2. It copies shipped default concepts into `vault/.oms/concepts/` and writes
100
- `vault/.oms/taxonomy.yaml` — seeded with the user's real folders.
101
- 3. The user fills in `intent` values and adds or removes fields/lenses freely.
102
- 4. Oh My Second Brain never imposes a folder structure; it adopts what already exists.
103
-
104
- ---
37
+ The user owns templates, ontology, taxonomy, and type definitions in the vault.
38
+ Oh My Second Brain applies those declarations without making them sticky: it does not
39
+ impose a folder structure, retain obsolete declarations, or replace user-authored
40
+ meaning. The user-owned semantic ontology remains active across ontology policy and
41
+ taxonomy; it is separate from template shape and type authority.
105
42
 
106
43
  ## Quick Reference for Host Agents
107
44
 
108
- - To understand a note: look up its folder in the taxonomy → read the `concept.intent`.
109
- - To validate frontmatter: load the concept's `fields`; check `required`, `type`, and any `enum`.
110
- - To retrieve knowledge: apply the relevant `lens` to surface the fields that matter.
111
- - To audit a vault: honor taxonomy `exclude` globs and routing-law flags.
112
- - When in doubt, preserve: `additionalProperties: preserve` means unknown keys are safe.
45
+ - For note shape and default values, read the applicable vault Markdown template.
46
+ - For note or field ontology, read `intent` in `.oms/template-policy.json`.
47
+ - For destination and folder/link ontology, read `.oms/taxonomy.yaml`.
48
+ - For types, read `.obsidian/types.json`; treat `.oms/types.json` only as derived data.
49
+ - When in doubt, preserve user-authored content and unknown frontmatter.
@@ -7,10 +7,12 @@ export interface ParsedCliArgs {
7
7
  readonly vault: string;
8
8
  readonly vaultExplicit: boolean;
9
9
  readonly yes: boolean;
10
+ readonly approvedDigest?: string;
11
+ readonly templateFolder?: string;
12
+ readonly maxPerTemplate?: number;
10
13
  /** linkify: opt into rewriting notes in place (still requires `--yes`). */
11
14
  readonly apply: boolean;
12
15
  readonly installClaude: boolean;
13
- readonly suggestFields: boolean;
14
16
  readonly runtime: RuntimeSelection | undefined;
15
17
  readonly dryRun: boolean;
16
18
  readonly executeExternal: boolean;
@@ -19,7 +21,6 @@ export interface ParsedCliArgs {
19
21
  readonly agentVault: string | undefined;
20
22
  readonly verbose: boolean;
21
23
  readonly json: boolean;
22
- readonly maxPerConcept: number | undefined;
23
24
  readonly folders: readonly string[];
24
25
  readonly conventionNote: boolean;
25
26
  readonly embeddingDescriptorPath: string | undefined;
package/dist/cli/args.js CHANGED
@@ -16,9 +16,11 @@ export function parseCliArgs(argv, cwd = process.cwd()) {
16
16
  let vault = cwd;
17
17
  let vaultExplicit = false;
18
18
  let yes = false;
19
+ let approvedDigest;
20
+ let templateFolder;
21
+ let maxPerTemplate;
19
22
  let apply = false;
20
23
  let installClaude = false;
21
- let suggestFields = false;
22
24
  let runtime;
23
25
  let dryRun = false;
24
26
  let executeExternal = false;
@@ -27,7 +29,6 @@ export function parseCliArgs(argv, cwd = process.cwd()) {
27
29
  let agentVault;
28
30
  let verbose = false;
29
31
  let json = false;
30
- let maxPerConcept;
31
32
  const folders = [];
32
33
  let conventionNote = true;
33
34
  let embeddingDescriptorPath;
@@ -45,15 +46,34 @@ export function parseCliArgs(argv, cwd = process.cwd()) {
45
46
  else if (arg === "--yes") {
46
47
  yes = true;
47
48
  }
49
+ else if (arg === "--approved-digest") {
50
+ if (next === undefined || next.startsWith("--")) {
51
+ return parsedArgsWithError("[oms] Missing value for --approved-digest.");
52
+ }
53
+ approvedDigest = next;
54
+ i++;
55
+ }
56
+ else if (arg === "--template-folder") {
57
+ if (next === undefined || next.startsWith("--")) {
58
+ return parsedArgsWithError("[oms] Missing value for --template-folder.");
59
+ }
60
+ templateFolder = next;
61
+ i++;
62
+ }
63
+ else if (arg === "--max-per-template") {
64
+ const parsed = Number.parseInt(next ?? "", 10);
65
+ if (next === undefined || !Number.isFinite(parsed) || parsed <= 0 || `${parsed}` !== next) {
66
+ return parsedArgsWithError(`[oms] --max-per-template must be a positive integer.`);
67
+ }
68
+ maxPerTemplate = parsed;
69
+ i++;
70
+ }
48
71
  else if (arg === "--apply") {
49
72
  apply = true;
50
73
  }
51
74
  else if (arg === "--install-claude") {
52
75
  installClaude = true;
53
76
  }
54
- else if (arg === "--suggest-fields") {
55
- suggestFields = true;
56
- }
57
77
  else if (arg === "--check") {
58
78
  checkUpdate = true;
59
79
  }
@@ -90,14 +110,6 @@ export function parseCliArgs(argv, cwd = process.cwd()) {
90
110
  else if (arg === "--json") {
91
111
  json = true;
92
112
  }
93
- else if (arg === "--max" && next) {
94
- const parsed = Number.parseInt(next, 10);
95
- if (!Number.isFinite(parsed) || parsed <= 0) {
96
- return parsedArgsWithError(`[oms] Unsupported --max value: ${next}`);
97
- }
98
- maxPerConcept = parsed;
99
- i++;
100
- }
101
113
  else if (arg === "--folder" && next) {
102
114
  folders.push(next);
103
115
  i++;
@@ -124,9 +136,11 @@ export function parseCliArgs(argv, cwd = process.cwd()) {
124
136
  vault,
125
137
  vaultExplicit,
126
138
  yes,
139
+ approvedDigest,
140
+ templateFolder,
141
+ maxPerTemplate,
127
142
  apply,
128
143
  installClaude,
129
- suggestFields,
130
144
  runtime,
131
145
  dryRun,
132
146
  executeExternal,
@@ -135,7 +149,6 @@ export function parseCliArgs(argv, cwd = process.cwd()) {
135
149
  agentVault,
136
150
  verbose,
137
151
  json,
138
- maxPerConcept,
139
152
  folders,
140
153
  conventionNote,
141
154
  embeddingDescriptorPath,
@@ -150,9 +163,11 @@ export function parseCliArgs(argv, cwd = process.cwd()) {
150
163
  vault,
151
164
  vaultExplicit,
152
165
  yes,
166
+ approvedDigest,
167
+ templateFolder,
168
+ maxPerTemplate,
153
169
  apply,
154
170
  installClaude,
155
- suggestFields,
156
171
  runtime,
157
172
  dryRun,
158
173
  executeExternal,
@@ -161,7 +176,6 @@ export function parseCliArgs(argv, cwd = process.cwd()) {
161
176
  agentVault,
162
177
  verbose,
163
178
  json,
164
- maxPerConcept,
165
179
  folders,
166
180
  conventionNote,
167
181
  embeddingDescriptorPath,
@@ -1 +1 @@
1
- {"version":3,"file":"args.js","sourceRoot":"","sources":["../../src/cli/args.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,sBAAsB,EAAE,MAAM,uCAAuC,CAAC;AAG/E,MAAM,OAAO,gBAAiB,SAAQ,KAAK;IACzC,YAAY,OAAe;QACzB,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,IAAI,CAAC,IAAI,GAAG,kBAAkB,CAAC;IACjC,CAAC;CACF;AA8BD,MAAM,UAA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,KAAK,wBAAwB,IAAI,IAAI,EAAE,CAAC;YACpD,uBAAuB,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC;YAClD,CAAC,EAAE,CAAC;QACN,CAAC;aAAM,IAAI,GAAG,KAAK,wBAAwB,EAAE,CAAC;YAC5C,kBAAkB,GAAG,IAAI,CAAC;QAC5B,CAAC;aAAM,IAAI,GAAG,KAAK,qBAAqB,EAAE,CAAC;YACzC,gBAAgB,GAAG,IAAI,CAAC;QAC1B,CAAC;aAAM,IAAI,GAAG,KAAK,SAAS,EAAE,CAAC;YAC7B,YAAY,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QACzB,CAAC;IACH,CAAC;IAED,OAAO;QACL,OAAO;QACP,KAAK;QACL,aAAa;QACb,GAAG;QACH,KAAK;QACL,aAAa;QACb,aAAa;QACb,OAAO;QACP,MAAM;QACN,eAAe;QACf,WAAW;QACX,SAAS;QACT,UAAU;QACV,OAAO;QACP,IAAI;QACJ,aAAa;QACb,OAAO;QACP,cAAc;QACd,uBAAuB;QACvB,kBAAkB;QAClB,gBAAgB;QAChB,YAAY;QACZ,KAAK,EAAE,SAAS;KACjB,CAAC;IAEF,SAAS,mBAAmB,CAAC,OAAe;QAC1C,OAAO;YACL,OAAO;YACP,KAAK;YACL,aAAa;YACb,GAAG;YACH,KAAK;YACL,aAAa;YACb,aAAa;YACb,OAAO;YACP,MAAM;YACN,eAAe;YACf,WAAW;YACX,SAAS;YACT,UAAU;YACV,OAAO;YACP,IAAI;YACJ,aAAa;YACb,OAAO;YACP,cAAc;YACd,uBAAuB;YACvB,kBAAkB;YAClB,gBAAgB;YAChB,YAAY;YACZ,KAAK,EAAE,IAAI,gBAAgB,CAAC,OAAO,CAAC;SACrC,CAAC;IACJ,CAAC;AACH,CAAC"}
1
+ {"version":3,"file":"args.js","sourceRoot":"","sources":["../../src/cli/args.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC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d,cAAc;QACd,KAAK;QACL,aAAa;QACb,OAAO;QACP,MAAM;QACN,eAAe;QACf,WAAW;QACX,SAAS;QACT,UAAU;QACV,OAAO;QACP,IAAI;QACJ,OAAO;QACP,cAAc;QACd,uBAAuB;QACvB,kBAAkB;QAClB,gBAAgB;QAChB,YAAY;QACZ,KAAK,EAAE,SAAS;KACjB,CAAC;IAEF,SAAS,mBAAmB,CAAC,OAAe;QAC1C,OAAO;YACL,OAAO;YACP,KAAK;YACL,aAAa;YACb,GAAG;YACH,cAAc;YACd,cAAc;YACd,cAAc;YACd,KAAK;YACL,aAAa;YACX,OAAO;YACT,MAAM;YACN,eAAe;YACf,WAAW;YACX,SAAS;YACT,UAAU;YACV,OAAO;YACP,IAAI;YACF,OAAO;YACT,cAAc;YACd,uBAAuB;YACvB,kBAAkB;YAClB,gBAAgB;YAChB,YAAY;YACZ,KAAK,EAAE,IAAI,gBAAgB,CAAC,OAAO,CAAC;SACrC,CAAC;IACJ,CAAC;AACH,CAAC"}
@@ -2,5 +2,4 @@ export declare function runAudit(opts: {
2
2
  readonly vault: string;
3
3
  readonly json?: boolean;
4
4
  readonly folder?: string;
5
- readonly suggestFields?: boolean;
6
5
  }): Promise<number>;