AI SDK migration guide
Migrate Vercel AI SDK from 4 to 5, 5 to 6, or 6 to 7. Find breaking changes in your TypeScript or JavaScript code and review supported fixes.
Choose your AI SDK migration path
The ai package is Vercel AI SDK. Start with the release you are moving to. Each guide names the changes Emendant covers, shows code before and after, and states what still needs your review.
- Migrate AI SDK 4.x to 5.0: React and RSC imports move, message types change, and
tool()usesinputSchema. - Migrate AI SDK 5.x to 6.0: old
CoreMessagenames are removed, and agent and tool names change. - Migrate AI SDK 6.x to 7.0: experimental names, call options, stream results, and token usage fields change.
Check your repository before you upgrade
- Check the installed
aiversion in your manifest and lockfile. Read the guide for the target release above. - Run
npx emendant scanin your TypeScript or JavaScript repository. It reports supported changes at affected call sites without editing your files. - Review the findings, then run
npx emendant fix --dry-runto inspect eligible patches. Emendant does not update package versions for you. - After you update dependencies, run your own typecheck and tests. Some migration steps need manual work or a model provider you name.
For a worked example, read one measured AI SDK 6 to 7 migration of a public repository. It gives every command from a pinned commit and feed snapshot, the patch Emendant wrote, the edits it left to the reader, and the changes it did not report.
Emendant reports only changes in its curated feed. A clean scan does not prove that every AI SDK migration step is complete. Read the supported projects guide for the current scope and the fix guide for patch grades.
AI SDK release pages
- ai 7.x breaking changes: 7.0.14 to 7.0.143
10 releases, 7.0.14 to 7.0.143, released 2 July 2026 to 16 October 2026. 21 breaking, 13 deprecations. - AI SDK 7.0.0: what breaks when you upgrade ai from 6.x
ai 7.0.0, released 25 June 2026. 60 breaking, 17 deprecations. - ai@6.0.312: metadata type changed on TelemetrySettings
ai 6.0.312, released 21 October 2026. 1 breaking, 0 deprecations. - AI SDK 6.0.0: what breaks when you upgrade ai from 5.x
ai 6.0.0, released 22 December 2025. 4 breaking, 2 deprecations. - AI SDK 5.0.0: what breaks when you upgrade ai from 4.x
ai 5.0.0, released 31 July 2025. 19 breaking, 3 deprecations. - AI SDK 4.0: what breaks when the 2.x stream helpers go
ai 4.0.0, released 18 November 2024. 4 breaking, 0 deprecations.
Releases without a page here may still be in the feed. Run emendant feed status to see what your snapshot holds.