Memory & Conversation Chain | Chain Types | Learning Langchain Series | Tutorial on 4 Memory Types

Опубликовано: 22 Февраль 2026
на канале: Full Stack AI LAB
556
18

Github Code for this video:
https://github.com/full-stack-ai/popu...

Learn how to work with 4 types of Memories in Langchain using Conversation Chain.

Conversation chain is very useful when you build your QA Chatbot or you have a conversational Search mechanism using LLMs.

Knowledge Graph Memory is one of the most efficient methods to store lots of information in a low space memory and take advantage of LLMs interpretation to generate sentences out of the keywords from the knowledge graph.
https://aibrain.com/memory-graph/

I highly recommend do watch my other videos on other chain types from langchain:

API CHAIN |    • API Chain | Chain Types | Learning Langcha...  
CONSTITUTIONAL CHAIN |    • CONSTITUTIONAL CHAIN | Chain Types | Learn...  
RAG CHAIN |    • RETRIEVAL CHAIN - RAG | Chain Types | Lear...  
CHECKER CHAIN |    • LLM CHECKER CHAIN | Learning Langchain Ser...  
ROUTER CHAIN |    • ROUTER CHAIN | Learning Langchain Series |...  
SEQUENTIAL CHAIN |    • SEQUENTIAL CHAIN | Learning Langchain Seri...  

Follow us on:
Youtube:    / @fullstackailab  
Twitter:   / fullstackinfoai  
LinkedIn:   / fullstackaialta  
Join Discord:   / discord  

#langchain #ai #llm #python #conversation #chain #chatgpt #chatbot #openai #education #coding #artificialintelligence #machinelearning #fullstack #backend #largelanguagemodels #nlp #naturallanguageprocessing
------
Chapters:
0:00 Intro
0:12 What is Memory in Langchain?
1:02 Set up Virtual Environment
1:42 Working with ConversationBufferMemory from Langchain
3:34 What is under the hood for chat_memory and BaseChatMessageHistory
5:39 Install PyKernel for Jupyter Notebook
6:08 Return Memory's chat history
7:23 Build Conversation Chain from Langchain
7:53 Import Libraries
11:20 Construct LLM Model with OpenAI API
11:46 Construct Prompt Template
13:33 Construct Memory
14:08 Construct the Conversation Chain Object
16:28 Test the chain on ConversationBufferMemory
18:43 Test the chain on ConversationSummaryMemory
19:57 Test the chain on ConversationBufferWindowMemory
21:50 Test the chain on Conversation Knowledge Graph Memory
23:17 Recap
23:44 Thank you!