@oomkapwn/enquire-mcp 1.8.1 → 1.10.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.
package/docs/api.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # enquire — API
2
2
 
3
- **enquire is an MCP server for Obsidian vaults.** 26 MCP tools (22 always-on read + 1 opt-in read via `--persistent-index` + 3 opt-in write via `--enable-write`), 2 + 1 opt-in MCP resources, 10 MCP prompts. The server speaks stdio JSON-RPC and is launched per-vault.
3
+ **enquire is an MCP server for Obsidian vaults.** 27 MCP tools (22 always-on read + 1 opt-in read via `--persistent-index` + 4 opt-in write via `--enable-write`), 2 + 1 opt-in MCP resources, 10 MCP prompts. The server speaks stdio JSON-RPC and is launched per-vault.
4
4
 
5
5
  > Versioned dynamically — see [`CHANGELOG.md`](../CHANGELOG.md) for the current release.
6
6
 
@@ -9,7 +9,7 @@
9
9
  | Flag | Default | Notes |
10
10
  |------------------------|---------|--------------------------------------------|
11
11
  | `--vault <path>` | (required) | Path to the Obsidian vault root. |
12
- | `--enable-write` | off | Register the three write tools. |
12
+ | `--enable-write` | off | Register the four write tools. |
13
13
  | `--max-file-bytes <n>` | 5 MB | Max size for any single file read/write. |
14
14
  | `--cache-size <n>` | 1024 | LRU cap for parsed-note cache. |
15
15
  | `--persistent-cache` | off | Persist parsed-note cache to disk so cold starts skip re-parsing. **Stores full note bodies — see [Cache & privacy](../README.md#cache--privacy).** |
@@ -19,6 +19,7 @@
19
19
  | `--index-file <path>` | auto | Override the FTS5 index file location. Default: `~/Library/Caches/enquire/<vault-hash>.fts5.db` (macOS) or `~/.cache/enquire/<vault-hash>.fts5.db` (Linux). |
20
20
  | `--exclude-glob <pattern...>` | none | Repeatable glob pattern(s) — paths matching any pattern are invisible to every tool and refuse direct reads. Privacy filter (denylist). Supports `*` (within-segment), `**` (cross-segment), `?` (single char). Example: `--exclude-glob '02_Personal/**' '*.private.md'`. |
21
21
  | `--read-paths <pattern...>` | none | **Strict allowlist** — when set, ONLY paths matching one of these glob patterns are visible. Complement to `--exclude-glob`. If both are set: a path must match an allow-glob AND not match any exclude-glob. Same glob semantics. Repeatable. Example: `--read-paths '01_Projects/**' '99_Daily/**'`. |
22
+ | `--disabled-tools <name...>` | none | Skip registration of specific tools by exact name (matches `tools/list`). Repeatable. Useful for narrow-surface agents. Example: `--disabled-tools obsidian_dataview_query obsidian_full_text_search`. |
22
23
  | `--watch` | off | Watch the vault for `.md` add/change/unlink events. On change: invalidate the parsed-note cache for that file; if `--persistent-index` is also enabled, incrementally re-sync just that file's FTS5 chunks. Editor saves are debounced via chokidar's `awaitWriteFinish`. `--exclude-glob` patterns are honored — edits to excluded paths don't fire. Off by default; opt in for long-running servers. |
23
24
 
24
25
  ## Subcommands
@@ -56,6 +57,16 @@ Read a single note. Provide either `path` or `title`.
56
57
 
57
58
  **Returns:** `{ path, title, content, frontmatter, wikilinks, embeds, tags, mtime }`. `content` is the body with frontmatter stripped. `wikilinks` and `embeds` share the same shape (`{ raw, target, section?, block?, alias? }`) and are surfaced separately.
58
59
 
60
+ ### Periodic-note aliases (v1.10 plugin-aware)
61
+
62
+ `title` accepts the periodic aliases `today` / `daily` / `weekly` / `monthly` / `quarterly` / `yearly`. Resolution order:
63
+
64
+ 1. **Literal title match** — if you have a real file called `Today.md`, that one wins (no surprise alias hijacking).
65
+ 2. **User's plugin config** — `obsidian_read_note` reads `.obsidian/daily-notes.json` (Daily Notes core plugin) and `.obsidian/plugins/periodic-notes/data.json` (Periodic Notes community plugin) at first call, caches them for the session. The user's `format` (Moment.js pattern) and `folder` are honored exactly. Periodic Notes kinds with `enabled: false` are skipped (fall back to default).
66
+ 3. **Legacy default formats** — `YYYY-MM-DD` / `YYYY-[W]ww` / `YYYY-MM` / `YYYY-[Q]Q` / `YYYY` at vault root. Matches what enquire shipped pre-1.10.
67
+
68
+ The Moment.js format converter supports the tokens periodic-note configs actually use: `YYYY` / `YY` / `MMMM` / `MMM` / `MM` / `M` / `Mo` / `Do` / `DD` / `D` / `dddd` / `ddd` / `WW` / `ww` / `Wo` / `wo` / `gggg` / `GGGG` / `Q` / `QQ` / `H` / `HH` / `h` / `hh` / `m` / `mm` / `s` / `ss` / `A` / `a` and bracket-escaped literals (`[W]`, `[Q]`, `[The year is]`).
69
+
59
70
  ## `obsidian_resolve_wikilink`
60
71
 
61
72
  Resolve an Obsidian `[[wikilink]]` to a vault file. Handles aliases (`Note|alias`), section refs (`Note#Heading`), block refs (`Note^abc`), and relative paths (`../Folder/Note`) when `from_note` is supplied.
@@ -399,7 +410,7 @@ Pure-JS TF-IDF cosine retrieval. Tokenizes (alphanumeric + hyphen, stop-words fi
399
410
 
400
411
  ## Write tools (opt-in)
401
412
 
402
- All three write tools are **only registered when the server is started with `--enable-write`**. Without that flag the tools are not advertised to the client at all.
413
+ All four write tools are **only registered when the server is started with `--enable-write`**. Without that flag the tools are not advertised to the client at all.
403
414
 
404
415
  ### `obsidian_create_note`
405
416
 
@@ -440,6 +451,24 @@ Atomically rename a note **and** rewrite every `[[wikilink]]` / `![[embed]]` in
440
451
 
441
452
  **Returns:** `{ from, to, dry_run, files_updated: [{ path, rewrites, before, after }], total_links_rewritten }`. (`before`/`after` are blank in the response — they're used internally to apply the rewrite atomically.) Throws if `from` is missing, `to` exists without `overwrite`, either path traverses, or `from === to`.
442
453
 
454
+ ### `obsidian_replace_in_notes`
455
+
456
+ Bulk find/replace across the vault, code-fence-aware. Walks every note (or a `folder` subset), substitutes every literal occurrence of `search` with `replace` outside fenced code blocks (` ``` ` / `~~~`), and writes each modified file back. Reuses the same line walker rename_note uses, so example snippets and code documentation stay verbatim.
457
+
458
+ | Argument | Type | Notes |
459
+ |------------------|------------|------------------------------------------------------------------------|
460
+ | `search` | `string` | Required. Literal substring to find. Empty string is rejected. |
461
+ | `replace` | `string` | Replacement text. Empty string means delete every occurrence. |
462
+ | `folder` | `string?` | Restrict to a subfolder (vault-relative). Default: whole vault. |
463
+ | `dry_run` | `boolean?` | Preview the plan without writing. Default `false`. |
464
+ | `case_sensitive` | `boolean?` | Default `true`. `false` = case-insensitive substring match. Replace text is inserted verbatim. |
465
+
466
+ **Returns:** `{ search, replace, case_sensitive, dry_run, scope, files_scanned, files_updated: [{ path, occurrences }], total_replacements }`.
467
+
468
+ **Footgun guards.** Refuses (a) empty `search` and (b) identical `search` and `replace` (no-op). Honors `--exclude-glob` and `--read-paths`: writes to filtered paths fail at the `Vault.writeNote` layer.
469
+
470
+ **Use cases.** Vocabulary refactor (e.g. `GPT-3.5` → `GPT-4`). Deprecation cleanup (delete every `DEPRECATED ` prefix). Brand rename (case-insensitive `api` → `REST` in prose, while keeping URLs intact via the code-fence skip).
471
+
443
472
  ## MCP resources
444
473
 
445
474
  | URI | Type | Description |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oomkapwn/enquire-mcp",
3
- "version": "1.8.1",
3
+ "version": "1.10.0",
4
4
  "description": "Drop-in MCP server for Obsidian vaults. Wikilinks resolved, backlinks ranked, frontmatter typed, Dataview-style queries. Read-only by default; opt-in writes. Works with Claude Code, Cursor, OpenClaw, Codex, Devin, and any MCP-compatible client.",
5
5
  "type": "module",
6
6
  "bin": {