agent-memory-os 0.2.3__tar.gz → 0.2.4__tar.gz

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 (105) hide show
  1. agent_memory_os-0.2.4/.github/workflows/ci.yml +25 -0
  2. agent_memory_os-0.2.4/.github/workflows/release.yml +40 -0
  3. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/.gitignore +2 -0
  4. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/LICENSE +0 -0
  5. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/PKG-INFO +81 -7
  6. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/PROGRESS.md +0 -0
  7. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/README.md +73 -5
  8. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/SPEC.md +0 -0
  9. agent_memory_os-0.2.4/assets/README.md +19 -0
  10. agent_memory_os-0.2.4/assets/agent-memory-os-logo-ai-v1.png +0 -0
  11. agent_memory_os-0.2.4/assets/agent-memory-os-logo-integrated-v2.png +0 -0
  12. agent_memory_os-0.2.4/assets/agent-memory-os-logo.png +0 -0
  13. agent_memory_os-0.2.4/assets/agent-memory-os-logo.svg +18 -0
  14. agent_memory_os-0.2.4/assets/agent-memory-os-wordmark.png +0 -0
  15. agent_memory_os-0.2.4/assets/agent-memory-os-wordmark.svg +36 -0
  16. agent_memory_os-0.2.4/assets/integrations/claude-code.svg +11 -0
  17. agent_memory_os-0.2.4/assets/integrations/codex.svg +10 -0
  18. agent_memory_os-0.2.4/assets/integrations/hermes-agent.svg +11 -0
  19. agent_memory_os-0.2.4/assets/integrations/openclaw.svg +11 -0
  20. agent_memory_os-0.2.4/assets/logo-header.png +0 -0
  21. agent_memory_os-0.2.4/assets/logo-icon-128.png +0 -0
  22. agent_memory_os-0.2.4/assets/logo-icon-512.png +0 -0
  23. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/AgentMemoryOS_README.md +2 -0
  24. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/Memory_Resonance_Spec.md +0 -0
  25. agent_memory_os-0.2.4/docs/Roadmap.md +76 -0
  26. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/Shadow_Mode_Timeline.md +0 -0
  27. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/adr/ADR-0001-turbovec-semantic-sidecar-positioning.md +0 -0
  28. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/blockers/current.md +0 -0
  29. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/evidence/20260609_120837-repo-audit.md +0 -0
  30. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/evidence/20260609_121749-activation-gate-verification.md +0 -0
  31. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/evidence/20260617_221742-webui-availability-triage.md +0 -0
  32. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/evidence/20260617_225724-webui-port-8000-correction.md +0 -0
  33. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/handoffs/20260609_120837-mizuki-to-neo-governance-fill.md +0 -0
  34. agent_memory_os-0.2.4/docs/integrations/claude-code.md +67 -0
  35. agent_memory_os-0.2.4/docs/integrations/codex.md +43 -0
  36. agent_memory_os-0.2.4/docs/integrations/hermes-agent.md +62 -0
  37. agent_memory_os-0.2.4/docs/integrations/openclaw.md +67 -0
  38. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/plans/20260605_100751-memory-decay-recency-v0.2.md +0 -0
  39. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/plans/20260605_114049-retrieval-foundation-v0.2.1.md +0 -0
  40. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/plans/20260605_143442-version-downgrade-verification.md +0 -0
  41. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/plans/20260608_174539-turbovec-semantic-provider-validation.md +0 -0
  42. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/portfolio-status.md +0 -0
  43. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/project-status/current.md +0 -0
  44. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/reviews/.gitkeep +0 -0
  45. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/reviews/20260609_120837-neo-consistency-review.md +0 -0
  46. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/reviews/20260609_122032-mizuki-portfolio-maintenance.md +0 -0
  47. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/stress-cases/case-01-noisy-truth.md +0 -0
  48. agent_memory_os-0.2.4/logo.png +0 -0
  49. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/pyproject.toml +3 -2
  50. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/scripts/verify_acl_identities.py +0 -0
  51. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/scripts/verify_downgrade_compatibility.py +0 -0
  52. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/cache.py +0 -0
  53. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/candidates.py +0 -0
  54. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/cli.py +154 -0
  55. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/client.py +7 -0
  56. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/context_pack.py +0 -0
  57. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/db.py +74 -6
  58. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/mcp_server.py +14 -0
  59. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/providers/__init__.py +0 -0
  60. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/providers/turbovec.py +12 -4
  61. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/scoring.py +0 -0
  62. agent_memory_os-0.2.4/src/agent_memory_os/tokens.py +53 -0
  63. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/web_app.py +24 -1
  64. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/web_ui.py +73 -5
  65. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_acl_visibility.py +0 -0
  66. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_cli.py +0 -0
  67. agent_memory_os-0.2.4/tests/test_cli_tools.py +78 -0
  68. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_context_pack.py +0 -0
  69. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_decay_scoring.py +0 -0
  70. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_memory_client.py +0 -0
  71. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_memory_decay_recency.py +0 -0
  72. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_memory_enhancements.py +32 -0
  73. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_memory_resonance.py +0 -0
  74. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_retrieval_foundation.py +0 -0
  75. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_semantic_candidates.py +0 -0
  76. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_truth_arbitration.py +0 -0
  77. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_turbovec_provider.py +0 -0
  78. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_verification_script.py +0 -0
  79. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_web_app.py +32 -0
  80. agent_memory_os-0.2.3/.claude/launch.json +0 -18
  81. agent_memory_os-0.2.3/.claude/settings.local.json +0 -11
  82. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/CHANGELOG.md +0 -0
  83. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/NOTICE +0 -0
  84. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/PROJECT_STATUS.md +0 -0
  85. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/CANARY_MONITORING_SCHEDULE.md +0 -0
  86. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/HISTORY.md +0 -0
  87. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/INSTALLATION.md +0 -0
  88. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/Memory_Resonance_Prototype.md +0 -0
  89. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/PROJECT_STATUS.md +0 -0
  90. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/ROADMAP.md +0 -0
  91. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/Shadow_Mode_Verification_Report.md +0 -0
  92. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/hermes-activation-gates.md +0 -0
  93. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/docs/plans/20260613_dco-technical-design.md +0 -0
  94. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/__init__.py +0 -0
  95. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/golden_recall.py +0 -0
  96. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/hermes_importer.py +0 -0
  97. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/memory_resonance.py +0 -0
  98. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/schema.py +0 -0
  99. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/src/agent_memory_os/shadow_mode.py +0 -0
  100. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_context_orchestration.py +0 -0
  101. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_fts_triggers.py +0 -0
  102. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_golden_recall.py +0 -0
  103. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_hermes_importer.py +0 -0
  104. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_memory_links.py +0 -0
  105. {agent_memory_os-0.2.3 → agent_memory_os-0.2.4}/tests/test_shadow_mode.py +0 -0
@@ -0,0 +1,25 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+
8
+ jobs:
9
+ test:
10
+ runs-on: ubuntu-latest
11
+ strategy:
12
+ fail-fast: false
13
+ matrix:
14
+ python-version: ["3.11", "3.12", "3.13"]
15
+ steps:
16
+ - uses: actions/checkout@v4
17
+ - uses: actions/setup-python@v5
18
+ with:
19
+ python-version: ${{ matrix.python-version }}
20
+ - name: Install package with test extras
21
+ run: |
22
+ python -m pip install --upgrade pip
23
+ pip install -e '.[dev,api,semantic]' httpx
24
+ - name: Run test suite
25
+ run: pytest
@@ -0,0 +1,40 @@
1
+ name: Release to PyPI
2
+
3
+ on:
4
+ push:
5
+ tags: ["v*"]
6
+
7
+ jobs:
8
+ build:
9
+ runs-on: ubuntu-latest
10
+ steps:
11
+ - uses: actions/checkout@v4
12
+ - uses: actions/setup-python@v5
13
+ with:
14
+ python-version: "3.12"
15
+ - name: Run test suite before publishing
16
+ run: |
17
+ python -m pip install --upgrade pip
18
+ pip install -e '.[dev,api,semantic]' httpx
19
+ pytest
20
+ - name: Build distributions
21
+ run: |
22
+ pip install build
23
+ python -m build
24
+ - uses: actions/upload-artifact@v4
25
+ with:
26
+ name: dist
27
+ path: dist/
28
+
29
+ publish:
30
+ needs: build
31
+ runs-on: ubuntu-latest
32
+ environment: pypi
33
+ permissions:
34
+ id-token: write # PyPI Trusted Publishing (OIDC) — no token stored anywhere
35
+ steps:
36
+ - uses: actions/download-artifact@v4
37
+ with:
38
+ name: dist
39
+ path: dist/
40
+ - uses: pypa/gh-action-pypi-publish@release/v1
@@ -14,3 +14,5 @@ build/
14
14
  .hermes/
15
15
  shadow_recall*.jsonl
16
16
  *.pyc
17
+ .claude/launch.json
18
+ dist/
File without changes
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: agent-memory-os
3
- Version: 0.2.3
3
+ Version: 0.2.4
4
4
  Summary: Local-first, MCP-native memory engine for AI agents with RAM cache and context-budgeted recall.
5
5
  Author: Bastet Agent Team
6
6
  License-Expression: Apache-2.0
@@ -16,14 +16,22 @@ Requires-Dist: fastapi>=0.115; extra == 'api'
16
16
  Requires-Dist: uvicorn>=0.30; extra == 'api'
17
17
  Provides-Extra: dev
18
18
  Requires-Dist: pytest>=8.0; extra == 'dev'
19
+ Provides-Extra: full
20
+ Requires-Dist: fastapi>=0.115; extra == 'full'
21
+ Requires-Dist: mcp>=1.0.0; extra == 'full'
22
+ Requires-Dist: numpy>=1.26; extra == 'full'
23
+ Requires-Dist: turbovec<1.0,>=0.7; extra == 'full'
24
+ Requires-Dist: uvicorn>=0.30; extra == 'full'
19
25
  Provides-Extra: mcp
20
26
  Requires-Dist: mcp>=1.0.0; extra == 'mcp'
21
27
  Provides-Extra: semantic
22
28
  Requires-Dist: numpy>=1.26; extra == 'semantic'
23
- Requires-Dist: turbovec==0.7.0; extra == 'semantic'
29
+ Requires-Dist: turbovec<1.0,>=0.7; extra == 'semantic'
24
30
  Description-Content-Type: text/markdown
25
31
 
26
- # AgentMemoryOS
32
+ <p align="center">
33
+ <img src="https://raw.githubusercontent.com/yamantaka520/Agent-Memory-OS/main/assets/logo-header.png" alt="Agent Memory OS" width="560">
34
+ </p>
27
35
 
28
36
  A **local-first memory engine for AI agents** — single or multi-agent, with shared and private memories, associative recall, and context-budgeted retrieval. One SQLite file, zero required dependencies, Apache-2.0.
29
37
 
@@ -46,14 +54,25 @@ Agents need durable facts, preferences, procedures, and lessons — but prompt-i
46
54
  ## Install
47
55
 
48
56
  ```bash
49
- pip install agent-memory-os # core (no dependencies)
50
- pip install 'agent-memory-os[mcp]' # + MCP server
51
- pip install 'agent-memory-os[api]' # + Web UI
52
- pip install 'agent-memory-os[semantic]' # + vector candidate sidecar
57
+ pip install 'agent-memory-os[full]' # recommended: everything (Web UI, MCP, turbovec)
53
58
  ```
54
59
 
60
+ Or pick pieces: `agent-memory-os` (core, zero dependencies), `[api]` (Web UI), `[mcp]` (MCP server), `[semantic]` (turbovec vector recall).
61
+
55
62
  Requires Python 3.11+ with SQLite FTS5 (included in standard CPython builds).
56
63
 
64
+ After installing, run two commands:
65
+
66
+ ```bash
67
+ agent-memory doctor # verifies FTS5, turbovec, and the other extras
68
+ # (add --install to auto-install anything missing)
69
+ agent-memory token create # protects the Web UI API with a bearer token
70
+ ```
71
+
72
+ The token is stored at `<home>/web_token` (mode 600); `agent-memory-web` picks
73
+ it up automatically and the console prompts for it on first use. Manage it
74
+ later with `agent-memory token show|rotate|disable`.
75
+
57
76
  ## Quickstart
58
77
 
59
78
  ```python
@@ -108,6 +127,61 @@ Design invariants:
108
127
 
109
128
  See [SPEC.md](SPEC.md) for the full contract.
110
129
 
130
+ ## Storage engines: SQLite + turbovec
131
+
132
+ AgentMemoryOS uses **two storage layers with strictly different authority**:
133
+
134
+ - **SQLite** (always on) is the single source of truth: memories, links,
135
+ profiles, and the FTS5 lexical index all live in one `memories.db` file.
136
+ - **turbovec** (installed with `[full]` / `[semantic]`) is the semantic vector
137
+ engine: an in-memory quantized index that recalls memories by meaning rather
138
+ than keywords. It is deliberately **disposable** — it returns candidate
139
+ `memory_id`s and scores only; every candidate rejoins SQLite and passes the
140
+ ACL/expiry hard gates before its content can be used, and the index can be
141
+ dropped and rebuilt at any time without touching the truth store.
142
+
143
+ To activate semantic recall, supply an embedding function and wire the
144
+ provider in:
145
+
146
+ ```python
147
+ from agent_memory_os.providers.turbovec import TurbovecSemanticCandidateProvider
148
+
149
+ provider = TurbovecSemanticCandidateProvider.from_vectors(
150
+ vectors=embeddings, # one row per memory, any embedder
151
+ external_id_by_memory_id=id_mapping, # stable memory_id -> uint64
152
+ embed_query=embed, # str -> vector, same embedder
153
+ )
154
+ client = MemoryClient(home="~/.agent-memory", candidate_providers=[provider])
155
+ ```
156
+
157
+ `agent-memory doctor` confirms the turbovec backend is importable.
158
+
159
+ ## Backup & restore
160
+
161
+ ```bash
162
+ agent-memory backup ~/backups/memories-$(date +%F).db # online, WAL-safe
163
+ agent-memory restore ~/backups/memories-2026-07-11.db --force
164
+ ```
165
+
166
+ Backups use SQLite's online backup API, so they are consistent even while
167
+ agents are writing. Disposable indexes rebuild automatically after a restore.
168
+
169
+ ## Agent integrations
170
+
171
+ Step-by-step guides for wiring AgentMemoryOS into common agents — click a tile:
172
+
173
+ <p>
174
+ <a href="docs/integrations/claude-code.md"><img src="assets/integrations/claude-code.svg" alt="Claude Code integration guide" height="56"></a>
175
+ <a href="docs/integrations/codex.md"><img src="assets/integrations/codex.svg" alt="Codex integration guide" height="56"></a>
176
+ <br>
177
+ <a href="docs/integrations/openclaw.md"><img src="assets/integrations/openclaw.svg" alt="OpenClaw integration guide" height="56"></a>
178
+ <a href="docs/integrations/hermes-agent.md"><img src="assets/integrations/hermes-agent.svg" alt="Hermes Agent integration guide" height="56"></a>
179
+ </p>
180
+
181
+ Any MCP-capable agent can use the same pattern: run
182
+ `python -m agent_memory_os.mcp_server` as a stdio MCP server pointing at a
183
+ shared `AGENT_MEMORY_HOME`.
184
+
111
185
  ## MCP server
112
186
 
113
187
  ```bash
@@ -1,4 +1,6 @@
1
- # AgentMemoryOS
1
+ <p align="center">
2
+ <img src="https://raw.githubusercontent.com/yamantaka520/Agent-Memory-OS/main/assets/logo-header.png" alt="Agent Memory OS" width="560">
3
+ </p>
2
4
 
3
5
  A **local-first memory engine for AI agents** — single or multi-agent, with shared and private memories, associative recall, and context-budgeted retrieval. One SQLite file, zero required dependencies, Apache-2.0.
4
6
 
@@ -21,14 +23,25 @@ Agents need durable facts, preferences, procedures, and lessons — but prompt-i
21
23
  ## Install
22
24
 
23
25
  ```bash
24
- pip install agent-memory-os # core (no dependencies)
25
- pip install 'agent-memory-os[mcp]' # + MCP server
26
- pip install 'agent-memory-os[api]' # + Web UI
27
- pip install 'agent-memory-os[semantic]' # + vector candidate sidecar
26
+ pip install 'agent-memory-os[full]' # recommended: everything (Web UI, MCP, turbovec)
28
27
  ```
29
28
 
29
+ Or pick pieces: `agent-memory-os` (core, zero dependencies), `[api]` (Web UI), `[mcp]` (MCP server), `[semantic]` (turbovec vector recall).
30
+
30
31
  Requires Python 3.11+ with SQLite FTS5 (included in standard CPython builds).
31
32
 
33
+ After installing, run two commands:
34
+
35
+ ```bash
36
+ agent-memory doctor # verifies FTS5, turbovec, and the other extras
37
+ # (add --install to auto-install anything missing)
38
+ agent-memory token create # protects the Web UI API with a bearer token
39
+ ```
40
+
41
+ The token is stored at `<home>/web_token` (mode 600); `agent-memory-web` picks
42
+ it up automatically and the console prompts for it on first use. Manage it
43
+ later with `agent-memory token show|rotate|disable`.
44
+
32
45
  ## Quickstart
33
46
 
34
47
  ```python
@@ -83,6 +96,61 @@ Design invariants:
83
96
 
84
97
  See [SPEC.md](SPEC.md) for the full contract.
85
98
 
99
+ ## Storage engines: SQLite + turbovec
100
+
101
+ AgentMemoryOS uses **two storage layers with strictly different authority**:
102
+
103
+ - **SQLite** (always on) is the single source of truth: memories, links,
104
+ profiles, and the FTS5 lexical index all live in one `memories.db` file.
105
+ - **turbovec** (installed with `[full]` / `[semantic]`) is the semantic vector
106
+ engine: an in-memory quantized index that recalls memories by meaning rather
107
+ than keywords. It is deliberately **disposable** — it returns candidate
108
+ `memory_id`s and scores only; every candidate rejoins SQLite and passes the
109
+ ACL/expiry hard gates before its content can be used, and the index can be
110
+ dropped and rebuilt at any time without touching the truth store.
111
+
112
+ To activate semantic recall, supply an embedding function and wire the
113
+ provider in:
114
+
115
+ ```python
116
+ from agent_memory_os.providers.turbovec import TurbovecSemanticCandidateProvider
117
+
118
+ provider = TurbovecSemanticCandidateProvider.from_vectors(
119
+ vectors=embeddings, # one row per memory, any embedder
120
+ external_id_by_memory_id=id_mapping, # stable memory_id -> uint64
121
+ embed_query=embed, # str -> vector, same embedder
122
+ )
123
+ client = MemoryClient(home="~/.agent-memory", candidate_providers=[provider])
124
+ ```
125
+
126
+ `agent-memory doctor` confirms the turbovec backend is importable.
127
+
128
+ ## Backup & restore
129
+
130
+ ```bash
131
+ agent-memory backup ~/backups/memories-$(date +%F).db # online, WAL-safe
132
+ agent-memory restore ~/backups/memories-2026-07-11.db --force
133
+ ```
134
+
135
+ Backups use SQLite's online backup API, so they are consistent even while
136
+ agents are writing. Disposable indexes rebuild automatically after a restore.
137
+
138
+ ## Agent integrations
139
+
140
+ Step-by-step guides for wiring AgentMemoryOS into common agents — click a tile:
141
+
142
+ <p>
143
+ <a href="docs/integrations/claude-code.md"><img src="assets/integrations/claude-code.svg" alt="Claude Code integration guide" height="56"></a>
144
+ <a href="docs/integrations/codex.md"><img src="assets/integrations/codex.svg" alt="Codex integration guide" height="56"></a>
145
+ <br>
146
+ <a href="docs/integrations/openclaw.md"><img src="assets/integrations/openclaw.svg" alt="OpenClaw integration guide" height="56"></a>
147
+ <a href="docs/integrations/hermes-agent.md"><img src="assets/integrations/hermes-agent.svg" alt="Hermes Agent integration guide" height="56"></a>
148
+ </p>
149
+
150
+ Any MCP-capable agent can use the same pattern: run
151
+ `python -m agent_memory_os.mcp_server` as a stdio MCP server pointing at a
152
+ shared `AGENT_MEMORY_HOME`.
153
+
86
154
  ## MCP server
87
155
 
88
156
  ```bash
File without changes
@@ -0,0 +1,19 @@
1
+ # Assets
2
+
3
+ Canonical logo: `agent-memory-os-logo-integrated-v2.png` (wordmark, 1981×793).
4
+
5
+ Derived variants (regenerate from the canonical file when it changes):
6
+
7
+ - `logo-header.png` — 960px optimized banner; README header on GitHub /
8
+ GitLab and PyPI (referenced by absolute raw.githubusercontent URL).
9
+ - `logo-icon-512.png` — square A+cat glyph, transparent background; also
10
+ copied to the repo root as `logo.png`, which GitLab auto-uses as the
11
+ project avatar.
12
+ - `logo-icon-128.png` — small icon; embedded base64 in the Web UI as the
13
+ brand mark and favicon (`src/agent_memory_os/web_ui.py`).
14
+ - `integrations/` — clickable integration badges used by the root README.
15
+ Original wordmark tiles, no third-party trademark artwork.
16
+
17
+ GitHub has no repo avatar API: set Settings → Social preview manually with
18
+ `logo-header.png` if wanted. Other logo files (`-ai-v1`, plain, wordmark)
19
+ are design-iteration history.
@@ -0,0 +1,18 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" role="img" aria-labelledby="title desc">
2
+ <title id="title">Agent Memory OS logo</title>
3
+ <desc id="desc">A white geometric letter A on a purple field with a memory-profile silhouette formed in negative space.</desc>
4
+ <rect width="512" height="512" rx="72" fill="#4B2E83"/>
5
+ <path
6
+ fill="#FFFFFF"
7
+ fill-rule="evenodd"
8
+ d="M72 448 207 64h98l135 384H333l-22-76H201l-22 76H72Zm150-148h68l-34-116-34 116Z"
9
+ />
10
+ <path
11
+ fill="#4B2E83"
12
+ d="M201 448c0-70 9-132 28-186 18-53 46-102 83-147 8-10 23-7 27 6l14 48c8-2 17-3 27-2 32 3 58 27 63 59 2 13 8 20 19 24 17 6 27 23 25 42-3 35-29 59-69 68-30 7-51 18-57 36-4 13 1 24 15 33 27 17 49 41 65 72 8 15-3 33-20 33H201v-86Z"
13
+ />
14
+ <circle cx="295" cy="225" r="9" fill="#FFFFFF"/>
15
+ <circle cx="326" cy="203" r="7" fill="#FFFFFF"/>
16
+ <circle cx="359" cy="214" r="8" fill="#FFFFFF"/>
17
+ <path d="M302 221 321 207M333 205l19 7" stroke="#FFFFFF" stroke-width="7" stroke-linecap="round"/>
18
+ </svg>
@@ -0,0 +1,36 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1280 360" role="img" aria-labelledby="title desc">
2
+ <title id="title">Agent Memory OS wordmark</title>
3
+ <desc id="desc">Agent Memory OS wordmark with the negative-space A icon and text.</desc>
4
+ <rect width="360" height="360" rx="48" fill="#4B2E83"/>
5
+ <path
6
+ fill="#FFFFFF"
7
+ fill-rule="evenodd"
8
+ d="M51 315 146 45h69l95 270h-75l-15-54h-78l-15 54H51Zm105-104h48l-24-82-24 82Z"
9
+ />
10
+ <path
11
+ fill="#4B2E83"
12
+ d="M142 315c0-49 7-93 20-131 13-37 32-72 58-104 6-7 16-5 19 4l10 34c6-2 12-2 19-1 23 2 41 19 45 42 1 9 5 14 13 17 12 4 19 16 18 30-2 24-21 41-49 47-21 5-36 13-40 25-3 9 1 17 11 23 19 12 35 29 46 51 5 11-2 23-15 23H142v-60Z"
13
+ />
14
+ <circle cx="209" cy="158" r="6" fill="#FFFFFF"/>
15
+ <circle cx="230" cy="143" r="5" fill="#FFFFFF"/>
16
+ <circle cx="253" cy="151" r="6" fill="#FFFFFF"/>
17
+ <path d="m214 155 13-10m9-1 14 5" stroke="#FFFFFF" stroke-width="5" stroke-linecap="round"/>
18
+ <text
19
+ x="430"
20
+ y="163"
21
+ fill="#211A2E"
22
+ font-family="Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif"
23
+ font-size="78"
24
+ font-weight="800"
25
+ letter-spacing="0"
26
+ >Agent Memory OS</text>
27
+ <text
28
+ x="433"
29
+ y="227"
30
+ fill="#685B7F"
31
+ font-family="Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif"
32
+ font-size="30"
33
+ font-weight="600"
34
+ letter-spacing="0"
35
+ >Local-first recall for AI agents</text>
36
+ </svg>
@@ -0,0 +1,11 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="220" height="64" viewBox="0 0 220 64" role="img" aria-label="Claude Code integration guide">
2
+ <rect x="1" y="1" width="218" height="62" rx="14" fill="#1d1a17" stroke="#3d342c"/>
3
+ <circle cx="32" cy="32" r="17" fill="#d97757"/>
4
+ <g transform="translate(32 32)" stroke="#1d1a17" stroke-width="3.4" stroke-linecap="round">
5
+ <line x1="0" y1="-10" x2="0" y2="10"/>
6
+ <line x1="-8.7" y1="-5" x2="8.7" y2="5"/>
7
+ <line x1="-8.7" y1="5" x2="8.7" y2="-5"/>
8
+ </g>
9
+ <text x="60" y="30" font-family="-apple-system,'Segoe UI',Helvetica,Arial,sans-serif" font-size="16" font-weight="700" fill="#f3ede7">Claude Code</text>
10
+ <text x="60" y="47" font-family="-apple-system,'Segoe UI',Helvetica,Arial,sans-serif" font-size="11" fill="#a89e93">integration guide →</text>
11
+ </svg>
@@ -0,0 +1,10 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="220" height="64" viewBox="0 0 220 64" role="img" aria-label="Codex integration guide">
2
+ <rect x="1" y="1" width="218" height="62" rx="14" fill="#101314" stroke="#2c3436"/>
3
+ <circle cx="32" cy="32" r="17" fill="#e8eceb"/>
4
+ <g stroke="#101314" stroke-width="3.2" stroke-linecap="round" fill="none">
5
+ <polyline points="24,26 31,32 24,38"/>
6
+ <line x1="35" y1="38" x2="42" y2="38"/>
7
+ </g>
8
+ <text x="60" y="30" font-family="-apple-system,'Segoe UI',Helvetica,Arial,sans-serif" font-size="16" font-weight="700" fill="#eef2f1">Codex</text>
9
+ <text x="60" y="47" font-family="-apple-system,'Segoe UI',Helvetica,Arial,sans-serif" font-size="11" fill="#96a2a0">integration guide →</text>
10
+ </svg>
@@ -0,0 +1,11 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="220" height="64" viewBox="0 0 220 64" role="img" aria-label="Hermes Agent integration guide">
2
+ <rect x="1" y="1" width="218" height="62" rx="14" fill="#141126" stroke="#312a55"/>
3
+ <circle cx="32" cy="32" r="17" fill="#8b6ef6"/>
4
+ <g stroke="#141126" stroke-width="3" stroke-linecap="round" fill="none">
5
+ <path d="M 22 38 Q 30 36 34 30 Q 36 26 34 23"/>
6
+ <path d="M 26 40 Q 34 39 39 33"/>
7
+ <path d="M 31 42 Q 38 42 43 37"/>
8
+ </g>
9
+ <text x="60" y="30" font-family="-apple-system,'Segoe UI',Helvetica,Arial,sans-serif" font-size="16" font-weight="700" fill="#efecfb">Hermes Agent</text>
10
+ <text x="60" y="47" font-family="-apple-system,'Segoe UI',Helvetica,Arial,sans-serif" font-size="11" fill="#a49bce">integration guide →</text>
11
+ </svg>
@@ -0,0 +1,11 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="220" height="64" viewBox="0 0 220 64" role="img" aria-label="OpenClaw integration guide">
2
+ <rect x="1" y="1" width="218" height="62" rx="14" fill="#1b1210" stroke="#43261f"/>
3
+ <circle cx="32" cy="32" r="17" fill="#e0563a"/>
4
+ <g stroke="#1b1210" stroke-width="3.2" stroke-linecap="round" fill="none">
5
+ <path d="M 24 40 Q 24 24 33 22"/>
6
+ <path d="M 29 41 Q 30 29 37 26"/>
7
+ <path d="M 35 42 Q 37 33 42 31"/>
8
+ </g>
9
+ <text x="60" y="30" font-family="-apple-system,'Segoe UI',Helvetica,Arial,sans-serif" font-size="16" font-weight="700" fill="#f6ece8">OpenClaw</text>
10
+ <text x="60" y="47" font-family="-apple-system,'Segoe UI',Helvetica,Arial,sans-serif" font-size="11" fill="#b39a91">integration guide →</text>
11
+ </svg>
@@ -1,3 +1,5 @@
1
+ <p align="center"><img src="../assets/logo-header.png" alt="Agent Memory OS" width="480"></p>
2
+
1
3
  # AgentMemoryOS
2
4
 
3
5
  ## 🚀 Project Overview
@@ -0,0 +1,76 @@
1
+ # AgentMemoryOS Roadmap
2
+
3
+ Last updated: 2026-07-11
4
+
5
+ Governance rules:
6
+
7
+ 1. A milestone is "done" only when its features are merged, tested, and
8
+ evidenced in this repository. Production claims (canary percentages,
9
+ default-backend status, traffic switches) belong in `PROJECT_STATUS.md`
10
+ with evidence, never here.
11
+ 2. **Web console parity is part of Done**: every engine feature that changes
12
+ what users can inspect or control (new memory fields, new operations, new
13
+ retrieval behavior) ships with matching Web UI support in the same
14
+ milestone — the console must never lag the engine.
15
+
16
+ ## Shipped — v0.2.3 (current release)
17
+
18
+ - SQLite + FTS5 source of truth; requester-aware ACL and expiry hard gates
19
+ - Truth arbitration, context budget packs with auditable decisions
20
+ - Memory association layer: authoritative `memory_links`, resonance recall
21
+ (ACL-safe traversal), link decay, hub damping, supersedes demotion
22
+ - Recall loop: Hebbian reinforcement, negative feedback, auto-reinforce packs
23
+ - Per-agent `RecallProfile` personas (persisted, auto-applied)
24
+ - Write-side consolidation (duplicate merge + concept synthesis)
25
+ - turbovec semantic candidate sidecar (validation-gated, disposable)
26
+ - Web console: dashboard, search/browse/edit, association graph, tools,
27
+ bearer-token auth; MCP server (9 tools); token/doctor/backup CLI
28
+ - CI (3 Python versions) and Trusted-Publishing release workflow
29
+
30
+ ## v0.3 — Robust persistent memory (in progress)
31
+
32
+ Goal: a memory you can trust with years of an agent's life.
33
+
34
+ 1. **Durability operations** — `agent-memory backup/restore` (shipped),
35
+ scheduled snapshot rotation, integrity check command
36
+ (`PRAGMA integrity_check` + row-count/id invariants).
37
+ 2. **Schema migrations** — versioned migration table and forward-only
38
+ migration runner, replacing ad-hoc `ALTER TABLE` checks; downgrade
39
+ verification stays a release gate.
40
+ 3. **Embedding pipeline** — optional background indexer that keeps a turbovec
41
+ index in sync with the memories table (pluggable embedder), so semantic
42
+ recall works out of the box instead of requiring hand-wired vectors.
43
+ 4. **Retention policies** — per-scope/type archival rules: expired and
44
+ decayed-out memories move to a cold archive table (excluded from recall,
45
+ restorable) instead of deletion-only lifecycle.
46
+ 5. **Hermes activation evidence** — shadow comparison logs, golden recall at
47
+ target, importer idempotency; gates in `PROJECT_STATUS.md`.
48
+
49
+ ## v0.4 — Dynamic context orchestration (design + prototypes)
50
+
51
+ Goal: the memory system decides *what enters the context window, when* —
52
+ not just what exists.
53
+
54
+ 1. **Session working memory** — `ContextSnapshot` offload/reload (prototype
55
+ shipped, exposed via MCP): agents park working state mid-session and
56
+ resume across context-window resets; add snapshot retention and diffing.
57
+ 2. **Budget-aware orchestration** — one call that splits a token budget
58
+ across bedrock memories, task-relevant recall, resonance neighbors, and
59
+ session snapshots, with per-bucket reserves (extends the v0.2.2
60
+ arbitration allocator).
61
+ 3. **Proactive recall** — type-aware triggers: procedures surface when a task
62
+ type is detected, warnings surface before matching risky actions, not
63
+ only on lexical/semantic query match.
64
+ 4. **Mid-task recall loop** — MCP affordances for iterative deepening
65
+ (initial pack → follow-up queries with dedup against what the agent
66
+ already saw this session).
67
+ 5. **Resonance maturation** — LLM-assisted triplet extraction at
68
+ consolidation time replacing regex ERA; graph-quality metrics
69
+ (hub distribution, orphan rate) on the dashboard.
70
+
71
+ ## Later / research
72
+
73
+ - Cross-agent memory negotiation: explicit share/de-identify flows with audit
74
+ trail (private → team without copy-paste)
75
+ - Federated multi-host sync with conflict resolution
76
+ - Forgetting curves tuned from recall-feedback telemetry
@@ -0,0 +1,67 @@
1
+ # Using AgentMemoryOS with Claude Code
2
+
3
+ Claude Code speaks MCP natively, so the memory engine plugs in as a stdio MCP
4
+ server — no glue code required.
5
+
6
+ ## 1. Install
7
+
8
+ ```bash
9
+ pip install 'agent-memory-os[full]'
10
+ agent-memory doctor
11
+ ```
12
+
13
+ ## 2. Register the MCP server
14
+
15
+ Project-scoped (recommended — the whole team gets it via `.mcp.json`):
16
+
17
+ ```bash
18
+ claude mcp add agent-memory --scope project \
19
+ --env AGENT_MEMORY_HOME=$HOME/.agent-memory \
20
+ -- python -m agent_memory_os.mcp_server
21
+ ```
22
+
23
+ Or user-scoped (`--scope user`) to share one memory home across all projects.
24
+
25
+ Equivalent `.mcp.json` entry if you prefer editing the file directly:
26
+
27
+ ```json
28
+ {
29
+ "mcpServers": {
30
+ "agent-memory": {
31
+ "command": "python",
32
+ "args": ["-m", "agent_memory_os.mcp_server"],
33
+ "env": { "AGENT_MEMORY_HOME": "~/.agent-memory" }
34
+ }
35
+ }
36
+ }
37
+ ```
38
+
39
+ ## 3. Teach Claude when to use it
40
+
41
+ Add a short section to your `CLAUDE.md` so the model reaches for memory at the
42
+ right moments:
43
+
44
+ ```markdown
45
+ ## Memory
46
+ - At the start of a task, call `memory_context_pack` with a short description
47
+ of the task to recall relevant facts, procedures, and warnings.
48
+ - When you learn a durable fact, preference, decision, or lesson, save it with
49
+ `memory_add` (owner = this agent's id; use visibility ["global"] for
50
+ team-wide knowledge, [] for private).
51
+ - When recalled memories were helpful or misleading, report it with
52
+ `memory_recall_feedback` so ranking improves.
53
+ ```
54
+
55
+ ## 4. Available tools
56
+
57
+ `memory_add`, `memory_search`, `memory_context_pack`, `memory_link`,
58
+ `memory_update`, `memory_recall_feedback`, `memory_consolidate`,
59
+ `memory_offload_context`, `memory_reload_context`.
60
+
61
+ ## Tips
62
+
63
+ - Give each agent persona a stable `owner` id so private/team/global
64
+ visibility boundaries mean something.
65
+ - Keep `AGENT_MEMORY_HOME` on a local disk (not NFS/SMB).
66
+ - Run the Web console (`agent-memory-web`) beside it to inspect what the
67
+ agent remembers, browse the association graph, and prune.