@memfork/cli 0.1.41 → 0.1.43

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.
@@ -153,9 +153,8 @@ function upsertCodexMcp(tomlPath, creds) {
153
153
  }
154
154
  const block = `
155
155
  [mcp_servers.memwal]
156
- transport = "http"
157
156
  url = "${creds.relayerUrl}"
158
- headers = { Authorization = "Bearer ${creds.delegateKey}", x-memwal-account-id = "${creds.accountId}", Accept = "application/json, text/event-stream" }
157
+ http_headers = { Authorization = "Bearer ${creds.delegateKey}", x-memwal-account-id = "${creds.accountId}" }
159
158
  `;
160
159
  if (existing.includes("[mcp_servers.memwal]")) {
161
160
  // Replace the existing block — find from the header to the next blank line / EOF.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@memfork/cli",
3
- "version": "0.1.41",
3
+ "version": "0.1.43",
4
4
  "description": "MemForks CLI — init, commit, recall, merge, install plugins",
5
5
  "repository": {
6
6
  "type": "git",
@@ -0,0 +1,70 @@
1
+ ---
2
+ name: memory-commit
3
+ description: >-
4
+ Commit facts to the MemForks memory DAG using memfork commit --facts.
5
+ Use whenever the user says "remember that", "commit this", "save that",
6
+ "note that", "don't forget", or any phrasing that asks you to persist
7
+ a decision, convention, or finding for future sessions.
8
+ ---
9
+
10
+ # Memory Commit
11
+
12
+ When the user asks you to remember something — a decision, a convention, a
13
+ finding — **always use `memfork commit --facts`**, not `memwal_remember`.
14
+
15
+ `memfork commit --facts` does two things in one command:
16
+
17
+ 1. Indexes the facts in MemWal for semantic recall (same as `memwal_remember`)
18
+ 2. Anchors them on-chain on Sui, tagged to the current Git branch
19
+
20
+ `memwal_remember` alone does only step 1. It saves to `namespace=default`
21
+ with no branch scoping and no on-chain anchor. Use it only for transient,
22
+ throwaway notes that don't warrant a permanent record.
23
+
24
+ ## Procedure
25
+
26
+ ### 1. Identify the facts
27
+
28
+ Extract 1–3 concrete, standalone facts from what the user said. Facts should
29
+ be self-contained sentences — readable out of context in a future session.
30
+
31
+ Good:
32
+ ```
33
+ "error handling convention: always wrap in AppError, never throw raw"
34
+ "auth latency target: p99 < 200ms on bcrypt verify"
35
+ ```
36
+
37
+ Bad (too vague, depends on context):
38
+ ```
39
+ "we agreed on this"
40
+ "the thing we discussed"
41
+ ```
42
+
43
+ ### 2. Run the commit
44
+
45
+ ```bash
46
+ memfork commit \
47
+ --message "<one-line summary of the decision>" \
48
+ --facts "<fact 1>" "<fact 2>"
49
+ ```
50
+
51
+ The CLI auto-detects the current Git branch — do **not** pass `--branch`
52
+ unless explicitly targeting a different branch.
53
+
54
+ ### 3. Confirm to the user
55
+
56
+ After the commit succeeds, print a confirmation in this form:
57
+
58
+ ```
59
+ [memforks] Committed to <branch> — "<message>"
60
+ ```
61
+
62
+ Do not print the full CLI output. One line is enough.
63
+
64
+ ## Rules
65
+
66
+ - Never use `memwal_remember` for facts the user explicitly asks to save.
67
+ - Never commit task state, in-progress work, or temporary findings.
68
+ - If `memfork commit` fails (e.g. no tree initialised), tell the user to
69
+ run `memfork init` first and offer to retry.
70
+ - One commit per logical decision — don't batch unrelated facts together.