Software Development
What is Langchain?
JD
Akash yadav yadav
Mon Aug 18 2025
Langchain is an Open-source framework that helps developers build applications powered by Large Language Models (LLM) - Like OpenAI's GPT, Gemini Ai etc.
It Provides tools to connect LLM with external data, tools and memory, making them more useful, context-aware and capable.
Example:
- Chatbots that can read and answer from your PDFs.
- AI Search engines over your private docs(RAG Systems).
- Agents that use tools like calculators, Web Search, or APIs.
- Assistants that remember past conservations.
Why use Langchain?
LLMs like ChatGPT are powerful, but limited:
Without Langchain:
- Only know what it's trained on.
- Forget previous chats.
- Can't use tools
- Limited used in apps.
With Langchain:
- Can access your files, APIs, tools.
- Has Memory.
- Can use tools like search or functions.
- Easily integrated into Full-Stack apps.
Key Components of Langchain:
Components | Purpose |
---|---|
LLMs | The core language model |
Prompt Templates | Templates to Structure input to the LLMs. |
Chains | A sequence of steps using LLMs. |
Agens | Allow the llm to decide which tool to use |
Tools | External function the agents can use |
Memory | For remembering conversation history |
Retrievers | To fetch relevant information from a database |
Vector store | Store document embeddings for similarity search |