Building production-grade conversational AI requires robust memory management. LangGraph offers two complementary persistence mechanisms: the Checkpointer, which saves the full conversation state for resuming sessions, and the Store, which provides a namespace-based key-value storage for long-term facts and user preferences across sessions. Both can be backed by PostgreSQL, a common choice for teams already using relational databases. The Checkpointer is ideal for short-term session resumption, while the Store excels at maintaining user profiles or domain knowledge that persists indefinitely. Understanding the trade-offs—such as write frequency, data granularity, and query patterns—is critical for choosing the right tool. This article provides a clear architectural comparison, helping developers avoid common pitfalls like overusing the Checkpointer for data that belongs in the Store. For teams building chatbots, virtual assistants, or agentic workflows, mastering these two layers is essential for creating seamless, context-aware user experiences.
A practical guide to LangGraph's two memory persistence systems—Checkpointer for session state and Store for long-term memory—using PostgreSQL, with clear guidance on when to use each.