LangChain: Framework for building LLM applications
Modular framework for chaining LLMs with external data.
Learn more about LangChain
LangChain is a Python framework for building applications that integrate large language models with external data sources and computational tools. It implements a modular architecture with standardized interfaces for models, embeddings, vector stores, and retrievers, enabling different component implementations to be substituted without modifying core application logic. The framework uses a chain-based composition pattern where operations are linked together sequentially or conditionally to create complex workflows such as retrieval-augmented generation systems and multi-step reasoning agents. Components communicate through a common data structure that preserves context and intermediate results as information flows through the processing pipeline. This abstraction layer allows developers to combine various language models, data retrieval mechanisms, and external APIs into unified applications while maintaining separation between business logic and infrastructure concerns.
Provider-Agnostic Interfaces
Standardized abstractions let you swap LLM providers, vector stores, and embeddings without rewriting application logic. Switch between OpenAI, Anthropic, or local models by changing configuration, not code.
Pre-Built Connector Ecosystem
Includes native integrations for 100+ model providers, vector databases, and external APIs. Eliminates boilerplate for common data sources and reduces time spent on integration code.
Composable Chain Architecture
Links LLM calls, tools, and data retrieval into reusable chains with typed inputs and outputs. Build complex reasoning pipelines by composing simple, testable components.
from langgraph.graph import StateGraph, MessagesState, START, END
def chatbot(state: MessagesState):
return {"messages": [{"role": "ai", "content": "Hello! How can I help?"}]}
graph = StateGraph(MessagesState)
graph.add_node("chatbot", chatbot)
graph.add_edge(START, "chatbot")
graph.add_edge("chatbot", END)
app = graph.compile()
response = app.invoke({"messages": [{"role": "user", "content": "Hi"}]})Fixes response format schema normalization and improves token counting with threading context support.
- –Fix normalize raw schemas in middleware responseformat override
- –Support state updates from wrapmodelcall with commands
- –Bump min core version and improve approximate token counting
- –Threading context through create_agent flows + middleware
Adjusts token count scaling with caps and reverts regex pattern precompilation changes.
- –Adjust cap when scaling approximate token counts
- –Revert precompile hex color regex pattern at module level
- –Apply cap when scaling approximate token counts
- –Allow scaling by reported usage when counting tokens approximately
Fixes tool strategy reuse in agent factory and adds ToolCallRequest to middleware exports.
- –Fix reuse ToolStrategy in agent factory to prevent name mismatch
- –Add ToolCallRequest to middleware exports
- –Fix blocking unit test
- –Use blockbuster to detect blocking calls in the async event loop
See how people are using LangChain
Top in AI & ML
Related Repositories
Discover similar tools and frameworks used by developers
LeRobot
PyTorch library for robot imitation learning and sim-to-real transfer.
CUTLASS
CUDA C++ templates and Python DSLs for high-performance matrix multiplication on GPUs.
Crush
LLM-powered coding agent with LSP and MCP integration.
Optuna
Define-by-run Python framework for automated hyperparameter tuning.
GFPGAN
PyTorch framework for blind face restoration using StyleGAN2 priors.
Related Reading
Guides and comparisons from the Greptile content library
10 Powerful Code Quality Tools That Catch Bugs Before Deployment
We tested 10 code quality tools that catch bugs before production. Detailed comparison with real-world examples, pricing, and ROI analysis for dev teams.
Best Code Review Tools in 2026
The best code review tools in 2026, compared on pricing, features, deployment options, and ideal use cases for teams of any size.
Greptile Ranks #1 on Martian's AI Code Review Benchmark
Greptile ranks #1 on Martian's independent online AI code review benchmark, leading all evaluated tools in F1 score and precision with near-leading recall.
Best AI Code Review Tools for GitLab
Enterprise-grade AI code review tools for GitLab teams. In-depth comparison of accuracy, security, and integration features to accelerate your merge request workflows.