@membank/cli 0.10.0 → 0.10.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/README.md CHANGED
@@ -46,7 +46,7 @@ membank query "how to run pnpm in one package"
46
46
  membank query "auth decisions" --type decision --limit 5
47
47
  ```
48
48
 
49
- Options: `--type <type>`, `--limit <n>` (default 10)
49
+ Options: `--type <type>`, `--limit <n>` (default 10), `--include-pinned`
50
50
 
51
51
  ### `membank add <content>`
52
52
 
@@ -57,7 +57,7 @@ membank add "Use --filter flag for scoped pnpm commands" --type preference --tag
57
57
  ```
58
58
 
59
59
  Required: `--type <type>`
60
- Options: `--tags <a,b,c>`, `--scope <scope>`
60
+ Options: `--tags <a,b,c>`, `--global`
61
61
 
62
62
  ### `membank list`
63
63
 
@@ -117,14 +117,56 @@ membank import membank-export-2025-01-01.json
117
117
  membank import membank-export-2025-01-01.json --yes
118
118
  ```
119
119
 
120
+ ### `membank review`
121
+
122
+ List memories flagged for deduplication review, or dismiss review events.
123
+
124
+ ```bash
125
+ membank review
126
+ membank review --resolve <id>
127
+ ```
128
+
129
+ ### `membank migrate <mode> [name]`
130
+
131
+ List or run named data migrations.
132
+
133
+ ```bash
134
+ membank migrate list
135
+ membank migrate run <name>
136
+ ```
137
+
138
+ ### `membank config`
139
+
140
+ Read and write config values.
141
+
142
+ ```bash
143
+ membank config get <key>
144
+ membank config set <key> <value>
145
+ membank config show
146
+ ```
147
+
148
+ ### `membank synthesize`
149
+
150
+ View memory synthesis state.
151
+
152
+ ```bash
153
+ membank synthesize show # current synthesis for global scope
154
+ membank synthesize show --scope <s> # synthesis for a specific project scope
155
+ membank synthesize status # all scopes and their synthesis state
156
+ ```
157
+
120
158
  ### `membank inject`
121
159
 
122
160
  Output session context formatted for a harness. Called automatically by session hooks — you don't normally run this directly.
123
161
 
124
162
  ```bash
125
- membank inject --harness claude-code --scope <project-scope>
163
+ membank inject --harness claude-code
164
+ membank inject --harness claude-code --event user-prompt-submit
165
+ membank inject --harness claude-code --event session-stop
126
166
  ```
127
167
 
168
+ Options: `--harness <name>` (claude-code|copilot-cli|codex|opencode), `--event <event>` (session-start|user-prompt-submit|session-stop)
169
+
128
170
  ### `membank dashboard`
129
171
 
130
172
  Start the web dashboard for browsing and managing memories.
@@ -153,9 +195,12 @@ Starts the stdio MCP server. This is what harnesses connect to — `setup` write
153
195
 
154
196
  ## Session hooks
155
197
 
156
- `setup` installs a hook for Claude Code that injects memories at the start of each session:
198
+ `setup` installs hooks for each supported harness:
157
199
 
158
- **SessionStart** — calls `membank inject` to prepend pinned memories into the LLM context at the beginning of every session.
200
+ - **claude-code** — SessionStart, UserPromptSubmit, Stop hooks in `~/.claude/settings.json`
201
+ - **copilot** — MCP server config only (no session hooks)
202
+ - **codex** — SessionStart, UserPromptSubmit, Stop hooks in `~/.codex/hooks.json`
203
+ - **opencode** — `session.start` plugin at `~/.config/opencode/plugins/membank.js`
159
204
 
160
205
  ## Requirements
161
206
 
package/dist/index.mjs CHANGED
@@ -288,6 +288,10 @@ async function buildText() {
288
288
  }
289
289
  }
290
290
  async function handleEvent(harness, eventName) {
291
+ if (harness === "claude-code" && eventName === "Stop") {
292
+ process.stdout.write("{}");
293
+ return;
294
+ }
291
295
  const text = await buildText().catch((err) => {
292
296
  const msg = err instanceof Error ? err.message : String(err);
293
297
  process.stderr.write(`membank inject: ${msg}\n`);
@@ -1483,7 +1487,7 @@ var SetupOrchestrator = class {
1483
1487
  modelDownloaded = !(await this.#runModelDownload(this.#modelDownloader, out)).skipped;
1484
1488
  } else out("Model download step: see DRA-52");
1485
1489
  if (this.#synthesisOptIn && !yes && !json) {
1486
- if (await this.#prompter("Enable memory synthesis? (experimental — summarizes memories at session start using Claude Haiku, requires ANTHROPIC_API_KEY)")) {
1490
+ if (await this.#prompter("Enable memory synthesis? (experimental — summarizes memories using Claude Haiku via your local claude CLI. Requires one of: claude auth login, ANTHROPIC_API_KEY, or CLAUDE_CODE_OAUTH_TOKEN from `claude setup-token`)")) {
1487
1491
  ConfigManager.set("synthesis.enabled", true);
1488
1492
  out(" ✓ Memory synthesis enabled.");
1489
1493
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@membank/cli",
3
- "version": "0.10.0",
3
+ "version": "0.10.2",
4
4
  "type": "module",
5
5
  "repository": {
6
6
  "type": "git",
@@ -21,9 +21,9 @@
21
21
  "commander": "^14.0.3",
22
22
  "ora": "^9.4.0",
23
23
  "zod": "^4.4.3",
24
- "@membank/core": "0.9.0",
25
- "@membank/dashboard": "0.5.1",
26
- "@membank/mcp": "0.11.0"
24
+ "@membank/core": "0.9.1",
25
+ "@membank/dashboard": "0.5.2",
26
+ "@membank/mcp": "0.11.2"
27
27
  },
28
28
  "devDependencies": {
29
29
  "@types/node": "^25.6.0",