pi-vault-mind 0.7.0 → 0.7.2
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/CHANGELOG.md +17 -0
- package/README.md +24 -2
- package/dist/src/autosync.d.ts +16 -0
- package/dist/src/autosync.js +43 -0
- package/dist/src/commands.d.ts +18 -0
- package/dist/src/commands.js +464 -10
- package/dist/src/embed-queue.d.ts +80 -0
- package/dist/src/embed-queue.js +163 -0
- package/dist/src/index.js +9 -0
- package/dist/src/lance.d.ts +7 -0
- package/dist/src/lance.js +432 -0
- package/dist/src/modal-client.d.ts +176 -0
- package/dist/src/modal-client.js +174 -0
- package/dist/src/modal-config.d.ts +42 -0
- package/dist/src/modal-config.js +60 -0
- package/dist/src/settings-ui.d.ts +7 -0
- package/dist/src/settings-ui.js +109 -1
- package/dist/src/sync.d.ts +71 -0
- package/dist/src/sync.js +211 -0
- package/dist/src/types.d.ts +102 -1
- package/dist/test/embed-queue.test.js +105 -0
- package/dist/test/index.test.js +35 -0
- package/dist/test/lance-modal.test.js +95 -0
- package/dist/test/modal-client.test.js +294 -0
- package/dist/test/modal-config.test.js +86 -0
- package/dist/test/sync.test.js +132 -0
- package/package.json +3 -2
- package/skills/vault-mind-setup/SKILL.md +8 -1
- package/dist/test/index.test.d.ts +0 -1
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 0.7.1 - 2026-06-14
|
|
4
|
+
|
|
5
|
+
### Fixed
|
|
6
|
+
- Renamed skill directories to `vault-mind-{role}` for consistency.
|
|
7
|
+
- Updated subagent dispatch names to match the new skill roles.
|
|
8
|
+
- Fixed `vault-mind-setup` skill description formatting.
|
|
9
|
+
|
|
10
|
+
### Changed
|
|
11
|
+
- Documentation cleanup across README, skills, and setup FAQ.
|
|
12
|
+
- CI configuration simplified for single-package repo.
|
|
13
|
+
|
|
14
|
+
## 0.7.0 - 2026-06-10
|
|
15
|
+
|
|
16
|
+
### Added
|
|
17
|
+
- Initial release of `pi-vault-mind`.
|
package/README.md
CHANGED
|
@@ -182,6 +182,7 @@ The Broadcaster agent can generate podcasts, study guides, and slide decks from
|
|
|
182
182
|
- **Embedding Provider** — choose one:
|
|
183
183
|
- `@xenova/transformers` — built-in, no external deps (uses all-MiniLM-L6-v2, offline-capable)
|
|
184
184
|
- `ollama` — requires Ollama running locally with `embeddinggemma` (higher quality)
|
|
185
|
+
- `modal` — optional: offload embedding + bulk re-index to a cloud GPU service and sync vectors down for offline search (see [docs/MODAL_EMBEDDING.md](docs/MODAL_EMBEDDING.md)). Default behavior is unchanged until you opt in.
|
|
185
186
|
|
|
186
187
|
### 1. Install with pi
|
|
187
188
|
|
|
@@ -343,12 +344,13 @@ Edit `pi-vault-mind.config.json` to match your domain:
|
|
|
343
344
|
| `/wiki approve [collection]` | Batch-review pending entries |
|
|
344
345
|
| `/wiki settings` | Open interactive settings dashboard |
|
|
345
346
|
| `/wiki audit` | Audit config for missing defaults |
|
|
346
|
-
| `/wiki reindex [--all] [--reembed]` | Rebuild FTS + vector indexes
|
|
347
|
+
| `/wiki reindex [--all] [--reembed] [--remote]` | Rebuild FTS + vector indexes; `--remote` offloads to Modal |
|
|
347
348
|
| `/wiki collection select` | Select active collection (shortcut: ctrl+alt+l) |
|
|
348
349
|
| `/wiki collection create` | Interactive wizard to create a new collection |
|
|
349
350
|
| `/wiki injector create` | Interactive wizard to create a new injector |
|
|
350
351
|
| `/wiki context enable \| disable \| status` | Manage pi-context integration |
|
|
351
352
|
| `/wiki embedding status \| use \| model \| models \| pull` | Manage embedding provider |
|
|
353
|
+
| `/wiki modal status \| config \| sync \| jobs \| migrate` | Manage Modal embedding + vector sync |
|
|
352
354
|
| `/wiki watcher start \| stop \| status` | Manage the passive file watcher |
|
|
353
355
|
| `/wiki server status` | Show HTTP server status, port, and uptime |
|
|
354
356
|
|
|
@@ -362,6 +364,7 @@ Edit `pi-vault-mind.config.json` to match your domain:
|
|
|
362
364
|
| Doc | Description |
|
|
363
365
|
|---|---|
|
|
364
366
|
| [docs/QUICKSTART.md](docs/QUICKSTART.md) | **Fastest path** — 60-second install, setup, first append |
|
|
367
|
+
| [docs/NEW_VAULT_WALKTHROUGH.md](docs/NEW_VAULT_WALKTHROUGH.md) | **Fresh Mac → new vault → Modal → sync → verified**, one linear path (incl. multi-vault storage isolation) |
|
|
365
368
|
| [docs/INSTALL.md](docs/INSTALL.md) | **Canonical install playbook** — all 5 layers (pi ext, skills, Obsidian, config, external CLIs) |
|
|
366
369
|
| [docs/GETTING_STARTED.md](docs/GETTING_STARTED.md) | End-to-end workflow + daily "drop & forget" usage |
|
|
367
370
|
| [docs/WALKTHROUGH_PROMPT.md](docs/WALKTHROUGH_PROMPT.md) | Paste-into-pi guided setup with checkpoints between phases |
|
|
@@ -378,6 +381,25 @@ Edit `pi-vault-mind.config.json` to match your domain:
|
|
|
378
381
|
| [docs/NOTEBOOKLM_PIPELINE.md](docs/NOTEBOOKLM_PIPELINE.md) | NotebookLM automated podcast and study guide generation |
|
|
379
382
|
| [docs/OBSIDIAN_SETUP.md](docs/OBSIDIAN_SETUP.md) | Recommended Obsidian vault structure, plugins, and CLI |
|
|
380
383
|
|
|
384
|
+
### Modal embedding service (local integration done)
|
|
385
|
+
|
|
386
|
+
The local extension now integrates the Modal embedding service as a fully
|
|
387
|
+
configurable embedding provider: on-demand `/embed` for search (with an offline
|
|
388
|
+
fallback that degrades to FTS, never crashes), a sync-down path that pulls
|
|
389
|
+
server-side vectors into the local LanceDB with a monotonic `seq` watermark,
|
|
390
|
+
remote bulk re-index (`/wiki reindex --all --reembed --remote`), and debounced +
|
|
391
|
+
batched append embedding via the coalescer. Existing non-modal users see no
|
|
392
|
+
behavior change. See [docs/MODAL_EMBEDDING.md](docs/MODAL_EMBEDDING.md) for the
|
|
393
|
+
full design.
|
|
394
|
+
|
|
395
|
+
| Doc | Description |
|
|
396
|
+
|---|---|
|
|
397
|
+
| [docs/MODAL_EMBEDDING.md](docs/MODAL_EMBEDDING.md) | Design of record: ADRs, HTTP contract, sync protocol, roadmap for the cloud embedding service |
|
|
398
|
+
| [docs/plans/modal-embedding-plan.md](docs/plans/modal-embedding-plan.md) | **Consolidated plan & next steps** — phases, owners, status, decision gate (in repo, not on the docs site) |
|
|
399
|
+
| [docs/plans/embedding-open-questions.md](docs/plans/embedding-open-questions.md) | Embedding-strategy decision log (decided + open questions) |
|
|
400
|
+
| [modal/](modal/) | The deployable Modal app: embedding service + bulk worker + sync + dataset generator |
|
|
401
|
+
| [eval/](eval/) | Retrieval eval harness + labeled benchmark datasets for picking the canonical model |
|
|
402
|
+
|
|
381
403
|
### Reference
|
|
382
404
|
|
|
383
405
|
| Doc | Description |
|
|
@@ -417,7 +439,7 @@ Edit `pi-vault-mind.config.json` to match your domain:
|
|
|
417
439
|
| Doc | Description |
|
|
418
440
|
|---|---|
|
|
419
441
|
| [docs/_archive/](docs/_archive/) | Historical docs kept for context (e.g. the `pi-llm-wiki` → `pi-vault-mind` rename audit) |
|
|
420
|
-
| [docs/
|
|
442
|
+
| [docs/_archive/legacy-audit.md](docs/_archive/legacy-audit.md) | The 2026-06-08 legacy-terminology audit (139 findings, 13 blockers) and its resolution log. Resolved 2026-06-09; archived 2026-06-16 (in the repo, not on the docs site) |
|
|
421
443
|
|
|
422
444
|
## Contributing
|
|
423
445
|
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Optional background vector sync (off by default).
|
|
3
|
+
*
|
|
4
|
+
* When `wiki.embedding.modal.sync.autoSync` is true, a background interval pulls
|
|
5
|
+
* new server-side vectors into the local LanceDB on a configurable cadence so
|
|
6
|
+
* search keeps working with the latest embeddings. It is guarded by config and
|
|
7
|
+
* safe to leave disabled — if Modal is not configured or auto-sync is off, the
|
|
8
|
+
* tick is a no-op.
|
|
9
|
+
*
|
|
10
|
+
* Config is re-read on each tick so changes take effect without a restart.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Start the auto-sync interval. Returns a stop function (clears the timer).
|
|
14
|
+
* @param intervalMs fallback interval when config omits `autoSyncIntervalMs`.
|
|
15
|
+
*/
|
|
16
|
+
export declare const startAutoSync: (intervalMs?: number) => (() => void);
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Optional background vector sync (off by default).
|
|
3
|
+
*
|
|
4
|
+
* When `wiki.embedding.modal.sync.autoSync` is true, a background interval pulls
|
|
5
|
+
* new server-side vectors into the local LanceDB on a configurable cadence so
|
|
6
|
+
* search keeps working with the latest embeddings. It is guarded by config and
|
|
7
|
+
* safe to leave disabled — if Modal is not configured or auto-sync is off, the
|
|
8
|
+
* tick is a no-op.
|
|
9
|
+
*
|
|
10
|
+
* Config is re-read on each tick so changes take effect without a restart.
|
|
11
|
+
*/
|
|
12
|
+
import { isModalConfigured } from "./modal-config.js";
|
|
13
|
+
import { syncAll } from "./sync.js";
|
|
14
|
+
import { loadConfig } from "./utils.js";
|
|
15
|
+
/**
|
|
16
|
+
* Start the auto-sync interval. Returns a stop function (clears the timer).
|
|
17
|
+
* @param intervalMs fallback interval when config omits `autoSyncIntervalMs`.
|
|
18
|
+
*/
|
|
19
|
+
export const startAutoSync = (intervalMs = 300_000) => {
|
|
20
|
+
const tick = async () => {
|
|
21
|
+
try {
|
|
22
|
+
const cfg = loadConfig(process.cwd());
|
|
23
|
+
const sync = cfg.wiki.embedding.modal?.sync;
|
|
24
|
+
if (!sync?.autoSync)
|
|
25
|
+
return; // off by default
|
|
26
|
+
if (!isModalConfigured(cfg.wiki))
|
|
27
|
+
return; // nothing to sync
|
|
28
|
+
const ms = sync.autoSyncIntervalMs ?? intervalMs;
|
|
29
|
+
void ms; // cadence is fixed at start; tick honors config toggle
|
|
30
|
+
await syncAll(cfg);
|
|
31
|
+
console.log("[pi-vault-mind] auto-sync tick complete");
|
|
32
|
+
}
|
|
33
|
+
catch (err) {
|
|
34
|
+
console.warn(`[pi-vault-mind] auto-sync tick failed: ${err.message}`);
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
const id = setInterval(tick, intervalMs);
|
|
38
|
+
// setInterval holds the event loop alive; let the process exit if needed.
|
|
39
|
+
if (typeof id.unref === "function") {
|
|
40
|
+
id.unref();
|
|
41
|
+
}
|
|
42
|
+
return () => clearInterval(id);
|
|
43
|
+
};
|
package/dist/src/commands.d.ts
CHANGED
|
@@ -2,6 +2,24 @@ import type { ExtensionAPI, ExtensionContext } from "@earendil-works/pi-coding-a
|
|
|
2
2
|
import type { ServerState } from "./server.js";
|
|
3
3
|
export declare const auditConfig: (ctx: ExtensionContext) => Promise<void>;
|
|
4
4
|
export declare const selectActiveCollection: (ctx: ExtensionContext) => Promise<void>;
|
|
5
|
+
/**
|
|
6
|
+
* Vault-root `.gitignore` entries that keep pi-vault-mind compatible with
|
|
7
|
+
* `obsidian-git` (and, transitively, Obsidian Sync setups that also back up via
|
|
8
|
+
* git): the LanceDB index is a large, per-device, rebuildable binary and must
|
|
9
|
+
* never be committed; Obsidian's workspace UI state churns constantly. See
|
|
10
|
+
* docs/OBSIDIAN_SETUP.md §6.
|
|
11
|
+
*/
|
|
12
|
+
export declare const GITIGNORE_ENTRIES: string[];
|
|
13
|
+
/**
|
|
14
|
+
* Decide what to do with the vault `.gitignore`, given its current contents
|
|
15
|
+
* (`null` if absent). Pure — does no I/O — so it is unit-testable. Creates the
|
|
16
|
+
* file when missing, appends only the entries that aren't already present
|
|
17
|
+
* (line-exact match, trimmed), and skips when everything is covered.
|
|
18
|
+
*/
|
|
19
|
+
export declare const planGitignore: (existing: string | null) => {
|
|
20
|
+
action: "create" | "append" | "skip";
|
|
21
|
+
content: string;
|
|
22
|
+
};
|
|
5
23
|
export declare const watcherState: import("./watcher.js").WatcherState;
|
|
6
24
|
/** Module-level server state, referenced by the /wiki server command.
|
|
7
25
|
* Port is set when the server starts in index.ts. */
|