oh-my-second-brain 0.1.5 → 0.1.7

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 (61) hide show
  1. package/adapters/README.md +6 -6
  2. package/adapters/claude-code/.claude-plugin/plugin.json +1 -1
  3. package/adapters/claude-code/CLAUDE.md +2 -2
  4. package/adapters/claude-code/skills/capture/SKILL.md +1 -1
  5. package/adapters/claude-code/skills/define/SKILL.md +4 -4
  6. package/adapters/claude-code/skills/doctor/SKILL.md +3 -3
  7. package/adapters/claude-code/skills/retrieve/SKILL.md +14 -9
  8. package/adapters/claude-code/skills/setup/SKILL.md +12 -11
  9. package/adapters/claude-code/skills/uninstall/SKILL.md +4 -4
  10. package/adapters/codex/.codex-plugin/plugin.json +1 -1
  11. package/adapters/codex/.mcp.json +1 -3
  12. package/adapters/codex/AGENTS.md +1 -1
  13. package/adapters/codex/rules/oms.md +5 -5
  14. package/adapters/codex/skills/oms-doctor/SKILL.md +1 -1
  15. package/adapters/codex/skills/oms-install/SKILL.md +1 -1
  16. package/adapters/codex/skills/oms-retrieve/SKILL.md +9 -1
  17. package/adapters/codex/skills/oms-setup/SKILL.md +2 -2
  18. package/adapters/codex/skills/oms-uninstall/SKILL.md +2 -2
  19. package/adapters/hermes/SOUL.md +2 -2
  20. package/adapters/hermes/manifest.json +1 -1
  21. package/adapters/hermes/skills/doctor/SKILL.md +1 -1
  22. package/adapters/hermes/skills/install/SKILL.md +1 -1
  23. package/adapters/hermes/skills/retrieve/SKILL.md +9 -1
  24. package/adapters/hermes/skills/setup/SKILL.md +2 -2
  25. package/adapters/hermes/skills/uninstall/SKILL.md +2 -2
  26. package/core/agents/librarian.md +1 -1
  27. package/core/skills/capture/SKILL.md +9 -7
  28. package/core/skills/define/SKILL.md +2 -2
  29. package/core/skills/doctor/SKILL.md +2 -2
  30. package/core/skills/retrieve/SKILL.md +17 -5
  31. package/core/skills/setup/SKILL.md +3 -3
  32. package/core/skills/uninstall/SKILL.md +4 -4
  33. package/dist/cli/oms.js +15 -31
  34. package/dist/cli/oms.js.map +1 -1
  35. package/dist/conventions/frontmatter.d.ts +11 -0
  36. package/dist/conventions/frontmatter.js +56 -6
  37. package/dist/conventions/frontmatter.js.map +1 -1
  38. package/dist/graph/explore.d.ts +34 -0
  39. package/dist/graph/explore.js +181 -0
  40. package/dist/graph/explore.js.map +1 -0
  41. package/dist/index.d.ts +3 -0
  42. package/dist/index.js +3 -0
  43. package/dist/index.js.map +1 -1
  44. package/dist/install/hosts.js +4 -8
  45. package/dist/install/hosts.js.map +1 -1
  46. package/dist/mcp/server.js +69 -8
  47. package/dist/mcp/server.js.map +1 -1
  48. package/dist/retrieve/morning.d.ts +36 -0
  49. package/dist/retrieve/morning.js +73 -0
  50. package/dist/retrieve/morning.js.map +1 -0
  51. package/dist/runtime/assets.d.ts +7 -0
  52. package/dist/runtime/assets.js +13 -0
  53. package/dist/runtime/assets.js.map +1 -0
  54. package/dist/search/qmd.d.ts +59 -0
  55. package/dist/search/qmd.js +141 -0
  56. package/dist/search/qmd.js.map +1 -0
  57. package/docs/install.md +19 -20
  58. package/docs/release.md +5 -1
  59. package/package.json +5 -4
  60. package/scripts/install.sh +8 -5
  61. package/scripts/uninstall.sh +6 -3
@@ -43,7 +43,7 @@ adapters/<host>/
43
43
 
44
44
  ### claude-code (REAL installable v0)
45
45
 
46
- Release contract: the npm tarball must include `adapters/claude-code/` because `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup --install-claude` prints a packaged adapter path for `claude plugin install`.
46
+ Release contract: the npm tarball must include `adapters/claude-code/` because `oms setup --install-claude` prints a packaged adapter path for `claude plugin install`.
47
47
 
48
48
  - **Manifest**: `.claude-plugin/plugin.json`
49
49
  - Schema: `{ name, version, description, author, license, keywords, skills: string[] }`
@@ -80,11 +80,11 @@ contract validation, retrieve, graph/status, and gated capture tools.
80
80
  All three hosts natively support MCP (`.mcp.json` for claude-code and codex; "any MCP server" for Hermes).
81
81
  In the current repository, `src/mcp/server.ts` starts a real stdio MCP server via `oms mcp`.
82
82
 
83
- The MCP server currently exposes status/read/cache/capture tools:
83
+ The MCP server currently exposes status/read/cache/retrieve/capture tools:
84
84
  `oms_graph_status`, `oms_graph_build`, `oms_list_concepts`,
85
- `oms_retrieve_by_axis`, `oms_lazy_load_note`, `oms_validate_contract`,
86
- `oms_capture_prepare`, and `oms_capture_commit`.
87
- Capture commit is gated by path-safety, vault-confinement, and contract validation. The CLI (`npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup`, `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install`, `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall`, `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor`) remains the real surface for lifecycle commands.
85
+ `oms_retrieve_context`, `oms_retrieve_by_axis`, `oms_lazy_load_note`,
86
+ `oms_validate_contract`, `oms_capture_prepare`, and `oms_capture_commit`.
87
+ Capture commit is gated by path-safety, vault-confinement, and contract validation. The CLI (`oms setup`, `oms install`, `oms uninstall`, `oms doctor`) remains the real surface for lifecycle commands.
88
88
 
89
89
  ---
90
90
 
@@ -93,6 +93,6 @@ Capture commit is gated by path-safety, vault-confinement, and contract validati
93
93
  1. Create `adapters/<host>/`.
94
94
  2. Write the host-specific manifest in the correct subdirectory and schema.
95
95
  3. Write the convention-file shim (`CLAUDE.md` / `AGENTS.md` / `SOUL.md` / whatever the host uses).
96
- 4. Write skill wrappers that shell out to `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz <verb>` (for lifecycle) or call the MCP server (for capture/retrieve).
96
+ 4. Write skill wrappers that shell out to `oms <verb>` (for lifecycle) or call the MCP server (for capture/retrieve).
97
97
  5. Document the host's structural differences in this table.
98
98
  6. Do **not** modify `core/` or add host-specific logic to shared code.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oms",
3
- "version": "0.1.5",
3
+ "version": "0.1.7",
4
4
  "description": "Oh My Second Brain convention layer for Obsidian vaults \u2014 capture, retrieve, and validate knowledge under a declared semantic convention.",
5
5
  "author": {
6
6
  "name": "gobeumsu"
@@ -8,7 +8,7 @@ This vault is governed by Oh My Second Brain conventions stored in `.oms/`.
8
8
  All knowledge capture and retrieval must follow the declared semantic convention.
9
9
 
10
10
  **Before working with vault notes:**
11
- - Run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` to validate existing notes against the convention (exits 0, non-blocking).
11
+ - Run `oms doctor` to validate existing notes against the convention (exits 0, non-blocking).
12
12
  - Read `.oms/taxonomy.yaml` to understand which folders hold which concepts.
13
13
  - Read `.oms/concepts/*.yaml` to understand field requirements and lenses.
14
14
 
@@ -23,4 +23,4 @@ All knowledge capture and retrieval must follow the declared semantic convention
23
23
  - Return only the fields the lens specifies — do not dump full frontmatter.
24
24
 
25
25
  **Convention violations are warnings, not errors (v0).**
26
- `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` always exits 0. Fix violations incrementally.
26
+ `oms doctor` always exits 0. Fix violations incrementally.
@@ -27,7 +27,7 @@ after prepare returns `ready` or the user has supplied missing fields.
27
27
  5. If required fields are missing, ask for them; do not write.
28
28
  6. If placement is ambiguous, route to inbox.
29
29
  7. Commit only through `oms_capture_commit` (`create` or `append`).
30
- 8. Shell out: `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` (non-blocking, exits 0) to confirm the note is clean.
30
+ 8. Shell out: `oms doctor` (non-blocking, exits 0) to confirm the note is clean.
31
31
 
32
32
  ## Example
33
33
 
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: oms-define
3
- description: Grow the vault convention by adding a metadata field to a concept. Entry point is npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz define (roadmap).
3
+ description: Grow the vault convention by adding a metadata field to a concept. Entry point is oms define (roadmap).
4
4
  ---
5
5
 
6
6
  # Skill: oms-define (Claude Code)
@@ -19,7 +19,7 @@ Each frontmatter key is a unit of convention with a declared `intent`, type, and
19
19
  Intended to shell out to:
20
20
 
21
21
  ```bash
22
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz define
22
+ oms define
23
23
  ```
24
24
 
25
25
  **Roadmap note:** The `oms define` interactive runtime is not yet implemented in v0.
@@ -34,7 +34,7 @@ Today this skill guides you through the same steps manually (agent-guided).
34
34
  5. Choose **required**: yes / no.
35
35
  6. Optionally set **normalize** (e.g. `lowercase`) or **immutable** (lock after creation).
36
36
  7. Append the entry to `vault/.oms/concepts/<concept>.yaml`.
37
- 8. Run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` to validate existing notes against the updated schema.
37
+ 8. Run `oms doctor` to validate existing notes against the updated schema.
38
38
 
39
39
  ## YAML snippet to append
40
40
 
@@ -48,4 +48,4 @@ fields:
48
48
 
49
49
  ## When the runtime ships
50
50
 
51
- `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz define` will run the same Q&A interactively and write the YAML for you.
51
+ `oms define` will run the same Q&A interactively and write the YAML for you.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: oms-doctor
3
- description: Validate vault notes against the Oh My Second Brain convention by running npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor.
3
+ description: Validate vault notes against the Oh My Second Brain convention by running oms doctor.
4
4
  ---
5
5
 
6
6
  # Skill: oms-doctor (Claude Code)
@@ -19,7 +19,7 @@ This skill is **REAL in v0** — it shells out to the fully-implemented CLI.
19
19
  Shells out to:
20
20
 
21
21
  ```bash
22
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor [--vault <path>]
22
+ oms doctor [--vault <path>]
23
23
  ```
24
24
 
25
25
  The CLI will:
@@ -39,7 +39,7 @@ The CLI will:
39
39
  ## Example
40
40
 
41
41
  ```bash
42
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor --vault ~/Documents/MyVault
42
+ oms doctor --vault ~/Documents/MyVault
43
43
  ```
44
44
 
45
45
  ## Sample output
@@ -18,21 +18,25 @@ Surface the right notes and fields for a given purpose using the vault's declare
18
18
  Conceptually shells out to:
19
19
 
20
20
  ```bash
21
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz retrieve
21
+ oms retrieve
22
22
  ```
23
23
 
24
- **Runtime note:** Retrieval is available through MCP tools (`oms_retrieve_by_axis`
25
- and `oms_lazy_load_note`). This skill still guides the agent on intent and
26
- output shaping.
24
+ **Runtime note:** Retrieval is available through MCP tools. Prefer
25
+ `oms_retrieve_context` for live graph + qmd context retrieval, then
26
+ `oms_lazy_load_note` after selecting candidate notes. `oms_retrieve_by_axis`
27
+ remains available for legacy cache-backed axis retrieval.
27
28
 
28
29
  ## Agent-guided steps (v0)
29
30
 
30
31
  1. Clarify the user's **retrieval purpose** (synthesize, audit, plan, review, etc.).
31
32
  2. Narrow by declared **folder/concept/property/wikilink axes** where possible.
32
33
  3. Match the purpose to a declared **retrieval view** (`lenses` in YAML) in `vault/.oms/concepts/*.yaml`.
33
- 4. Scan notes in the candidate concept/folder set.
34
- 5. For each note, return the retrieval-view fields and lazy-load body only when needed.
35
- 6. Return results grouped by concept/folder with retrieval-view frontmatter.
34
+ 4. Call MCP `oms_retrieve_context` with the best available axes and query.
35
+ 5. Use default `qmdScope: "global"` for broad semantic search; use
36
+ `qmdScope: "graph"` only when qmd must stay inside the selected graph
37
+ candidates.
38
+ 6. For each note, return the retrieval-view fields and lazy-load body only when needed.
39
+ 7. Return results grouped by concept/folder with retrieval-view frontmatter.
36
40
 
37
41
  ## Example
38
42
 
@@ -51,5 +55,6 @@ Purpose: "Synthesize my transformer papers"
51
55
 
52
56
  ## Runtime
53
57
 
54
- Use MCP `oms_retrieve_by_axis` for axis-first narrowing and optional lexical
55
- ranking. Use MCP `oms_lazy_load_note` only after selecting candidate notes.
58
+ Use MCP `oms_retrieve_context` for live graph/qmd retrieval. Use MCP
59
+ `oms_retrieve_by_axis` only for legacy axis-first cache retrieval. Use MCP
60
+ `oms_lazy_load_note` only after selecting candidate notes.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: oms-setup
3
- description: Adopt an existing Obsidian vault into the Oh My Second Brain convention by running npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup.
3
+ description: Adopt an existing Obsidian vault into the Oh My Second Brain convention by running oms setup.
4
4
  ---
5
5
 
6
6
  # Skill: oms-setup (Claude Code)
@@ -19,8 +19,8 @@ This skill is **REAL in v0** — it shells out to the fully-implemented CLI.
19
19
  Shells out to:
20
20
 
21
21
  ```bash
22
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup [--vault <path>] [--yes] [--install-claude]
23
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install [--runtime <auto|all|claude|codex|hermes>] [--vault <path>] [--dry-run] [--execute] [--yes]
22
+ oms setup [--vault <path>] [--yes] [--install-claude]
23
+ oms install [--runtime <auto|all|claude|codex|hermes>] [--vault <path>] [--dry-run] [--execute] [--yes]
24
24
  ```
25
25
 
26
26
  The CLI will:
@@ -43,19 +43,19 @@ The CLI will:
43
43
 
44
44
  ```bash
45
45
  # Interactive (recommended first run):
46
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup --vault ~/Documents/MyVault
46
+ oms setup --vault ~/Documents/MyVault
47
47
 
48
48
  # Non-interactive (CI / scripted):
49
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup --vault ~/Documents/MyVault --yes
49
+ oms setup --vault ~/Documents/MyVault --yes
50
50
 
51
51
  # Preview all host adapter installs:
52
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install --runtime all --vault ~/Documents/MyVault --dry-run
52
+ oms install --runtime all --vault ~/Documents/MyVault --dry-run
53
53
 
54
54
  # Install all host adapter/MCP registrations:
55
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install --runtime all --vault ~/Documents/MyVault --yes
55
+ oms install --runtime all --vault ~/Documents/MyVault --yes
56
56
 
57
57
  # Also run external host CLIs where available:
58
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install --runtime claude --vault ~/Documents/MyVault --yes --execute
58
+ oms install --runtime claude --vault ~/Documents/MyVault --yes --execute
59
59
  ```
60
60
 
61
61
  ## After setup
@@ -65,7 +65,8 @@ Run `/oms-doctor` to validate your existing notes against the convention.
65
65
  ## Roadmap
66
66
 
67
67
  Setup plus `oms install`/`oms uninstall` host lifecycle commands are real and release-gated by unpacked npm tarball smoke tests. The MCP command starts
68
- the status/read/cache/capture runtime (`oms_graph_status`, `oms_graph_build`,
69
- `oms_list_concepts`, `oms_retrieve_by_axis`, `oms_lazy_load_note`,
70
- `oms_validate_contract`, `oms_capture_prepare`, `oms_capture_commit`).
68
+ the status/read/cache/retrieve/capture runtime (`oms_graph_status`, `oms_graph_build`,
69
+ `oms_list_concepts`, `oms_retrieve_context`, `oms_retrieve_by_axis`,
70
+ `oms_lazy_load_note`, `oms_validate_contract`, `oms_capture_prepare`,
71
+ `oms_capture_commit`).
71
72
  Capture commit is gated by path-safety and contract validation.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: oms-uninstall
3
- description: Remove Oh My Second Brain host adapter and MCP registrations by running npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall.
3
+ description: Remove Oh My Second Brain host adapter and MCP registrations by running oms uninstall.
4
4
  ---
5
5
 
6
6
  # Skill: oms-uninstall (Claude Code)
@@ -18,17 +18,17 @@ Remove Oh My Second Brain host registrations and adapter files. This does **not*
18
18
  Shells out to:
19
19
 
20
20
  ```bash
21
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall [--runtime <all|claude|codex|hermes>] [--dry-run] [--execute] [--yes]
21
+ oms uninstall [--runtime <all|claude|codex|hermes>] [--dry-run] [--execute] [--yes]
22
22
  ```
23
23
 
24
24
  ## Recommended flow
25
25
 
26
26
  ```bash
27
27
  # Preview first:
28
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall --runtime all --dry-run
28
+ oms uninstall --runtime all --dry-run
29
29
 
30
30
  # Remove Oh My Second Brain host registrations:
31
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall --runtime all --yes
31
+ oms uninstall --runtime all --yes
32
32
  ```
33
33
 
34
34
  Use `--execute` only when you want Oh My Second Brain to call external host CLIs such as `claude mcp remove oms` or `claude plugin uninstall oms`.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oms",
3
- "version": "0.1.5",
3
+ "version": "0.1.7",
4
4
  "description": "Oh My Second Brain convention layer for Obsidian vaults \u2014 Codex native rules, skills, and MCP adapter.",
5
5
  "_note": "oms install writes Codex MCP config, installs ~/.codex/rules/oms.md, and installs ~/.codex/skills/oms-*.",
6
6
  "skills": "./skills/",
@@ -1,10 +1,8 @@
1
1
  {
2
2
  "mcpServers": {
3
3
  "oms": {
4
- "command": "npx",
4
+ "command": "oms",
5
5
  "args": [
6
- "-y",
7
- "https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz",
8
6
  "mcp",
9
7
  "--vault",
10
8
  "."
@@ -7,7 +7,7 @@
7
7
  This vault is governed by Oh My Second Brain conventions stored in `.oms/`.
8
8
 
9
9
  **Before working with vault notes:**
10
- - Run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` to validate notes against the convention (exits 0, non-blocking).
10
+ - Run `oms doctor` to validate notes against the convention (exits 0, non-blocking).
11
11
  - Read `.oms/taxonomy.yaml` and `.oms/concepts/*.yaml` for folder and field declarations.
12
12
 
13
13
  **Capture:** Use `$oms-capture` skill or follow the librarian persona.
@@ -10,12 +10,12 @@ Oh My Second Brain is a convention harness, not a content generator. The user ow
10
10
 
11
11
  | User intent | Preferred Oh My Second Brain surface |
12
12
  |---|---|
13
- | adopt a vault | `$oms-setup` or `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup --vault <path>` |
14
- | install host integration | `$oms-install` or `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install --runtime codex --vault <path> --yes` |
15
- | uninstall host integration | `$oms-uninstall` or `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall --runtime codex --yes` |
16
- | validate notes | `$oms-doctor` or `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor --vault <path>` |
13
+ | adopt a vault | `$oms-setup` or `oms setup --vault <path>` |
14
+ | install host integration | `$oms-install` or `oms install --runtime codex --vault <path> --yes` |
15
+ | uninstall host integration | `$oms-uninstall` or `oms uninstall --runtime codex --yes` |
16
+ | validate notes | `$oms-doctor` or `oms doctor --vault <path>` |
17
17
  | capture knowledge | use MCP `oms_capture_prepare` then `oms_capture_commit` |
18
- | retrieve knowledge | use MCP `oms_retrieve_by_axis`, then `oms_lazy_load_note` only when needed |
18
+ | retrieve knowledge | use MCP `oms_retrieve_context`, then `oms_lazy_load_note` only when needed |
19
19
 
20
20
  ## Safety
21
21
 
@@ -8,7 +8,7 @@ description: Validate vault notes against the active Oh My Second Brain ontology
8
8
  Run:
9
9
 
10
10
  ```bash
11
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor --vault <vault>
11
+ oms doctor --vault <vault>
12
12
  ```
13
13
 
14
14
  The command is advisory in v0 and exits 0 even when warnings are found.
@@ -8,7 +8,7 @@ description: Install Oh My Second Brain Codex/Hermes/Claude host adapters and MC
8
8
  Use for host lifecycle installation.
9
9
 
10
10
  ```bash
11
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install --runtime <auto|all|claude|codex|hermes> --vault <vault> --yes
11
+ oms install --runtime <auto|all|claude|codex|hermes> --vault <vault> --yes
12
12
  ```
13
13
 
14
14
  For Codex, this installs:
@@ -5,6 +5,14 @@ description: Retrieve vault knowledge axis-first using folders, frontmatter, wik
5
5
 
6
6
  # oms-retrieve
7
7
 
8
- Use `oms_retrieve_by_axis` first. Narrow by concept/folder/property/value/wikilink before lexical query. Use `oms_lazy_load_note` only after selecting candidate notes.
8
+ Use `oms_retrieve_context` first for natural-language retrieval. It combines live
9
+ frontmatter/folder/wikilink graph context with optional qmd lexical/vector
10
+ candidates and does not require a warm graph cache. Pass declared
11
+ concept/folder/property/value/wikilink axes when the user's intent gives them.
12
+
13
+ Use `qmdScope: "global"` when the user asks broad semantic search across the
14
+ vault, and `qmdScope: "graph"` when qmd candidates must stay inside the selected
15
+ OMS graph candidates. Use `oms_retrieve_by_axis` only for legacy axis-first
16
+ cache retrieval. Use `oms_lazy_load_note` only after selecting candidate notes.
9
17
 
10
18
  Return lens-shaped fields where possible; do not dump full note bodies unless the user asks or the retrieval task needs body evidence.
@@ -10,13 +10,13 @@ Use when the user wants to initialize Oh My Second Brain for a vault.
10
10
  Run:
11
11
 
12
12
  ```bash
13
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup --vault <vault> --yes
13
+ oms setup --vault <vault> --yes
14
14
  ```
15
15
 
16
16
  Then, when host registration is desired:
17
17
 
18
18
  ```bash
19
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install --runtime codex --vault <vault> --yes
19
+ oms install --runtime codex --vault <vault> --yes
20
20
  ```
21
21
 
22
22
  Do not modify vault notes during setup. Oh My Second Brain writes only `vault/.oms/taxonomy.yaml` and `vault/.oms/concepts/`.
@@ -8,13 +8,13 @@ description: Remove Oh My Second Brain host adapter files and MCP registration w
8
8
  Preview first:
9
9
 
10
10
  ```bash
11
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall --runtime all --dry-run
11
+ oms uninstall --runtime all --dry-run
12
12
  ```
13
13
 
14
14
  Remove host registrations:
15
15
 
16
16
  ```bash
17
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall --runtime all --yes
17
+ oms uninstall --runtime all --yes
18
18
  ```
19
19
 
20
20
  Never delete vault notes or `vault/.oms/` as part of host uninstall.
@@ -7,12 +7,12 @@
7
7
  This vault is governed by Oh My Second Brain conventions stored in `.oms/`.
8
8
 
9
9
  **Before working with vault notes:**
10
- - Run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` to validate notes against the convention (exits 0, non-blocking).
10
+ - Run `oms doctor` to validate notes against the convention (exits 0, non-blocking).
11
11
  - Read `.oms/taxonomy.yaml` for folder-to-concept bindings.
12
12
  - Read `.oms/concepts/*.yaml` for field declarations and lenses.
13
13
 
14
14
  **Capture:** Follow the librarian persona — resolve concept, resolve folder from taxonomy,
15
- construct required frontmatter, write note, then run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor`.
15
+ construct required frontmatter, write note, then run `oms doctor`.
16
16
 
17
17
  **Retrieve:** Follow the retriever persona — identify purpose, match lens, project lens fields only.
18
18
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oms",
3
- "version": "0.1.5",
3
+ "version": "0.1.7",
4
4
  "description": "Oh My Second Brain convention layer for Obsidian vaults \u2014 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
  "skills": "./skills/"
@@ -8,7 +8,7 @@ description: Validate vault notes against the active Oh My Second Brain ontology
8
8
  Run:
9
9
 
10
10
  ```bash
11
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor --vault <vault>
11
+ oms doctor --vault <vault>
12
12
  ```
13
13
 
14
14
  The command is advisory in v0 and exits 0 even when warnings are found.
@@ -8,7 +8,7 @@ description: Install Oh My Second Brain Codex/Hermes/Claude host adapters and MC
8
8
  Use for host lifecycle installation.
9
9
 
10
10
  ```bash
11
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install --runtime <auto|all|claude|codex|hermes> --vault <vault> --yes
11
+ oms install --runtime <auto|all|claude|codex|hermes> --vault <vault> --yes
12
12
  ```
13
13
 
14
14
  For Codex, this installs:
@@ -5,6 +5,14 @@ description: Retrieve vault knowledge axis-first using folders, frontmatter, wik
5
5
 
6
6
  # oms-retrieve
7
7
 
8
- Use `oms_retrieve_by_axis` first. Narrow by concept/folder/property/value/wikilink before lexical query. Use `oms_lazy_load_note` only after selecting candidate notes.
8
+ Use `oms_retrieve_context` first for natural-language retrieval. It combines live
9
+ frontmatter/folder/wikilink graph context with optional qmd lexical/vector
10
+ candidates and does not require a warm graph cache. Pass declared
11
+ concept/folder/property/value/wikilink axes when the user's intent gives them.
12
+
13
+ Use `qmdScope: "global"` when the user asks broad semantic search across the
14
+ vault, and `qmdScope: "graph"` when qmd candidates must stay inside the selected
15
+ OMS graph candidates. Use `oms_retrieve_by_axis` only for legacy axis-first
16
+ cache retrieval. Use `oms_lazy_load_note` only after selecting candidate notes.
9
17
 
10
18
  Return lens-shaped fields where possible; do not dump full note bodies unless the user asks or the retrieval task needs body evidence.
@@ -10,13 +10,13 @@ Use when the user wants to initialize Oh My Second Brain for a vault.
10
10
  Run:
11
11
 
12
12
  ```bash
13
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup --vault <vault> --yes
13
+ oms setup --vault <vault> --yes
14
14
  ```
15
15
 
16
16
  Then, when host registration is desired:
17
17
 
18
18
  ```bash
19
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz install --runtime codex --vault <vault> --yes
19
+ oms install --runtime codex --vault <vault> --yes
20
20
  ```
21
21
 
22
22
  Do not modify vault notes during setup. Oh My Second Brain writes only `vault/.oms/taxonomy.yaml` and `vault/.oms/concepts/`.
@@ -8,13 +8,13 @@ description: Remove Oh My Second Brain host adapter files and MCP registration w
8
8
  Preview first:
9
9
 
10
10
  ```bash
11
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall --runtime all --dry-run
11
+ oms uninstall --runtime all --dry-run
12
12
  ```
13
13
 
14
14
  Remove host registrations:
15
15
 
16
16
  ```bash
17
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz uninstall --runtime all --yes
17
+ oms uninstall --runtime all --yes
18
18
  ```
19
19
 
20
20
  Never delete vault notes or `vault/.oms/` as part of host uninstall.
@@ -21,7 +21,7 @@ It reads the convention first, then acts.
21
21
  2. **Folder resolution** — look up the correct target folder from `vault/.oms/taxonomy.yaml` based on the matched concept.
22
22
  3. **Frontmatter construction** — fill every `required: true` field; fill known optional fields; leave undeclared fields untouched.
23
23
  4. **Note creation** — write the file at the resolved path; use the concept's naming convention (default: `YYYY-MM-DD-<slug>.md`).
24
- 5. **Post-capture validation** — run `npx oms doctor` (non-blocking) to confirm the new note is clean.
24
+ 5. **Post-capture validation** — run `npx oh-my-second-brain doctor` (non-blocking) to confirm the new note is clean.
25
25
 
26
26
  ## Decision rules
27
27
 
@@ -18,14 +18,16 @@ The librarian persona governs this action.
18
18
  - Fill optional fields where values are known.
19
19
  - Leave undeclared (extra) frontmatter fields untouched (`additionalProperties: preserve`).
20
20
  5. Write the note body after the frontmatter block.
21
- 6. Run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` (non-blocking, exits 0) to confirm the new note passes field validation.
21
+ 6. Run `oms doctor` (non-blocking, exits 0) to confirm the new note passes field validation.
22
22
 
23
- ## Conceptual shell-out (roadmap — NOT wired in v0)
23
+ ## Engine
24
24
 
25
- The runtime automation described above is **agent-guidance only in v0**.
26
- No capture engine exists yet; the agent follows these steps manually.
27
- When the MCP server is wired (`src/mcp/server.ts` real), `capture` will call
28
- the `capture` MCP tool directly.
25
+ The capture engine is implemented in `src/capture/safe.ts` and exposed via two MCP tools:
26
+
27
+ - **`oms_capture_prepare`** — resolves the target path and constructs the proposed frontmatter/body without writing anything. Call this first to let the agent review the proposed note before committing.
28
+ - **`oms_capture_commit`** — writes the file to disk. Gated by vault confinement: rejects writes that are outside the vault, to non-`.md` files, or into the `.oms/` config directory. Frontmatter violations are warn-only and do not block the commit.
29
+
30
+ The recommended agent flow is to call `oms_capture_prepare`, review the result, then call `oms_capture_commit` to finalize.
29
31
 
30
32
  ## Example agent steps
31
33
 
@@ -40,7 +42,7 @@ User: "Save this paper: 'Attention Is All You Need', arxiv.org/abs/1706.03762"
40
42
  source-url: "https://arxiv.org/abs/1706.03762"
41
43
  captured-at: "2026-05-31"
42
44
  5. write note body
43
- 6. npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor ← verify (exits 0, non-blocking)
45
+ 6. oms doctor ← verify (exits 0, non-blocking)
44
46
  ```
45
47
 
46
48
  ## Persona
@@ -12,7 +12,7 @@ type, and optional rules (`required`, `normalize`, `immutable`).
12
12
  ## Entry point
13
13
 
14
14
  ```bash
15
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz define
15
+ oms define
16
16
  ```
17
17
 
18
18
  This is the intended user-facing command (roadmap: interactive runtime not built yet).
@@ -27,7 +27,7 @@ Use `define` as **agent-guided convention editing** until the interactive runtim
27
27
  4. Ask: **type** (`string` | `string[]` | `date` | `url` | `boolean`), **required** (yes/no).
28
28
  5. Optionally ask: `normalize` (e.g. `lowercase`), `immutable` (lock after creation).
29
29
  6. Open `vault/.oms/concepts/<concept>.yaml` and append the new field entry.
30
- 7. Run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` to validate existing notes against the updated schema (exits 0).
30
+ 7. Run `oms doctor` to validate existing notes against the updated schema (exits 0).
31
31
 
32
32
  ## Convention YAML shape (one field entry)
33
33
 
@@ -11,7 +11,7 @@ This skill is **REAL in v0** — the CLI command is fully implemented.
11
11
  ## Shell-out
12
12
 
13
13
  ```bash
14
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor [--vault <path>]
14
+ oms doctor [--vault <path>]
15
15
  ```
16
16
 
17
17
  - `--vault <path>` — path to your Obsidian vault root (default: current directory).
@@ -40,7 +40,7 @@ Undeclared frontmatter fields are **never** reported as violations
40
40
 
41
41
  ## Recommended usage
42
42
 
43
- Run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` after:
43
+ Run `oms doctor` after:
44
44
  - Any `oms setup` run
45
45
  - Adding a new field via `oms define`
46
46
  - Bulk-editing notes
@@ -32,12 +32,24 @@ lenses:
32
32
 
33
33
  The retrieval skill reads these declarations from `vault/.oms/concepts/*.yaml`.
34
34
 
35
- ## Conceptual shell-out (roadmap — NOT wired in v0)
35
+ ## Engine
36
36
 
37
- The runtime automation described above is **agent-guidance only in v0**.
38
- No retrieval engine exists yet; the agent follows these steps manually.
39
- When the MCP server is wired (`src/mcp/server.ts` real), `retrieve` will call
40
- the `retrieve` MCP tool directly.
37
+ Use MCP `oms_retrieve_context` first for natural-language retrieval. It combines:
38
+
39
+ - live folder/frontmatter/wikilink graph exploration without requiring a warm cache
40
+ - taxonomy-axis seeds from concept, folder, property, value, or wikilink inputs
41
+ - graph neighbors through shared frontmatter values, wikilinks, and backlinks
42
+ - optional qmd lexical/vector candidates when the local `qmd` CLI is available
43
+
44
+ Use `qmdScope: "global"` for broad semantic search across the vault. Use
45
+ `qmdScope: "graph"` when qmd candidates must stay inside the selected OMS graph
46
+ candidates. The qmd provider is fail-soft: retrieval must still return OMS graph
47
+ hits when qmd is unavailable or disabled.
48
+
49
+ Use the older MCP tools only for narrower follow-up steps:
50
+
51
+ - **`oms_retrieve_by_axis`** — legacy cache-backed axis retrieval by concept, folder, property, value, or wikilink.
52
+ - **`oms_lazy_load_note`** — fetches the full body of a single selected note on demand, avoiding loading all note bodies upfront.
41
53
 
42
54
  ## Example agent steps
43
55
 
@@ -11,7 +11,7 @@ This skill is **REAL in v0** — the CLI command is fully implemented.
11
11
  ## Shell-out
12
12
 
13
13
  ```bash
14
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz setup [--vault <path>] [--yes]
14
+ oms setup [--vault <path>] [--yes]
15
15
  ```
16
16
 
17
17
  - `--vault <path>` — path to your Obsidian vault root (default: current directory).
@@ -27,7 +27,7 @@ npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.t
27
27
  6. Copies the shipped default concepts into `vault/.oms/concepts/`.
28
28
 
29
29
  After setup, the vault is governed by Oh My Second Brain conventions.
30
- Run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor` at any time to validate existing notes.
30
+ Run `oms doctor` at any time to validate existing notes.
31
31
 
32
32
  ## What setup does NOT do
33
33
 
@@ -40,5 +40,5 @@ Run `npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.
40
40
  Run the `doctor` skill to check your notes against the convention:
41
41
 
42
42
  ```bash
43
- npx -y https://github.com/GoBeromsu/oms/releases/download/oms-v0.1.5/oms-0.1.5.tgz doctor [--vault <path>]
43
+ oms doctor [--vault <path>]
44
44
  ```