Philosophy: state machines vs type contracts
**LangGraph's core bet is that agents are state machines**, and that representing them explicitly as graphs makes them easier to reason about, debug, and extend. Every LangGraph program has a `StateGraph` with a typed state schema (a `TypedDict`), a set of nodes that read and write that state, and edges that route between nodes based on the current state. The graph can be cyclic — a node can route back to itself or to a previous node — which is what enables agent loops where the model calls a tool, checks the result, and decides whether to call another tool or return. This is not a metaphor: your agent control flow is literally a directed graph that you can inspect, visualize with `graph.get_graph().draw_mermaid()`, and checkpoint at any node boundary.
**Pydantic AI's core bet is that the right abstraction boundary is the Python type system.** If you define a `Result` model with Pydantic validators, the framework guarantees the agent's output conforms to that model — retry on validation failure is built in. If you define your agent's dependencies as a typed `Deps` dataclass, you inject them at run time and mock them in tests. The framework is intentionally thin: there is an `Agent`, there are `Tool`s, there is a `Result` type, and there is a run loop. That's most of it. Samuel Colvin's explicit goal was to make something that a FastAPI developer would recognize immediately — minimal magic, maximum type coverage.
**These philosophies attract different kinds of builders.** If you are building a complex multi-step pipeline where the routing logic is a first-class concern — where the agent might need to call a tool, branch based on the result, wait for human approval, and then resume hours later — LangGraph's explicit graph model pays off. The routing is visible, debuggable, and modifiable without reading the framework internals. If you are building an agent that needs to return a reliably structured response and you want your editor and mypy to tell you when you break something, Pydantic AI's type-contract model pays off.
**Neither framework is a thin wrapper around a single model provider's SDK.** Both are model-agnostic by design, both support tool calling via a unified interface, and both are actively maintained in 2026. The difference is which dimension of the problem they optimize for: LangGraph optimizes for control-flow expressiveness; Pydantic AI optimizes for type-safety and testability.
**The LangChain heritage matters for LangGraph.** Because LangGraph is built on LangChain 0.4, it inherits LangChain's integrations — hundreds of LLM providers, vector stores, document loaders, and tools. If you are already in the LangChain ecosystem, LangGraph is a natural upgrade from linear chains to cyclic agents. If you are starting fresh with no LangChain investment, you should evaluate whether you want that dependency surface or whether Pydantic AI's leaner dependency tree is preferable.
**Pydantic AI's independence from LangChain is a feature for some teams.** Pydantic itself is a near-universal Python dependency (it's in FastAPI, SQLModel, and most modern Python web stacks), but Pydantic AI the framework is a new dependency with a smaller footprint than the LangChain+LangGraph stack. For teams that have been burned by LangChain's historically unstable API surface, Pydantic AI's smaller, more opinionated design is a selling point.