@romiluz/clawmongo 2026.3.23 → 2026.3.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.
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ClawMongo --
|
|
1
|
+
# ClawMongo -- OpenClaw, but it remembers.
|
|
2
2
|
|
|
3
3
|
<p align="center">
|
|
4
4
|
<img src="./README-clawmongo-header-v2.png" alt="ClawMongo" width="100%">
|
|
@@ -11,7 +11,9 @@
|
|
|
11
11
|
<a href="LICENSE"><img src="https://img.shields.io/badge/License-MIT-blue.svg?style=for-the-badge" alt="MIT License"></a>
|
|
12
12
|
</p>
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
Same channels. Same plugins. Same voice. But your agent's memory lives in MongoDB -- not in files that corrupt, disappear, or overflow your context window.
|
|
15
|
+
|
|
16
|
+
ClawMongo is [OpenClaw](https://github.com/openclaw/openclaw) (329K+ stars, 22 messaging channels, native apps, 78 extensions) with its memory replaced by a production MongoDB backend. Where OpenClaw defaults to QMD (SQLite + Markdown files), ClawMongo uses MongoDB Community + mongot + Voyage AI for vector search, knowledge graphs, episode materialization, event-sourcing, and 8 retrieval paths -- all in one database. Nothing is ever lost.
|
|
15
17
|
|
|
16
18
|
[ClawMongo Repo](https://github.com/romiluz13/ClawMongo) |
|
|
17
19
|
[Getting Started](docs/start/clawmongo-getting-started.md) |
|
|
@@ -24,15 +26,15 @@ ClawMongo is [OpenClaw](https://github.com/openclaw/openclaw) (329K stars, 22 me
|
|
|
24
26
|
|
|
25
27
|
## What Is ClawMongo?
|
|
26
28
|
|
|
27
|
-
|
|
29
|
+
The full OpenClaw personal AI assistant -- 22 messaging channels (WhatsApp, Telegram, Slack, Discord, Signal, iMessage, Microsoft Teams, Matrix, and 14 more), 78 extensions (25+ LLM providers, tools, media, infra), companion apps for macOS/iOS/Android, voice wake, live canvas, and the entire skills platform -- with a MongoDB brain instead of files.
|
|
28
30
|
|
|
29
|
-
ClawMongo is **not** a memory library. It is a complete personal AI assistant
|
|
31
|
+
ClawMongo is **not** a memory library. It is a complete personal AI assistant with a real database behind it. The product is the assistant. MongoDB is what makes it production-ready.
|
|
30
32
|
|
|
31
|
-
**
|
|
33
|
+
**Who is this for:**
|
|
32
34
|
|
|
33
|
-
1. **OpenClaw
|
|
34
|
-
2. **MongoDB developers** who want a personal AI assistant that stores everything in the database
|
|
35
|
-
3. **
|
|
35
|
+
1. **OpenClaw users** whose agent forgot something important. Again. You want a real backend, not files.
|
|
36
|
+
2. **MongoDB developers** who want a personal AI assistant that stores everything in the database you already know and operate.
|
|
37
|
+
3. **Teams building Company OS** -- multi-agent systems that need shared memory, knowledge bases, audit trails, and enterprise-grade isolation. All in MongoDB.
|
|
36
38
|
|
|
37
39
|
---
|
|
38
40
|
|
package/dist/build-info.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
5bb97da39c969f15f4f6c2e635463a7bd72ab48619e302f1632b2a3a4682ab4d
|
|
@@ -0,0 +1,397 @@
|
|
|
1
|
+
# Web Research: Company OS -- AI Agents as the Operating System for Companies, and Why MongoDB Is the Ideal Database
|
|
2
|
+
|
|
3
|
+
## Execution
|
|
4
|
+
- Preferred backend: websearch+webfetch
|
|
5
|
+
- Allowed fallbacks: webfetch-only
|
|
6
|
+
- Research round: 1
|
|
7
|
+
|
|
8
|
+
## Sources Used
|
|
9
|
+
- WebFetch: MongoDB product pages, blog, newsroom, investor relations (multiple URLs)
|
|
10
|
+
- WebFetch: Anthropic's building effective agents guide
|
|
11
|
+
- WebFetch: LangChain/LangGraph agent documentation
|
|
12
|
+
- WebFetch: CrewAI memory documentation
|
|
13
|
+
- WebFetch: Lilian Weng's agent memory architecture survey
|
|
14
|
+
- WebFetch: LangSmith observability documentation
|
|
15
|
+
- WebFetch: Supabase agent blog
|
|
16
|
+
- WebFetch: OpenAI governance practices paper
|
|
17
|
+
- Failed sources: Reddit (blocked), Google Search (JS-rendered), McKinsey (timeout), Gartner (403), a16z/Sequoia (404s), multiple MongoDB developer docs (CSS-only rendering)
|
|
18
|
+
|
|
19
|
+
## Research Quality
|
|
20
|
+
- Status: PARTIAL
|
|
21
|
+
- Quality level: medium
|
|
22
|
+
- Backend mode: webfetch-only
|
|
23
|
+
- Notes: Google Search and Reddit were inaccessible. Many MongoDB developer pages returned only CSS (server-side rendering not captured). Multiple VC/analyst sites returned 404s. Research is synthesized from ~15 successfully fetched sources plus strong domain knowledge from the project codebase.
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## 1. What Is "Company OS"?
|
|
28
|
+
|
|
29
|
+
### The Concept
|
|
30
|
+
|
|
31
|
+
"Company OS" is the emerging idea that AI agents will collectively form the **operating system of a company** -- handling workflows, decisions, and coordination the way an OS handles processes, memory, and I/O for a computer.
|
|
32
|
+
|
|
33
|
+
Just as a computer OS manages:
|
|
34
|
+
- **Processes** (running programs concurrently)
|
|
35
|
+
- **Memory** (shared and isolated state)
|
|
36
|
+
- **File system** (persistent knowledge)
|
|
37
|
+
- **I/O** (communication between processes and the outside world)
|
|
38
|
+
- **Security** (access control, permissions)
|
|
39
|
+
|
|
40
|
+
A Company OS manages:
|
|
41
|
+
- **Agents** (sales agent, support agent, engineering agent running concurrently)
|
|
42
|
+
- **Memory** (shared company knowledge and per-agent context)
|
|
43
|
+
- **Knowledge base** (documents, procedures, policies)
|
|
44
|
+
- **Channels** (email, Slack, SMS, voice, web -- the agent's I/O)
|
|
45
|
+
- **Permissions** (which agents can access what data, who can override whom)
|
|
46
|
+
|
|
47
|
+
### Who Is Building This
|
|
48
|
+
|
|
49
|
+
The trend manifests across multiple layers:
|
|
50
|
+
|
|
51
|
+
1. **Workspace platforms** (Notion, Microsoft 365 Copilot, Google Workspace) are adding agent layers on top of existing document/project tools.
|
|
52
|
+
2. **Vertical SaaS** (Rippling for HR, Ramp for finance) is embedding domain-specific agents into existing workflows.
|
|
53
|
+
3. **Horizontal agent platforms** (LangChain/LangGraph, CrewAI, AutoGen, OpenAI Agents SDK, Anthropic Claude Agent SDK) provide the orchestration layer.
|
|
54
|
+
4. **Infrastructure providers** (MongoDB, Supabase, Temporal) are positioning as the data and execution backbone.
|
|
55
|
+
|
|
56
|
+
### Requirements for a Company OS
|
|
57
|
+
|
|
58
|
+
From the research, the requirements cluster into:
|
|
59
|
+
|
|
60
|
+
| Requirement | Why |
|
|
61
|
+
|---|---|
|
|
62
|
+
| **Multi-agent orchestration** | Companies need many specialized agents, not one monolith |
|
|
63
|
+
| **Shared memory with isolation** | Agents must share company knowledge but maintain per-agent context |
|
|
64
|
+
| **Persistent knowledge base** | Company documents, SOPs, product info must be retrievable by agents |
|
|
65
|
+
| **Audit trail** | Every agent action must be traceable for compliance and debugging |
|
|
66
|
+
| **Channel multiplexing** | Agents must operate across email, chat, voice, web simultaneously |
|
|
67
|
+
| **Human-in-the-loop** | Critical decisions must route to humans with full context |
|
|
68
|
+
| **Durable execution** | Long-running agent workflows must survive failures |
|
|
69
|
+
| **Access control** | Agents must respect data boundaries (HR data vs. sales data) |
|
|
70
|
+
| **Observability** | Operators must see what agents are doing and why |
|
|
71
|
+
|
|
72
|
+
---
|
|
73
|
+
|
|
74
|
+
## 2. Why Companies Need an Agentic Data Layer
|
|
75
|
+
|
|
76
|
+
### The Problem with Simple Storage
|
|
77
|
+
|
|
78
|
+
LangChain's documentation (confirmed via fetch) states that "more agentic systems require substantial new infrastructure" including orchestration, durable execution, observability, and evaluation frameworks. This is not a problem that SQLite or flat files solve.
|
|
79
|
+
|
|
80
|
+
**Why flat files / SQLite fail for agent systems:**
|
|
81
|
+
|
|
82
|
+
1. **No concurrent access model.** Multiple agents writing to the same SQLite DB creates locking contention. MongoDB handles concurrent writes natively with document-level locking.
|
|
83
|
+
|
|
84
|
+
2. **No vector search.** Agent memory requires semantic retrieval (finding relevant memories by meaning, not just by key). SQLite has no built-in vector similarity. MongoDB Atlas Vector Search is native.
|
|
85
|
+
|
|
86
|
+
3. **No schema flexibility.** Agent state is heterogeneous -- conversation messages, tool calls, extracted entities, structured facts, episodes. A rigid relational schema cannot model this without dozens of tables. MongoDB's document model handles polymorphic data naturally.
|
|
87
|
+
|
|
88
|
+
4. **No graph traversal.** Entities and relationships require graph-like queries ($graphLookup). No equivalent in SQLite.
|
|
89
|
+
|
|
90
|
+
5. **No Change Streams.** Real-time event-driven patterns (new event triggers episode materialization) require change notification. MongoDB Change Streams provide this natively.
|
|
91
|
+
|
|
92
|
+
6. **No built-in replication/HA.** Company OS is production infrastructure. SQLite is single-node by design.
|
|
93
|
+
|
|
94
|
+
### What an Agentic Data Layer Must Provide
|
|
95
|
+
|
|
96
|
+
Drawing from the research and ClawMongo's architecture:
|
|
97
|
+
|
|
98
|
+
- **Event sourcing**: Every agent interaction is an immutable event (audit + replay)
|
|
99
|
+
- **Derived views**: Chunks, episodes, and entities projected from events (flexibility)
|
|
100
|
+
- **Semantic retrieval**: Vector search across memory and knowledge (relevance)
|
|
101
|
+
- **Graph queries**: Entity-relationship traversal ($graphLookup for "what does the agent know about X and everything connected to X?")
|
|
102
|
+
- **Hybrid search**: Combining vector similarity + full-text + metadata filters in one query
|
|
103
|
+
- **TTL and lifecycle**: Automatic expiration of short-term memory, importance-based eviction
|
|
104
|
+
- **Multi-tenancy**: Per-agent, per-team, per-company isolation with shared knowledge layers
|
|
105
|
+
- **Transactions**: ACID guarantees when writing events and projecting derived data
|
|
106
|
+
|
|
107
|
+
---
|
|
108
|
+
|
|
109
|
+
## 3. Why MongoDB for Agentic Systems
|
|
110
|
+
|
|
111
|
+
### MongoDB's Official Positioning
|
|
112
|
+
|
|
113
|
+
From successfully fetched MongoDB sources:
|
|
114
|
+
|
|
115
|
+
**MongoDB's headline AI positioning** (mongodb.com/use-cases/artificial-intelligence): "AI isn't forcing change. It is the change." They position three core AI capabilities:
|
|
116
|
+
1. Semantic Search
|
|
117
|
+
2. Retrieval Augmented Generation (RAG)
|
|
118
|
+
3. **Agentic AI** -- explicitly called out as a primary use case
|
|
119
|
+
|
|
120
|
+
**MongoDB's definition of AI agents** (mongodb.com/resources): AI agents "take autonomous actions rather than just respond to queries... execute tasks using available tools... move beyond conversation to actual task completion." MongoDB positions itself as the "data infrastructure backbone."
|
|
121
|
+
|
|
122
|
+
**MongoDB's Voyage AI acquisition** (investor relations, Q4 FY2025): "Following the Voyage AI acquisition, we combine real-time data, sophisticated embedding and retrieval models and semantic search directly in the database." This is the key strategic move -- embeddings are now native to MongoDB, not an external service.
|
|
123
|
+
|
|
124
|
+
**MongoDB's January 2026 announcements** (newsroom):
|
|
125
|
+
- **Automated Embedding**: MongoDB automatically generates and stores embeddings when data is inserted, updated, or queried. No external embedding pipeline needed.
|
|
126
|
+
- **Voyage 4 models**: Four tiers of embedding models (general, large, lite, nano) including multimodal (text + images + video).
|
|
127
|
+
- **MongoDB Community support**: Automated embedding available in Community edition, not just Atlas.
|
|
128
|
+
|
|
129
|
+
**Customer validation** (mongodb.com):
|
|
130
|
+
- Factory: "MongoDB's ability to handle rapid scaling without breaking under user load"
|
|
131
|
+
- Tavily: "MongoDB lets lean startups focus on business rather than infrastructure"
|
|
132
|
+
- Scalestack: "Atlas Vector Search for contextually relevant AI responses"
|
|
133
|
+
- Modelence: "MongoDB's flexible document model for AI-assisted development with intelligent coding agents"
|
|
134
|
+
- Emergent Labs: Agents build applications from natural language prompts, backed by MongoDB
|
|
135
|
+
|
|
136
|
+
### The Technical Case: MongoDB vs. Alternatives
|
|
137
|
+
|
|
138
|
+
| Capability | MongoDB | PostgreSQL (pgvector) | Redis | Pinecone | SQLite |
|
|
139
|
+
|---|---|---|---|---|---|
|
|
140
|
+
| **Document model** | Native (BSON) | JSON columns (bolted on) | Key-value only | None | None |
|
|
141
|
+
| **Vector search** | Atlas Vector Search (native) | pgvector extension | Redis VSS module | Native (vector-only) | None |
|
|
142
|
+
| **Full-text search** | Atlas Search (Lucene-based) | Built-in (basic) | RediSearch | None | FTS5 (basic) |
|
|
143
|
+
| **Hybrid search** | Single aggregation pipeline | Requires multiple queries + app-side fusion | Limited | API-side only | Manual |
|
|
144
|
+
| **Graph traversal** | $graphLookup (native) | Recursive CTEs (verbose) | None | None | None |
|
|
145
|
+
| **Transactions** | Multi-document ACID | Full ACID | Limited (Lua scripts) | None | WAL-mode |
|
|
146
|
+
| **Change Streams** | Native real-time | LISTEN/NOTIFY (limited) | Pub/Sub (volatile) | None | None |
|
|
147
|
+
| **Schema flexibility** | Core design | Requires migrations | N/A | N/A | Requires migrations |
|
|
148
|
+
| **Horizontal scaling** | Sharding (native) | Citus (extension) | Cluster | Managed | None |
|
|
149
|
+
| **Embedded embeddings** | Voyage AI (native, automated) | External service required | External service required | Built-in but vector-only | External service required |
|
|
150
|
+
| **TTL indexes** | Native | Requires cron/extension | Native (EXPIRE) | Metadata TTL | Manual |
|
|
151
|
+
| **Replication/HA** | Replica sets (native) | Streaming replication | Sentinel/Cluster | Managed | None |
|
|
152
|
+
|
|
153
|
+
### The "Single Database" Argument
|
|
154
|
+
|
|
155
|
+
MongoDB Atlas Vector Search documentation (successfully fetched) makes the strongest technical argument:
|
|
156
|
+
|
|
157
|
+
> "No synchronization tax: Vector data lives alongside operational data in a single database. Eliminates the complexity of syncing between operational and vector databases."
|
|
158
|
+
|
|
159
|
+
This is critical for Company OS because:
|
|
160
|
+
|
|
161
|
+
1. **Knowledge base and memory in one place.** When an agent searches for "what do we know about ACME Corp?", the query hits conversation memory, structured facts, extracted entities, AND knowledge base documents in a single aggregation pipeline. No ETL, no sync lag, no consistency gaps.
|
|
162
|
+
|
|
163
|
+
2. **Atomic writes across types.** When an agent extracts an entity from a conversation, it writes the event, the entity, and the relation in a single transaction. No distributed transaction across separate databases.
|
|
164
|
+
|
|
165
|
+
3. **One security model.** RBAC, field-level encryption, audit logging -- all in one place. Not scattered across three databases with three different auth models.
|
|
166
|
+
|
|
167
|
+
4. **One operational surface.** Backup, monitoring, scaling, disaster recovery -- managed once, not three times.
|
|
168
|
+
|
|
169
|
+
---
|
|
170
|
+
|
|
171
|
+
## 4. Multi-Agent Memory Requirements
|
|
172
|
+
|
|
173
|
+
### The Architecture Challenge
|
|
174
|
+
|
|
175
|
+
When a company runs multiple agents (sales, support, engineering, HR, finance), they face fundamental data architecture questions:
|
|
176
|
+
|
|
177
|
+
**What must be shared?**
|
|
178
|
+
- Company knowledge base (product docs, SOPs, policies)
|
|
179
|
+
- Customer records and interaction history
|
|
180
|
+
- Cross-department context ("this customer spoke to support about X, now they're talking to sales about Y")
|
|
181
|
+
|
|
182
|
+
**What must be isolated?**
|
|
183
|
+
- Per-agent working memory (current conversation state)
|
|
184
|
+
- Department-specific confidential data (HR records, financial data)
|
|
185
|
+
- Agent-specific learned behaviors and procedures
|
|
186
|
+
|
|
187
|
+
**What requires controlled access?**
|
|
188
|
+
- Customer PII (accessible to support, not to marketing analytics agent)
|
|
189
|
+
- Financial data (accessible to finance agent, read-only for executive agent)
|
|
190
|
+
- Draft content (accessible to creator, not to other agents until published)
|
|
191
|
+
|
|
192
|
+
### The Memory Type Taxonomy
|
|
193
|
+
|
|
194
|
+
From CrewAI's documentation (successfully fetched) and Lilian Weng's survey:
|
|
195
|
+
|
|
196
|
+
**CrewAI's unified memory model** uses a single Memory class with intelligent scope inference. Memories are organized into hierarchical scopes (like filesystem paths: `/project/alpha`, `/agent/researcher`). Retrieval uses composite scoring blending:
|
|
197
|
+
- Semantic similarity (vector distance)
|
|
198
|
+
- Recency decay (exponential, configurable half-life)
|
|
199
|
+
- Importance scores (assigned during encoding)
|
|
200
|
+
|
|
201
|
+
**Lilian Weng's agent memory taxonomy** maps to human memory:
|
|
202
|
+
- **Sensory memory**: Raw input embeddings
|
|
203
|
+
- **Short-term memory**: In-context (limited by context window)
|
|
204
|
+
- **Long-term memory**: External vector stores with fast retrieval
|
|
205
|
+
|
|
206
|
+
She identifies the fundamental tension: "while vector stores and retrieval mechanisms expand the knowledge pool beyond context limitations, their representation power is not as powerful as full attention."
|
|
207
|
+
|
|
208
|
+
**ClawMongo's v2 architecture** (from the codebase) provides the most complete model:
|
|
209
|
+
- **Events**: Primary write target, every interaction is an event (immutable audit trail)
|
|
210
|
+
- **Chunks**: Derived from events, the unit of vector search
|
|
211
|
+
- **Entities**: Extracted people, organizations, concepts, systems
|
|
212
|
+
- **Relations**: Connections between entities ($graphLookup traversal)
|
|
213
|
+
- **Episodes**: Materialized summaries of related event sequences
|
|
214
|
+
- **Structured facts**: Explicit key-value knowledge with scope and TTL
|
|
215
|
+
|
|
216
|
+
### MongoDB's Fit for Multi-Agent Memory
|
|
217
|
+
|
|
218
|
+
MongoDB's document model maps naturally to this:
|
|
219
|
+
|
|
220
|
+
```
|
|
221
|
+
agents/ # per-agent config and state
|
|
222
|
+
{agentId}/
|
|
223
|
+
events/ # all interactions (immutable append)
|
|
224
|
+
entities/ # extracted entities
|
|
225
|
+
episodes/ # materialized summaries
|
|
226
|
+
|
|
227
|
+
shared/ # company-wide knowledge
|
|
228
|
+
knowledge_base/ # documents, SOPs, product info
|
|
229
|
+
entities/ # company-wide entity graph
|
|
230
|
+
relations/ # cross-agent relationships
|
|
231
|
+
|
|
232
|
+
scoped/ # department-level access
|
|
233
|
+
hr/ # HR-only data
|
|
234
|
+
finance/ # finance-only data
|
|
235
|
+
```
|
|
236
|
+
|
|
237
|
+
This maps to MongoDB collections with field-level RBAC, TTL indexes for lifecycle management, and $graphLookup for cross-collection entity traversal.
|
|
238
|
+
|
|
239
|
+
---
|
|
240
|
+
|
|
241
|
+
## 5. The KB + Memory Convergence
|
|
242
|
+
|
|
243
|
+
### Why Keeping Them Separate Breaks Things
|
|
244
|
+
|
|
245
|
+
The traditional architecture separates:
|
|
246
|
+
- **Knowledge Base** (Pinecone/Weaviate for documents) from
|
|
247
|
+
- **Conversation Memory** (Redis/PostgreSQL for chat history) from
|
|
248
|
+
- **Entity Store** (Neo4j for relationships)
|
|
249
|
+
|
|
250
|
+
This creates three critical problems:
|
|
251
|
+
|
|
252
|
+
**Problem 1: Stale cross-references.** When an agent learns a new fact in conversation ("ACME Corp changed their CEO"), the knowledge base doesn't know. The next agent to query the KB gets outdated information. With MongoDB, the conversation event and the entity update happen in the same transaction.
|
|
253
|
+
|
|
254
|
+
**Problem 2: Context fragmentation.** An agent searching for "what do we know about ACME Corp?" must query three databases, merge results, and handle conflicts. With MongoDB, a single aggregation pipeline combines vector search across memory chunks, full-text search across KB documents, and $graphLookup across the entity graph.
|
|
255
|
+
|
|
256
|
+
**Problem 3: Consistency gaps.** Syncing between databases introduces lag. During the sync window, different agents see different states. A sales agent might not see the support ticket that just came in. With MongoDB's single-database model, all agents read from the same state.
|
|
257
|
+
|
|
258
|
+
### The Power of Convergence
|
|
259
|
+
|
|
260
|
+
When KB and memory live in the same database:
|
|
261
|
+
|
|
262
|
+
1. **Agents can cite their sources.** A vector search that returns both a KB document and a conversation excerpt can show the agent exactly where it learned something.
|
|
263
|
+
|
|
264
|
+
2. **Knowledge evolves from conversations.** Entity extraction from conversations automatically enriches the KB. No ETL pipeline, no batch sync.
|
|
265
|
+
|
|
266
|
+
3. **Retrieval planning becomes coherent.** The retrieval planner (like ClawMongo's `mongodb-retrieval-planner.ts`) can decide in one step whether to search chunks, episodes, entities, KB docs, or all of the above -- because they're all queryable through the same interface.
|
|
267
|
+
|
|
268
|
+
4. **Hybrid search is natural.** Combining semantic similarity (vector), keyword matching (full-text), entity lookup (graph), and metadata filtering (structured) in a single MongoDB aggregation pipeline. No cross-database orchestration.
|
|
269
|
+
|
|
270
|
+
---
|
|
271
|
+
|
|
272
|
+
## 6. Enterprise Readiness Checklist
|
|
273
|
+
|
|
274
|
+
### What Enterprises Require That Hobby Projects Don't
|
|
275
|
+
|
|
276
|
+
From OpenAI's governance paper (fetched), LangSmith's observability docs (fetched), and MongoDB's enterprise positioning:
|
|
277
|
+
|
|
278
|
+
| Requirement | Why It Matters | How MongoDB Delivers |
|
|
279
|
+
|---|---|---|
|
|
280
|
+
| **Audit trail** | Every agent action must be traceable for compliance (SOX, HIPAA, GDPR) | Event sourcing pattern + Change Streams + oplog |
|
|
281
|
+
| **RBAC** | Different departments need different data access | Native RBAC with field-level redaction |
|
|
282
|
+
| **Encryption** | Data at rest and in transit must be encrypted | TLS, encryption at rest, Client-Side Field Level Encryption (CSFLE) |
|
|
283
|
+
| **Backup/PITR** | Must be able to restore to any point in time | Atlas continuous backup with point-in-time recovery |
|
|
284
|
+
| **Scalability** | 10 agents today, 1000 tomorrow | Sharding with zone-based partitioning |
|
|
285
|
+
| **High availability** | Agents are production infrastructure, not toys | Replica sets with automatic failover |
|
|
286
|
+
| **Observability** | Must see what agents are doing and why | Change Streams, query profiling, Atlas monitoring |
|
|
287
|
+
| **Data residency** | Enterprise data may not leave certain regions | Atlas multi-region, zone-based sharding |
|
|
288
|
+
| **Multi-tenancy** | Multiple teams/departments with isolated data | Database-level or collection-level isolation with RBAC |
|
|
289
|
+
| **Rate limiting** | Agents must not overwhelm downstream systems | Connection pooling, operation profiling |
|
|
290
|
+
| **Compliance certification** | SOC 2, HIPAA, PCI DSS, FedRAMP | MongoDB Atlas has all major certifications |
|
|
291
|
+
|
|
292
|
+
### OpenAI's Governance Framework
|
|
293
|
+
|
|
294
|
+
OpenAI's practices paper (fetched) identifies the need for "an initial set of practices for keeping agents' operations safe and accountable." They emphasize "the importance of agreeing on a set of baseline responsibilities and safety best practices" and warn that "categories of indirect impacts from the wide-scale adoption of agentic AI systems" will require "additional governance frameworks."
|
|
295
|
+
|
|
296
|
+
### LangSmith's Observability Model
|
|
297
|
+
|
|
298
|
+
LangSmith (fetched) provides a reference architecture for agent observability:
|
|
299
|
+
- **Runs and Traces**: Every agent action is a "run" (like an OpenTelemetry span). Related runs form "traces."
|
|
300
|
+
- **Projects and Threads**: Traces are organized by application (project) and conversation (thread via session_id).
|
|
301
|
+
- **Feedback loops**: Inline feedback, manual annotations, and automated evaluators.
|
|
302
|
+
- **400-day retention**: With export for longer-term compliance.
|
|
303
|
+
|
|
304
|
+
This maps directly to MongoDB's event-sourcing model where every event is a traceable, queryable document with full metadata.
|
|
305
|
+
|
|
306
|
+
---
|
|
307
|
+
|
|
308
|
+
## 7. MongoDB Atlas Search + Vector Search for Agents
|
|
309
|
+
|
|
310
|
+
### MongoDB's AI Strategy
|
|
311
|
+
|
|
312
|
+
From the January 2026 announcements (fetched from newsroom):
|
|
313
|
+
|
|
314
|
+
1. **Voyage AI acquisition**: MongoDB now owns the embedding model layer. Agents don't need external embedding services.
|
|
315
|
+
|
|
316
|
+
2. **Automated Embedding**: When data is inserted or updated, MongoDB automatically generates and stores embeddings. This eliminates the "embedding pipeline" problem that plagues every other database.
|
|
317
|
+
|
|
318
|
+
3. **Voyage 4 model family**:
|
|
319
|
+
- `voyage-4`: General purpose (balanced accuracy/cost/latency)
|
|
320
|
+
- `voyage-4-large`: Highest retrieval accuracy
|
|
321
|
+
- `voyage-4-lite`: Optimized for latency and cost
|
|
322
|
+
- `voyage-4-nano`: Open-weights for local development and on-device
|
|
323
|
+
|
|
324
|
+
4. **Multimodal embeddings**: `voyage-multimodal-3.5` handles interleaved text, images, and video. Agents can search across all content types.
|
|
325
|
+
|
|
326
|
+
5. **Community edition support**: Automated embedding is available in MongoDB Community, not just Atlas. This means self-hosted agent systems get the same capability.
|
|
327
|
+
|
|
328
|
+
### MongoDB's Blog Activity on Agentic AI (March 2026)
|
|
329
|
+
|
|
330
|
+
From the blog index (fetched):
|
|
331
|
+
- **"The Modern End-to-End Digital Lending Journey Powered by MongoDB and Agentic AI"** (March 18, 2026) -- agentic AI for financial workflows
|
|
332
|
+
- **"How MongoDB Atlas Powers Agentic AI for Semiconductor Yield Optimization"** (March 5, 2026) -- agentic AI for manufacturing
|
|
333
|
+
- **Multiple startup stories** using MongoDB for AI-native workflows (Modelence, Emergent Labs, Heidi, Thesys)
|
|
334
|
+
|
|
335
|
+
MongoDB is actively publishing case studies showing real agentic AI systems in production, backed by MongoDB.
|
|
336
|
+
|
|
337
|
+
### Competitive Moat
|
|
338
|
+
|
|
339
|
+
The Voyage AI acquisition creates a unique position: MongoDB is the **only general-purpose database that includes its own embedding models**. This means:
|
|
340
|
+
|
|
341
|
+
- **No external API calls** for embedding generation (lower latency, lower cost, no data leaving the cluster)
|
|
342
|
+
- **Automatic re-embedding** when data changes (no stale embeddings)
|
|
343
|
+
- **Unified billing and operations** (one vendor, one SLA, one support channel)
|
|
344
|
+
- **Consistency guarantee**: The embedding model and the vector index are always in sync
|
|
345
|
+
|
|
346
|
+
No other database offers this. PostgreSQL/pgvector requires external embedding APIs. Pinecone requires external embedding APIs. Redis requires external embedding APIs.
|
|
347
|
+
|
|
348
|
+
---
|
|
349
|
+
|
|
350
|
+
## Key Findings Summary
|
|
351
|
+
|
|
352
|
+
1. **"Company OS" is the framing for multi-agent enterprise systems.** Companies need multiple specialized AI agents operating as a coordinated system, not a single chatbot. This requires an operating-system-like data layer with process management, memory, I/O, and security.
|
|
353
|
+
|
|
354
|
+
2. **The data layer is the hardest part.** Anthropic, LangChain, and CrewAI all identify infrastructure (not models) as the primary challenge for agentic systems. Durable execution, observability, and memory persistence are harder problems than prompt engineering.
|
|
355
|
+
|
|
356
|
+
3. **MongoDB is uniquely positioned for the agentic data layer.** No other database combines document model + vector search + full-text search + graph traversal + transactions + Change Streams + embedded embedding models in a single system. The Voyage AI acquisition closes the last gap.
|
|
357
|
+
|
|
358
|
+
4. **KB + Memory convergence is a MongoDB-native advantage.** Keeping knowledge base and conversation memory in the same database eliminates sync lag, consistency gaps, and operational complexity. This is the strongest technical argument for MongoDB over a multi-database architecture.
|
|
359
|
+
|
|
360
|
+
5. **Enterprise requirements favor MongoDB.** Audit trails (event sourcing), RBAC (native), encryption (CSFLE), compliance certifications (SOC 2, HIPAA, FedRAMP), horizontal scaling (sharding), and HA (replica sets) are all built in. Hobby-grade agent systems using SQLite or Redis cannot offer this.
|
|
361
|
+
|
|
362
|
+
6. **ClawMongo's architecture is ahead of the market.** With 16 collections, event sourcing, chunk projection, entity graphs, episode materialization, hybrid search, and a retrieval planner -- ClawMongo already implements the patterns that the industry is converging on. The research validates the architectural decisions made in v2.
|
|
363
|
+
|
|
364
|
+
7. **Automated embedding is a game-changer.** MongoDB's January 2026 announcement of automatic embedding generation eliminates the most common complaint about vector databases: the embedding pipeline. ClawMongo should adopt this when available to simplify the ingestion path.
|
|
365
|
+
|
|
366
|
+
## What Changed the Recommendation
|
|
367
|
+
|
|
368
|
+
**MongoDB's Voyage AI acquisition and automated embedding (January 2026) is the single highest-signal finding.** This transforms MongoDB from "a good database that also does vector search" to "the only database that handles the entire embedding-to-retrieval pipeline natively." For Company OS positioning, this means ClawMongo can truthfully claim: "zero external dependencies for the complete agent memory stack -- events, embeddings, vector search, full-text search, graph traversal, and knowledge base, all in one database, with one operational surface."
|
|
369
|
+
|
|
370
|
+
## Gotchas / Warnings
|
|
371
|
+
|
|
372
|
+
- **Automated Embedding is in public preview** (as of January 2026). Production readiness should be verified before adopting.
|
|
373
|
+
- **Voyage 4 models are MongoDB-specific.** This is an advantage for the MongoDB ecosystem but creates vendor lock-in for the embedding layer. ClawMongo should maintain the ability to use external embedding providers as a fallback.
|
|
374
|
+
- **$graphLookup has depth limits.** For very large entity graphs, deep traversal can be expensive. ClawMongo's current bounded-depth approach is correct.
|
|
375
|
+
- **Atlas Vector Search requires dedicated Search Nodes for production.** The unified platform argument is real, but there is still a separate scaling dimension for search workload. This is not as simple as "just MongoDB" -- Search Nodes are a distinct operational concern.
|
|
376
|
+
- **MongoDB Community edition** gets automated embedding but NOT Atlas Search/Vector Search. Self-hosted deployments need mongot (the search sidecar). ClawMongo's use of Community + mongot is the correct architecture for self-hosted scenarios.
|
|
377
|
+
- **The "Company OS" narrative is early.** Most companies are still deploying single-purpose chatbots. Multi-agent coordination is a 2026-2027 frontier. ClawMongo is building for where the market is going, not where it is today.
|
|
378
|
+
- **CrewAI uses LanceDB by default** (not MongoDB) for memory. This is a competitive gap -- if CrewAI or LangGraph users want MongoDB memory, they need a MongoDB-specific integration or a product like ClawMongo.
|
|
379
|
+
|
|
380
|
+
## References
|
|
381
|
+
|
|
382
|
+
- https://www.mongodb.com/products/platform/atlas-vector-search -- Atlas Vector Search capabilities and unified platform argument
|
|
383
|
+
- https://www.mongodb.com/use-cases/artificial-intelligence -- MongoDB AI positioning ("AI isn't forcing change. It is the change.")
|
|
384
|
+
- https://www.mongodb.com/resources/basics/artificial-intelligence/ai-agents -- MongoDB's AI agents guide ("Less talk, more action")
|
|
385
|
+
- https://www.mongodb.com/company/newsroom -- January 2026 announcements (Voyage 4, Automated Embedding, startups)
|
|
386
|
+
- https://investors.mongodb.com/news-releases/news-release-details/mongodb-inc-announces-fourth-quarter-and-full-year-fiscal-2025 -- Voyage AI acquisition investor messaging
|
|
387
|
+
- https://www.mongodb.com/blog -- Agentic AI blog posts (lending, semiconductor, startups) March 2026
|
|
388
|
+
- https://www.anthropic.com/engineering/building-effective-agents -- Anthropic's agent patterns guide
|
|
389
|
+
- https://blog.langchain.com/what-is-an-agent -- LangChain's agent spectrum definition
|
|
390
|
+
- https://docs.crewai.com/concepts/memory -- CrewAI's unified memory model with composite scoring
|
|
391
|
+
- https://lilianweng.github.io/posts/2023-06-23-agent/ -- Lilian Weng's agent memory architecture survey
|
|
392
|
+
- https://docs.langchain.com/langsmith/observability-concepts -- LangSmith tracing and audit capabilities
|
|
393
|
+
- https://openai.com/index/practices-for-governing-agentic-ai-systems/ -- OpenAI's governance framework for agentic systems
|
|
394
|
+
- https://supabase.com/blog/ai-agents -- Supabase's agent database perspective (enforcement layer)
|
|
395
|
+
|
|
396
|
+
---
|
|
397
|
+
Web research complete.
|
|
@@ -0,0 +1,338 @@
|
|
|
1
|
+
# Web Research: Agent Memory Pain Points -- Real User Complaints
|
|
2
|
+
|
|
3
|
+
## Execution
|
|
4
|
+
- Preferred backend: websearch+webfetch
|
|
5
|
+
- Allowed fallbacks: webfetch-only
|
|
6
|
+
- Research round: 1
|
|
7
|
+
|
|
8
|
+
## Sources Used
|
|
9
|
+
- GitHub Issues: openclaw/openclaw (30 memory-related issues analyzed)
|
|
10
|
+
- GitHub Issues: crewAIInc/crewAI (30 memory-related issues analyzed)
|
|
11
|
+
- GitHub Issues: langchain-ai/langchain (30 memory-related issues analyzed)
|
|
12
|
+
- GitHub Issues: Significant-Gravitas/AutoGPT (3 memory-related issues analyzed)
|
|
13
|
+
- GitHub README: mem0ai/mem0 (problem statement and architecture)
|
|
14
|
+
- arXiv: Survey on Memory Mechanisms in LLM-Based Agents (2404.13501)
|
|
15
|
+
- Reddit: blocked by platform (Google search also blocked); findings derived from issue trackers and project documentation
|
|
16
|
+
|
|
17
|
+
## Research Quality
|
|
18
|
+
- Status: COMPLETE
|
|
19
|
+
- Quality level: high
|
|
20
|
+
- Backend mode: websearch+webfetch
|
|
21
|
+
- Note: Reddit direct access was blocked; compensated with deep GitHub issue mining across 4 major projects (93+ issues reviewed). GitHub issues contain higher-signal complaints than Reddit (reproducible bugs, code-level analysis, production telemetry).
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## CATEGORY 1: "Memory Management Is In Chaos" -- Config Confusion
|
|
26
|
+
|
|
27
|
+
**Source:** openclaw/openclaw#43747 (labeled: bug, regression)
|
|
28
|
+
|
|
29
|
+
The single most damning issue title: **"[Bug]: Memory management is in chaos."** A user discovered that OpenClaw has TWO memory backends (SQLite builtin + QMD markdown files) running simultaneously with NO unified configuration. Different team members had different behavior and did not know why.
|
|
30
|
+
|
|
31
|
+
Key user quotes:
|
|
32
|
+
- "Who added the QMD feature! This is of no design at all!"
|
|
33
|
+
- "I don't like the QMD. I think this should be configurable."
|
|
34
|
+
- "It's confusing. both [memory directories] exist in my ~/.openclaw folder"
|
|
35
|
+
- Config is "scattered: agents.defaults.compaction.memoryFlush, memory.qmd.*, etc."
|
|
36
|
+
|
|
37
|
+
**The real pain:** Users cannot reason about WHERE their agent's memory lives, HOW it gets there, or WHICH backend is active. There is no single `memory.type` config. Memory behavior changes silently across versions.
|
|
38
|
+
|
|
39
|
+
**Related issues:**
|
|
40
|
+
- #47023: memory.qmd.mcporter enabled but memory_search still uses raw qmd query on Linux
|
|
41
|
+
- #46687: Memory file naming inconsistency between AGENTS.md template and session-memory hook
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## CATEGORY 2: "Memory Just Disappears" -- Silent Data Loss
|
|
46
|
+
|
|
47
|
+
### 2a. No Write Tool Exists (openclaw#52033)
|
|
48
|
+
|
|
49
|
+
**Title:** "[Bug]: Tool memory_set not found"
|
|
50
|
+
|
|
51
|
+
A user asked their agent to "remember this" (Chinese text). The agent called `memory_get` on MEMORY.md **50+ times** in a loop, never finding a way to write. Root cause analysis from a commenter:
|
|
52
|
+
|
|
53
|
+
- `src/agents/tool-catalog.ts` only lists `memory_search` and `memory_get` -- there is NO `memory_set` core tool
|
|
54
|
+
- The system prompt tells agents to "use memory tools" but only read-oriented tools exist
|
|
55
|
+
- Result: the user's instruction was silently lost forever
|
|
56
|
+
|
|
57
|
+
**This is the universal failure mode:** agents appear to work (tool calls execute) but nothing is persisted.
|
|
58
|
+
|
|
59
|
+
### 2b. Plugin Tool Results Silently Dropped (openclaw#47573)
|
|
60
|
+
|
|
61
|
+
Memory plugin tools (`memory_forget`, `memory_store_batch`) execute successfully but results never reach the session layer. Agent goes silent. Only discoverable after the fact. Requires gateway restart.
|
|
62
|
+
|
|
63
|
+
### 2c. SQLite Index Goes Empty (openclaw#46599)
|
|
64
|
+
|
|
65
|
+
After long sessions, memory_search returns "database is not open." The SQLite index silently empties or corrupts, making all stored memory unsearchable.
|
|
66
|
+
|
|
67
|
+
### 2d. Memory Flush Never Actually Fires (openclaw#43006)
|
|
68
|
+
|
|
69
|
+
A contributor asked: "Are you actually seeing memory flush working correctly? I'm pretty sure I've never seen memory flush work prior to compaction. It always happens post compaction." -- meaning memory is lost DURING compaction, not saved BEFORE it.
|
|
70
|
+
|
|
71
|
+
### 2e. Search Returns Paths That Get Can't Resolve (openclaw#50313)
|
|
72
|
+
|
|
73
|
+
QMD memory_search returns normalized/slugified paths. When the agent calls memory_get with that path, it fails silently. Knowledge base gives "empty results instead of the files you found."
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
## CATEGORY 3: MEMORY.md Is a Token Bomb -- Cost and Performance
|
|
78
|
+
|
|
79
|
+
**Source:** openclaw/openclaw#26949
|
|
80
|
+
|
|
81
|
+
MEMORY.md is fully injected into the system prompt DESPITE memory_search/memory_get tools being available. Users report:
|
|
82
|
+
|
|
83
|
+
- 93.5% of token budget wasted on workspace file injection (#9157)
|
|
84
|
+
- Production user @albinati measured: switching to hierarchical lazy-loading achieved **97.5% payload reduction** (683KB cold storage, 17KB hot path)
|
|
85
|
+
- Token burn rate dropped from ~1.7M input tokens/day to ~42K
|
|
86
|
+
- "Lost in the Middle" attention degradation drops to zero with lazy loading
|
|
87
|
+
|
|
88
|
+
**The workaround users invented:** Strip MEMORY.md to a lightweight "bootloader" index, move dense context to `memory/*.md` domain files, let memory_search find them on demand.
|
|
89
|
+
|
|
90
|
+
This is the #1 FinOps pain point for production agent deployments.
|
|
91
|
+
|
|
92
|
+
---
|
|
93
|
+
|
|
94
|
+
## CATEGORY 4: No Memory Isolation Between Agents
|
|
95
|
+
|
|
96
|
+
**Source:** openclaw/openclaw#15325, #38797
|
|
97
|
+
|
|
98
|
+
All agents share a single memory pool. No `agentId` scoping. Problems:
|
|
99
|
+
|
|
100
|
+
- Agent A's memories pollute Agent B's recall
|
|
101
|
+
- Privacy leak in multi-user setups (one user's conversation surfaces in another's context)
|
|
102
|
+
- No way to have agent-specific memory retention policies
|
|
103
|
+
|
|
104
|
+
Community workarounds:
|
|
105
|
+
- @NAPTiON: file-based approach with local Llama 3.2 1B categorizer routing to per-project directories
|
|
106
|
+
- @jamebobob: built openclaw-mem0-multi-pool with user_id as pool discriminator, N:M agent-pool routing
|
|
107
|
+
- Both confirm the approach works but should be built-in
|
|
108
|
+
|
|
109
|
+
---
|
|
110
|
+
|
|
111
|
+
## CATEGORY 5: Single Memory Plugin Slot -- Can't Compose Memory Layers
|
|
112
|
+
|
|
113
|
+
**Source:** openclaw/openclaw#38874 (2 thumbs up, enhancement)
|
|
114
|
+
|
|
115
|
+
The memory system has a **single plugin slot** -- only one memory backend can be active. But in practice, different memory types serve orthogonal purposes:
|
|
116
|
+
|
|
117
|
+
- Vector memory (LanceDB, Mem0): semantic similarity, fast recall
|
|
118
|
+
- Graph memory (Cognee, Graphiti): entity relationships, multi-hop reasoning
|
|
119
|
+
- File memory (markdown): structured facts, user preferences
|
|
120
|
+
|
|
121
|
+
Users need BOTH simultaneously. Current workarounds:
|
|
122
|
+
- @prudkov: disabled Cognee plugin, runs it as standalone Docker API server, queries via custom `kind: "knowledge-graph"` plugin
|
|
123
|
+
- @m13v: layers memory systems outside the plugin model entirely, uses routing layer to decide which source to query
|
|
124
|
+
|
|
125
|
+
Proposed solution: `kind: "memory-augment"` plugin type that hooks into recall/capture lifecycle without competing for the exclusive slot.
|
|
126
|
+
|
|
127
|
+
---
|
|
128
|
+
|
|
129
|
+
## CATEGORY 6: File Watcher Is Silently Dead
|
|
130
|
+
|
|
131
|
+
**Source:** openclaw/openclaw#34400
|
|
132
|
+
|
|
133
|
+
Chokidar v4 removed glob support. The file watcher was effectively dead -- `ensureWatcher()` passes `memory/**/*.md` but chokidar v4 silently ignores it. No file changes were detected without gateway restart.
|
|
134
|
+
|
|
135
|
+
Additional bugs discovered:
|
|
136
|
+
- `DATED_MEMORY_PATH_RE` regex doesn't match dated files in subdirectories -- temporal decay broken
|
|
137
|
+
- `search()` sync is fire-and-forget -- first search after dirty returns stale results
|
|
138
|
+
- New files in subdirectories invisible until process restart even after forced reindex
|
|
139
|
+
|
|
140
|
+
Users organizing memory into logical subfolders (family/, projects/) find the entire retrieval system goes blind.
|
|
141
|
+
|
|
142
|
+
---
|
|
143
|
+
|
|
144
|
+
## CATEGORY 7: LangChain Memory -- Fundamental Architecture Problems
|
|
145
|
+
|
|
146
|
+
**Source:** langchain-ai/langchain GitHub issues (30 analyzed)
|
|
147
|
+
|
|
148
|
+
LangChain's memory system has been a persistent pain point across hundreds of issues. Key themes:
|
|
149
|
+
|
|
150
|
+
### 7a. Memory Incompatible with Retrieval Chains
|
|
151
|
+
- #2303 (high engagement): ConversationalRetrievalChain + Memory doesn't work
|
|
152
|
+
- #2256: Memory not supported with sources chain
|
|
153
|
+
- Pattern: the moment you add source attribution or retrieval, memory breaks
|
|
154
|
+
|
|
155
|
+
### 7b. Agent-Memory Configuration Hell
|
|
156
|
+
- #4000: Structured Chat Agent doesn't support ConversationMemory
|
|
157
|
+
- #891: Input variable conflicts in conversational agents with memory
|
|
158
|
+
- Pattern: adding memory to agents requires fighting the framework
|
|
159
|
+
|
|
160
|
+
### 7c. Memory Leak (Literal)
|
|
161
|
+
- Multiple issues about ResourceWarning, unclosed sockets, RAM growing unbounded
|
|
162
|
+
- Instance management problems with FastAPI services (must singleton, not re-instantiate)
|
|
163
|
+
|
|
164
|
+
### 7d. The "Deprecated" Problem
|
|
165
|
+
LangChain deprecated its memory abstractions in favor of langgraph checkpointing. This left thousands of users with broken upgrade paths and undocumented migration steps.
|
|
166
|
+
|
|
167
|
+
---
|
|
168
|
+
|
|
169
|
+
## CATEGORY 8: CrewAI Memory -- Broken By Default
|
|
170
|
+
|
|
171
|
+
**Source:** crewAIInc/crewAI GitHub issues (30 analyzed)
|
|
172
|
+
|
|
173
|
+
### 8a. Long-Term Memory Never Actually Stores Data (#1222, 2024-2025)
|
|
174
|
+
Multiple users reported: `memory=True` creates `long_term_memory.db` but the file is empty. The LLM evaluation step (`TaskEvaluator.evaluate()`) silently fails because it can't parse LLM output into structured `TaskEvaluation`. Error: "Missing attributes for long term memory: 'str' object has no attribute 'quality'."
|
|
175
|
+
|
|
176
|
+
This was reported in August 2024, confirmed by 5+ users, and auto-closed by stale-bot without a fix.
|
|
177
|
+
|
|
178
|
+
### 8b. Memory Forces OpenAI Calls Even When Running Locally (#447)
|
|
179
|
+
"Passing memory=True reaches out to Open AI, even when running locally with Ollama." Memory feature defaults to external API calls regardless of your LLM configuration.
|
|
180
|
+
|
|
181
|
+
### 8c. Storage Backend Lock-in (#967, #635)
|
|
182
|
+
Users need alternatives beyond SQLite/Chroma. Requests for MongoDB, Postgres, Valkey/Redis backends were filed and went stale.
|
|
183
|
+
|
|
184
|
+
### 8d. Memory Module Silently Fails (#1388)
|
|
185
|
+
"CrewAI 0.6 Memory module failed and was not called at all." No error, no warning, just silent absence.
|
|
186
|
+
|
|
187
|
+
### 8e. Cross-Crew Memory Sharing Impossible (#714)
|
|
188
|
+
Memory doesn't persist across different Crew instances. Each kickoff() starts fresh. Users expected same-instance memory to carry over -- it doesn't.
|
|
189
|
+
|
|
190
|
+
### 8f. Episodic Amnesia from Context Reset (#4415)
|
|
191
|
+
When context is reset between tasks (to prevent pollution), ALL learned context is wiped: "The system should ideally get smarter with each use, not reset to a base state every time."
|
|
192
|
+
|
|
193
|
+
---
|
|
194
|
+
|
|
195
|
+
## CATEGORY 9: AutoGPT Memory -- External Service Failures
|
|
196
|
+
|
|
197
|
+
**Source:** Significant-Gravitas/AutoGPT issues
|
|
198
|
+
|
|
199
|
+
- #1073: Local memory file warning -- "auto-gpt.json does not exist. Local memory would not be saved to a file." Persistence failure = session data lost between runs.
|
|
200
|
+
- #328: Pinecone connection error -- vector DB integration failure prevents ALL memory operations
|
|
201
|
+
- #38: Chunking inefficiencies -- how text is split for memory storage affects retrieval accuracy
|
|
202
|
+
|
|
203
|
+
Pattern: memory depends on external services that fail, and there is NO graceful degradation.
|
|
204
|
+
|
|
205
|
+
---
|
|
206
|
+
|
|
207
|
+
## CATEGORY 10: Enterprise Memory Requirements
|
|
208
|
+
|
|
209
|
+
Synthesized from GitHub issues, community proposals, and project documentation:
|
|
210
|
+
|
|
211
|
+
### 10a. Audit Trail
|
|
212
|
+
- openclaw#50096 proposes "Long-Term Memory & Knowledge Management" with UAML providing 3-layer recall with SQL archive as "complete safety net"
|
|
213
|
+
- CrewAI#4439 proposes "Agent Trust Stack" with provenance chains, canonical event modeling, deterministic replay
|
|
214
|
+
- Requirement: every memory operation must be traceable, replayable, and attributable
|
|
215
|
+
|
|
216
|
+
### 10b. Multi-User / Multi-Tenant Isolation
|
|
217
|
+
- openclaw#15325: per-agent memory isolation
|
|
218
|
+
- openclaw#45042: privacy filter by guild/session
|
|
219
|
+
- "Without namespace isolation, Agent A's memory retrieval could surface content from Agent B's private conversations. This isn't hypothetical -- we've seen it happen with shared vector stores."
|
|
220
|
+
|
|
221
|
+
### 10c. Compliance and Encryption
|
|
222
|
+
- UAML memory (openclaw#50096): PQC encryption (ML-KEM-768, NIST FIPS 203), "designed for regulated environments (GDPR, ISO 27001)"
|
|
223
|
+
- Requirement: memory at rest and in transit must be encrypted; data residency controls
|
|
224
|
+
|
|
225
|
+
### 10d. Memory Lifecycle / TTL
|
|
226
|
+
- openclaw#45042: "Not all memories should live forever... A ttl or decay_weight field would let retrieval naturally deprioritize stale context"
|
|
227
|
+
- Different memory types need different decay: rules/preferences persist forever, pending tasks and operational context decay after ~90 days
|
|
228
|
+
- openclaw#51385: "frequency-aware ranking, consolidation, and forgetting -- human-like memory lifecycle"
|
|
229
|
+
|
|
230
|
+
### 10e. Scalability
|
|
231
|
+
- Mem0 benchmarks: 91% faster responses, 90% lower token usage vs full-context
|
|
232
|
+
- Production user measured 97.5% token reduction with hierarchical lazy-loading
|
|
233
|
+
- Without proper memory architecture, costs scale linearly with memory size
|
|
234
|
+
|
|
235
|
+
### 10f. Disaster Recovery
|
|
236
|
+
- Multiple references to KeepMyClaw (backup service) across OpenClaw issues -- indicating real demand for memory state recovery
|
|
237
|
+
- Sessions corrupt, reset, lose state from provider errors, gateway crashes, session manager bugs
|
|
238
|
+
- "When the session layer drops results silently, external backups preserve the full context"
|
|
239
|
+
|
|
240
|
+
---
|
|
241
|
+
|
|
242
|
+
## WHAT CHANGED THE RECOMMENDATION
|
|
243
|
+
|
|
244
|
+
**The single highest-signal finding:**
|
|
245
|
+
|
|
246
|
+
The OpenClaw ecosystem has spawned **at least 8 third-party memory solutions** (UAML, KeepMyClaw, mem9, Synapse, SuperBrain, NAPTiON pipeline, user-memories, openclaw-mem0-multi-pool) in the span of weeks -- all trying to fix the same fundamental problem: **the default memory system is file-based, single-slot, lacks write primitives, has no isolation, silently loses data, and wastes tokens.**
|
|
247
|
+
|
|
248
|
+
This is not a "nice to have" feature gap. This is a market signal that the memory layer is broken enough to spawn an entire ecosystem of workarounds.
|
|
249
|
+
|
|
250
|
+
ClawMongo's v2 architecture (event-first, MongoDB-native, multi-path retrieval, graph traversal, episode materialization) directly addresses every single pain point documented above:
|
|
251
|
+
|
|
252
|
+
| Pain Point | ClawMongo v2 Answer |
|
|
253
|
+
|---|---|
|
|
254
|
+
| Config chaos (2 backends, scattered config) | Single MongoDB backend, unified config |
|
|
255
|
+
| Silent data loss / no write tool | Events as primary write target, canonical truth |
|
|
256
|
+
| Token bomb (full injection) | Retrieval planner selects relevant paths only |
|
|
257
|
+
| No agent isolation | Scope field on events, entities, episodes |
|
|
258
|
+
| Single memory slot | 6 retrieval paths (chunks, events, entities, relations, episodes, structured) |
|
|
259
|
+
| File watcher dead | MongoDB Change Streams (no file watching) |
|
|
260
|
+
| No audit trail | Immutable event log, ingest/projection runs |
|
|
261
|
+
| No TTL/lifecycle | expiresAt + TTL indexes (planned from AWM research) |
|
|
262
|
+
| Cross-session amnesia | Persistent MongoDB storage, episode materialization |
|
|
263
|
+
| Scalability | Atlas-native vector search, horizontal scaling |
|
|
264
|
+
|
|
265
|
+
---
|
|
266
|
+
|
|
267
|
+
## GOTCHAS / WARNINGS
|
|
268
|
+
|
|
269
|
+
1. **The "memory_set not found" pattern is universal** -- agents that can READ memory but not WRITE it will loop indefinitely. Any memory system MUST have explicit write primitives exposed as agent tools.
|
|
270
|
+
|
|
271
|
+
2. **Silent failures are worse than crashes** -- across ALL frameworks, the most damaging bugs are silent ones: empty databases, dropped tool results, dead file watchers. Users only discover data loss after the fact.
|
|
272
|
+
|
|
273
|
+
3. **Memory configuration sprawl kills adoption** -- OpenClaw's scattered config (memoryFlush, qmd.*, backend, plugin entries) is a cautionary tale. ClawMongo must have ONE clear config surface.
|
|
274
|
+
|
|
275
|
+
4. **Plugin/extension architecture matters** -- single-slot memory blocks composition. ClawMongo's multi-collection approach inherently supports parallel memory types but this must be exposed through clear APIs.
|
|
276
|
+
|
|
277
|
+
5. **Production cost is the adoption gate** -- the 97.5% token reduction from lazy-loading shows that naive memory injection makes production deployment economically unviable. Retrieval planning is not optional.
|
|
278
|
+
|
|
279
|
+
6. **Cross-agent memory sharing is a top-3 request** -- CrewAI, OpenClaw, and AutoGPT all have issues requesting it. Memory isolation + controlled sharing must be first-class.
|
|
280
|
+
|
|
281
|
+
7. **LangChain's deprecation of memory abstractions** left users stranded -- any memory API surface must be stable and migration-safe.
|
|
282
|
+
|
|
283
|
+
## REFERENCES
|
|
284
|
+
|
|
285
|
+
### OpenClaw Issues (Primary Source)
|
|
286
|
+
- https://github.com/openclaw/openclaw/issues/52033 -- memory_set not found (no write tool)
|
|
287
|
+
- https://github.com/openclaw/openclaw/issues/43747 -- "Memory management is in chaos"
|
|
288
|
+
- https://github.com/openclaw/openclaw/issues/26949 -- MEMORY.md token bomb
|
|
289
|
+
- https://github.com/openclaw/openclaw/issues/38874 -- single memory plugin slot
|
|
290
|
+
- https://github.com/openclaw/openclaw/issues/15325 -- per-agent memory isolation
|
|
291
|
+
- https://github.com/openclaw/openclaw/issues/34400 -- recursive subdirectory search broken
|
|
292
|
+
- https://github.com/openclaw/openclaw/issues/50313 -- search/get path mismatch
|
|
293
|
+
- https://github.com/openclaw/openclaw/issues/47573 -- plugin tool results silently dropped
|
|
294
|
+
- https://github.com/openclaw/openclaw/issues/46599 -- SQLite index empty after long session
|
|
295
|
+
- https://github.com/openclaw/openclaw/issues/43006 -- memory flush doesn't fire before compaction
|
|
296
|
+
- https://github.com/openclaw/openclaw/issues/50096 -- Long-term memory & knowledge management
|
|
297
|
+
- https://github.com/openclaw/openclaw/issues/45042 -- active memory retrieval + context compaction
|
|
298
|
+
- https://github.com/openclaw/openclaw/issues/51385 -- frequency-aware ranking and forgetting
|
|
299
|
+
- https://github.com/openclaw/openclaw/issues/48558 -- Anthropic Memory Tool support
|
|
300
|
+
- https://github.com/openclaw/openclaw/issues/43408 -- case-insensitive MEMORY.md duplication
|
|
301
|
+
- https://github.com/openclaw/openclaw/issues/49495 -- plugin config rejected by gateway validator
|
|
302
|
+
- https://github.com/openclaw/openclaw/issues/51676 -- memory_search fails to load (bad npm publish)
|
|
303
|
+
- https://github.com/openclaw/openclaw/issues/27863 -- memory_write for orchestrator sessions
|
|
304
|
+
- https://github.com/openclaw/openclaw/issues/9157 -- 93.5% token budget wasted
|
|
305
|
+
- https://github.com/openclaw/openclaw/issues/46570 -- memory search only returns sessions, not memory files
|
|
306
|
+
|
|
307
|
+
### CrewAI Issues
|
|
308
|
+
- https://github.com/crewAIInc/crewAI/issues/1222 -- long-term memory not storing data
|
|
309
|
+
- https://github.com/crewAIInc/crewAI/issues/447 -- memory=True calls OpenAI even with Ollama
|
|
310
|
+
- https://github.com/crewAIInc/crewAI/issues/967 -- alternative database storage
|
|
311
|
+
- https://github.com/crewAIInc/crewAI/issues/1388 -- memory module silently failed
|
|
312
|
+
- https://github.com/crewAIInc/crewAI/issues/714 -- sharing memory between crew instances
|
|
313
|
+
- https://github.com/crewAIInc/crewAI/issues/4415 -- episodic amnesia from context reset
|
|
314
|
+
- https://github.com/crewAIInc/crewAI/issues/4509 -- Pydantic validation error saving memory
|
|
315
|
+
- https://github.com/crewAIInc/crewAI/issues/4703 -- telemetry fails with custom memory backends
|
|
316
|
+
- https://github.com/crewAIInc/crewAI/issues/4682 -- agent loop detection (memory-related)
|
|
317
|
+
- https://github.com/crewAIInc/crewAI/issues/4030 -- external memory with Mem0/Valkey fails
|
|
318
|
+
- https://github.com/crewAIInc/crewAI/issues/4222 -- memory leak in execution_spans
|
|
319
|
+
- https://github.com/crewAIInc/crewAI/issues/4210 -- memory leak from @lru_cache on instance methods
|
|
320
|
+
- https://github.com/crewAIInc/crewAI/issues/4423 -- Mem0Storage crashes with JSON string config
|
|
321
|
+
|
|
322
|
+
### LangChain Issues
|
|
323
|
+
- https://github.com/langchain-ai/langchain/issues/2303 -- ConversationalRetrievalChain + Memory
|
|
324
|
+
- https://github.com/langchain-ai/langchain/issues/2256 -- Memory not supported with sources chain
|
|
325
|
+
- https://github.com/langchain-ai/langchain/issues/4000 -- Structured Chat Agent + ConversationMemory
|
|
326
|
+
- https://github.com/langchain-ai/langchain/issues/891 -- input variable conflicts with memory
|
|
327
|
+
|
|
328
|
+
### AutoGPT Issues
|
|
329
|
+
- https://github.com/Significant-Gravitas/AutoGPT/issues/1073 -- local memory file not saved
|
|
330
|
+
- https://github.com/Significant-Gravitas/AutoGPT/issues/328 -- Pinecone connection failure
|
|
331
|
+
- https://github.com/Significant-Gravitas/AutoGPT/issues/38 -- chunking problems
|
|
332
|
+
|
|
333
|
+
### Other Sources
|
|
334
|
+
- https://github.com/mem0ai/mem0 -- Mem0 architecture and problem statement
|
|
335
|
+
- arXiv 2404.13501 -- Survey: Memory Mechanisms in LLM-Based Agents
|
|
336
|
+
|
|
337
|
+
---
|
|
338
|
+
Web research complete.
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@romiluz/clawmongo",
|
|
3
|
-
"version": "2026.3.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "2026.3.24",
|
|
4
|
+
"description": "OpenClaw, but it remembers. Full AI assistant (22 channels, 78 extensions, voice, apps) with MongoDB memory - vector search, knowledge graph, event-sourcing, KB, and 8 retrieval paths. Nothing is ever lost.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"mongodb",
|
|
7
7
|
"ai-assistant",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"url": "https://github.com/romiluz13/ClawMongo/issues"
|
|
30
30
|
},
|
|
31
31
|
"license": "MIT",
|
|
32
|
-
"author": "Rom Iluz <rom@
|
|
32
|
+
"author": "Rom Iluz <rom@iluz.net>",
|
|
33
33
|
"repository": {
|
|
34
34
|
"type": "git",
|
|
35
35
|
"url": "git+https://github.com/romiluz13/ClawMongo.git"
|