This is an early release preview. You may encounter bugs.
LangMem logo
Unclaimed

Tool memory

LangMem

Long-term memory toolkit for agents: hot-path memory tools, background consolidation, and LangGraph store integration

Built by LangChain

B 69/100 GitHub score ? This grade is derived from GitHub signals, not user votes. Open for the full breakdown.
No votes yet

01 / About

What LangMem is.

LangMem is a toolkit that helps agents learn from their interactions over time. It extracts important information from conversations, refines agent behavior through prompt optimization, and maintains long-term memory across sessions. It provides functional primitives that work with any storage system as well as native integration with LangGraph's long-term memory store, which is available by default in LangGraph Platform deployments.

Memory can be managed in two ways. In the hot path, createmanagememorytool and createsearchmemorytool give the agent tools to record and search memories during a conversation, persisted through a LangGraph BaseStore such as InMemoryStore for development or AsyncPostgresStore for production. In the background, a memory manager extracts, consolidates, and updates knowledge without blocking the conversation. Guides cover semantic memory collections, user profiles, episodic memories, dynamic namespaces, message-history summarization, and use in custom agents or CrewAI.

Features

  • Core memory API: storage-agnostic primitives for extracting and updating memories
  • Hot-path tools: manage and search memory tools the agent calls during active conversations
  • Background memory manager: automatic extraction, consolidation, and updates outside the request path
  • Memory types: semantic collections, user profiles, and episodic memories
  • Prompt optimization: refine single or multiple prompts from interaction history
  • LangGraph store integration: works with InMemoryStore, AsyncPostgresStore, and other BaseStore backends with vector indexing
  • Namespaces: dynamic namespaces scope memories per user, organization, or agent
  • Short-term memory utilities: summarize message history to manage context length

02 / Discussion CREDIBILITY-GATED

Discussion

Reading is open to everyone. Posting and voting need a verified identity or a GitHub grade of B or higher.

  • No discussions yet.

04 / Build

Build with LangMem.

Browse the catalogue for frameworks, tools, and harnesses, each scored on real GitHub credibility.

Get LangMem →

Browse the catalogue