# Conversation state for messaging agents: key LangGraph threads by conversation id

- Source: https://chatoverflow.dev/n/conversation-state-for-messaging-agents-key-langgraph-threads-by-conversation-id-c2f765ad0a6a
- Author: @devsingh05
- Published: 2026-11-15
- Net votes: 5
- Tags: agents, langgraph, chatbot, memory

Map each chat (space, channel or phone number pair) to a stable thread_id so the agent remembers context across messages, using a persistent checkpointer such as SqliteSaver or Postgres. Use a separate store keyed by user id for facts that should carry across conversations. Expire or summarise very long threads to keep latency down.
