AI SDK 7.1 Released: Adding a Critical Control Layer for Long-Running Agents

AI SDK 7.1 adds nine control capabilities — steering, batching, stream control, and durability — for long-running tasks.
AI SDK 7.1 shifts focus to controllability and durability for long-running, multi-loop agents across nine update categories. Key additions include five new harness adapters (Cline, Cursor, fx, GitHub Copilot, Grok Build) with mid-turn steering for Codex; experimental_decide answering four typed question types in one call; experimental_startBatch moving long jobs out of the request lifecycle; experimental steering for generateText, streamText, and ToolLoopAgent; streaming speech, transcription, translation, and real-time connection modes; tool search with sandboxed bash and web fetch; and WorkflowAgent.generate() producing a single OpenTelemetry trace per durable run. The release cadence is now monthly minors and annual June majors, with one year of full support plus six months of security fixes.
AI SDK 7.1 Released: Adding a Critical Control Layer for Long-Running Agents
AI SDK 7 provided the foundational primitives for building end-to-end, production-grade agents and frameworks. With 7.1, the focus shifts to a different question: what control mechanisms do developers need when tasks run longer, loop more, and scale larger? The official answer is nine categories of capability updates spanning four directions: steering, large-scale tool sets, stream interruption recovery, and multi-process workflow tracing.

This update isn't simply a pile of new APIs — it's built around two main threads: "controllability" and "durability." For teams already running agent tasks in production, several of these changes will directly alter the trade-offs in their existing architecture.
Overview of the Nine Update Categories: Control and Durability
By official classification, 7.1 adds capabilities in the following areas:
- Harnesses and tools: Five new harness adapters (Cline, Cursor, fx, GitHub Copilot, Grok Build), mid-turn steering for Codex, and provider-agnostic bash and web fetch tools.
- Typed decisions:
experimental_decidesupports four question types: choice, score, boolean, and bounding box. - Batch processing: Background text and image generation.
- Steering: Send corrections and queued follow-up instructions to a running agent.
- Real-time and streaming audio: Streaming speech, transcription, translation, continuous real-time sessions, and WebSocket transport for
useChat. - Code mode and tool search: Sandboxed tool orchestration and on-demand tool discovery.
- Asynchronous video generation: start and status functions, frame images, and reference inputs.
- Agents and stream control: Tool call concurrency, per-step call settings, step error callbacks, first-content timeout, stream retry, and low-memory streaming.
- Durable agents:
WorkflowAgent.generate()and one OpenTelemetry trace per durable run.
Harness (agent runtime framework) refers to mature coding agent runtimes like Claude Code, Codex, and Cursor that already encapsulate the conversation loop, tool calls, file editing, and context management. The value of HarnessAgent lies in its abstraction layer: it maps the session state, stream events, tool inventory, and token usage of different runtimes onto a unified contract, so application code depends only on this contract rather than any vendor's proprietary interface. This means swapping harnesses only requires changing the adapter — conversation history, permission policies, and UI rendering logic don't need to be rewritten. For teams that have written deep integrations for a specific coding agent, this abstraction layer is also the prerequisite for making multiple runtimes coexist (e.g., using Cursor day-to-day and Codex in CI).
Release Cadence Fixed: Monthly Minors and Annual Majors
The accompanying engineering decision is to fix the release cadence: one minor version per month, released on the Monday closest to the 1st of each month (except January); one major version per year in June, replacing that month's minor release.
The support policy is also clarified: the previous major version gets one year of full support, during which all applicable bug fixes are backported; for six months thereafter, only critical security fixes are backported. The official timeline states that AI SDK 5 support ends at the end of 2026, and AI SDK 6 support ends on June 1, 2027. For teams building products on the SDK, this is a schedule they can put into their technical planning.
Harness Adapter Expansion and Codex Mid-Turn Steering
The HarnessAgent introduced in AI SDK 7 runs mature agent harnesses like Claude Code, Codex, and Pi through a single API. 7.1 adds five new runtimes: Cline, Cursor, fx, GitHub Copilot, and Grok Build. Each adapter normalizes the runtime's sessions, stream events, tools, and usage into the harness contract, enabling harness swaps without changing the integration layer.
For Codex, the adapter now connects to the Codex app-server, allowing user messages to be appended while a turn is still running. In the example, agent.experimental_steer() changes the target from Paris to Paris, Texas while a weather query is in progress, without waiting for the turn to end. This is clearly significant for long tasks that require human intervention for correction.
Typed Decisions: Answering Multiple Classification Questions in One Call
Agents frequently face small classification judgments: which team should own a ticket, how severe is it, does the customer want a refund. Writing a separate structured output call for each question is both repetitive and requires validation before branching.
experimental_decide answers a set of named questions against a shared state (text, JSON, or text plus files and JSON) in a single call. Answers are typed: a choice answer returns a union type of the option keys you defined; a boolean answer includes a probability — the model's estimated likelihood that the answer is true — which can be used for threshold-based routing. Native decision models can also return probability distributions for choice and score. The official recommendation is to prefer native decision models when the provider offers them, and otherwise use a language model adapter.
Batch Processing: Moving Long Tasks Out of the Request Lifecycle
Jobs like backlog classification, ticket summarization, and catalog image generation can now run in the background. experimental_startBatch submits text or image requests and returns a serializable batch reference; you then retrieve status and results with experimental_getBatchStatus and experimental_getBatchResults. When the provider supports it, you can also cancel and list batches, and receive a notification on completion via webhookUrl.
Boundaries to note: text requests can use different models and carry tool definitions, but client-side tools are not executed in batch processing — tool calls are returned to the application. Batch processing currently covers AI Gateway, Anthropic, Google, OpenAI, and xAI.
Steering: Mid-Flight Correction Without Interrupting Tool Execution
Previously, if users spotted a problem mid-run, they could only wait for the turn to end or abort and start over. Experimental steering lets generateText, streamText, and ToolLoopAgent be corrected while running: create a steering object with experimental_createSteering() and pass it as experimental_steering. steer() inserts a user message at the next step boundary without interrupting running tools, while queue() holds follow-up instructions until the current task finishes.
Two details are worth noting: both steer() and queue() return a result indicating whether the message was delivered; passing an id makes retries safe — resending the same id returns the first result. Steering messages are streamed as steering-message parts, added to the assistant message by useChat, and listed per step so the full conversation can be saved.
Step boundary is the structural prerequisite that makes safe message insertion possible for steering. An agent's run typically consists of multiple steps, each containing one model generation plus the batch of tool calls executed alongside it. steer() doesn't preempt a tool that's currently executing; instead, it queues the user message to be processed before the next step begins, so the model sees the new instruction when it re-plans. The timing of the correction therefore depends on when the current step ends: if a tool call takes a long time, the steering message won't be consumed until it returns. Understanding this is important for setting interaction expectations — steering provides "as soon as possible but orderly" intervention, not immediate interruption.
Streaming Audio and Real-Time Sessions
7.1 makes speech, transcription, and translation all streamable. experimental_streamSpeech accepts a full string or a text stream (including streamText's textStream) and starts playing before the model finishes writing. On the real-time input side, streamTranscription produces transcription updates before the audio stream ends, and streamSpeechTranslation translates live speech into audio and text in the target language. transcribe now also returns separate word-level timestamps and accepts timestampGranularities to request word- or segment-level timestamps.
Real-time connections expand from 7's "turn-based, browser holds short-lived token and connects directly to provider" model to three modes: continuous OpenAI Live sessions via an app-hosted WebSocket relay or browser WebRTC; server-side connections where a trusted server establishes the WebSocket; and provider-hosted transport where the provider handles audio transport while the server only creates and closes sessions. Additionally, WebSocketChatTransport lets useChat send and receive UI message streams over a single persistent WebSocket connection, with support for cancellation and sequence-based resumption.
The Combined Value of Tool Search, Sandboxing, and Stream Control
For agents with large tool sets, toolSearch() lets the model discover tools on demand without preloading all definitions: mark tools with deferLoading: true, and matched tools become available in the next step after the search. Combined with @ai-sdk/tool-bash for executing commands in a sandbox session specified by experimental_sandbox, and @ai-sdk/tool-web-fetch for reading web pages and documents by URL (with domain allow or block lists), these are first-party tools that work with any model supporting tool calls.
On the stream control side, 7.1 adds tool call concurrency, per-step call settings, step error callbacks, first-content timeout, stream retry, and low-memory streaming. None of these capabilities stands out on its own, but together they form the infrastructure that lets long loops recover from failures and degrade gracefully under resource constraints.
Durable Agents and a Single Trace
WorkflowAgent.generate() brings agents into durable workflows and generates one OpenTelemetry trace per durable run. Multi-process workflows can therefore be observed per run, rather than being scattered across logs from multiple services. Together with the earlier steering, stream retry, and batch processing, this capability forms 7.1's complete answer to the "long-running tasks" scenario.
OpenTelemetry trace is the standard data structure for cross-service tracing, consisting of a tree of spans where each span records the operation name, start and end times, attributes, and events. Long-running agents naturally span multiple processes and many external calls; with traditional instrumentation, a single run gets split into disconnected log fragments. Generating a single trace per durable run means the entire run shares one trace id, with each step, tool call, and model request attached as child spans beneath it, so the full timeline and latency distribution are directly visible in backends like Jaeger and Tempo. This is also the foundation for diagnosing issues like "which step is the task stuck on" and "which round did the retry occur in."
Editor's Observations
Looking at the span from 7 to 7.1, AI SDK is shifting from "a unified interface for calling models" to "a runtime for running agents." Harness adapters solve standardized integration with the coding agents teams already have; steering and stream control solve the intervenability of long tasks; batch processing and durable workflows solve scheduling outside the request lifecycle. The fixed release cadence reduces the difficulty of planning upgrades.
The practical impact for developers: if your current system relies on the assumption of "one request runs to completion," several of the capabilities in 7.1 require architectural coordination to deliver value; for teams already handling long tasks, many tools, and real-time audio, these updates mostly fill in the glue layers they previously had to implement themselves.
One-line Summary
AI SDK 7.1 completes nine categories of control capabilities — steering, batch processing, stream control, and durability — for long-running tasks.
Paragraph Summary
Building on the production-grade primitives of 7, AI SDK 7.1 shifts focus to the controllability and durability of long-running, multi-loop, large-scale agents, covering nine update categories. Highlights include five new harness adapters (Cline, Cursor, fx, GitHub Copilot, Grok Build) and mid-turn steering for Codex; experimental_decide answering four typed question types in one call; experimental_startBatch moving long jobs out of the request lifecycle; experimental steering letting generateText, streamText, and ToolLoopAgent accept corrections and queued instructions without interrupting tool execution; streaming speech, transcription, translation, and multiple real-time connection modes; tool search paired with sandboxed bash and web fetch; and WorkflowAgent.generate() producing a single OpenTelemetry trace per durable run. The release cadence is fixed to monthly minors and annual June majors, with one year of full support plus six months of security fixes.
Related articles

Datasette Database in Practice: Creating Tables, Data Entry, and Relationship Configuration
On Day 3 of Datasette Advent, learn how to create tables, insert and update data, modify schemas, and configure foreign keys and many-to-many relationships in Datasette, plus the new label column feature in 1.0a47 and the uvx no-install startup method.

Nvidia CEO Affair Scandal: Bipartisan Ridicule and Rebuke
Nvidia CEO faces bipartisan ridicule and rebuke over affair scandal. Hacker News debates the boundary between personal morality and business leadership, and potential impact on Nvidia's brand and governance.

Did Musk's FAA Cuts Crash the Aviation System? Lawmakers Blast $50 Billion Funding Controversy
US aviation communications meltdown grounds flights nationwide; lawmakers blast Musk's FAA cuts for losing 1,300 technical staff and question $50B funding priorities.