Full-Code · Orchestration Frameworksactive

LangGraph

Type: full-code  ·  Vendor: LangChain Inc.  ·  Language: Python, TypeScript  ·  License: MIT  ·  Status: active  ·  Status in practice: mature  ·  First released: 2024

Links: homepage docs repo

Provide low-level orchestration infrastructure for long-running, stateful agents with durable execution, persistent memory, and built-in human-in-the-loop interrupts.

Description. LangGraph is the MIT-licensed orchestration framework from LangChain Inc. that models an agent as a graph of nodes operating over a shared, checkpointed state object. Production users (Klarna, Replit, Elastic) build durable agents that resume from failures, pause for human approval via interrupt(), and share short-term thread-scoped memory plus long-term cross-session memory in a Store. LangGraph draws structural inspiration from Pregel and Apache Beam; it can be used standalone or paired with LangChain, LangSmith for observability, and LangGraph Platform for hosted runs. Multi-agent topologies (supervisor, swarm, hierarchical) ship as separate prebuilt libraries.

Agent loop shape. Graph of nodes with explicit state edges; the runtime checkpoints state after every super-step so any node can be paused, resumed, or restarted, and Command-typed return values can re-route control between nodes or subgraphs.

Primary use cases

  • long-running stateful agents resilient to failures
  • multi-agent supervisor / swarm / hierarchical topologies
  • agents with mid-run human-approval steps
  • agents needing both working memory and cross-session persistent memory

Key concepts

  • StateGraph (docs)The core abstraction: a graph whose nodes read from and write to a typed state object the runtime checkpoints.
  • Checkpointer agent-resumption (docs)Persistence layer that saves state at each super-step so executions are durable and resumable.
  • interrupt() human-in-the-loop (docs)Pauses graph execution at a node and waits indefinitely for external (human) input before continuing.
  • Command handoff (docs)Return value from a node combining a state update with a goto routing decision; Command.PARENT crosses subgraph boundaries.
  • create_react_agent react (docs)Prebuilt tool-calling ReAct-style agent that loops over tool calls until the model emits a final answer.
  • Subgraphs hierarchical-agentsNested graphs that let a node delegate to a complete inner graph (the basis for hierarchical agents).
  • Store (long-term memory) cross-session-memory (docs)Cross-thread persistence of long-term memories under custom namespaces and keys.
  • recursion_limit / GraphRecursionError step-budget (docs)Cap on total super-steps (default 25); exceeding it raises GraphRecursionError.

Patterns this full-code implements

Neighbourhood

Click any neighbour to follow the lineage. Scroll to zoom, drag to pan.