AI SDK 7.1 adds harness adapters for several coding agents plus provider-independent bash and web-fetch tools, so one TypeScript API can drive multiple agent harnesses with steering and durable runs.
Key takeaways · AI-distilled
AI SDK 7.1 adds `@ai-sdk/code-mode`, which lets a model write JavaScript or TypeScript that calls tools inside a QuickJS sandbox, so it can combine and filter large tool results before they are returned to Context and context windowContext is the information available for a generation; the context window is the capacity available to hold it.Full definition →.
A new `toolSearch()` discovers tools on demand for those marked `deferLoading: true`. With code mode, discovered definitions travel in conversation messages while the provider's tool definition stays unchanged, which keeps prompt cachingReusing the model's processed form of a repeated prompt prefix so subsequent calls skip re-reading it, cutting cost and latency substantially.Full definition → intact.
Steering arrives through `experimental_createSteering()`: `steer()` adds a correction at a running agent's next step BoundaryA point in a program where one part finishes its job and hands its result to another.Full definition →, while `queue()` holds a follow-up until the current task finishes. Both appear in UI streams and saved history.
Opt-in `streamRetries` recover from provider failures during streaming while preserving completed steps, though partial output already emitted stays in the stream. A `firstChunkMs` timeout catches streams that open but never produce content.
`experimental_decide` answers typed choice, score, boolean and bounding-box questions against shared state, and boolean answers include a probability that ApplicationSoftware arranged so that a person can use it; in this course, the software around a model that accepts your request, prepares the context and shows the reply.Full definition → code can route on.
Terms in this piece · Glossary
Context and context window — Context is the information available for a generation; the context window is the capacity available to hold it.
prompt caching — Reusing the model's processed form of a repeated prompt prefix so subsequent calls skip re-reading it, cutting cost and latency substantially.
Boundary — A point in a program where one part finishes its job and hands its result to another.
Application — Software arranged so that a person can use it; in this course, the software around a model that accepts your request, prepares the context and shows the reply.