Pick a TypeScript agent framework by reading its tool-calling API and you will learn almost nothing, because all four of these agree on it: typed tools, a loop, streaming, MCP. The decision they actually make for you is what happens to a half-finished run when the HTTP request ends — the user closes the tab, the serverless function hits its ceiling, you deploy. That is one axis, it picks your database and your deploy target, and it is the most expensive thing on this page to change your mind about later.
At a glance
All four are current as of 20 September 2026; the version and date columns are from the npm registry on that day.
| Project | Latest stable | Licence | Where the run lives after the request |
|---|---|---|---|
AI SDK (ai) |
7.0.107 — 18 Sep 2026 | Apache 2.0 | Nowhere, until you add a durable runtime |
Mastra (@mastra/core) |
1.67.0 — 15 Sep 2026 | Apache 2.0 core, EE dirs source-available | A snapshot in its own storage |
LangGraph.js (@langchain/langgraph) |
1.4.16 — 18 Sep 2026 | MIT | A checkpoint per superstep, in your DB |
VoltAgent (@voltagent/core) |
2.10.0 — 27 Aug 2026 | MIT | A suspended workflow plus durable memory |
That chart is the one number worth internalising before the feature comparison. The AI SDK ships stable versions at roughly two and a half a day; VoltAgent ships one every couple of weeks. Neither is wrong — they are different contracts with your lockfile. A library moving that fast is one you consume behind your own thin wrapper; a library moving slowly is one whose open issue you may be waiting on.
The AI SDK — the best primitive, and deliberately not a runtime
What it is
A provider-agnostic model interface plus the streaming UI layer that most of the TypeScript ecosystem renders through, at over twenty million monthly downloads. Version 6 added a proper Agent abstraction, tool-execution approval, DevTools and full MCP support, which closed the gap with what people were hand-rolling. Version 7 is current.
The seam
Everything above happens inside a request. The SDK's own troubleshooting documentation contains the sharpest statement of the problem on this page: with resumable streams enabled, a client-side abort is treated as a disconnect, so calling stop() does not stop the generation — it reconnects to it. Closing a tab and pressing Stop produce the same bytes on the wire, and the SDK cannot tell them apart, so you are told to build a separate stop endpoint that persists the partial response, cancels the work and clears the active stream.
That is not a bug to be embarrassed about; it is what happens when you add durability to a request-scoped design. The answer Vercel shipped is to move the loop onto a durable runtime: AI SDK 7's WorkflowAgent — the successor to the Workflow SDK's DurableAgent — turns each tool call into a retryable workflow step with tool approval and OpenTelemetry attached. It works, and it means the honest description of the AI SDK is a model and UI layer that becomes an agent framework once you adopt a second product.
Mastra — the integrated stack, and the one with a licence to read
What it is
The most complete single-vendor answer for TypeScript: agents, a graph workflow builder with .then() / .branch() / .parallel(), memory, RAG, model routing across dozens of providers, evals as first-class primitives, and an observability UI. It reached 1.0 in January 2026, sits at 28.2k GitHub stars, and is venture-funded at roughly $35M total after a $22M Series A — relevant here only because a framework with a hosted product attached has a commercial interest in where your state lives.
The seam
Mastra's durability is a snapshot. Suspend a workflow — for human approval or an external event — and it writes a record containing the run id, the input, per-step status, the suspend and resume payloads and the final output, into storage that defaults to libSQL and can be Postgres or Upstash. Agent memory shares that storage. The design consequence is pleasant and worth stating plainly: you get durable agents without adopting a workflow engine, because Mastra is the workflow engine.
Two things to check before you commit. First, the licence is not uniformly Apache 2.0 — the enterprise directories are source-available and need a licence for production, so read which capability sits where before it becomes load-bearing. Second, the same integration that makes it pleasant makes it the hardest of the four to leave: your evals, traces, memory schema and workflow definitions are all in its vocabulary. That is the classic trade the wiki works through in exiting a managed agent runtime, and it applies to an open-source framework with a cloud product just as much as to a closed one.
LangGraph.js — the durability model is the product
What it is
A low-level orchestration library: a state graph, conditional edges, and a checkpointer that persists state at every superstep, which is what makes interrupt-and-resume, time travel and human-in-the-loop editing fall out rather than be bolted on. Checkpointers ship for in-memory, SQLite, Postgres, Redis and MongoDB. Both the Python and JavaScript editions went 1.0 GA in October 2025.
The seam
There isn't one, which is the point — durability is not a layer you add, it is the execution model. The cost is paid elsewhere. The graph forces you to make control flow explicit before you know what it is, and the JS edition lives inside an ecosystem whose centre of gravity is Python: the langgraphjs repository carries 3.3k stars against a Python sibling an order of magnitude larger, and the integrations, examples and blog posts you will search for mostly land Python-first. Core primitives are at parity; the surrounding gravity is not.
Take it when your control flow is genuinely a graph with cycles and approvals, when a Python service of record already speaks LangGraph, or when you want durability without adopting anyone's runtime — a checkpointer is a table in a database you already run. The deeper treatment of when a reasoning graph wants a durable runtime underneath it is in durable execution: LangGraph plus Temporal.
VoltAgent — the framework is the smaller half
What it is
An MIT-licensed core with typed agents, tools, memory, a declarative workflow engine with suspend/resume, durable memory adapters and resumable streaming — plus VoltOps, a console for traces, dashboards, memory inspection, eval suites and prompt management that you can run hosted or self-host. At 10.6k stars it is the smallest community here, and the newest: @voltagent/core reached 2.x this year with a 3.0 in pre-release.
The seam
VoltAgent's bet is that the expensive part of agent work is not the loop, it is seeing inside it, and that you should not have to buy a separate observability vendor to do that. If you would otherwise stand up a tracing product alongside your framework, getting both from one dependency is a real saving and a genuine reduction in wiring — the alternatives are compared in Langfuse vs LangSmith vs Phoenix vs Braintrust.
The counterweight is the cadence chart. Five stable releases in ninety days, against 26 for Mastra and 230 for the AI SDK, is the profile of a project with a smaller maintenance surface — read that as stability if you pin, and as your own patch if you hit a provider bug in a week when nothing ships. It is also the framework whose value is most concentrated in a first-party console, which means the honest question to ask is the exit one: if VoltOps went away, how much of your agent would you still have?
The axis, side by side
Read the four together and they stop looking like competitors. The AI SDK persists nothing by default and pushes durability into a companion runtime, which keeps its core small and makes its adoption curve the gentlest; LangGraph.js persists per superstep into a database you already own, which is the most portable answer and the most opinionated about how you write control flow; Mastra persists a snapshot in storage it manages, which buys the most capability per line of code and concentrates the most in one vendor's vocabulary; VoltAgent persists workflow suspension and memory and then spends its differentiation on the console rather than on the loop.
The same ordering shows up in memory. Three of the four ship a memory subsystem with adapters and a schema; the AI SDK ships message state and expects you to bring your own, which is why AI SDK teams end up assembling what the others include — and why, once you have assembled it, you have written a worse version of Mastra. The memory layer comparison is the right place to decide whether that is a good trade for you.
One caution that applies to all four equally: none of them makes a long-running agent safe to redeploy by itself. A checkpoint or a snapshot restores state; it does not guarantee that a tool call which already fired will not fire again on resume. That is an idempotency contract you write at the tool boundary, and it is the seam where teams lose money — see idempotency and retries and durable state and resumability.
When to pick which
| Situation | Pick | Because | Watch out for |
|---|---|---|---|
| Chat UI, streaming, runs that finish in one request | AI SDK alone | Smallest thing that works; best streaming ergonomics | Stop vs disconnect, the moment you add resumable streams |
| Long runs, approvals, tasks that outlive a request | Mastra, or AI SDK + WorkflowAgent | Suspension is a first-class state, not an error path | Mastra's EE directories; Vercel's runtime as a second dependency |
| Explicit graph control flow, or a Python service of record | LangGraph.js | Checkpoints into your own database; portable | Ecosystem gravity is Python-first |
| You would otherwise buy tracing and evals separately | VoltAgent | Console included, self-hostable, MIT core | Slowest release cadence; value concentrated in VoltOps |
Before you compare APIs, write down the longest task your agent will ever run and what must be true if the process dies halfway through it. If the answer is "the user retries", take the AI SDK and stop reading. If the answer names a side effect that must not repeat or a human who must approve something, you are shopping for a durability model, and the framework question is downstream of that.
FAQ
Which TypeScript agent framework should most teams start with in 2026?
The AI SDK, unless your runs outlive a request. It is the smallest dependency, it owns the streaming edge, and the others interoperate with it. Move to Mastra or LangGraph.js when you find yourself writing your own checkpoint table.
Is the Vercel AI SDK an agent framework?
Since version 6 it has an Agent abstraction, tool approval and MCP support, so yes for single-request agents. For durable, resumable, long-running agents it relies on a companion runtime — AI SDK 7's WorkflowAgent on the Workflow SDK — which is a second product to adopt and operate.
Is LangGraph.js at parity with LangGraph for Python?
On the core primitives — state graphs, conditional edges, checkpointers, streaming, human-in-the-loop — yes, and both went 1.0 GA in October 2025. What is not at parity is gravity: the JS repository is an order of magnitude smaller in stars, and integrations and examples tend to land Python-first.
Is Mastra fully open source?
The core is Apache 2.0, but the repository is dual-licensed: the enterprise directories are source-available and require a licence for production use. Check which capability sits under which licence before you build on it.
What does VoltAgent add over a framework plus a tracing vendor?
One dependency instead of two, and a console you can self-host. It is a genuine saving in wiring if you were going to buy observability anyway. The trade is a smaller community and the slowest release cadence of the four.
Does a checkpoint make my agent safe to redeploy?
No. It restores state; it does not make a tool call that already fired idempotent on resume. That contract lives at your tool boundary regardless of which of these four you choose.
Further reading
On this wiki:
- Pydantic AI vs Agno vs smolagents vs Strands — the same question in Python.
- Spring AI vs LangChain4j vs Eino vs Rig — and on the JVM and in Rust.
- Durable execution: LangGraph plus Temporal — the pattern when the reasoning graph needs a runtime beneath it.
- Durable state and resumability — what must persist, and what you can recompute.
- Agent frameworks — the concept-level version of this choice.