superlocalmemory 4.1.22 → 4.1.24

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.
Files changed (172) hide show
  1. package/.claude-plugin/marketplace.json +2 -2
  2. package/CHANGELOG.md +145 -0
  3. package/README.md +72 -46
  4. package/antigravity-plugin/_GENERATED.md +33 -0
  5. package/antigravity-plugin/agents/slm-governance-advisor.md +78 -0
  6. package/antigravity-plugin/agents/slm-loop-runner.md +82 -0
  7. package/antigravity-plugin/agents/slm-memory-advisor.md +50 -0
  8. package/antigravity-plugin/agents/slm-optimize-advisor.md +44 -0
  9. package/antigravity-plugin/commands/slm-loop.md +33 -0
  10. package/antigravity-plugin/hooks/hooks.json +59 -0
  11. package/antigravity-plugin/hooks.json +42 -0
  12. package/antigravity-plugin/mcp_config.json +14 -0
  13. package/antigravity-plugin/plugin.json +25 -0
  14. package/antigravity-plugin/scripts/antigravity_hook_adapter.py +85 -0
  15. package/antigravity-plugin/skills/slm-bot-memory/SKILL.md +146 -0
  16. package/antigravity-plugin/skills/slm-cache/SKILL.md +147 -0
  17. package/antigravity-plugin/skills/slm-compress/SKILL.md +150 -0
  18. package/antigravity-plugin/skills/slm-getting-started-bot/SKILL.md +146 -0
  19. package/antigravity-plugin/skills/slm-governance/SKILL.md +221 -0
  20. package/antigravity-plugin/skills/slm-graph/SKILL.md +327 -0
  21. package/antigravity-plugin/skills/slm-loop/SKILL.md +153 -0
  22. package/antigravity-plugin/skills/slm-mesh/SKILL.md +287 -0
  23. package/antigravity-plugin/skills/slm-profile/SKILL.md +159 -0
  24. package/antigravity-plugin/skills/slm-recall/SKILL.md +430 -0
  25. package/antigravity-plugin/skills/slm-remember/SKILL.md +370 -0
  26. package/antigravity-plugin/skills/slm-scope/SKILL.md +183 -0
  27. package/antigravity-plugin/skills/slm-session/SKILL.md +291 -0
  28. package/antigravity-plugin/skills/slm-status/SKILL.md +185 -0
  29. package/antigravity-plugin/skills/slm-web-access/SKILL.md +93 -0
  30. package/codex-plugin/.claude-plugin/plugin.json +19 -0
  31. package/codex-plugin/.codex/config.toml +40 -0
  32. package/codex-plugin/.codex-plugin/plugin.json +43 -0
  33. package/codex-plugin/.mcp.json +16 -0
  34. package/codex-plugin/AGENTS.md +161 -0
  35. package/codex-plugin/README.md +205 -0
  36. package/codex-plugin/_GENERATED.md +52 -0
  37. package/codex-plugin/agents/slm-governance-advisor.md +78 -0
  38. package/codex-plugin/agents/slm-loop-runner.md +82 -0
  39. package/codex-plugin/agents/slm-memory-advisor.md +50 -0
  40. package/codex-plugin/agents/slm-optimize-advisor.md +44 -0
  41. package/codex-plugin/commands/slm-loop.md +33 -0
  42. package/codex-plugin/hooks/hooks.json +59 -0
  43. package/codex-plugin/scripts/ensure-venv.bat +108 -0
  44. package/codex-plugin/scripts/ensure-venv.sh +100 -0
  45. package/codex-plugin/scripts/slm-launch +55 -0
  46. package/codex-plugin/scripts/slm-launch.bat +30 -0
  47. package/codex-plugin/skills/slm-bot-memory/SKILL.md +146 -0
  48. package/codex-plugin/skills/slm-cache/SKILL.md +147 -0
  49. package/codex-plugin/skills/slm-compress/SKILL.md +150 -0
  50. package/codex-plugin/skills/slm-getting-started-bot/SKILL.md +146 -0
  51. package/codex-plugin/skills/slm-governance/SKILL.md +221 -0
  52. package/codex-plugin/skills/slm-graph/SKILL.md +327 -0
  53. package/codex-plugin/skills/slm-loop/SKILL.md +153 -0
  54. package/codex-plugin/skills/slm-mesh/SKILL.md +287 -0
  55. package/codex-plugin/skills/slm-profile/SKILL.md +159 -0
  56. package/codex-plugin/skills/slm-recall/SKILL.md +430 -0
  57. package/codex-plugin/skills/slm-remember/SKILL.md +370 -0
  58. package/codex-plugin/skills/slm-scope/SKILL.md +183 -0
  59. package/codex-plugin/skills/slm-session/SKILL.md +291 -0
  60. package/codex-plugin/skills/slm-status/SKILL.md +185 -0
  61. package/codex-plugin/skills/slm-web-access/SKILL.md +93 -0
  62. package/copilot-plugin/.github/agents/slm-governance-advisor.agent.md +80 -0
  63. package/copilot-plugin/.github/agents/slm-loop-runner.agent.md +84 -0
  64. package/copilot-plugin/.github/agents/slm-memory-advisor.agent.md +52 -0
  65. package/copilot-plugin/.github/agents/slm-optimize-advisor.agent.md +46 -0
  66. package/copilot-plugin/.github/copilot-instructions.md +52 -0
  67. package/copilot-plugin/.github/hooks/slm-hooks.json +44 -0
  68. package/copilot-plugin/.github/prompts/slm-bot-memory.prompt.md +147 -0
  69. package/copilot-plugin/.github/prompts/slm-cache.prompt.md +151 -0
  70. package/copilot-plugin/.github/prompts/slm-compress.prompt.md +154 -0
  71. package/copilot-plugin/.github/prompts/slm-getting-started-bot.prompt.md +147 -0
  72. package/copilot-plugin/.github/prompts/slm-governance.prompt.md +224 -0
  73. package/copilot-plugin/.github/prompts/slm-graph.prompt.md +322 -0
  74. package/copilot-plugin/.github/prompts/slm-loop.prompt.md +159 -0
  75. package/copilot-plugin/.github/prompts/slm-mesh.prompt.md +290 -0
  76. package/copilot-plugin/.github/prompts/slm-profile.prompt.md +155 -0
  77. package/copilot-plugin/.github/prompts/slm-recall.prompt.md +434 -0
  78. package/copilot-plugin/.github/prompts/slm-remember.prompt.md +375 -0
  79. package/copilot-plugin/.github/prompts/slm-scope.prompt.md +183 -0
  80. package/copilot-plugin/.github/prompts/slm-session.prompt.md +291 -0
  81. package/copilot-plugin/.github/prompts/slm-status.prompt.md +190 -0
  82. package/copilot-plugin/.github/prompts/slm-web-access.prompt.md +97 -0
  83. package/copilot-plugin/.vscode/mcp.json +11 -0
  84. package/copilot-plugin/README.md +26 -0
  85. package/copilot-plugin/_GENERATED.md +49 -0
  86. package/copilot-plugin/scripts/ensure-venv.bat +122 -0
  87. package/copilot-plugin/scripts/ensure-venv.sh +169 -0
  88. package/copilot-plugin/scripts/slm-launch +207 -0
  89. package/copilot-plugin/scripts/slm-launch.bat +32 -0
  90. package/copilot-plugin/scripts/slm-resolve.sh +128 -0
  91. package/copilot-plugin/scripts/slm-run +76 -0
  92. package/copilot-plugin/scripts/torch-cpu-resolve.sh +86 -0
  93. package/docs/pi-dev-integration.md +0 -2
  94. package/hermes-plugin/README.md +30 -0
  95. package/hermes-plugin/_GENERATED.md +3 -0
  96. package/hermes-plugin/__init__.py +417 -0
  97. package/hermes-plugin/agents/slm-governance-advisor.md +78 -0
  98. package/hermes-plugin/agents/slm-loop-runner.md +82 -0
  99. package/hermes-plugin/agents/slm-memory-advisor.md +50 -0
  100. package/hermes-plugin/agents/slm-optimize-advisor.md +44 -0
  101. package/hermes-plugin/command-inventory.json +7 -0
  102. package/hermes-plugin/plugin.yaml +24 -0
  103. package/hermes-plugin/remote.py +390 -0
  104. package/hermes-plugin/skills/slm-bot-memory/SKILL.md +146 -0
  105. package/hermes-plugin/skills/slm-cache/SKILL.md +147 -0
  106. package/hermes-plugin/skills/slm-compress/SKILL.md +150 -0
  107. package/hermes-plugin/skills/slm-getting-started-bot/SKILL.md +146 -0
  108. package/hermes-plugin/skills/slm-governance/SKILL.md +221 -0
  109. package/hermes-plugin/skills/slm-graph/SKILL.md +327 -0
  110. package/hermes-plugin/skills/slm-loop/SKILL.md +153 -0
  111. package/hermes-plugin/skills/slm-mesh/SKILL.md +287 -0
  112. package/hermes-plugin/skills/slm-profile/SKILL.md +159 -0
  113. package/hermes-plugin/skills/slm-recall/SKILL.md +430 -0
  114. package/hermes-plugin/skills/slm-remember/SKILL.md +370 -0
  115. package/hermes-plugin/skills/slm-scope/SKILL.md +183 -0
  116. package/hermes-plugin/skills/slm-session/SKILL.md +291 -0
  117. package/hermes-plugin/skills/slm-status/SKILL.md +185 -0
  118. package/hermes-plugin/skills/slm-web-access/SKILL.md +93 -0
  119. package/package.json +9 -18
  120. package/plugin/.claude-plugin/plugin.json +1 -1
  121. package/plugin/.cursor-plugin/plugin.json +1 -1
  122. package/plugin/CLAUDE.md +14 -12
  123. package/plugin/agents/slm-governance-advisor.md +14 -16
  124. package/plugin/agents/slm-loop-runner.md +22 -11
  125. package/plugin/agents/slm-memory-advisor.md +14 -14
  126. package/plugin/agents/slm-optimize-advisor.md +5 -5
  127. package/plugin/commands/slm-loop.md +5 -3
  128. package/plugin/cursor-skills/slm-bot-memory/SKILL.md +19 -12
  129. package/plugin/cursor-skills/slm-getting-started-bot/SKILL.md +17 -9
  130. package/plugin/cursor-skills/slm-recall/SKILL.md +151 -54
  131. package/plugin/cursor-skills/slm-remember/SKILL.md +132 -35
  132. package/plugin/cursor-skills/slm-scope/SKILL.md +24 -17
  133. package/plugin/cursor-skills/slm-session/SKILL.md +77 -57
  134. package/plugin/mcp.cursor.json +1 -1
  135. package/plugin/requirements.txt +1 -1
  136. package/plugin/skills/slm-bot-memory/SKILL.md +19 -12
  137. package/plugin/skills/slm-cache/SKILL.md +6 -7
  138. package/plugin/skills/slm-compress/SKILL.md +3 -3
  139. package/plugin/skills/slm-getting-started-bot/SKILL.md +17 -9
  140. package/plugin/skills/slm-governance/SKILL.md +126 -153
  141. package/plugin/skills/slm-graph/SKILL.md +27 -15
  142. package/plugin/skills/slm-loop/SKILL.md +74 -20
  143. package/plugin/skills/slm-mesh/SKILL.md +17 -12
  144. package/plugin/skills/slm-profile/SKILL.md +101 -92
  145. package/plugin/skills/slm-recall/SKILL.md +151 -54
  146. package/plugin/skills/slm-remember/SKILL.md +132 -35
  147. package/plugin/skills/slm-scope/SKILL.md +24 -17
  148. package/plugin/skills/slm-session/SKILL.md +77 -57
  149. package/plugin/skills/slm-status/SKILL.md +54 -35
  150. package/plugin/skills/slm-web-access/SKILL.md +93 -0
  151. package/plugin-src/agents/slm-governance-advisor.md +78 -0
  152. package/plugin-src/agents/slm-loop-runner.md +82 -0
  153. package/plugin-src/agents/slm-memory-advisor.md +14 -14
  154. package/plugin-src/agents/slm-optimize-advisor.md +5 -5
  155. package/plugin-src/commands/slm-loop.md +33 -0
  156. package/plugin-src/rules/AGENTS.md +45 -36
  157. package/plugin-src/rules/CLAUDE.md.fragment +47 -0
  158. package/plugin-src/skills/slm-bot-memory/SKILL.md +19 -12
  159. package/plugin-src/skills/slm-cache/SKILL.md +6 -7
  160. package/plugin-src/skills/slm-compress/SKILL.md +3 -3
  161. package/plugin-src/skills/slm-getting-started-bot/SKILL.md +17 -9
  162. package/plugin-src/skills/slm-governance/SKILL.md +126 -153
  163. package/plugin-src/skills/slm-graph/SKILL.md +27 -15
  164. package/plugin-src/skills/slm-loop/SKILL.md +74 -20
  165. package/plugin-src/skills/slm-mesh/SKILL.md +17 -12
  166. package/plugin-src/skills/slm-profile/SKILL.md +101 -92
  167. package/plugin-src/skills/slm-recall/SKILL.md +151 -54
  168. package/plugin-src/skills/slm-remember/SKILL.md +132 -35
  169. package/plugin-src/skills/slm-scope/SKILL.md +24 -17
  170. package/plugin-src/skills/slm-session/SKILL.md +77 -57
  171. package/plugin-src/skills/slm-status/SKILL.md +54 -35
  172. package/plugin-src/skills/slm-web-access/SKILL.md +93 -0
@@ -1,8 +1,8 @@
1
1
  ---
2
2
  name: slm-loop
3
- description: Run gate-verified bounded loops with SuperLocalMemory as the durable ledger. Use when a task has a checkable acceptance condition (tests, schema, lint, reconciliation) and you must iterate until an INDEPENDENT gate passes — never stopping just because the agent believes it is done. `slm loop demo` runs a keyless convergence demo; `slm loop history` and `slm loop show <run_id>` inspect past runs whose every lap is persisted as queryable SLM memory (tag `loop:<name>`). Terminal statuses are DONE / HALT / PAUSE / KILLED / ERROR — report them exactly, never converting HALT/PAUSE/ERROR into success.
4
- when_to_use: "run a bounded loop, gate-verified task, iterate until tests pass, verify against an independent gate, don't trust the agent's own done claim, slm loop, convergence loop, loop until green, loop ledger, resume a loop"
5
- allowed-tools: Bash, recall
3
+ description: Gate-verified bounded loops with SuperLocalMemory as the durable ledger. Use when a task has a checkable acceptance condition and you must iterate until an INDEPENDENT gate passes — never stopping because the agent believes it is done. `slm_loop_run` (MCP) waits, under hard bounds, for a recall gate to pass; `slm loop demo` shows the control flow keyless; `slm loop history` and `slm loop show <run_id>` (or `slm_loop_history` / `slm_loop_show`) inspect past runs, whose every lap is stored as queryable SLM memory (tag `loop:<name>`). Terminal statuses are DONE / HALT / PAUSE / KILLED / ERROR — report them exactly, never converting HALT/PAUSE/ERROR into success.
4
+ when_to_use: "run a bounded loop, gate-verified task, iterate until tests pass, verify against an independent gate, don't trust the agent's own done claim, slm loop, convergence loop, loop until green, loop ledger, wait for another agent's result"
5
+ allowed-tools: slm_loop_run, slm_loop_history, slm_loop_show, recall, Bash
6
6
  ---
7
7
 
8
8
  # slm-loop — Bounded, gate-verified agent loops
@@ -16,19 +16,71 @@ this skill: **the gate is the authority.**
16
16
 
17
17
  Use a bounded loop whenever the goal has a mechanical, checkable contract: a
18
18
  test suite, a JSON schema, a linter, a reconciliation rule, a citation checker,
19
- a security scan. When the goal is subjective, keep a human approval gate (see
20
- rungs below).
19
+ a security scan. When the goal is subjective, keep a human approval gate.
20
+
21
+ ## What SLM runs, and what you run
22
+
23
+ SLM's loop engine runs the laps, enforces the bounds, calls the gate and writes
24
+ the ledger. It does **not** start your tests or linters: it carries no
25
+ subprocess or sandbox machinery. What each surface gives you:
26
+
27
+ | Surface | What it does |
28
+ |---|---|
29
+ | `slm_loop_run` (MCP) | A *watcher*: each lap is a recall of `gate_query`; the loop ends when a confident match appears, or a bound trips. Use it to wait for a verification or coordination memory another agent will write (for example "build passed"). |
30
+ | `slm loop demo` (CLI) | A keyless convergence demo: a stub proposer, a deterministic gate that passes on lap 3, every lap recorded. Proves the engine and ledger work end to end. |
31
+ | `slm loop history`, `slm loop show` / `slm_loop_history`, `slm_loop_show` | Read the ledger of past runs. |
32
+ | `superlocalmemory.loops.run_bounded_loop` (Python) | The engine itself, for code that supplies its own runner and gate callables. |
33
+
34
+ For a task whose gate is a command (`pytest -q`, a schema validation), you run
35
+ that command yourself each lap with Bash and read its exit code; the discipline
36
+ below still applies, but SLM is not recording those laps. For graph runs with
37
+ receipts, use the separate Bounded Loops product; SLM can take a read-only
38
+ snapshot of its finished runs with `observe_bounded_loop_evidence(workspace)`
39
+ (an absolute path), which records observations only and never changes recall or
40
+ ranking.
21
41
 
22
42
  ## What SLM adds
23
43
 
24
- Every lap is written to SuperLocalMemory as a durable, queryable memory (tagged
25
- `loop:<name>`, session `loop:<run_id>`). That makes a run:
44
+ Every lap SLM runs is written as a durable, queryable memory (tagged `loop:<name>`,
45
+ session `loop:<run_id>`). That makes a run:
26
46
 
27
- - **auditable** — inspect the decision + gate verdict + budget for each lap;
28
- - **resumable / historical** — a run's ledger survives across sessions;
47
+ - **auditable** — inspect the decision, gate verdict and budget for each lap;
48
+ - **historical** — a run's ledger survives across sessions;
29
49
  - **discoverable** — visible via `slm recall`, the dashboard, and any
30
50
  SLM-integrated tool, alongside everything else the agent remembers.
31
51
 
52
+ ## MCP: `slm_loop_run`
53
+
54
+ ```
55
+ slm_loop_run(
56
+ name: str, # 1–128 chars; also the memory tag
57
+ gate_query: str, # the recall the gate checks each lap (up to 2000 chars)
58
+ gate_min_score: float = 0.0, # minimum top-result score to pass
59
+ max_iterations: int = 20, # hard lap cap, 1–200
60
+ max_wallclock_s: float = 15.0,# hard time cap; 0 disables; never more than 120
61
+ poll_interval_s: float = 1.0, # wait between laps; at least 0.25
62
+ max_tokens: int = 0, # optional token budget; 0 disables
63
+ no_progress_window: int = 0, # halt after N no-change laps; leave 0 for a watcher
64
+ require_support: bool = False,# pass only if the answer check ran and judged it sufficient
65
+ )
66
+ ```
67
+
68
+ The call **blocks** until the gate passes or a bound trips, then returns
69
+ `{ok, status, reason, passed, laps, run_id, ledger: [{lap, decision, passed, detail}]}`.
70
+ The gate recalls at most three memories per lap and ignores the loop's own
71
+ ledger entries, so only a memory written by someone else can satisfy it. A
72
+ recall the answer check judged insufficient never passes, even with a high
73
+ score; with `require_support=True` an unchecked recall (check off, busy,
74
+ loading, out of time) does not pass either. When the answer check is on, each
75
+ lap asks it once about those memories; with the online check that is a request
76
+ to the provider and may be billed. `slm_loop_run` is not available to remote
77
+ callers.
78
+
79
+ ```
80
+ slm_loop_history(name, limit=20) # runs recorded under a loop name
81
+ slm_loop_show(run_id, limit=200) # every lap of one run, in order
82
+ ```
83
+
32
84
  ## CLI
33
85
 
34
86
  ```bash
@@ -37,9 +89,7 @@ slm loop history [--name NAME] [--json] # list recorded runs
37
89
  slm loop show <run_id> [--json] # every lap of one run
38
90
  ```
39
91
 
40
- `slm loop demo` proposes a fix, checks it against a deterministic gate that
41
- passes on lap 3, and records the run — a zero-setup way to see the control flow
42
- and confirm the SLM-backed ledger works end to end.
92
+ There is no `slm loop run`.
43
93
 
44
94
  ## The bounds
45
95
 
@@ -49,11 +99,14 @@ A loop runs inside a safety envelope. Any bound tripping ends the run with
49
99
  - **max_iterations** — a hard lap cap.
50
100
  - **no_progress_window** — consecutive no-change laps before halting a spinning
51
101
  agent.
52
- - **token budget / wall-clock** — cumulative ceilings.
53
- - **kill switch** — set `SLM_LOOP_KILL` to stop before the next lap.
102
+ - **token budget / wall-clock** — cumulative ceilings, checked again after each
103
+ lap, so an overshooting lap halts even if its gate would pass.
104
+ - **kill switch** — a non-empty `SLM_LOOP_KILL` in the loop's process
105
+ environment stops it before the next lap, with status `KILLED`.
54
106
  - **approval rung** — L1 (report), L2 (assisted, pauses for approval), L3
55
- (unattended). L2/L3 require approval before a passing gate is accepted as
56
- DONE unless approval is explicitly configured off.
107
+ (unattended). L2 and L3 require approval before a passing gate is accepted as
108
+ DONE unless approval is explicitly configured off. `slm_loop_run` and the demo
109
+ run at L1, so `PAUSE` arises only from code that sets a higher rung.
57
110
 
58
111
  ## Terminal statuses — report exactly
59
112
 
@@ -72,8 +125,8 @@ paused, name the approval needed; when errored, quote the short detail.
72
125
  ## Reporting workflow
73
126
 
74
127
  1. Run or resume the loop.
75
- 2. Read back the ledger with `slm loop show <run_id>` (or `slm recall` on tag
76
- `loop:<name>`).
128
+ 2. Read back the ledger with `slm_loop_show` or `slm loop show <run_id>` (or
129
+ `slm recall` on tag `loop:<name>`).
77
130
  3. Report the exact terminal status, the lap count, and the gate's final
78
131
  verdict. Include the `run_id` so the run can be re-inspected later.
79
132
 
@@ -91,9 +144,10 @@ paused, name the approval needed; when errored, quote the short detail.
91
144
  ## Related skills
92
145
 
93
146
  - `slm-status` — confirm SLM is healthy before relying on the ledger.
94
- - `slm-recall` — query a loop's laps directly (`loop:<name>` tag).
147
+ - `slm-recall` — query a loop's laps directly (`loop:<name>` tag), and the
148
+ answer-check fields the recall gate depends on.
95
149
  - `slm-session` — session lifecycle around a longer loop run.
96
150
 
97
151
  ---
98
152
 
99
- SuperLocalMemory v4.1.22 · Qualixar · AGPL-3.0-or-later
153
+ SuperLocalMemory v4.1.24 · Qualixar · AGPL-3.0-or-later
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: slm-mesh
3
- description: Cross-session peer coordination via the SLM mesh network. Lets multiple AI agent sessions on the same machine discover each other, send messages, share lightweight state, and lock files to avoid conflicts. Requires full, power, or mesh MCP profile. All 8 tools are MCP-only — there is no CLI fallback.
3
+ description: Cross-session peer coordination via the SLM mesh network. Lets multiple AI agent sessions on the same machine discover each other, send messages, share lightweight state, and lock files to avoid conflicts. Available in the default tool set and in the full, power and mesh MCP profiles. Only `slm mesh status` and `slm mesh peers` exist on the command line; the other tools are MCP-only.
4
4
  when_to_use: |
5
5
  - Multiple agent sessions running simultaneously on the same machine
6
6
  - "Announce what I'm working on to other sessions"
@@ -19,17 +19,21 @@ each other and coordinate in real time — without writing to the persistent
19
19
  memory store. Mesh messages are transient (48-hour TTL); they complement memory
20
20
  (which is durable) rather than replacing it.
21
21
 
22
- Mesh is local-only: it uses the SLM daemon as a local broker. No data leaves
23
- the machine.
22
+ By default the mesh is local: the SLM daemon on this machine is the broker and
23
+ nothing leaves it. Two machines can be joined only if the user sets
24
+ `SLM_MESH_PEER_URL` and `SLM_MESH_SHARED_SECRET` for their daemons; then peers and
25
+ messages cross to the other machine. Do not configure that yourself.
24
26
 
25
27
  ---
26
28
 
27
29
  ## Profile requirement
28
30
 
29
- Mesh tools are available in the `full`, `power`, and `mesh` MCP profiles.
30
- Confirm the active profile with `slm status` before calling mesh tools. If the
31
- tools are not available, switch to `full` profile with `switch_profile("full")`
32
- (requires `code` or higher active profile). See `slm-profile`.
31
+ Mesh tools are registered in the `full`, `power` and `mesh` MCP tool sets and in
32
+ the default set that applies when the host configures none. They are not in
33
+ `core` or `code`. The tool set is fixed when the MCP server starts, and
34
+ `switch_profile` cannot change it (it changes the active memory profile). If the
35
+ tools are missing, check `SLM_MCP_PROFILE` in the host's MCP config and ask the
36
+ user before changing it. See `slm-profile`.
33
37
 
34
38
  ---
35
39
 
@@ -209,8 +213,9 @@ mesh_status() -> dict
209
213
  Returns broker uptime, peer count, and connection health. Use at session start
210
214
  to confirm the mesh is available before relying on coordination.
211
215
 
212
- Response includes: `broker_up`, `peer_count`, `uptime_seconds`, `my_peer_id`,
213
- `heartbeat_active`.
216
+ Response includes: `broker_up`, `peer_count` (active peers, with
217
+ `remote_peer_count`, `local_session_count` and stale counts alongside),
218
+ `uptime_s`, `my_peer_id`, `heartbeat_active`.
214
219
 
215
220
  ---
216
221
 
@@ -259,7 +264,7 @@ All 8 mesh tools return structured errors — they never raise exceptions.
259
264
 
260
265
  | Error | Cause | Action |
261
266
  |-------|-------|--------|
262
- | `broker_up: false` from `mesh_status` | Daemon not running or mesh not configured | Run `slm status` to check daemon health |
267
+ | `broker_up: false` from `mesh_status` | Daemon not running or mesh not configured | Run `slm mesh status` (prints the broker's answer) or `slm status` to check daemon health |
263
268
  | `ok: false` from `mesh_send` with circuit-breaker message | Repeated daemon unreachability | Daemon unreachable; stop sending until broker is up |
264
269
  | `ok: false` from `mesh_lock` | Lock operation failed | Check `file_path` is absolute; retry once |
265
270
  | Empty `peers` from `mesh_peers` | No other sessions registered | You're the only active session |
@@ -272,11 +277,11 @@ mesh availability.
272
277
 
273
278
  ## Related skills
274
279
 
275
- - `slm-profile` — activate full/power/mesh profile to access mesh tools
280
+ - `slm-profile` — which tool sets include the mesh tools
276
281
  - `slm-scope` — for durable cross-profile sharing (complement to transient mesh state)
277
282
  - `slm-remember` — persist coordination decisions that should survive session end
278
283
  - `slm-governance` — enterprise governance of mesh (who can send/receive)
279
284
 
280
285
  ---
281
286
 
282
- *SuperLocalMemory v4.1.22 · Qualixar · AGPL-3.0-or-later*
287
+ *SuperLocalMemory v4.1.24 · Qualixar · AGPL-3.0-or-later*
@@ -1,150 +1,159 @@
1
1
  ---
2
2
  name: slm-profile
3
- description: Workspace isolation and runtime profile switching for SuperLocalMemory. Each profile is a fully independent memory namespace — separate facts, code graphs, and tool sets. Use switch_profile (MCP, requires code/full/power profile) to change the active workspace without restarting. Check the active profile with slm status. Required when working across multiple projects, clients, or tenants.
3
+ description: Memory profiles (separate namespaces inside one SuperLocalMemory store) and MCP tool sets (which tools your host sees). Use switch_profile or slm profile switch to change the active memory profile, the profile_id argument to read or write another profile for one call, and SLM_MCP_PROFILE to choose a tool set. Required when working across multiple projects, clients, or tenants.
4
4
  when_to_use: |
5
5
  - "Switch to my work profile"
6
- - "Use the code profile for this session"
7
6
  - "What profile am I currently in?"
8
- - "I need mesh tools — switch to full profile"
9
- - "Load the devops workspace"
7
+ - "Create a profile for this client"
8
+ - "Read the work profile once without leaving this one"
9
+ - "I need mesh or code-graph tools" (a tool-set question, not a profile switch)
10
+ - "Why can't I see tool X?"
10
11
  - Multi-project workflows needing memory isolation
11
12
  - Switching between personal and team workspaces
12
- - Enabling additional MCP tools by activating a richer profile
13
- allowed-tools: switch_profile, Bash
13
+ allowed-tools: switch_profile, get_status, Bash
14
14
  ---
15
15
 
16
- # slm-profile — Workspace Isolation and Profile Switching
16
+ # slm-profile — Memory Profiles and Tool Sets
17
17
 
18
- A profile is a fully isolated memory workspace. Each profile has its own:
19
- - Memory facts (nothing bleeds across profiles by default)
20
- - Code graph index (separate per repo/project)
21
- - Active MCP tool set (determined by profile tier)
22
- - Retention policy and decay settings
18
+ Two different things are called "profile" in SuperLocalMemory. Keep them apart.
23
19
 
24
- Profiles are the right tool when you have genuinely separate contexts: a personal
25
- project, a client engagement, a production vs staging environment.
20
+ - A **memory profile** is a namespace inside one store. It has its own memories,
21
+ knowledge graph, learned patterns, retention settings and audit trail. A fresh
22
+ install has one, called `default`. This is what `switch_profile`,
23
+ `slm profile` and the `profile_id` argument are about.
24
+ - An **MCP tool set** (`SLM_MCP_PROFILE`: `core`, `code`, `full`, `power`,
25
+ `mesh`) decides which tools the server shows your host. `switch_profile` does
26
+ not change it.
26
27
 
27
- ---
28
-
29
- ## Available profiles and their tool sets
30
-
31
- | Profile | Tools | When to use |
32
- |---------|-------|-------------|
33
- | `core` | 18 tools — remember, recall, search, session, optimize | Minimal footprint, no code tools |
34
- | `code` | 38 tools — core + portable Brain evidence + code graph + profile switching + bounded loops + memory-kind management | Default for IDE/coding agents |
35
- | `full` | 56 tools — code + all memory ops + mesh + bounded loops | Multi-session, team workflows |
36
- | `power` | 68 tools — full + governance + behavioral tools | Enterprise, admin, audit use cases |
37
- | `mesh` | 8 tools — mesh coordination only | Lightweight cross-session signalling |
38
-
39
- The profile is set at MCP server startup via `SLM_MCP_PROFILE` in the MCP config.
40
- `switch_profile` lets you change it at runtime without a restart.
28
+ A memory profile organises memory. It is not a security boundary: any local
29
+ caller that can name a profile can read it, unless the user has turned on company
30
+ mode with roles. For memories that must be unreachable from another bot or user,
31
+ use a separate data directory (`SLM_DATA_DIR`) or company mode (`slm-governance`).
41
32
 
42
33
  ---
43
34
 
44
- ## Checking the active profile
35
+ ## Memory profiles
45
36
 
46
37
  ```bash
47
- slm status --json
38
+ slm profile list [--json]
39
+ slm profile create <name> [--json]
40
+ slm profile switch <name> [--json]
41
+ slm status --json # data.profile is the active profile
48
42
  ```
49
43
 
50
- The `profile` field in the output is the currently active profile name.
51
-
52
- Or via MCP (works in any profile):
44
+ Creating a profile is a CLI action; there is no MCP tool for it. Over MCP:
53
45
 
54
- ```bash
55
- slm status
46
+ ```
47
+ switch_profile(
48
+ profile_id: str, # the name of an existing profile
49
+ )
56
50
  ```
57
51
 
58
- ---
52
+ `switch_profile` changes the **active profile**. The change is not private to
53
+ your session: it is written as the machine's active profile, so every later call
54
+ from every session on this machine, and the dashboard, now work in it until
55
+ someone switches again. An unknown name is refused (`Profile '<name>' does not
56
+ exist`); nothing is created. In company mode it also needs a role on the target
57
+ profile. Only switch when the user asks to move; do not switch to peek at
58
+ something.
59
59
 
60
- ## Switching profiles at runtime (v3.8.0+)
60
+ ### Reaching another profile for one call
61
61
 
62
- `switch_profile` is available in `code`, `full`, and `power` profiles.
62
+ Most tools take an optional `profile_id`: `remember`, `recall`, `search`,
63
+ `fetch`, `list_recent`, `update_memory`, `delete_memory`, `session_init`,
64
+ `close_session`, `report_outcome`, `report_feedback`, `get_status`,
65
+ `get_memory_summary`, the correction and memory-kind tools, and others. A
66
+ non-empty value serves that one call from that profile (which must already
67
+ exist) and **never moves the active profile**. An empty value means the active
68
+ profile. Prefer this to switching and switching back.
63
69
 
64
70
  ```
65
- switch_profile(
66
- profile: str, # one of: "core", "code", "full", "power", "mesh"
67
- )
71
+ recall(query="rollout plan", profile_id="work", session_id="<sid>")
72
+ remember(content="...", tags="ops", profile_id="client-acme")
68
73
  ```
69
74
 
70
- ### Example: activate full profile to access mesh tools
75
+ `forget` and the mesh tools take no `profile_id`; they act on the active profile.
71
76
 
72
- ```
73
- # You started in code profile but need mesh coordination
74
- switch_profile(profile="full")
77
+ ### What a profile isolates
75
78
 
76
- # Now mesh_peers, mesh_send, mesh_inbox, etc. are available
77
- mesh_peers()
78
- ```
79
+ - `recall` returns only the profile's own memories, plus shared or global ones
80
+ only when you opt in (see `slm-scope`).
81
+ - `remember` writes to the profile you name or the active one.
82
+ - The code graph is not partitioned by profile: it lives in `code_graph.db` in the data directory.
83
+ - The `slm_cache_*` key-value cache and `slm_compress` recovery store are keyed
84
+ by the calling agent, not by profile, so switching profiles does not give you
85
+ a clean cache (see `slm-cache`).
79
86
 
80
- ### Example: switch workspaces
87
+ ### Separate stores
81
88
 
82
- ```
83
- # Switch from personal to work workspace
84
- switch_profile(profile="work-project")
85
- ```
89
+ To keep two bots or two clients completely apart, give each its own
90
+ `SLM_DATA_DIR` in its MCP config. You can run several SLM MCP servers at once,
91
+ named differently (for example `superlocalmemory-personal` and
92
+ `superlocalmemory-work`), each pointed at its own directory.
86
93
 
87
- Wait — profile names and workspace names are distinct concepts:
88
- - **Profile tier** (`core`, `code`, `full`, `power`, `mesh`) controls which MCP
89
- tools are registered.
90
- - **Workspace / data directory** (`SLM_DATA_DIR`) controls which memory database
91
- is used.
94
+ ---
92
95
 
93
- `switch_profile` changes the **tool tier** within the current workspace. To
94
- switch to a completely different memory database (workspace), you need to change
95
- `SLM_DATA_DIR` — this requires restarting the MCP server or using a separately
96
- configured MCP server instance.
96
+ ## MCP tool sets
97
97
 
98
- ---
98
+ | Profile | Tools | What it is |
99
+ |---------|-------|------------|
100
+ | `core` | 18 tools — remember, recall, search, fetch, list_recent, update_memory, forget, session, optimize, corrections, summaries, switch_profile | Smallest set; the Grok Bot / Cursor plugin uses it |
101
+ | `code` | 38 tools — core + portable Brain evidence, report_outcome/report_feedback, 6 code-graph tools, memory kinds, bounded loops | For coding agents that need the graph; no mesh, no `get_status` |
102
+ | `full` | 56 tools — everyday memory, delete_memory, get_status, observe, saved views, learning tools, skills, optimize, kinds, loops, mesh | Same set as the no-profile default |
103
+ | `power` | 68 tools — full + audit_trail, retention, compaction, consistency_check, behavioral and diagnostic tools | Governance and admin work |
104
+ | `mesh` | 8 tools — mesh coordination only | Lightweight cross-session signalling |
99
105
 
100
- ## Configuring the initial profile
106
+ A host that sets no profile gets the 56-tool `full` set (this is what the Claude
107
+ Code and Codex plugins do; the Antigravity plugin sets `power`). Two more
108
+ environment variables widen or narrow it: `SLM_MCP_ALL_TOOLS=1` registers every
109
+ tool (103), and `SLM_MCP_TOOLS=remember,recall,...` registers exactly the names
110
+ listed. `SLM_MCP_PROFILE=whole` is also every tool. The code-graph tools beyond
111
+ the six in `code` (such as `update_code_graph`, `list_graph_stats`) and tools
112
+ such as `core_memory` and `settle_session_outcomes` exist only with
113
+ `SLM_MCP_ALL_TOOLS=1`, `whole` or an explicit `SLM_MCP_TOOLS` list. Tools whose
114
+ function is to manage the SLM computer are never available to a remote caller.
101
115
 
102
- Set it where your host defines the MCP server's environment — `.mcp.json` (Claude
103
- Code), `.codex/config.toml` (Codex), or `mcp.cursor.json` (Cursor / Grok Bot):
116
+ The tool set is read when the MCP server starts. To change it, set it in the
117
+ host's MCP config and restart the host; asking the server at runtime does not
118
+ work:
104
119
 
105
120
  ```json
106
121
  "env": {
107
122
  "SLM_MCP_PROFILE": "code",
108
- "SLM_AGENT_ID": "claude_code",
109
- "SLM_DATA_DIR": "~/.superlocalmemory"
123
+ "SLM_AGENT_ID": "claude_code"
110
124
  }
111
125
  ```
112
126
 
113
- Profile aliases from older versions still resolve: `code20` → `code`,
114
- `full38` → `full`, `power50` → `power`. Stale configs get a startup warning
115
- but continue to work.
116
-
117
- ---
118
-
119
- ## Profile isolation guarantees
127
+ `slm connect <ide> --profile <name>` writes that variable into a supported
128
+ host's config. Setting `SLM_MCP_PROFILE` to a name that does not exist stops
129
+ `slm mcp` with a message listing the valid names. Older count-suffixed names
130
+ such as `code20`, `full38` and `power50` still resolve, with a startup warning.
131
+ On an install that already has memories, do not set `SLM_DATA_DIR` in the MCP
132
+ config: it points the host at a different, empty store.
120
133
 
121
- - `recall` returns only memories in the active profile (plus opt-in shared/global
122
- facts — see `slm-scope`).
123
- - `remember` writes to the active profile only unless `scope="shared"/"global"`.
124
- - Code graph tools (`build_code_graph`, `get_blast_radius`, etc.) index into the
125
- active profile's graph store.
126
- - KV cache entries are namespaced per profile — switching profiles gives you a
127
- clean cache.
134
+ `switch_profile` is in `core`, `code`, `full` and `power`, and in the default
135
+ set. It is not in `mesh`.
128
136
 
129
137
  ---
130
138
 
131
- ## Multiple concurrent profiles
139
+ ## If a tool is missing
132
140
 
133
- You can run multiple SLM MCP server instances simultaneously, each pointed at a
134
- different `SLM_DATA_DIR`, to serve different workspaces in the same IDE session.
135
- Name them differently in your MCP config (e.g. `superlocalmemory-personal` and
136
- `superlocalmemory-work`) and route tool calls to the appropriate server.
141
+ Check the tool set first (`slm status` does not show it; look at the host's MCP
142
+ config for `SLM_MCP_PROFILE`). Mesh tools need `full`, `power`, `mesh` or the
143
+ default. Code-graph tools need `code` or `SLM_MCP_ALL_TOOLS=1`. Audit and
144
+ retention tools need `power`. `report_outcome` and `report_feedback` need
145
+ anything but `core` or `mesh`.
137
146
 
138
147
  ---
139
148
 
140
149
  ## Related skills
141
150
 
142
151
  - `slm-scope` — opt-in fact sharing across profiles (personal/shared/global)
143
- - `slm-graph` — code-graph tools available in code/full/power profiles
144
- - `slm-mesh` — mesh tools available in full/power/mesh profiles
145
- - `slm-status` — check active profile name and tool inventory
146
- - `slm-governance` — enterprise role-based access to profiles
152
+ - `slm-graph` — code-graph tools and the tool set they need
153
+ - `slm-mesh` — mesh tools and the tool set they need
154
+ - `slm-status` — check the active profile name
155
+ - `slm-governance` — roles and company mode
147
156
 
148
157
  ---
149
158
 
150
- *SuperLocalMemory v4.1.22 · Qualixar · AGPL-3.0-or-later*
159
+ *SuperLocalMemory v4.1.24 · Qualixar · AGPL-3.0-or-later*