CONCEPTS — APR 3, 2026

Why Memory Isn't a Plugin

Why Memory Isn't a Plugin artwork

Ever since we've been working on MemGPT (now @Letta_AI), a common question @charlespacker and I have gotten is:

“How can I plug your memory system into my agent?”

To me, this question doesn't make sense. Asking to plug memory into an agent harness is like asking to plug driving into a car. Managing context, and therefore memory, is a core capability and responsibility of the agent harness. If a harness isn't managing context, what is it doing?

RAG over past session data (or a processed form of it) can certainly be a plugin—but retrieval is a small part of memory. And even then, it's hard to do much better than just grep.

Because RAG is often branded as “memory,” MemGPT has frequently been mistaken for RAG or a pluggable memory tool. But MemGPT was actually a stateful agent harness, before the term “harness” even existed. The agent's memory emerged from the tools the harness exposed for rewriting prompts and managing external state, combined with the harness's own context management.

Ultimately, the harness makes many invisible decisions that an external plugin can't control:

Different harnesses answer each of these questions differently. Your context window likely contains various context-related hints passed through system messages that you never see.

As an example, in a recent analysis of Claude Code's memory system from its leaked source code, you can see how a multi-level memory hierarchy is built directly into the harness.

Based on everything explored in the source code, here's the full technical recipe behind Claude Code's memory architecture:

[shared by claude code]

Claude Code's memory system is actually insanely well-designed. It isn't like “store everything” but constrained, structured and…

himanshu (@himanshustwts), March 31, 2026

Letta Code, a memory-first agent harness, takes this even further—projecting agent memory to a git-backed filesystem that can be concurrently modified by background memory subagents specializing in prompt rewriting and active memory management.

Letta's recently released Context Constitution outlines the common principles agents follow for context management, which is tightly coupled with harness design.

Ultimately, how the harness manages context and state in general is the foundation for agent memory.

If you want to know what using a memory-first agent harness feels like, you can check out Letta Code (works with Codex plans + BYOK!) and follow @Letta_AI.

npm install -g @letta-ai/letta-code