Skip to content

Commit 389750c

Browse files
committed
docs: clarify dual-memory architecture (fixes CortexReach#344)
Add two improvements addressing Issue CortexReach#344: 1. README: add Dual-Memory Architecture section explaining Plugin Memory (LanceDB) vs Markdown Memory distinction 2. index.ts: log dual-memory warning on plugin startup Refs: CortexReach#344
1 parent 7fe2ae0 commit 389750c

3 files changed

Lines changed: 34 additions & 1371 deletions

File tree

README.md

Lines changed: 25 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,10 @@
99
A LanceDB-backed OpenClaw memory plugin that stores preferences, decisions, and project context, then auto-recalls them in future sessions.
1010

1111
[![OpenClaw Plugin](https://img.shields.io/badge/OpenClaw-Plugin-blue)](https://github.com/openclaw/openclaw)
12-
[![OpenClaw 2026.3+](https://img.shields.io/badge/OpenClaw-2026.3%2B-brightgreen)](https://github.com/openclaw/openclaw)
1312
[![npm version](https://img.shields.io/npm/v/memory-lancedb-pro)](https://www.npmjs.com/package/memory-lancedb-pro)
1413
[![LanceDB](https://img.shields.io/badge/LanceDB-Vectorstore-orange)](https://lancedb.com)
1514
[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](LICENSE)
1615

17-
<h2>⚡ <a href="https://github.com/CortexReach/memory-lancedb-pro/releases/tag/v1.1.0-beta.10">v1.1.0-beta.10 — OpenClaw 2026.3+ Hook Adaptation</a></h2>
18-
19-
<p>
20-
✅ Fully adapted for OpenClaw 2026.3+ new plugin architecture<br>
21-
🔄 Uses <code>before_prompt_build</code> hooks (replacing deprecated <code>before_agent_start</code>)<br>
22-
🩺 Run <code>openclaw doctor --fix</code> after upgrading
23-
</p>
24-
2516
[English](README.md) | [简体中文](README_CN.md) | [繁體中文](README_TW.md) | [日本語](README_JA.md) | [한국어](README_KO.md) | [Français](README_FR.md) | [Español](README_ES.md) | [Deutsch](README_DE.md) | [Italiano](README_IT.md) | [Русский](README_RU.md) | [Português (Brasil)](README_PT-BR.md)
2617

2718
</div>
@@ -129,6 +120,31 @@ Add to your `openclaw.json`:
129120
- `extractMinMessages: 2` → extraction triggers in normal two-turn chats
130121
- `sessionMemory.enabled: false` → avoids polluting retrieval with session summaries on day one
131122

123+
---
124+
125+
## ⚠️ Dual-Memory Architecture (Important)
126+
127+
When `memory-lancedb-pro` is active, your system has **two independent memory layers** that do **not** auto-sync:
128+
129+
| Memory Layer | Storage | What it's for | Recallable? |
130+
|---|---|---|---|
131+
| **Plugin Memory** | LanceDB (vector store) | Semantic recall via `memory_recall` / auto-recall | ✅ Yes |
132+
| **Markdown Memory** | `MEMORY.md`, `memory/YYYY-MM-DD.md` | Startup context, human-readable journal | ❌ Not auto-recalled |
133+
134+
**Key principle:**
135+
> A fact written into `memory/YYYY-MM-DD.md` is visible in startup context, but `memory_recall` **will not find it** unless it was also written via `memory_store` (or auto-captured by the plugin).
136+
137+
**What this means for you:**
138+
- Need semantic recall? → Use `memory_store` or let auto-capture do it
139+
- `memory/YYYY-MM-DD.md` → treat as a **daily journal / log**, not a recall source
140+
- `MEMORY.md` → curated human-readable reference, not a recall source
141+
- Plugin memory → **primary recall source** for `memory_recall` and auto-recall
142+
143+
**If you want your Markdown memories to be recallable**, use the import command:
144+
```bash
145+
npx memory-lancedb-pro memory-pro import-markdown
146+
```
147+
132148
Validate & restart:
133149

134150
```bash
@@ -620,19 +636,6 @@ Sometimes the model may echo the injected `<relevant-memories>` block.
620636
621637
</details>
622638

623-
<details>
624-
<summary><strong>Auto-recall timeout tuning</strong></summary>
625-
626-
Auto-recall has a configurable timeout (default 5s) to prevent stalling agent startup. If you're behind a proxy or using a high-latency embedding API, increase it:
627-
628-
```json
629-
{ "plugins": { "entries": { "memory-lancedb-pro": { "config": { "autoRecallTimeoutMs": 8000 } } } } }
630-
```
631-
632-
If auto-recall consistently times out, check your embedding API latency first. The timeout only affects the automatic injection path — manual `memory_recall` tool calls are not affected.
633-
634-
</details>
635-
636639
<details>
637640
<summary><strong>Session Memory</strong></summary>
638641

0 commit comments

Comments
 (0)