Agents don't need memory, they need documentation

244 points · 132 comments on HN · read original →

Points and comments are a snapshot, not live.

RAG-based memory plugins for AI agents should be replaced with document-based workflows.

The article argues that memory plugins for coding agents are flawed because they rely on similarity search over decontextualized snippets. These plugins surface snippets by embedding proximity, treat past transcripts as truth, and store context-free fragments. The proposed alternative is document-based memory: agents maintain a Markdown 'brain' of instructions, specs, and indexes that they read before work and update afterward. This replaces the prompt-build-forget loop with prompt-consult-build-update. The author created an open-source plugin called Operator Memory that implements this approach without vector databases or embeddings.

What commenters are saying

Commenters largely agreed with the article's critique of RAG-based memory but offered alternative implementations. One commenter described extracting semantic statements into proposition trees linked to code files. Another advocated for writing principles instead of memories, with a versioning system referenced in code comments. A practical concern was raised about token costs when reading and updating many documents. Some noted that session history already provides perfect recall within a session, questioning the need for memory across sessions when code itself serves as persistent memory.