npm / @ai-sdk/deepseek
@ai-sdk/deepseek
What changed in @ai-sdk/deepseek 1 to 3, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-18.
12 new APIs and options1 behavior and defaults12 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli init@ai-sdk/deepseek 323 changes
New APIs and options 12
Adds max as a portable reasoning level, with native provider mappings, compatibility coercions, and budget-based fallback support.
provider-utils adds deleteFromApi.
FilesV4 call options now support abortSignal.
FilesV4 gains an optional deleteFile operation.
FilesV4 gains an optional streaming downloadFile operation.
FilesV4 gains an optional getFileMetadata operation.
FilesV4 call options now support headers.
provider-utils adds postMultipartStreamToApi for streaming multipart uploads with deterministic part ordering and failure-path stream teardown.
Upload data now accepts a { type: 'stream' } variant.
Upload results now expose byteSize.
Upload results now expose createdAt.
Upload results now expose expiresAt.
Behavior and default changes 1
Preserves reasoning content on all assistant turns for future DeepSeek models, using current reasoning-enabled defaults; known pre-V4 versions and legacy chat/reasoner aliases retain previous handling.
Fixes and other changes 10
Fixes cached input token reporting for OpenAI-compatible DeepSeek responses.
Uses a standards-compliant User-Agent header.
Fixes streamed tool calls with missing, blank, or repeated IDs.
Tool-result images are now sent as image content parts.
Non-streaming responses without choices now return a typed error.
The deepseek-flash alias is treated as a V4 model so prior-turn reasoning_content is preserved in multi-turn requests.
Preserves reasoning streams across empty tool-call deltas.
The core uploadFile() helper now forwards abortSignal.
The core uploadFile() helper now forwards headers.
Preserves complete raw chat usage objects.
@ai-sdk/deepseek 21 changes
Fixes and other changes 1
Complete raw chat usage objects are now preserved, so developers retain all usage data.
@ai-sdk/deepseek 11 changes
Fixes and other changes 1
Treats the deepseek-flash alias as a V4 model so prior-turn reasoning_content is preserved in multi-turn requests.