Skip to content
← Tools / Skills
ToolLangChain/10 trustVerified

LangMem

Long-term memory layer for LangGraph agents

Visit official site →

About

LangMem is a Python library that gives LLM agents long-term memory. It extracts facts from conversations, stores them, and retrieves them later, splitting memory into semantic (facts), episodic (past events), and procedural (learned instructions) types. Agents can manage memory in the hot path with dedicated tools, or a background memory manager can extract and consolidate knowledge after activity settles.

It is an extraction and consolidation layer rather than a database: it works with any LangGraph store, from InMemoryStore for development to Postgres-backed stores for production, and integrates natively with LangGraph Platform deployments. The docs also show it working with CrewAI agents, so it is not locked to a single framework.

What it can do

  • Memory extraction and consolidation from conversations
  • Semantic, episodic, and procedural memory types
  • Hot-path memory tools agents call during conversations
  • Background memory manager for deferred extraction
  • Namespace-scoped memories (e.g. per user)
  • Native LangGraph long-term memory store integration

Setup

  1. Install the package with pip install -U langmem
  2. Export an API key for your LLM provider (e.g. ANTHROPIC_API_KEY)
  3. Create a LangGraph store: InMemoryStore for development, AsyncPostgresStore for production
  4. Attach create_manage_memory_tool and create_search_memory_tool to your agent

Prerequisites

Python 3.9 or newer, a LangGraph store, and an API key for a supported LLM provider.

Use cases

agent-memorylong-term-memorypersonalizationlanggraph-agents

Works with

Trust score — 8/10

/10 trustVerified

Scored 8/10 (TIER verified, metrics-v1). Evidence: 1,706 GitHub stars (api.github.com, 2026-10-16); last push 2026-10-02; MIT license; maintained by LangChain. Docs at langchain-ai.github.io/langmem corroborate the memory-tool and background-manager design. Strengths: official LangChain project, active maintenance, clear docs. Docked for: (1) modest star count next to flagship frameworks; (2) extraction quality depends on the underlying LLM, which the vendor does not benchmark. License: MIT.

★ 1,706 GitHub stars

How the trust score is built

Full methodology →
Adoption · stars/downloads, log-scaled vs peers
7.0/10
Maintenance · recency, releases, issue load
8.0/10
Openness · license + docs
8.0/10
Manual review · sanity read + red-flag check
7.0/10
  • · 1,706 GitHub stars via api.github.com/repos/langchain-ai/langmem (2026-10-16)
  • · Last push 2026-10-02T19:35:27Z - actively maintained
  • · Official LangChain project with docs at langchain-ai.github.io/langmem
  • · README documents CrewAI usage alongside LangGraph

Sources

Every fact above was checked against these sources. Where a claim comes from the provider and couldn't be independently verified, the text says so.