LLMs Technical Reviews
Home / Agent memory layers

Agent memory layers

Libraries and services that give LLM agents long-term memory — extracting, storing, updating and recalling what matters across sessions.

Agent memory layers store what an LLM application learned in one session so it can be used in the next. They sit between your agent and one or more databases: on write, an LLM decides what is worth keeping; on read, a search picks what goes back into the prompt. The projects differ in the unit they store, from short facts about a user to a full knowledge graph built from documents. When choosing, look at the write path (how many LLM calls per message, and whether old facts are updated or only appended), what retrieval returns (ranked records or a finished answer), how isolation between users is enforced, which databases you must run, and which features exist only in a hosted version.

Projects (2)

ProjectStarsLanguageLicense
mem0ai/mem0Python and TypeScript memory layer: an LLM extracts facts from chats into a vector store, recalled by semantic, BM25 and entity scoring.★ 67kPythonApache-2.0
topoteretes/cogneePython memory engine that LLM-extracts a knowledge graph from data into graph and vector stores, then answers queries over it.★ 31kPythonApache-2.0

In the research queue: thedotmack/claude-mem, vectorize-io/hindsight, supermemoryai/supermemory, getzep/graphiti, letta-ai/letta, MemoriLabs/Memori, MemTensor/MemOS, MemMachine/MemMachine.

Comparison questions

Each question is answered separately for every project in this category, from that project's source code.

All verdicts on one page →

  1. How are memories extracted from interactions?What gets stored (facts, events, preferences); LLM extraction prompts; deduplication and conflict handling at write time.
  2. How are memories stored?Vector, graph, key-value or SQL backends; the memory schema; embeddings used; pluggable stores.
  3. How are memories retrieved and injected into the prompt?Search strategy (semantic, keyword, graph, temporal); ranking and filtering; how results reach the LLM context.
  4. How are memories updated, consolidated or forgotten?Update/merge logic; summarisation or consolidation; decay, TTL and deletion; versioning or history.
  5. How is memory scoped and isolated?User / agent / session / tenant scoping; multi-tenancy; access control; privacy controls.
  6. How do agents integrate with it, and what is self-hostable?SDKs, REST API, MCP server, framework plugins; required services; open vs hosted-only parts.