Patch Changes
-
0b8cbfa:
generateTextandstreamTextpassed the messages array thatprepareStepreturned to tools and tool approval functions as it was. WhenprepareStepreturned the same array for several steps or calls, tool approval functions could not tell the tool calls of one model response from the tool calls of another. The messages array of every step is now created for that step, so the messages thatprepareStepreturns are copied. -
6815153: fix(ai): forward the
preliminaryflag on provider-executed tool results instreamText, so preliminary results (e.g. OpenAI image generation previews) are no longer recorded as final tool results in step content and response messages -
15bfd6b: add telemetry, runtime context and lifecycle callbacks to
experimental_extract -
15bfd6b: redact file urls from download errors sent to telemetry
-
2613bb4: fix(ai): build the
ai,ai/internal, andai/testentrypoints together so their types stay compatible with each other -
63593a7: With
experimental_toolApprovalSecretconfigured,generateTextandstreamTextsigned the approval request of a tool call that the tool approval policy had denied automatically. A client that controls the message history could send that request back with an approved response and have the denied tool call executed. Approval requests of automatically denied tool calls are no longer signed, so such a response is rejected withAI_InvalidToolApprovalSignatureError.Signatures that earlier versions issued for automatic denials stay valid. To invalidate them, rotate the secret passed to
experimental_toolApprovalSecret. Approval requests that are still waiting for a user decision then have to be requested again. -
Updated dependencies [1d2c2ff]
-
Updated dependencies [a51981c]
-
Updated dependencies [875de7b]
- @ai-sdk/provider-utils@5.0.83
- @ai-sdk/gateway@4.0.151