open-memex 0.6.0 → 0.6.1-alpha.3
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/AGENTS.md +3 -0
- package/README.md +546 -387
- package/README.zh-CN.md +381 -447
- package/dist/cli.js +71 -7
- package/dist/doctor.js +23 -1
- package/dist/init.js +3 -0
- package/dist/retrieve/cjk.js +14 -2
- package/dist/retrieve/query.js +54 -0
- package/dist/retrieve/search.js +20 -19
- package/dist/store/audit.js +101 -0
- package/dist/store/db.js +5 -0
- package/dist/store/markdown.js +6 -1
- package/dist/tools/memory.js +9 -1
- package/dist/tools/ops.js +6 -6
- package/docs/CONCEPTS.md +181 -0
- package/docs/CONCEPTS.zh-CN.md +163 -0
- package/docs/V2-DESIGN.md +80 -0
- package/package.json +1 -1
- package/scripts/smoke-pure.ts +36 -0
- package/src/cli.ts +78 -7
- package/src/doctor.ts +23 -1
- package/src/init.ts +3 -0
- package/src/retrieve/cjk.ts +18 -2
- package/src/retrieve/query.ts +58 -0
- package/src/retrieve/search.ts +27 -19
- package/src/store/audit.ts +136 -0
- package/src/store/db.ts +5 -0
- package/src/store/markdown.ts +6 -1
- package/src/tools/memory.ts +16 -1
- package/src/tools/ops.ts +6 -6
- package/docs/USER-GUIDE.md +0 -196
- package/docs/USER-GUIDE.zh-CN.md +0 -160
package/AGENTS.md
CHANGED
|
@@ -18,6 +18,8 @@ via `prepublishOnly` — Node refuses `--experimental-strip-types` for files und
|
|
|
18
18
|
|
|
19
19
|
Tool logic is host-agnostic and lives in `src/tools/ops.ts` (plain functions + shared zod arg shapes + `TOOL_DESCRIPTIONS`). `src/tools/memory.ts` (opencode) and `src/mcp.ts` are thin adapters — when adding or changing a tool, change `ops.ts` once and both hosts pick it up.
|
|
20
20
|
|
|
21
|
+
**Plugin code must not runtime-import `@opencode-ai/plugin`** (D58): it is a devDependency, and opencode does not resolve it for `file://` plugins loaded from a global npm install — the import fails and opencode silently skips the plugin (no error, no tools). Type-only imports are fine. `src/tools/memory.ts` carries a local stand-in for the SDK's `tool()` (a runtime identity) for exactly this reason.
|
|
22
|
+
|
|
21
23
|
Consequences:
|
|
22
24
|
- Imports **must** use explicit `.ts` extensions (`allowImportingTsExtensions: true`, `moduleResolution: "Bundler"`).
|
|
23
25
|
- No transpile / bundle output. Do not add one; opencode loads the `.ts` file directly.
|
|
@@ -31,6 +33,7 @@ npm run typecheck # tsc --noEmit — the only
|
|
|
31
33
|
npm run cli -- where | list | search "q" | add ... | forget <id> | reindex
|
|
32
34
|
npm run cli -- <command> --help # per-command help (AI assistants discover flags this way)
|
|
33
35
|
npm run cli -- sync-status # last sync time/kind + outbox drafts + repo review states + uncommitted files
|
|
36
|
+
npm run cli -- audit [--scope project|personal|both] # memory health: near-dup pairs, stale actives, broken chains, personal-in-repo (read-only)
|
|
34
37
|
npm run cli -- pull # fetch + fast-forward only (explicit; diverged = clean failure, never force-merge)
|
|
35
38
|
npm run cli -- push # push current branch to remote (explicit only; open-memex never auto-pushes)
|
|
36
39
|
npm run cli -- export [--scope project|personal|both] [--all] [-o <file>] # portable .tar.gz bundle (markdown + manifest); private excluded unless --all
|