github cloudflare/ai @cloudflare/tanstack-ai@0.1.10

latest release: workers-ai-provider@3.2.0
11 hours ago

Patch Changes

  • #570 104c4a7 Thanks @threepointone! - Update for the latest @tanstack/ai adapter API and refresh Workers AI model references.

    • Use the new provider summarize factory functions (createAnthropicSummarize, createGeminiSummarize, createGrokSummarize, createOpenaiSummarize, createOpenRouterSummarize) instead of the removed *SummarizeAdapter classes, and give the gateway create*Summarize wrappers explicit AnySummarizeAdapter return types so declaration files generate cleanly.
    • Migrate the Workers AI streaming adapter to the EventType enum and the updated TextOptions shape (sampling knobs such as temperature/max_tokens now flow through modelOptions; systemPrompts accepts SystemPrompt objects).
    • Align the image, transcription, and TTS adapters with the new (model, config?) base-adapter constructor signature.
    • Update default/example Workers AI model references to current models (@cf/google/gemma-4-26b-a4b-it, @cf/moonshotai/kimi-k2.7-code), replacing deprecated ones.
  • #572 667873f Thanks @threepointone! - Fix broken streamed tool calls in the Workers AI adapter (#523).

    Some Workers AI models stream a tool call's argument fragments before the function name arrives. The adapter buffers those fragments while waiting for the name (it must, because TanStack AI's StreamProcessor reads the tool name only once, from TOOL_CALL_START), but it previously dropped the buffered prefix and forwarded only the post-name fragment. The result was a tool-call message part with truncated/empty arguments (and, in earlier versions, a missing name), so tool dispatch silently failed.

    The adapter now tracks how many argument characters have been emitted and flushes any buffered fragments via TOOL_CALL_ARGS as soon as TOOL_CALL_START is emitted, guaranteeing the full argument string and the tool name reach the consumer regardless of the order in which the model streams name and arguments.

Don't miss a new ai release

NewReleases is sending notifications on new releases.