MemGPT treats an LLM’s limited context window like an operating system’s memory, using a tiered hierarchy and self-directed paging so an agent can hold and recall information across long tasks and repeated sessions.
Builder read
MemGPT (“MemGPT: Towards LLMs as Operating Systems,” Packer et al.) starts from a hard constraint: large language models “are constrained by limited context windows.” Its answer is “virtual context management, a technique drawing inspiration from hierarchical memory systems in traditional operating systems.” The system manages tiers, a fast main context (what fits in the window) versus slower external storage, and uses interrupt-driven control flow and function calls to move information between them itself, the way an operating system pages memory in and out. The agent decides what to keep resident and what to retrieve, rather than depending on a single fixed window.
Exec read
Memory is a behavioral property, not only a capability. An agent that cannot reliably hold context across a long task, or return to a prior session, will drop commitments, repeat itself, and lose the thread, all of which a user experiences as unreliable. MemGPT’s contribution is architectural: it frames memory as a managed system with an explicit hierarchy rather than as a bigger context window to buy. The paper demonstrates the approach on document analysis beyond the underlying model’s context limit and on multi-session chat, where agents “remember, reflect, and evolve dynamically through long-term interactions with their users.”
Source
Primary: MemGPT: Towards LLMs as Operating Systems (Packer, Wooders, Lin, Fang, Patil, Stoica, and Gonzalez, UC Berkeley).
Related
- LangGraph - durable, checkpointed state as a runtime feature
- Behavioral Contracts - holding context across time as a behavioral commitment
- Failure and Repair - what an agent that forgets cannot do