AI SDK 5 made the chat boundary and agent loop explicit in TypeScript
Vercel released AI SDK 5 on July 31, 2025, separating UI and model messages while adding typed chat data parts and configurable tool-calling loops.
Historical reporting: Vercel announced AI SDK 5 on July 31, 2025, and its public repository release records the 5.0.0 artifact. The event documents framework APIs, not the behavior, cost, or reliability of an application built with them.

Key takeaways
- AI SDK 5 separated persistent UI messages from model-facing messages.
- The release made stopping and step preparation visible parts of a tool loop.
- A migration needs transcript and stream-contract tests as well as type checks.
A typed chat redesign was the July release event[source 1][source 2]
Vercel announced AI SDK 5 on July 31, 2025, describing a TypeScript and JavaScript release with a redesigned chat layer, agentic loop controls, speech features, tool improvements, and updated specifications. Its central architectural split was between `UIMessage`, the richer application-facing record, and `ModelMessage`, the representation sent to a language model. The announcement also introduced typed data parts for streaming application-defined status and tool information. The associated `[email protected]` repository release is a separate artifact record for the package. Together, those sources establish what shipped at that point; they do not show that a particular chat history, provider, or agent workflow migrated correctly.
The release separated browser state from model context[source 1]
The message split matters because a visible conversation can contain UI metadata, tool results, and partial updates that are unsuitable or unnecessary as model input. AI SDK 5 made conversion from UI messages to model messages an explicit operation, so an application could keep a durable reader-facing history while choosing the smaller, relevant context for each inference call. On the execution side, `stopWhen` turned a default single request into a bounded tool-calling loop, and `prepareStep` allowed step-specific model, tool, or prompt adjustments. These are framework controls, not a planning algorithm: their effect still depends on the model, the tool definitions, and the application code that supplies context.
A v5 move changed records at two interfaces[source 1][source 2]
For a product team, the important upgrade target was not merely a new import path. Persisted chat records needed an explicit versioned shape, and the server-to-client stream needed tests for every data part and tool result the interface renders. Tool loops also needed deliberate terminal conditions: a maximum step count, a named completion tool, or another domain-specific stop condition. Teams could compare representative transcripts before and after the change, including interrupted streams and failed tool calls, to learn whether the new conversion boundary changed the model context. That test is more informative than a successful compilation because message preservation and model context are related but different contracts.
The release is best read as a composability change[source 1][source 2]
AI SDK 5 put a practical boundary around an application’s three moving parts: what users see, what a model receives, and what happens during a multi-step tool loop. That separation gave developers a vocabulary for debugging a common failure mode, where a UI state and a provider request are assumed to be the same thing. A useful release note for a v5 adoption would therefore retain the package version, provider adapter, stored-message schema, stream protocol, stop condition, and representative traces. It should also preserve the conversion rule used to select message context for each model step. Those fields make a later regression distinguishable from an ordinary provider-output change. The July record supports the existence of those primitives. It does not support a generic claim that typed messages prevent incorrect answers or that a bounded loop makes a tool operation successful.
Sources
- Vercel: AI SDK 5 (July 31, 2025)
- Vercel AI repository: [email protected] release (July 31, 2025)
