superlocalmemory 4.0.2 → 4.0.4

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 (57) hide show
  1. package/CHANGELOG.md +48 -0
  2. package/README.md +36 -40
  3. package/package.json +1 -1
  4. package/plugin/.claude-plugin/plugin.json +1 -1
  5. package/plugin/CLAUDE.md +3 -3
  6. package/plugin/agents/slm-governance-advisor.md +1 -1
  7. package/plugin/agents/slm-loop-runner.md +1 -1
  8. package/plugin/agents/slm-memory-advisor.md +1 -1
  9. package/plugin/agents/slm-optimize-advisor.md +1 -1
  10. package/plugin/requirements.txt +1 -1
  11. package/plugin/skills/slm-cache/SKILL.md +1 -1
  12. package/plugin/skills/slm-compress/SKILL.md +1 -1
  13. package/plugin/skills/slm-governance/SKILL.md +1 -1
  14. package/plugin/skills/slm-graph/SKILL.md +1 -1
  15. package/plugin/skills/slm-loop/SKILL.md +1 -1
  16. package/plugin/skills/slm-mesh/SKILL.md +1 -1
  17. package/plugin/skills/slm-profile/SKILL.md +4 -4
  18. package/plugin/skills/slm-recall/SKILL.md +1 -1
  19. package/plugin/skills/slm-remember/SKILL.md +1 -1
  20. package/plugin/skills/slm-scope/SKILL.md +1 -1
  21. package/plugin/skills/slm-session/SKILL.md +1 -1
  22. package/plugin/skills/slm-status/SKILL.md +1 -1
  23. package/plugin-src/rules/AGENTS.md +3 -3
  24. package/plugin-src/skills/slm-cache/SKILL.md +1 -1
  25. package/plugin-src/skills/slm-compress/SKILL.md +1 -1
  26. package/plugin-src/skills/slm-governance/SKILL.md +1 -1
  27. package/plugin-src/skills/slm-graph/SKILL.md +1 -1
  28. package/plugin-src/skills/slm-loop/SKILL.md +1 -1
  29. package/plugin-src/skills/slm-mesh/SKILL.md +1 -1
  30. package/plugin-src/skills/slm-profile/SKILL.md +4 -4
  31. package/plugin-src/skills/slm-recall/SKILL.md +1 -1
  32. package/plugin-src/skills/slm-remember/SKILL.md +1 -1
  33. package/plugin-src/skills/slm-scope/SKILL.md +1 -1
  34. package/plugin-src/skills/slm-session/SKILL.md +1 -1
  35. package/plugin-src/skills/slm-status/SKILL.md +1 -1
  36. package/pyproject.toml +1 -1
  37. package/scripts/postinstall-interactive.js +1 -0
  38. package/scripts/postinstall.js +4 -0
  39. package/src/superlocalmemory/__init__.py +1 -1
  40. package/src/superlocalmemory/cli/commands.py +10 -19
  41. package/src/superlocalmemory/cli/host_upgrades.py +175 -0
  42. package/src/superlocalmemory/cli/main.py +29 -4
  43. package/src/superlocalmemory/integrations/bounded_loops_mcp.py +184 -0
  44. package/src/superlocalmemory/learning/database.py +2 -1
  45. package/src/superlocalmemory/mcp/profiles.py +28 -13
  46. package/src/superlocalmemory/mcp/server.py +7 -6
  47. package/src/superlocalmemory/mcp/tools_brain.py +89 -4
  48. package/src/superlocalmemory/server/routes/brain.py +6 -1
  49. package/src/superlocalmemory/storage/_migration_internals.py +4 -0
  50. package/src/superlocalmemory/storage/_schema_version.py +2 -2
  51. package/src/superlocalmemory/storage/agent_experience.py +26 -4
  52. package/src/superlocalmemory/storage/external_evidence.py +359 -0
  53. package/src/superlocalmemory/storage/migration_runner.py +5 -0
  54. package/src/superlocalmemory/storage/migrations/M041_external_evidence_receipts.py +189 -0
  55. package/src/superlocalmemory/storage/migrations/__init__.py +2 -0
  56. package/src/superlocalmemory/ui/js/od-brain.js +9 -0
  57. package/src/superlocalmemory/ui/js/od-mcp.js +6 -6
package/CHANGELOG.md CHANGED
@@ -5,6 +5,54 @@ All notable changes to SuperLocalMemory will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [4.0.4] - 2026-08-15 — Optional Bounded Loops evidence bridge
9
+
10
+ ### Added
11
+ - An optional MCP 2 bridge discovers the separately installed
12
+ `bounded-loops-mcp` producer at call time and negotiates the public
13
+ `bounded-loops.dev/slm-bridge/v1` capability rather than pinning a producer
14
+ package version.
15
+ - `observe_bounded_loop_evidence(workspace)` explicitly imports sanitized
16
+ terminal graph evidence using the producer's `run_ref` address. It is
17
+ available in the default, `code`, `full`, and `power` MCP surfaces.
18
+ - M041 stores typed, profile-scoped external evidence in `learning.db`; Living
19
+ Brain displays honest Bounded Loop observation totals and documentation
20
+ explains the independent-product contract.
21
+
22
+ ### Safety
23
+ - The bridge accepts no caller-supplied executable or shell arguments, has a
24
+ five-second producer timeout, validates the exact v1 evidence shape, and
25
+ preserves `eligible_for_learning: false`.
26
+ - External receipts never enter recall, ranking, routing, reward, or automatic
27
+ learning. Profile erasure removes them and a durable tombstone blocks stale
28
+ processes from recreating them.
29
+
30
+ ## [4.0.3] - 2026-08-15 — Consented host integration upgrades
31
+
32
+ ### Added
33
+ - `slm upgrade-hosts` provides a read-only preview of existing SLM host
34
+ integrations. `--apply` requires either explicit `--host` targets or
35
+ `--all-detected`; unbounded host mutation is rejected.
36
+ - The npm runtime installer and interactive setup checklist direct existing
37
+ users to the upgrade preview. README, source docs, and Wiki source document
38
+ the host-specific upgrade and restart path.
39
+ - Portable Brain evidence is now reachable from the `code`, `full`, and
40
+ `power` MCP profiles used by installed agents. Profile counts are now code
41
+ 28, full 46, power 58, and whole 91; legacy count-suffixed aliases remain
42
+ supported.
43
+ - The separately packaged Codex rules and skills are synchronized from the
44
+ shared plugin source for this release.
45
+
46
+ ### Changed
47
+ - Existing portable MCP blocks are verified and preserved, retaining their
48
+ host-specific command paths, environment variables, and unrelated servers.
49
+ Codex refreshes only SLM-owned skills, agents, and lifecycle hooks.
50
+ - Claude Code plugin updates remain owned by its native plugin manager.
51
+
52
+ ### Safety
53
+ - Normal CLI commands and MCP startup no longer auto-install or update Claude
54
+ Code hooks. Host configuration changes require explicit operator action.
55
+
8
56
  ## [4.0.2] - 2026-08-15 — Portable Living Brain evidence
9
57
 
10
58
  ### Added
package/README.md CHANGED
@@ -5,7 +5,7 @@
5
5
  </picture>
6
6
  </p>
7
7
 
8
- <h1 align="center">SuperLocalMemory V4.0.2</h1>
8
+ <h1 align="center">SuperLocalMemory V4.0.4</h1>
9
9
 
10
10
  <h2 align="center">Rent the LLM. Own the memory.</h2>
11
11
 
@@ -27,12 +27,12 @@ guarantee here is stated as a falsifiable invariant, tested under an adversarial
27
27
  negative control, and shipped with the harness that regenerates the evidence:
28
28
  <code>python benchmark/run_all.py --trials 200 --output-dir results/</code>. What each experiment
29
29
  does <em>not</em> exercise is stated too.</p>
30
- <p align="center"><code>v4.0.2</code> — one control plane: <strong>SLM-Mesh</strong> peer coordination · multi-scope memory (personal / shared / global) · profiles · Cache · Compress · 7-layer retrieval · code graph · Entity Explorer · skill evolution · Modes A/B/C · GDPR retention &amp; audit chain · bounded loops — across CLI, MCP, dashboard, the <strong>Claude plugin</strong>, the <strong>Codex add-on</strong>, and documented IDE integrations.<br/>
30
+ <p align="center"><code>v4.0.4</code> — one control plane: <strong>SLM-Mesh</strong> peer coordination · multi-scope memory (personal / shared / global) · profiles · Cache · Compress · 7-layer retrieval · code graph · Entity Explorer · skill evolution · Modes A/B/C · GDPR retention &amp; audit chain · bounded loops — across CLI, MCP, dashboard, the <strong>Claude plugin</strong>, the <strong>Codex add-on</strong>, and documented IDE integrations.<br/>
31
31
  Proxy: <code>slm wrap claude</code> &nbsp;·&nbsp; MCP: add <code>slm_compress</code> to your config &nbsp;·&nbsp; Skill: zero-config</p>
32
32
  <p align="center"><strong>Four public arXiv preprints</strong> · V4: <a href="https://arxiv.org/abs/2608.08253">arXiv:2608.08253</a> · companion archive: <a href="https://zenodo.org/records/21853302">Zenodo 21853302</a> (<a href="https://doi.org/10.5281/zenodo.21853302">DOI 10.5281/zenodo.21853302</a>) · prior preprints: <a href="https://arxiv.org/abs/2603.02240">2603.02240</a> · <a href="https://arxiv.org/abs/2603.14588">2603.14588</a> · <a href="https://arxiv.org/abs/2604.04514">2604.04514</a>.</p>
33
33
 
34
34
  <p align="center">
35
- <a href="CHANGELOG.md"><img src="https://img.shields.io/badge/v4.0.2-Current_Release-2ea44f?style=for-the-badge&logo=checkmarx&logoColor=white" alt="v4.0.2 — Current Release"/></a>
35
+ <a href="CHANGELOG.md"><img src="https://img.shields.io/badge/v4.0.4-Current_Release-2ea44f?style=for-the-badge&logo=checkmarx&logoColor=white" alt="v4.0.4 — Current Release"/></a>
36
36
  <a href="https://arxiv.org/abs/2608.08253"><img src="https://img.shields.io/badge/arXiv-2608.08253-b31b1b?style=for-the-badge&logo=arxiv&logoColor=white" alt="SuperLocalMemory 4.0 paper on arXiv:2608.08253"/></a>
37
37
  <a href="https://zenodo.org/records/21853302"><img src="https://img.shields.io/badge/Zenodo-10.5281%2Fzenodo.21853302-1682D4?style=for-the-badge&logo=zenodo&logoColor=white" alt="V4 paper on Zenodo: 10.5281/zenodo.21853302"/></a>
38
38
  <a href="https://arxiv.org/abs/2603.14588"><img src="https://img.shields.io/badge/arXiv-2603.14588-b31b1b?style=for-the-badge&logo=arxiv&logoColor=white" alt="arXiv Paper"/></a>
@@ -62,7 +62,7 @@ SuperLocalMemory V4 combines conventional dense and lexical retrieval with graph
62
62
 
63
63
  **Memory with a sense of time.** SLM does not only store *what* an agent learned — it records *when*. Every fact carries ingestion timing and provenance; recall runs a dedicated temporal candidate channel alongside semantic, lexical, and associative retrieval; scenes and entity timelines reconstruct sequence; and the lifecycle lets neglected memory decay and self-archive instead of growing without bound. Time is a first-class ranking and lifecycle signal rather than a timestamp column an agent never reads — which is what lets a long-lived agent reason about how its context changed, not only what it currently holds.
64
64
 
65
- **What V4.0.2 ships.** V4 is a *governed* local-first control plane — every canonical write is admitted, policy-authorized, tracked as durable per-store obligations (lexical, temporal, vector), and sealed by a completion manifest, so it is either fully applied or explicitly marked degraded, never silently half-done. Flagship surfaces in this release:
65
+ **What V4.0.4 ships.** Existing users can now preview and explicitly refresh SLM-owned host integrations with `slm upgrade-hosts`, while package installation and MCP startup no longer silently modify host hook configuration. V4.0.4 also adds an optional, capability-negotiated Bounded Loops observation bridge: compatible terminal graph receipts enter a separate, profile-scoped `learning.db` table and appear in Living Brain, without affecting recall, ranking, routing, or automatic learning. V4 remains a *governed* local-first control plane — every canonical write is admitted, policy-authorized, tracked as durable per-store obligations (lexical, temporal, vector), and sealed by a completion manifest, so it is either fully applied or explicitly marked degraded, never silently half-done. Flagship surfaces in this release:
66
66
 
67
67
  - **[SLM-Mesh](#slm-mesh-cross-session--cross-machine-coordination)** — authenticated cross-session and cross-machine peer coordination (messages, locks, shared state, inbox/outbox, optional discovery). Coordination only — not automatic replicated memory.
68
68
  - **Multi-scope memory & profiles** — workspaces (profiles) plus `personal` / `shared` / `global` scopes; cross-profile recall is default-deny.
@@ -71,7 +71,7 @@ SuperLocalMemory V4 combines conventional dense and lexical retrieval with graph
71
71
  - **Modes A / B / C** — local-only (A), on-device LLM enrichment (B), provider-assisted (C). An operating mode records technical locality facts; it does **not** determine EU AI Act legal compliance (that is deployment-context assessment — see [Privacy controls](#privacy-controls-and-operating-modes)).
72
72
  - **GDPR posture, retention & audit chain** — export, fail-closed cross-store erasure, retention policies, and a hash-chained audit trail. Engineering controls for compliance programs, not a legal certification.
73
73
  - **7-layer retrieval/recall stack & code graph** — multi-channel candidates (semantic, BM25, temporal, Hopfield, spreading activation) plus optional code-graph tools for blast radius and review context.
74
- - **MCP profiles** — `full` exposes **42** tools (default everyday surface); `power` **54**; `whole` **87** (all registered). Also `core` (14), `code` (24), and `mesh` (8).
74
+ - **MCP profiles** — `code` exposes **29** tools for installed coding agents; `full` **47**; `power` **59**; `whole` **92** (all registered). Also `core` (14), `mesh` (8), and the unrestricted default surface (47 with mesh enabled).
75
75
  - **Governed write path & verifiable transactions** — admission + policy control, a per-owner obligation ledger, and a hash-sealed completion manifest with a reconciler that redrives unmet obligations.
76
76
  - **Self-healing lifecycle & admin remediation** — stale locks cleared on restart; list/resolve stuck operations from CLI, MCP, or the dashboard.
77
77
 
@@ -387,6 +387,22 @@ Full docs: [docs/multi-machine.md](docs/multi-machine.md) · [docs/distributed-d
387
387
 
388
388
  After any install path: `slm setup` → `slm doctor` → `slm warmup` (optional, pre-downloads ~500MB embedding model).
389
389
 
390
+ ### Upgrading an existing installation
391
+
392
+ An npm, pip, or repository update upgrades the SLM runtime; it does not silently
393
+ rewrite your IDE configuration, hooks, or plugin state. Review the existing
394
+ integrations first:
395
+
396
+ ```bash
397
+ slm upgrade-hosts
398
+ ```
399
+
400
+ Then explicitly apply the hosts you approve, for example
401
+ `slm upgrade-hosts --host codex --apply`, or use
402
+ `slm upgrade-hosts --all-detected --apply` after reviewing the preview. See
403
+ [Host Integration Upgrades](docs/host-upgrades.md) for the full safety contract
404
+ and the Claude Code plugin update path.
405
+
390
406
  | Component | Size | When |
391
407
  |:----------|:-----|:-----|
392
408
  | Core libraries (numpy, scipy, networkx) | ~50MB | During install |
@@ -420,11 +436,11 @@ Control tool surface via `SLM_MCP_PROFILE`:
420
436
  | Profile | Tools | Use case |
421
437
  |:--------|:-----:|:---------|
422
438
  | `core` | 14 | Memory, session, and optimize core |
423
- | `code` | 24 | Core + code-graph tools + profile switching + bounded loops |
439
+ | `code` | 29 | Core + portable Brain evidence + code-graph tools + profile switching + bounded loops |
424
440
  | `mesh` | 8 | SLM-Mesh only — multi-session / multi-machine coordination |
425
- | `full` | 42 | Memory + optimize + evolution + mesh + bounded loops |
426
- | `power` | 54 | Full + administration, lifecycle, and diagnostics |
427
- | `whole` | 87 | Every registered MCP tool |
441
+ | `full` | 47 | Memory + portable Brain evidence + optimize + evolution + mesh + bounded loops |
442
+ | `power` | 59 | Full + administration, lifecycle, and diagnostics |
443
+ | `whole` | 92 | Every registered MCP tool |
428
444
 
429
445
  **Precedence:** `ALL` > `TOOLS` > `PROFILE` > `default`
430
446
 
@@ -435,7 +451,7 @@ slm mcp
435
451
 
436
452
  For a predictable small surface, set `core` explicitly. Leaving the variable
437
453
  unset retains the compatibility default, whose mesh tools follow the local
438
- mesh setting. Count-suffixed aliases remain for backward compatibility and emit a migration warning: `core14`, `code20`, `code21`, `code24`, `mesh8`, `full38`, `full39`, `full42`, `power50`, `power51`, `power54`, `whole81`, `whole84`. Unknown names stop startup instead of silently selecting another tool set.
454
+ mesh setting. Count-suffixed aliases remain for backward compatibility and emit a migration warning: `core14`, `code20`, `code21`, `code24`, `code28`, `code29`, `mesh8`, `full38`, `full39`, `full42`, `full46`, `full47`, `power50`, `power51`, `power54`, `power58`, `power59`, `whole81`, `whole84`, `whole91`, `whole92`. Unknown names stop startup instead of silently selecting another tool set.
439
455
 
440
456
  Per-IDE configs available for Claude Code, Cursor, Windsurf, VS Code Copilot, Continue, Gemini CLI, JetBrains, Zed, and more (15 configs in `ide/configs/`). See [docs/ide-setup.md](docs/ide-setup.md).
441
457
 
@@ -647,25 +663,12 @@ Multi-Agent Memory workspace.
647
663
 
648
664
  ## Framework Adapters (V4)
649
665
 
650
- SLM ships nine framework adapters under `ide/integrations/`. Each adapter
651
- wires SLM as the memory and history provider for the respective framework
652
- without replacing the framework's own agent runtime.
653
-
654
- | Framework | Directory |
655
- |-----------|-----------|
656
- | LangGraph | `ide/integrations/langgraph/` |
657
- | Semantic Kernel | `ide/integrations/semantic-kernel/` |
658
- | Microsoft Agent Framework | `ide/integrations/agent-framework/` |
659
- | LangChain | `ide/integrations/langchain/` |
660
- | LlamaIndex | `ide/integrations/llamaindex/` |
661
- | CrewAI | `ide/integrations/crewai/` |
662
- | AutoGen | `ide/integrations/autogen/` |
663
- | Google ADK | `ide/integrations/google-adk/` |
664
- | OpenAI Agents | `ide/integrations/openai-agents/` |
665
-
666
- Pydantic AI is not included — it does not expose a formal memory interface for
667
- external providers. Each adapter's `README.md` covers installation and
668
- configuration for that framework.
666
+ SLM ships nine adapters under `ide/integrations/`: LangGraph, Semantic Kernel,
667
+ Microsoft Agent Framework, LangChain, LlamaIndex, CrewAI, AutoGen, Google ADK,
668
+ and OpenAI Agents. Each wires SLM as memory and history without replacing the
669
+ framework runtime; its directory contains installation/configuration guidance.
670
+ Pydantic AI is not included because it does not expose a formal external-memory
671
+ interface.
669
672
 
670
673
  ---
671
674
 
@@ -681,6 +684,7 @@ configuration for that framework.
681
684
  | Published benchmark evidence | [docs/benchmarks.md](docs/benchmarks.md) |
682
685
  | CLI reference | [docs/cli-reference.md](docs/cli-reference.md) |
683
686
  | MCP tools reference | [docs/mcp-tools.md](docs/mcp-tools.md) |
687
+ | Optional Bounded Loops bridge | [docs/bounded-loops-bridge.md](docs/bounded-loops-bridge.md) |
684
688
  | Getting started | [docs/getting-started.md](docs/getting-started.md) |
685
689
  | IDE setup (15 configs) | [docs/ide-setup.md](docs/ide-setup.md) |
686
690
  | Teams, users, and RBAC | [docs/rbac-teams.md](docs/rbac-teams.md) |
@@ -697,21 +701,13 @@ runtime capability is enabled and healthy. See [CHANGELOG.md](CHANGELOG.md) for
697
701
  the complete release history.
698
702
  ## Research Papers
699
703
 
700
- SuperLocalMemory has a V4 arXiv preprint with a companion Zenodo archive, plus three earlier arXiv preprints (2026):
701
-
702
- - **SuperLocalMemory 4.0: The Governed Memory Operating System for AI Agents:** [arXiv:2608.08253](https://arxiv.org/abs/2608.08253) · [Zenodo 21853302](https://zenodo.org/records/21853302) · [DOI 10.5281/zenodo.21853302](https://doi.org/10.5281/zenodo.21853302).
703
- - **The Living Brain (V3.3):** [arXiv:2604.04514](https://arxiv.org/abs/2604.04514) · [Zenodo 19435120](https://zenodo.org/records/19435120)
704
- - **Information-Geometric Foundations (V3):** [arXiv:2603.14588](https://arxiv.org/abs/2603.14588) · [Zenodo 19038659](https://zenodo.org/records/19038659)
705
- - **Trust & Behavioral Foundations (V2):** [arXiv:2603.02240](https://arxiv.org/abs/2603.02240) · [Zenodo 18709670](https://zenodo.org/records/18709670)
704
+ SuperLocalMemory has a V4 [arXiv preprint](https://arxiv.org/abs/2608.08253) with [Zenodo archive](https://zenodo.org/records/21853302) and [DOI](https://doi.org/10.5281/zenodo.21853302), plus [The Living Brain (V3.3)](https://arxiv.org/abs/2604.04514), [Information-Geometric Foundations (V3)](https://arxiv.org/abs/2603.14588), and [Trust & Behavioral Foundations (V2)](https://arxiv.org/abs/2603.02240).
706
705
 
707
706
  Use the citation metadata on the linked arXiv or Zenodo records.
708
707
 
709
708
  ## Support / License / Qualixar
710
- See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines, the [Wiki](https://github.com/qualixar/superlocalmemory/wiki) for detailed documentation, and [LICENSE](LICENSE) for the GNU Affero General Public License v3.0 (AGPL-3.0).
711
- For commercial licensing (closed-source, proprietary, or hosted use), see [COMMERCIAL-LICENSE.md](COMMERCIAL-LICENSE.md) or contact varun.pratap.bhardwaj@gmail.com.
712
- Copyright (c) 2026 Varun Pratap Bhardwaj / Qualixar · Part of [Qualixar](https://qualixar.com) · Author: [Varun Pratap Bhardwaj](https://varunpratap.com)
713
- Acknowledgments: [Everything Claude Code](https://github.com/affaan-m/everything-claude-code) informed skill observation; [HKUDS/OpenSpace](https://github.com/HKUDS/OpenSpace) informed skill-evolution verification.
714
- Qualixar builds open-source infrastructure for AI reliability engineering. Start at [qualixar.com](https://qualixar.com) or browse the [research archive](https://huggingface.co/Qualixar).
709
+ See [CONTRIBUTING.md](CONTRIBUTING.md), the [Wiki](https://github.com/qualixar/superlocalmemory/wiki), and [LICENSE](LICENSE) (AGPL-3.0). For commercial licensing, see [COMMERCIAL-LICENSE.md](COMMERCIAL-LICENSE.md) or contact varun.pratap.bhardwaj@gmail.com.
710
+ Copyright (c) 2026 Varun Pratap Bhardwaj / Qualixar · [Qualixar](https://qualixar.com) · [research archive](https://huggingface.co/Qualixar). Acknowledgments: [Everything Claude Code](https://github.com/affaan-m/everything-claude-code) informed skill observation; [HKUDS/OpenSpace](https://github.com/HKUDS/OpenSpace) informed skill-evolution verification.
715
711
 
716
712
  ## Star This Project
717
713
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "superlocalmemory",
3
- "version": "4.0.2",
3
+ "version": "4.0.4",
4
4
  "description": "Local-first agent memory with MCP and an agent-native CLI. Documented clients include Claude Code, Cursor, and Windsurf.",
5
5
  "keywords": [
6
6
  "ai-memory",
@@ -15,5 +15,5 @@
15
15
  "mcpServers": "./.mcp.json",
16
16
  "name": "superlocalmemory",
17
17
  "repository": "https://github.com/qualixar/superlocalmemory",
18
- "version": "4.0.2"
18
+ "version": "4.0.4"
19
19
  }
package/plugin/CLAUDE.md CHANGED
@@ -1,4 +1,4 @@
1
- <!-- BEGIN SuperLocalMemory v4.0.2 -->
1
+ <!-- BEGIN SuperLocalMemory v4.0.4 -->
2
2
 
3
3
  ## SuperLocalMemory (SLM) — Agent Rules
4
4
 
@@ -39,6 +39,6 @@ slm-recall · slm-remember · slm-session · slm-status · slm-cache · slm-comp
39
39
  ### Subagents
40
40
  slm-memory-advisor (memory decisions, session hygiene, scope/profile guidance) · slm-optimize-advisor (context compression + KV cache) · slm-governance-advisor (scope/roles/compliance/GDPR)
41
41
 
42
- <!-- END SuperLocalMemory v4.0.2 -->
42
+ <!-- END SuperLocalMemory v4.0.4 -->
43
43
 
44
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
44
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -77,4 +77,4 @@ slm-scope · slm-governance · slm-profile · slm-remember · slm-recall
77
77
  # What NOT to do
78
78
  Never session_init twice; never forget without dry-run preview; never store secrets; never bypass role checks; never claim an erasure succeeded without verifying via recall.
79
79
 
80
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
80
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -68,4 +68,4 @@ assessment. The gate is the authority.
68
68
 
69
69
  ---
70
70
 
71
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
71
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -46,4 +46,4 @@ slm-recall · slm-remember · slm-session · slm-scope · slm-profile · slm-gov
46
46
  # What NOT to do
47
47
  Never session_init twice; never forget dry_run=False without reporting preview; never dump a whole file into remember; never invent a memory; never claim "saved" without success:true / clean CLI exit; never bypass scope or governance restrictions.
48
48
 
49
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
49
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -41,4 +41,4 @@ slm-compress · slm-cache · slm-status · slm-profile
41
41
  # What NOT to do
42
42
  Never compress code-for-edit/JSON-to-parse/<500 chars; never store secrets/ccr_ids; never let optimize failure block/alter the task; never claim a specific savings %; never carry ccr_ids across profile switches.
43
43
 
44
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
44
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -1 +1 @@
1
- superlocalmemory==4.0.2
1
+ superlocalmemory==4.0.4
@@ -145,4 +145,4 @@ These subcommands control daemon-level cache settings. They do not read or write
145
145
 
146
146
  ---
147
147
 
148
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
148
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -147,4 +147,4 @@ Content over 1 MB (1 000 000 bytes UTF-8) is processed but `reversible` is force
147
147
 
148
148
  ---
149
149
 
150
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
150
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -245,4 +245,4 @@ Before running any destructive operation (`forget`, `compact_memories`):
245
245
 
246
246
  ---
247
247
 
248
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
248
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -311,4 +311,4 @@ profile. See `slm-profile` for the full profile switching workflow.
311
311
 
312
312
  ---
313
313
 
314
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
314
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -96,4 +96,4 @@ paused, name the approval needed; when errored, quote the short detail.
96
96
 
97
97
  ---
98
98
 
99
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
99
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -279,4 +279,4 @@ mesh availability.
279
279
 
280
280
  ---
281
281
 
282
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
282
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -31,9 +31,9 @@ project, a client engagement, a production vs staging environment.
31
31
  | Profile | Tools | When to use |
32
32
  |---------|-------|-------------|
33
33
  | `core` | 14 tools — remember, recall, search, session, optimize | Minimal footprint, no code tools |
34
- | `code` | 24 tools — core + 6 code-graph tools + switch_profile + 3 bounded-loop tools | Default for IDE/coding agents |
35
- | `full` | 42 tools — code + all memory ops + mesh + bounded loops | Multi-session, team workflows |
36
- | `power` | 54 tools — full + governance + behavioral tools | Enterprise, admin, audit use cases |
34
+ | `code` | 29 tools — core + portable Brain evidence + code graph + profile switching + bounded loops | Default for IDE/coding agents |
35
+ | `full` | 47 tools — code + all memory ops + mesh + bounded loops | Multi-session, team workflows |
36
+ | `power` | 59 tools — full + governance + behavioral tools | Enterprise, admin, audit use cases |
37
37
  | `mesh` | 8 tools — mesh coordination only | Lightweight cross-session signalling |
38
38
 
39
39
  The profile is set at MCP server startup via `SLM_MCP_PROFILE` in the MCP config.
@@ -145,4 +145,4 @@ Name them differently in your MCP config (e.g. `superlocalmemory-personal` and
145
145
 
146
146
  ---
147
147
 
148
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
148
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -236,4 +236,4 @@ before recalling, then switch back. See `slm-profile` for workspace switching.
236
236
 
237
237
  ---
238
238
 
239
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
239
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -238,4 +238,4 @@ different workspace, use `switch_profile` first. See `slm-profile`.
238
238
 
239
239
  ---
240
240
 
241
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
241
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -173,4 +173,4 @@ to review the impact. See `slm-remember` for the full deletion discipline.
173
173
 
174
174
  ---
175
175
 
176
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
176
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -227,4 +227,4 @@ explicitly and call `recall` with `include_global`/`include_shared` after
227
227
 
228
228
  ---
229
229
 
230
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
230
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -163,4 +163,4 @@ multi-profile setup. To switch the active profile, see `slm-profile`.
163
163
 
164
164
  ---
165
165
 
166
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
166
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -82,10 +82,10 @@ When the SLM MCP server is unavailable, use these CLI equivalents:
82
82
 
83
83
  ## Tool reference (core profile — 14 tools)
84
84
 
85
- > The MCP config ships `SLM_MCP_PROFILE=code` (24 tools): the 14 core memory tools below
85
+ > The MCP config ships `SLM_MCP_PROFILE=code` (29 tools): the 14 core memory tools below
86
86
  > **plus** 6 code-graph tools (`build_code_graph`, `get_blast_radius`, `query_graph`,
87
87
  > `semantic_search_code`, `get_review_context`, `detect_changes`) and `switch_profile`.
88
- > Use `full` (42 tools) to add mesh coordination. Use `power` (54 tools) for governance
88
+ > Use `full` (47 tools) to add mesh coordination. Use `power` (59 tools) for governance
89
89
  > and audit tools. See slm-profile for profile switching.
90
90
 
91
91
  | Tool | Signature (key params) | Notes |
@@ -128,4 +128,4 @@ When the SLM MCP server is unavailable, use these CLI equivalents:
128
128
  - **slm-optimize-advisor** — context compression and KV cache
129
129
  - **slm-governance-advisor** — scope/role compliance, retention policies, GDPR
130
130
 
131
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
131
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -145,4 +145,4 @@ These subcommands control daemon-level cache settings. They do not read or write
145
145
 
146
146
  ---
147
147
 
148
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
148
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -147,4 +147,4 @@ Content over 1 MB (1 000 000 bytes UTF-8) is processed but `reversible` is force
147
147
 
148
148
  ---
149
149
 
150
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
150
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -245,4 +245,4 @@ Before running any destructive operation (`forget`, `compact_memories`):
245
245
 
246
246
  ---
247
247
 
248
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
248
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -311,4 +311,4 @@ profile. See `slm-profile` for the full profile switching workflow.
311
311
 
312
312
  ---
313
313
 
314
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
314
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -96,4 +96,4 @@ paused, name the approval needed; when errored, quote the short detail.
96
96
 
97
97
  ---
98
98
 
99
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
99
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
@@ -279,4 +279,4 @@ mesh availability.
279
279
 
280
280
  ---
281
281
 
282
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
282
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -31,9 +31,9 @@ project, a client engagement, a production vs staging environment.
31
31
  | Profile | Tools | When to use |
32
32
  |---------|-------|-------------|
33
33
  | `core` | 14 tools — remember, recall, search, session, optimize | Minimal footprint, no code tools |
34
- | `code` | 24 tools — core + 6 code-graph tools + switch_profile + 3 bounded-loop tools | Default for IDE/coding agents |
35
- | `full` | 42 tools — code + all memory ops + mesh + bounded loops | Multi-session, team workflows |
36
- | `power` | 54 tools — full + governance + behavioral tools | Enterprise, admin, audit use cases |
34
+ | `code` | 29 tools — core + portable Brain evidence + code graph + profile switching + bounded loops | Default for IDE/coding agents |
35
+ | `full` | 47 tools — code + all memory ops + mesh + bounded loops | Multi-session, team workflows |
36
+ | `power` | 59 tools — full + governance + behavioral tools | Enterprise, admin, audit use cases |
37
37
  | `mesh` | 8 tools — mesh coordination only | Lightweight cross-session signalling |
38
38
 
39
39
  The profile is set at MCP server startup via `SLM_MCP_PROFILE` in the MCP config.
@@ -145,4 +145,4 @@ Name them differently in your MCP config (e.g. `superlocalmemory-personal` and
145
145
 
146
146
  ---
147
147
 
148
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
148
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -236,4 +236,4 @@ before recalling, then switch back. See `slm-profile` for workspace switching.
236
236
 
237
237
  ---
238
238
 
239
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
239
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -238,4 +238,4 @@ different workspace, use `switch_profile` first. See `slm-profile`.
238
238
 
239
239
  ---
240
240
 
241
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
241
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -173,4 +173,4 @@ to review the impact. See `slm-remember` for the full deletion discipline.
173
173
 
174
174
  ---
175
175
 
176
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
176
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -227,4 +227,4 @@ explicitly and call `recall` with `include_global`/`include_shared` after
227
227
 
228
228
  ---
229
229
 
230
- *SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later*
230
+ *SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later*
@@ -163,4 +163,4 @@ multi-profile setup. To switch the active profile, see `slm-profile`.
163
163
 
164
164
  ---
165
165
 
166
- SuperLocalMemory v4.0.2 · Qualixar · AGPL-3.0-or-later
166
+ SuperLocalMemory v4.0.4 · Qualixar · AGPL-3.0-or-later
package/pyproject.toml CHANGED
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "superlocalmemory"
3
- version = "4.0.2"
3
+ version = "4.0.4"
4
4
  description = "Local-first agent memory with auditable hybrid retrieval"
5
5
  readme = "README.md"
6
6
  license = "AGPL-3.0-or-later"
@@ -554,6 +554,7 @@ function printFirstRunChecklist(config) {
554
554
  console.log('Next steps:');
555
555
  console.log(' slm status --verbose — daemon, mode, dashboard, health');
556
556
  console.log(' slm doctor — run health checks (DB, models, ports)');
557
+ console.log(' slm upgrade-hosts — preview existing host integrations after an update');
557
558
  console.log(' slm health --watch — live health ladder readout');
558
559
  console.log(' slm dashboard — open the dashboard in your browser');
559
560
  console.log('');
@@ -206,6 +206,10 @@ function main(argv = process.argv.slice(2)) {
206
206
  console.log('');
207
207
  console.log(' slm setup');
208
208
  console.log('');
209
+ console.log(' If this updated an existing SLM installation, preview host integrations first:');
210
+ console.log('');
211
+ console.log(' slm upgrade-hosts');
212
+ console.log('');
209
213
  console.log(' Prefer to tune performance profiles? Use: slm reconfigure');
210
214
  console.log('');
211
215
  return 0;
@@ -32,7 +32,7 @@ if "OMP_NUM_THREADS" not in os.environ:
32
32
  os.environ["OMP_NUM_THREADS"] = "2"
33
33
  # ---------------------------------------------------------------------------
34
34
 
35
- __version__ = "4.0.2"
35
+ __version__ = "4.0.4"
36
36
 
37
37
  _REQUIRED_VERSIONS = {
38
38
  "sentence_transformers": "5.3.0",
@@ -321,25 +321,22 @@ def cmd_session(args: Namespace) -> None:
321
321
  print("Session close failed (daemon unreachable?)")
322
322
 
323
323
 
324
+ def _cmd_upgrade_hosts(args: Namespace) -> None:
325
+ """Run the consented host-integration refresh command."""
326
+ from superlocalmemory.cli.host_upgrades import cmd_upgrade_hosts
327
+
328
+ cmd_upgrade_hosts(args)
329
+
330
+
324
331
  def dispatch(args: Namespace) -> None:
325
332
  """Route CLI command to the appropriate handler."""
326
- # Auto-install/upgrade hooks on version change (single file read, ~0.1ms)
327
- if (
328
- args.command not in ("hooks", "codex", "init", "mcp")
329
- and not getattr(args, "dry_run", False)
330
- ):
331
- try:
332
- from superlocalmemory.hooks.claude_code_hooks import auto_install_if_needed
333
- auto_install_if_needed()
334
- except Exception:
335
- pass
336
-
337
333
  handlers = {
338
334
  "init": cmd_init,
339
335
  "setup": cmd_setup,
340
336
  "mode": cmd_mode,
341
337
  "provider": cmd_provider,
342
338
  "connect": cmd_connect,
339
+ "upgrade-hosts": _cmd_upgrade_hosts,
343
340
  "migrate": cmd_migrate,
344
341
  "list": cmd_list,
345
342
  "remember": cmd_remember,
@@ -2151,6 +2148,7 @@ _COMMAND_GROUPS: list[tuple[str, list[tuple[str, str]]]] = [
2151
2148
  ("mode", "Switch memory mode: a (local) / b (Ollama) / c (cloud)"),
2152
2149
  ("provider", "Configure the cloud LLM provider + API key (Mode C)"),
2153
2150
  ("connect", "Auto-configure detected IDEs (Cursor, VS Code, …)"),
2151
+ ("upgrade-hosts", "Preview or explicitly refresh existing SLM host integrations"),
2154
2152
  ("hooks", "Install/inspect Claude Code hooks"),
2155
2153
  ("codex", "Configure the Codex / OpenAI integration"),
2156
2154
  ]),
@@ -2206,6 +2204,7 @@ _COMMAND_GROUPS: list[tuple[str, list[tuple[str, str]]]] = [
2206
2204
  ("Learning & maintenance", [
2207
2205
  ("evolve", "Skill-evolution controls"),
2208
2206
  ("observe", "External observation / telemetry ingestion"),
2207
+ ("brain", "Show profile-scoped Living Brain evidence"),
2209
2208
  ("decay", "Run a forgetting/decay pass"),
2210
2209
  ("consolidate", "Merge/consolidate related memories"),
2211
2210
  ("quantize", "Quantize embeddings to save space"),
@@ -2967,14 +2966,6 @@ def cmd_mcp(_args: Namespace) -> None:
2967
2966
  except Exception:
2968
2967
  pass # A diagnostic must never prevent the server from starting.
2969
2968
 
2970
- # Auto-install hooks on MCP startup (fast path: ~0.1ms if already current)
2971
- # CRITICAL: No stdout — MCP uses stdio transport, any print corrupts protocol
2972
- try:
2973
- from superlocalmemory.hooks.claude_code_hooks import auto_install_if_needed
2974
- auto_install_if_needed()
2975
- except Exception:
2976
- pass
2977
-
2978
2969
  from superlocalmemory.mcp.server import server
2979
2970
 
2980
2971
  server.run(transport="stdio")