MCPcopy Create free account
hub / github.com/langchain-ai/langgraph

github.com/langchain-ai/langgraph

Chat with this repo
repository ↗ · DeepWiki ↗ · release checkpointsqlite==3.1.1 ↗ · + Follow · compare 11 versions
7,810 symbols 45,656 edges 455 files ⚖ MIT 2,865 documented · 37% updated todaysdk==0.4.3 · 2026-08-19★ 40,521481 open issues

Browse by type

Functions 6,684 Types & classes 1,100 Endpoints 26
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

  <img alt="LangGraph Logo" src="https://github.com/langchain-ai/langgraph/raw/checkpointsqlite==3.1.1/github/images/logo-dark.svg" width="50%">

Low-level orchestration framework for building stateful agents.

PyPI - License PyPI - Downloads Version Twitter / X

Trusted by companies shaping the future of agents – including Klarna, Replit, Elastic, and more – LangGraph is a low-level orchestration framework for building, managing, and deploying long-running, stateful agents.

pip install -U langgraph

[!TIP] If you're looking to quickly build agents, check out Deep Agents — a higher-level package built on LangGraph for agents that can plan, use subagents, and leverage file systems for complex tasks.

For an equivalent JS/TS library, check out LangGraph.js and the JS docs.

Why use LangGraph?

LangGraph provides low-level supporting infrastructure for any long-running, stateful workflow or agent:

  • Durable execution — Build agents that persist through failures and can run for extended periods, automatically resuming from exactly where they left off.
  • Human-in-the-loop — Seamlessly incorporate human oversight by inspecting and modifying agent state at any point during execution.
  • Comprehensive memory — Create truly stateful agents with both short-term working memory for ongoing reasoning and long-term persistent memory across sessions.
  • Debugging with LangSmith — Gain deep visibility into complex agent behavior with visualization tools that trace execution paths, capture state transitions, and provide detailed runtime metrics.
  • Production-ready deployment — Deploy sophisticated agent systems confidently with scalable infrastructure designed to handle the unique challenges of stateful, long-running workflows.

[!TIP] For developing, debugging, and deploying AI agents and LLM applications, see LangSmith.

LangGraph ecosystem

While LangGraph can be used standalone, it also integrates seamlessly with any LangChain product, giving developers a full suite of tools for building agents.

To improve your LLM application development, pair LangGraph with:

  • Deep Agents – Build agents that can plan, use subagents, and leverage file systems for complex tasks.
  • LangChain – Provides integrations and composable components to streamline LLM application development.
  • LangSmith – Helpful for agent evals and observability. Debug poor-performing LLM app runs, evaluate agent trajectories, gain visibility in production, and improve performance over time.
  • LangSmith Deployment – Deploy and scale agents effortlessly with a purpose-built deployment platform for long-running, stateful workflows. Discover, reuse, configure, and share agents across teams – and iterate quickly with visual prototyping in LangSmith Studio.

Documentation

Discussions: Visit the LangChain Forum to connect with the community and share all of your technical questions, ideas, and feedback.

Additional resources

  • Guides – Quick, actionable code snippets for topics such as streaming, adding memory & persistence, and design patterns (e.g. branching, subgraphs, etc.).
  • LangChain Academy – Learn the basics of LangGraph in our free, structured course.
  • Case studies – Hear how industry leaders use LangGraph to ship AI applications at scale.
  • Contributing Guide – Learn how to contribute to LangChain projects and find good first issues.
  • Code of Conduct – Our community guidelines and standards for participation.

Acknowledgements

LangGraph is inspired by Pregel and Apache Beam. The public interface draws inspiration from NetworkX. LangGraph is built by LangChain Inc, the creators of LangChain, but can be used without LangChain.

Core symbols most depended-on inside this repo

browse all functions →

Shape

Function 4,076
Method 2,608
Class 1,100
Route 26

Languages

Python100%
TypeScript1%

Modules by API surface

libs/langgraph/tests/test_pregel.py411 symbols
libs/langgraph/tests/test_pregel_async.py341 symbols
libs/langgraph/tests/test_pregel_stream_events_v3.py265 symbols
libs/langgraph/tests/test_retry.py231 symbols
libs/sdk-py/langgraph_sdk/_async/stream.py121 symbols
libs/sdk-py/langgraph_sdk/_sync/stream.py110 symbols
libs/prebuilt/tests/test_react_agent.py103 symbols
libs/cli/tests/unit_tests/test_deploy_helpers.py98 symbols
libs/prebuilt/tests/test_tool_node.py95 symbols
libs/cli/tests/unit_tests/test_config.py93 symbols
libs/langgraph/tests/test_stream_events_v3.py90 symbols
libs/langgraph/tests/test_time_travel.py86 symbols

Dependencies from manifests, versioned

@eslint/eslintrc3.3.5 · 1×
@eslint/js10.0.1 · 1×
@js-monorepo-example/shared* · 1×
@langchain/core1.2.1 · 1×
@tsconfig/recommended1.0.13 · 1×
@types/jest30.0.0 · 1×
@typescript-eslint/eslint-plugin8.62.1 · 1×
@typescript-eslint/parser8.62.1 · 1×
dotenv17.4.2 · 1×
eslint10.6.0 · 1×

Datastores touched

postgresDatabase · 1 repos
dbnameDatabase · 1 repos
mydbDatabase · 1 repos

For agents

$ claude mcp add langgraph \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page