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
@@ -0,0 +1,290 @@
1
+ ---
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. 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
+ version: "4.1.24"
5
+ agent: agent
6
+ tools:
7
+ - mesh_summary
8
+ - mesh_peers
9
+ - mesh_send
10
+ - mesh_inbox
11
+ - mesh_state
12
+ - mesh_lock
13
+ - mesh_events
14
+ - mesh_status
15
+ - Bash
16
+ ---
17
+
18
+ # slm-mesh — Cross-Session Peer Coordination
19
+
20
+ The mesh network lets multiple AI agent sessions on the same machine discover
21
+ each other and coordinate in real time — without writing to the persistent
22
+ memory store. Mesh messages are transient (48-hour TTL); they complement memory
23
+ (which is durable) rather than replacing it.
24
+
25
+ By default the mesh is local: the SLM daemon on this machine is the broker and
26
+ nothing leaves it. Two machines can be joined only if the user sets
27
+ `SLM_MESH_PEER_URL` and `SLM_MESH_SHARED_SECRET` for their daemons; then peers and
28
+ messages cross to the other machine. Do not configure that yourself.
29
+
30
+ ---
31
+
32
+ ## Profile requirement
33
+
34
+ Mesh tools are registered in the `full`, `power` and `mesh` MCP tool sets and in
35
+ the default set that applies when the host configures none. They are not in
36
+ `core` or `code`. The tool set is fixed when the MCP server starts, and
37
+ `switch_profile` cannot change it (it changes the active memory profile). If the
38
+ tools are missing, check `SLM_MCP_PROFILE` in the host's MCP config and ask the
39
+ user before changing it. See `slm-profile`.
40
+
41
+ ---
42
+
43
+ ## Tool reference
44
+
45
+ ### 1. `mesh_summary` — announce what this session is doing
46
+
47
+ ```
48
+ mesh_summary(summary: str = "") -> dict
49
+ ```
50
+
51
+ Call at session start to register on the mesh and announce your purpose. Other
52
+ sessions can see your summary via `mesh_peers`. The session stays alive via
53
+ automatic heartbeat.
54
+
55
+ ```
56
+ mesh_summary(summary="Refactoring auth module in api/src/auth/")
57
+ ```
58
+
59
+ Response: `{peer_id, summary, project_path, registered, heartbeat_active, broker_response}`
60
+
61
+ Call this once at the start of any session that will participate in the mesh.
62
+ The peer registration happens automatically at MCP startup, but calling
63
+ `mesh_summary` sets the human-readable description that other agents see.
64
+
65
+ ---
66
+
67
+ ### 2. `mesh_peers` — list active sessions
68
+
69
+ ```
70
+ mesh_peers() -> dict
71
+ ```
72
+
73
+ Returns all active peer sessions on this machine.
74
+
75
+ ```
76
+ mesh_peers()
77
+ ```
78
+
79
+ Response: `{peers: [{peer_id, summary, project_path, last_seen}], count, my_peer_id}`
80
+
81
+ Use this to discover other sessions before sending a message or checking for
82
+ conflicts.
83
+
84
+ ---
85
+
86
+ ### 3. `mesh_send` — send a message to another session
87
+
88
+ ```
89
+ mesh_send(
90
+ to: str, # peer_id | "broadcast" | "project:/path/to/dir"
91
+ message: str, # max 4 KB — use file paths for large data
92
+ ) -> dict
93
+ ```
94
+
95
+ Send a targeted, broadcast, or project-wide message.
96
+
97
+ ```
98
+ # Direct message to a specific peer
99
+ peers = await mesh_peers()
100
+ target_id = peers["peers"][0]["peer_id"]
101
+ mesh_send(to=target_id, message="I'm starting work on auth/handler.py — please hold off")
102
+
103
+ # Broadcast to all sessions
104
+ mesh_send(to="broadcast", message="Deploying to staging in 5 minutes")
105
+
106
+ # Message all sessions working in the same project
107
+ mesh_send(to="project:~/myproject", message="Tests are green on main")
108
+ ```
109
+
110
+ **4 KB message cap.** For large payloads (diffs, file contents), write to a file
111
+ and send the path instead. The circuit breaker opens automatically if the daemon
112
+ is repeatedly unreachable — `mesh_send` returns `ok: false` in that case.
113
+
114
+ ---
115
+
116
+ ### 4. `mesh_inbox` — read messages sent to this session
117
+
118
+ ```
119
+ mesh_inbox() -> dict
120
+ ```
121
+
122
+ Returns unread messages (direct, broadcast, and project-targeted). Messages are
123
+ automatically marked as read after retrieval.
124
+
125
+ ```
126
+ inbox = await mesh_inbox()
127
+ for msg in inbox["messages"]:
128
+ print(msg["from"], msg["content"])
129
+ ```
130
+
131
+ Response: `{messages: [{id, from, content, sent_at, read}], count, unread}`
132
+
133
+ Messages auto-expire after 48 hours.
134
+
135
+ ---
136
+
137
+ ### 5. `mesh_state` — get or set shared coordination state
138
+
139
+ ```
140
+ mesh_state(
141
+ key: str = "",
142
+ value: str = "",
143
+ action: str = "get", # "get" | "set"
144
+ ) -> dict
145
+ ```
146
+
147
+ Shared state is visible to all authenticated peers. Use it for non-secret
148
+ coordination metadata: feature flags, task assignments, progress markers.
149
+
150
+ ```
151
+ # Set state
152
+ mesh_state(key="deploy_in_progress", value="true", action="set")
153
+ mesh_state(key="current_reviewer", value=my_peer_id, action="set")
154
+
155
+ # Read one key
156
+ mesh_state(key="deploy_in_progress", action="get")
157
+
158
+ # Read all state
159
+ mesh_state(action="get")
160
+ ```
161
+
162
+ **Security constraint:** Credentials, tokens, passwords, and API keys are
163
+ rejected by the broker. Never store secrets in shared state.
164
+
165
+ ---
166
+
167
+ ### 6. `mesh_lock` — file lock coordination
168
+
169
+ ```
170
+ mesh_lock(
171
+ file_path: str, # must be an absolute path
172
+ action: str = "query", # "query" | "acquire" | "release"
173
+ ) -> dict
174
+ ```
175
+
176
+ Check, acquire, or release a file lock before editing a shared file.
177
+
178
+ ```
179
+ # Step 1: check if the file is already locked
180
+ lock = await mesh_lock(file_path="/abs/path/to/auth/handler.py", action="query")
181
+
182
+ if lock.get("locked"):
183
+ print(f"File is locked by {lock['locked_by']} — wait")
184
+ else:
185
+ # Step 2: acquire the lock
186
+ mesh_lock(file_path="/abs/path/to/auth/handler.py", action="acquire")
187
+
188
+ # ... edit the file ...
189
+
190
+ # Step 3: release the lock when done
191
+ mesh_lock(file_path="/abs/path/to/auth/handler.py", action="release")
192
+ ```
193
+
194
+ `file_path` must be an absolute path (starts with `/` on Unix, drive letter on
195
+ Windows). Relative paths are rejected.
196
+
197
+ ---
198
+
199
+ ### 7. `mesh_events` — recent mesh activity log
200
+
201
+ ```
202
+ mesh_events() -> dict
203
+ ```
204
+
205
+ Returns the activity log for the mesh network: peer joins, leaves, messages sent,
206
+ and state changes. Use to understand what other sessions have been doing.
207
+
208
+ ---
209
+
210
+ ### 8. `mesh_status` — mesh broker health
211
+
212
+ ```
213
+ mesh_status() -> dict
214
+ ```
215
+
216
+ Returns broker uptime, peer count, and connection health. Use at session start
217
+ to confirm the mesh is available before relying on coordination.
218
+
219
+ Response includes: `broker_up`, `peer_count` (active peers, with
220
+ `remote_peer_count`, `local_session_count` and stale counts alongside),
221
+ `uptime_s`, `my_peer_id`, `heartbeat_active`.
222
+
223
+ ---
224
+
225
+ ## Common workflow: parallel agents coordinating on a shared repo
226
+
227
+ ```
228
+ # Both agents call at session start:
229
+ await mesh_summary(summary="Working on feature/auth-refactor")
230
+
231
+ # Agent A: check who else is active
232
+ peers = await mesh_peers()
233
+ # → sees Agent B working on the same project
234
+
235
+ # Agent A: before editing a shared file
236
+ lock = await mesh_lock("/repo/src/auth/handler.py", action="query")
237
+ if not lock.get("locked"):
238
+ await mesh_lock("/repo/src/auth/handler.py", action="acquire")
239
+ # ... edit handler.py ...
240
+ await mesh_lock("/repo/src/auth/handler.py", action="release")
241
+
242
+ # Agent A: after finishing a phase
243
+ await mesh_send(to="project:/repo", message="Auth refactor complete — handler.py ready for review")
244
+
245
+ # Agent B: check inbox
246
+ inbox = await mesh_inbox()
247
+ ```
248
+
249
+ ---
250
+
251
+ ## Mesh vs memory: when to use which
252
+
253
+ | Need | Use |
254
+ |------|-----|
255
+ | Ephemeral coordination signal (< 48h) | `mesh_send` / `mesh_state` |
256
+ | Durable fact across sessions/days | `remember` |
257
+ | File conflict prevention | `mesh_lock` |
258
+ | Cross-profile fact sharing | `scope="shared"/"global"` on `remember` |
259
+ | Session announcement | `mesh_summary` |
260
+ | Finding parallel agents | `mesh_peers` |
261
+
262
+ ---
263
+
264
+ ## Error handling
265
+
266
+ All 8 mesh tools return structured errors — they never raise exceptions.
267
+
268
+ | Error | Cause | Action |
269
+ |-------|-------|--------|
270
+ | `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 |
271
+ | `ok: false` from `mesh_send` with circuit-breaker message | Repeated daemon unreachability | Daemon unreachable; stop sending until broker is up |
272
+ | `ok: false` from `mesh_lock` | Lock operation failed | Check `file_path` is absolute; retry once |
273
+ | Empty `peers` from `mesh_peers` | No other sessions registered | You're the only active session |
274
+
275
+ Mesh failures are non-fatal for the primary task. If `mesh_status` shows
276
+ `broker_up: false`, proceed without mesh coordination — do not block work on
277
+ mesh availability.
278
+
279
+ ---
280
+
281
+ ## Related skills
282
+
283
+ - `slm-profile` — which tool sets include the mesh tools
284
+ - `slm-scope` — for durable cross-profile sharing (complement to transient mesh state)
285
+ - `slm-remember` — persist coordination decisions that should survive session end
286
+ - `slm-governance` — enterprise governance of mesh (who can send/receive)
287
+
288
+ ---
289
+
290
+ *SuperLocalMemory v4.1.24 · Qualixar · AGPL-3.0-or-later*
@@ -0,0 +1,155 @@
1
+ ---
2
+ name: slm-profile
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
+ version: "4.1.24"
5
+ agent: agent
6
+ tools:
7
+ - switch_profile
8
+ - get_status
9
+ - Bash
10
+ ---
11
+
12
+ # slm-profile — Memory Profiles and Tool Sets
13
+
14
+ Two different things are called "profile" in SuperLocalMemory. Keep them apart.
15
+
16
+ - A **memory profile** is a namespace inside one store. It has its own memories,
17
+ knowledge graph, learned patterns, retention settings and audit trail. A fresh
18
+ install has one, called `default`. This is what `switch_profile`,
19
+ `slm profile` and the `profile_id` argument are about.
20
+ - An **MCP tool set** (`SLM_MCP_PROFILE`: `core`, `code`, `full`, `power`,
21
+ `mesh`) decides which tools the server shows your host. `switch_profile` does
22
+ not change it.
23
+
24
+ A memory profile organises memory. It is not a security boundary: any local
25
+ caller that can name a profile can read it, unless the user has turned on company
26
+ mode with roles. For memories that must be unreachable from another bot or user,
27
+ use a separate data directory (`SLM_DATA_DIR`) or company mode (`slm-governance`).
28
+
29
+ ---
30
+
31
+ ## Memory profiles
32
+
33
+ ```bash
34
+ slm profile list [--json]
35
+ slm profile create <name> [--json]
36
+ slm profile switch <name> [--json]
37
+ slm status --json # data.profile is the active profile
38
+ ```
39
+
40
+ Creating a profile is a CLI action; there is no MCP tool for it. Over MCP:
41
+
42
+ ```
43
+ switch_profile(
44
+ profile_id: str, # the name of an existing profile
45
+ )
46
+ ```
47
+
48
+ `switch_profile` changes the **active profile**. The change is not private to
49
+ your session: it is written as the machine's active profile, so every later call
50
+ from every session on this machine, and the dashboard, now work in it until
51
+ someone switches again. An unknown name is refused (`Profile '<name>' does not
52
+ exist`); nothing is created. In company mode it also needs a role on the target
53
+ profile. Only switch when the user asks to move; do not switch to peek at
54
+ something.
55
+
56
+ ### Reaching another profile for one call
57
+
58
+ Most tools take an optional `profile_id`: `remember`, `recall`, `search`,
59
+ `fetch`, `list_recent`, `update_memory`, `delete_memory`, `session_init`,
60
+ `close_session`, `report_outcome`, `report_feedback`, `get_status`,
61
+ `get_memory_summary`, the correction and memory-kind tools, and others. A
62
+ non-empty value serves that one call from that profile (which must already
63
+ exist) and **never moves the active profile**. An empty value means the active
64
+ profile. Prefer this to switching and switching back.
65
+
66
+ ```
67
+ recall(query="rollout plan", profile_id="work", session_id="<sid>")
68
+ remember(content="...", tags="ops", profile_id="client-acme")
69
+ ```
70
+
71
+ `forget` and the mesh tools take no `profile_id`; they act on the active profile.
72
+
73
+ ### What a profile isolates
74
+
75
+ - `recall` returns only the profile's own memories, plus shared or global ones
76
+ only when you opt in (see `slm-scope`).
77
+ - `remember` writes to the profile you name or the active one.
78
+ - The code graph is not partitioned by profile: it lives in `code_graph.db` in the data directory.
79
+ - The `slm_cache_*` key-value cache and `slm_compress` recovery store are keyed
80
+ by the calling agent, not by profile, so switching profiles does not give you
81
+ a clean cache (see `slm-cache`).
82
+
83
+ ### Separate stores
84
+
85
+ To keep two bots or two clients completely apart, give each its own
86
+ `SLM_DATA_DIR` in its MCP config. You can run several SLM MCP servers at once,
87
+ named differently (for example `superlocalmemory-personal` and
88
+ `superlocalmemory-work`), each pointed at its own directory.
89
+
90
+ ---
91
+
92
+ ## MCP tool sets
93
+
94
+ | Profile | Tools | What it is |
95
+ |---------|-------|------------|
96
+ | `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 |
97
+ | `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` |
98
+ | `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 |
99
+ | `power` | 68 tools — full + audit_trail, retention, compaction, consistency_check, behavioral and diagnostic tools | Governance and admin work |
100
+ | `mesh` | 8 tools — mesh coordination only | Lightweight cross-session signalling |
101
+
102
+ A host that sets no profile gets the 56-tool `full` set (this is what the Claude
103
+ Code and Codex plugins do; the Antigravity plugin sets `power`). Two more
104
+ environment variables widen or narrow it: `SLM_MCP_ALL_TOOLS=1` registers every
105
+ tool (103), and `SLM_MCP_TOOLS=remember,recall,...` registers exactly the names
106
+ listed. `SLM_MCP_PROFILE=whole` is also every tool. The code-graph tools beyond
107
+ the six in `code` (such as `update_code_graph`, `list_graph_stats`) and tools
108
+ such as `core_memory` and `settle_session_outcomes` exist only with
109
+ `SLM_MCP_ALL_TOOLS=1`, `whole` or an explicit `SLM_MCP_TOOLS` list. Tools whose
110
+ function is to manage the SLM computer are never available to a remote caller.
111
+
112
+ The tool set is read when the MCP server starts. To change it, set it in the
113
+ host's MCP config and restart the host; asking the server at runtime does not
114
+ work:
115
+
116
+ ```json
117
+ "env": {
118
+ "SLM_MCP_PROFILE": "code",
119
+ "SLM_AGENT_ID": "claude_code"
120
+ }
121
+ ```
122
+
123
+ `slm connect <ide> --profile <name>` writes that variable into a supported
124
+ host's config. Setting `SLM_MCP_PROFILE` to a name that does not exist stops
125
+ `slm mcp` with a message listing the valid names. Older count-suffixed names
126
+ such as `code20`, `full38` and `power50` still resolve, with a startup warning.
127
+ On an install that already has memories, do not set `SLM_DATA_DIR` in the MCP
128
+ config: it points the host at a different, empty store.
129
+
130
+ `switch_profile` is in `core`, `code`, `full` and `power`, and in the default
131
+ set. It is not in `mesh`.
132
+
133
+ ---
134
+
135
+ ## If a tool is missing
136
+
137
+ Check the tool set first (`slm status` does not show it; look at the host's MCP
138
+ config for `SLM_MCP_PROFILE`). Mesh tools need `full`, `power`, `mesh` or the
139
+ default. Code-graph tools need `code` or `SLM_MCP_ALL_TOOLS=1`. Audit and
140
+ retention tools need `power`. `report_outcome` and `report_feedback` need
141
+ anything but `core` or `mesh`.
142
+
143
+ ---
144
+
145
+ ## Related skills
146
+
147
+ - `slm-scope` — opt-in fact sharing across profiles (personal/shared/global)
148
+ - `slm-graph` — code-graph tools and the tool set they need
149
+ - `slm-mesh` — mesh tools and the tool set they need
150
+ - `slm-status` — check the active profile name
151
+ - `slm-governance` — roles and company mode
152
+
153
+ ---
154
+
155
+ *SuperLocalMemory v4.1.24 · Qualixar · AGPL-3.0-or-later*