Vercel has released updates to its AI SDK, including version ai@7.0.94. These updates introduce new features and fixes for handling AI model interactions.
Key Points
- The ai@7.0.94 release supports per-request models in batch operations.
- Tool choices are now enforced within the
streamTextfunction. - The SDK includes retry mechanisms for unclassified empty image results.
- Retry-attempt accounting is preserved for these retries.
- A provider-independent result retryability classification has been added.
- Google and Google Vertex prompt blocks are marked as terminal.
- Dependencies for
@ai-sdk/provider,@ai-sdk/gateway,@ai-sdk/provider-utils,@ai-sdk/alibaba, and@ai-sdk/amazon-bedrockhave been updated.
Context
According to Vercel, these changes are part of routine patch updates to the AI SDK. The updates aim to enhance the flexibility and reliability of AI model integrations, particularly concerning batch processing and tool usage.
Why It Matters
These updates provide developers with more granular control over model selection in batch requests and improve the predictability of tool usage in streaming text scenarios. The enhanced retry logic also contributes to more robust application performance when dealing with image results.
What To Do
- Review the updated documentation for ai@7.0.94 to understand the new batch model support.
- Test the
streamTextfunction with explicit tool choices to observe the enforcement. - Note the new retry mechanisms for image results and their impact on error handling.
- Compare the updated dependencies to ensure compatibility with existing projects.
