AG-UI Mastra 2.1 adds a CopilotKit 2.x entry and moves run guidance to the model boundary
On November 27, AG-UI released `@ag-ui/mastra` 2.1.0. It adds `@ag-ui/mastra/copilotkit-2`, importing the CopilotKit 2.x runtime from `@copilotkit/runtime`, while the old and new entries share the same route implementation. The optional peer dependency now accepts CopilotKit `^1.76.0` or 2.x.
Why it matters
The release separates a frontend-runtime major migration from AG-UI route semantics, reducing the need for applications to duplicate adapter code for CopilotKit 2.x. The adapter also declares its version in capabilities identity and adds per-run guidance and capability discovery so the model boundary can understand the interface capabilities available to the agent.
A closer look
In-process agents on supported Mastra versions enable run guidance by default. The adapter consumes the reserved `OpenBot standing role` and `OpenBot granted tools guidance` context entries at the model boundary, while ordinary context still reaches callbacks. Both CopilotKit entries use one route implementation, so the release states that their route behavior is identical.
Who this is for
Frontend and agent-platform teams maintaining Mastra, AG-UI, and CopilotKit integrations, migrating to CopilotKit 2.x, or depending on requestContext, custom tools, and prompt callbacks.
Original sources
Revisions & corrections (1)
— Official AG-UI release notes document a distinct compatibility and model-boundary behavior change with an explicit migration caveat.