Wiki / entities / wiki

MemGPT

Agent memory architecture (Packer et al., 2024) that treats the model like an operating system and gives it tools to manage its own memory. The context window holds read-only system instructions, a writable working context and a first-in, first-out message queue. Messages pushed out of the queue go to recall storage, searchable by exact text, and long-term facts and documents go to archival storage, a vector database.

In michael-ryan's walkthrough (Stanford CS329Z, Oct 2026), the agent writes "birthday, boyfriend James" into working context and replaces it after a breakup, searches recall storage for "Six Flags", and pages through archival search results to answer a question. The model picks its own search terms; there is no hidden entity recognition. On deep memory retrieval it lifted GPT-4 from 32.1% to 92.5% and GPT-4 Turbo from 35.3% to 93.4%, and its accuracy held steady as more documents were retrieved. Ryan notes that rewriting the context invalidates the KV cache.

Ryan compares it with MemoryOS, which has short-, medium- and long-term tiers and a background system deciding what moves up; MemGPT leaves those decisions to the model. Sleep-time compute comes from the same line of work (sleep-time-compute).

Source: report

Linked from

Michael RyanSleep-time compute