docs(memory): add memory system deep dive guide#60048
Conversation
Create docs/concepts/memory-deep-dive.md covering: 1. Memory Architecture — two-layer model (MEMORY.md + daily logs), indexing scope, and what is searchable 2. Writing Effective Memory — what belongs in MEMORY.md vs daily logs, promotion workflow, formatting for searchability 3. Search Optimization — hybrid retrieval pipeline, query strategies, memory_search + memory_get workflow, tuning parameters 4. Memory Maintenance — heartbeat-based review, cleanup strategies, heartbeat-state.json tracking 5. Advanced Patterns — entity tracking, opinion evolution, cross-session recall via session transcripts 6. Troubleshooting — common issues with search, memory_get, file size Register the new page in docs.json Mintlify navigation under Sessions and memory > Memory group. Closes openclaw#43032
Greptile SummaryThis PR adds
Confidence Score: 4/5Safe to merge after resolving the factual contradiction between the new guide and the existing memory overview on daily log auto-injection. One P1 factual discrepancy exists between the new doc and the existing memory.md overview: the deep dive claims daily logs are never auto-injected, while memory.md says today and yesterday's notes load automatically. This needs resolution before the guide ships, otherwise users get directly conflicting mental models about how the system works. docs/concepts/memory-deep-dive.md line 47 — needs to be reconciled with docs/concepts/memory.md line 22. Prompt To Fix All With AIThis is a comment left during a code review.
Path: docs/concepts/memory-deep-dive.md
Line: 46-48
Comment:
**Contradicts existing memory overview on auto-injection**
The existing `docs/concepts/memory.md` (line 22) explicitly states: *"Today and yesterday's notes are loaded automatically."* This new guide says the opposite — that daily logs are *not* injected automatically and are only surfaced on demand. A user who reads both docs will get directly conflicting information about a fundamental behavior. One of these needs to be corrected or reconciled before shipping.
How can I resolve this? If you propose a fix, please make it concise.Reviews (1): Last reviewed commit: "docs(memory): add memory system deep div..." | Re-trigger Greptile |
| Daily logs are not injected automatically. They are indexed and surfaced on | ||
| demand through `memory_search`, and `memory_get` can read the exact file or line | ||
| range you need. |
There was a problem hiding this comment.
Contradicts existing memory overview on auto-injection
The existing docs/concepts/memory.md (line 22) explicitly states: "Today and yesterday's notes are loaded automatically." This new guide says the opposite — that daily logs are not injected automatically and are only surfaced on demand. A user who reads both docs will get directly conflicting information about a fundamental behavior. One of these needs to be corrected or reconciled before shipping.
Prompt To Fix With AI
This is a comment left during a code review.
Path: docs/concepts/memory-deep-dive.md
Line: 46-48
Comment:
**Contradicts existing memory overview on auto-injection**
The existing `docs/concepts/memory.md` (line 22) explicitly states: *"Today and yesterday's notes are loaded automatically."* This new guide says the opposite — that daily logs are *not* injected automatically and are only surfaced on demand. A user who reads both docs will get directly conflicting information about a fundamental behavior. One of these needs to be corrected or reconciled before shipping.
How can I resolve this? If you propose a fix, please make it concise.|
Codex review: needs changes before merge. Reviewed July 3, 2026, 4:59 PM ET / 20:59 UTC. Summary PR surface: Docs +402. Total +402 across 2 files. Reproducibility: not applicable. this is a documentation-only PR. The blockers are source-verifiable against current docs, runtime code, tests, and upstream Codex source rather than a failing runtime reproduction path. Review metrics: none identified. Root-cause cluster Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Risk before merge
Maintainer options:
Copy recommended automerge instructionNext step before merge
Security Review findings
Review detailsBest possible solution: Merge the guide after correcting those source-backed behavior claims, rebasing or refreshing against current main, and rerunning the narrow docs validation path. Do we have a high-confidence way to reproduce the issue? Not applicable: this is a documentation-only PR. The blockers are source-verifiable against current docs, runtime code, tests, and upstream Codex source rather than a failing runtime reproduction path. Is this the best way to solve the issue? No, not as submitted. A deep-dive guide is an appropriate docs surface, but it must first distinguish ordinary on-demand memory from startup preload behavior and native Codex tool routing from fallback injection. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 010b61746379. Label changesLabel justifications:
Evidence reviewedPR surface: Docs +402. Total +402 across 2 files. View PR surface stats
Acceptance criteria:
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
|
ClawSweeper PR egg 🔥 Warming up: real-behavior proof passed; findings, security review, or rank-up moves are still in progress. Hatch commandComment Hatchability rules:
What is this egg doing here?
|
|
Heads up: this PR needs to be updated against current |
|
This pull request has been automatically marked as stale due to inactivity. |
Summary
Add a comprehensive memory system deep dive guide, addressing #43032.
Problem
docs/concepts/memory.mdcovers basics (~600 words) but lacks depth on memory best practices, search optimization, lifecycle management, and advanced patterns.New document:
docs/concepts/memory-deep-dive.md(401 lines)Covers all 6 sections requested in the issue:
MEMORY.md+memory/YYYY-MM-DD.md), indexing scope, what is searchable vs notmemory_search→memory_getworkflow, tuning parameters (maxResults,minScore)heartbeat-state.jsontrackingsessionMemorymemory_getfile restrictions, MEMORY.md bloat, missing transcript searchNavigation
Added to
docs.jsonunder Sessions and memory → Memory group, right afterconcepts/memory.Source references
packages/memory-host-sdk/src/host/backend-config.ts— default settings (maxResults: 6, maxSnippetChars: 700)packages/memory-host-sdk/src/host/read-file.ts—memory_getfile boundary enforcementsrc/agents/memory-search.ts— search config resolution and sourcesdocs/concepts/memory-builtin.md— existing builtin engine docsCloses #43032