Conversational Memory in LangChain for 2025
Автор: James Briggs
Загружено: 2025-06-19
Просмотров: 5038
Conversational memory allows our chatbots and agents to remember previous interactions within a conversation. Without conversational memory, our chatbots would only ever be able to respond to the last message they received, essentially forgetting all previous messages with each new message.
Naturally, conversations require our chatbots to be able to respond over multiple interactions and refer to previous messages to understand the context of the conversation.
LangChain versions 0.0.x consisted of various conversational memory types. Most of these are due to deprecation, but they still hold value in understanding the different approaches to building conversational memory.
Throughout the video, we will refer to these older memory types and then rewrite them for LangChain v0.3 (the latest version in 2025) using the recommended RunnableWithMessageHistory class. We will learn about:
ConversationBufferMemory
ConversationBufferWindowMemory
ConversationSummaryMemory
ConversationSummaryBufferMemory
We'll work through each of these memory types in turn and rewrite each one using the RunnableWithMessageHistory class.
🔗 Full Course: https://www.aurelio.ai/course/langchain
📌 Article and code: https://www.aurelio.ai/learn/langchai...
💡 Subscribe for Latest Courses and Tutorials:
https://www.aurelio.ai/subscribe
👾 Discord:
/ discord
Twitter: / jamescalam
LinkedIn: / jamescalam
#ai #coding #aiagents #langchain
00:00 Conversational Memory in LangChain
01:12 LangChain Chat Memory Types
04:26 LangChain ConversationBufferMemory
08:23 Buffer Memory with LCEL
13:14 LangChain ConversationBufferWindowMemory
16:01 Buffer Window Memory with LCEL
22:32 LangChain ConversationSummaryMemory
25:17 Summary Memory with LCEL
30:12 Token Usage in LangSmith
32:08 Conversation Summary Buffer Memory
34:36 Summary Buffer with LCEL
Доступные форматы для скачивания:
Скачать видео mp4
-
Информация по загрузке: