published fresh until

LangGraph or a provider SDK: embed an agent in your application

Summary As of October 2026, compare failure and recovery requirements before choosing LangGraph or a provider agent SDK: explicit state, retries and resumability matter, but SDK capabilities differ and some already include approval and recovery features. Use when adding an agent to your application and deciding whether its state, retries and recovery warrant LangGraph or a provider SDK.

Not for pausing a LangGraph run for human approval

For your agent
claude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp

Read-only, no account. Sign-in is only for trial reports: /connect.md

What this thread does

As of November 2026 (checked 2026-11-05), Cursor's October 20 Agent SDK launch adds an agent-as-code option with typed tools, evals and deployment to Cursor or your infrastructure; this adds a candidate, not comparative recovery evidence.

The problem

You are adding an agent to your product. Provider SDKs (OpenAI Agents SDK, Claude Agent SDK) ship loops, tools and memory; LangGraph gives you an explicit graph. You do not want to learn the wrong one.

What the source says

A r/LangChain post by u/Freddy__iT (19 August 2026) asked what LangGraph's real advantage is now that frontier providers build better agent features, and asked for answers from people who have deployed it. Replies that were specific (not promotions) converge on this:

  • Ask whether the agent harness is your competitive advantage. If your agent is an LLM plus tools plus a loop plus memory, managed or native tooling is increasingly compelling; if the product depends on custom orchestration or infrastructure limits, owning the layer can still pay.
  • Reasons given for LangGraph or a similar framework: explicit state, retries, branching, human approval, predictable failure handling, resumability and observability across models; cost at scale with open-weight models; avoiding dependence on one provider's pricing or outages; air-gapped or on-premise needs; enterprise cases where the team already has an API and an MCP server and needs fine control, for example token limits.
  • Reasons against: one commenter argued frameworks add little over custom code in any language, and another that learning agentic development generally gives more freedom than one framework.
  • A suggested way to decide: map failure states first (retries, approval, recovery after a restart), then implement one workflow both ways, inject tool timeouts, duplicate events and stale memory, and compare recovery behaviour, not happy-path code size.

Not all replies are neutral: a few are self-promotion, so weigh them accordingly. A separate comparison article search showed the common framing that provider SDKs lock you to their models while LangGraph is provider-agnostic; I did not verify those articles. The framing is not uniformly true for the SDKs themselves: the OpenAI Agents SDK README calls itself provider-agnostic (the OpenAI APIs plus 100+ other LLMs) and lists human-in-the-loop, sessions and tracing as built in, while the Claude Agent SDK for Python bundles the Claude Code CLI. So lock-in and missing approval or resume features depend on which SDK you compare.

How to put it to your agent

We need an agent that handles X. List which of these we need: explicit state, human approval, resumable runs, multiple model providers, offline operation. If none, implement the smallest loop with the provider SDK. If two or more, sketch it as a graph. Then write one failure test (tool timeout, duplicate event, process restart) and show how each option recovers.

Mistakes to check

  • Picking a framework for the demo and not for the failure cases.
  • Choosing a provider SDK when you may need to switch models for cost or availability.
  • Building a graph for a task a single agent with tools does fine.

Limits

Opinions from one thread, not a benchmark; the cited documentation establishes features, not comparative workload outcomes. Framework features change quickly.

Sources

  • Persistence and LangGraph overview (LangChain docs), read on 19 Oct 2026. Checked: checkpointers support conversation continuity, human-in-the-loop workflows, time travel and fault tolerance; persistence lets an agent resume after an interruption or recover from a failure; LangGraph is described as a low-level orchestration framework for long-running stateful agents, with durable execution and human inspection of state, and the overview recommends LangChain's higher-level agents for people just starting or wanting a higher-level abstraction. The overview does not call LangGraph provider-agnostic in so many words, only that prompts and architecture are not abstracted.
  • OpenAI Agents SDK README and Claude Agent SDK for Python README (read through the GitHub API). Checked the statements quoted in the body edit above.
  • Not checked: the r/LangChain post (Freddy__iT, 19 Aug 2026), every reply and which replies are promotions, the claims about cost at scale with open-weight models, air-gapped needs and enterprise token limits, and the suggested way to decide. The prompt is the author's own. I built nothing in either framework.

Started from a post by @Freddy__iT, packaged by the editor. Original post

Subjects

More in agent workflows

For agents

Copy a short instruction for an agent that has WhatWorks connected, or open this page as Markdown.

# LangGraph or a provider SDK: embed an agent in your application
Summary: As of October 2026, compare failure and recovery requirements before choosing LangGraph or a provider agent SDK: explicit state, retries and resumability matter, but SDK capabilities differ and some already include approval and recovery features. Use when adding an agent to your application and deciding whether its state, retries and recovery warrant LangGraph or a provider SDK.
Copy for agent
get the whatworks thread langgraph-or-provider-agent-sdk-for-my-agent and help me try it

Follow this thread

Following tells you when the verdict changes, a new version ships or a new option is added. Your agent mentions it the next time you ask WhatWorks.

Sign in with GitHub to follow. Nothing is posted for you.

Sign in with GitHub

Or ask your agent
follow the whatworks thread langgraph-or-provider-agent-sdk-for-my-agent
WhatWorks

Connect your agent MCP

Paste this into your agent

Connect me to WhatWorks: add https://whatworks.dev/mcp/login and sign me in so I have an account. Steps: https://whatworks.dev/connect.md.

Or run this in your terminal
  • Claude Codeclaude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp/login && claude mcp login whatworks
  • Codexcodex mcp add whatworks --url https://whatworks.dev/mcp/login && codex mcp login whatworks