Packages

@ai-sdk/google

4.0.122 · 17 Nov 2026Apache-2.014.6M / weekRepositoryHomepagenpmAtom feed

Your version

3.0.0

major22 Dec 2025Where it was published

3.0.147 is the newest release of 3.x.

In short

1 breaking26 new22 fixed8 internal

  • Breaking

    Ai SDK 6 beta

Release note

Major Changes

  • Breaking

    Ai SDK 6 beta

Patch Changes

  • provider: Add specificationVersion to ProviderV3

  • provider: Shared spec v3

  • google: thinking_level option for Gemini 3

  • provider/google: Preserve nested empty object schemas and descriptions in tool parameters

  • feat(openai); update spec for mcp approval

  • The mediaResolution option has been added and is now passed to the Google API.

  • Support latest gemini model id

  • Add Google Maps grounding tool support for location-aware Gemini responses

  • Fixed Zod validation error when using google.tools.fileSearch(). The Google File Search API returns fileSearchStore instead of uri in retrievedContext. Updated extractSources() function to handle both the old format (Google Search with uri) and new format (File Search with fileSearchStore), maintaining backward compatibility while preventing validation errors. Also fixed title handling to use undefined for URL sources and 'Unknown Document' for document sources.

  • google: Use dynamic providerOptionsName when retrieving thoughtSignature in convertToGoogleGenerativeAIMessages

    When using @ai-sdk/google-vertex provider with Gemini thinking models, multi-step tool calls would fail with "function call is missing a thought_signature" error. This was because thoughtSignature was stored under providerOptions.vertex but retrieved using hardcoded providerOptions.google. This fix passes providerOptionsName to convertToGoogleGenerativeAIMessages and uses it dynamically.

  • openai: Allow custom names for provider-defined tools

  • Add Google Vertex RAG Engine grounding provider tool

  • EmbeddingModelV3

  • Fix adding google search along with url context in vertex ai

  • provider/google: Remove includethoughts warning

  • Change streamText loop to merge file part processing into main parts loop

  • provider/google: Add support for the imageSize provider option

  • Support for custom provider name in google and anthropic providers

  • Tool execution approval

  • Provider-V3

  • Extended token usage

  • Add provider version to user-agent header

  • Improve error message when mixing function tools with provider-defined tools to clarify fallback behavior and list ignored function tools

  • LanguageModelV3

  • provider/google: Lazy schema loading

    import time improved by 12.5% (22.3ms ➡️ 19.5ms)

  • provider/google: Add enterpriseWebSearch tool

  • google: Add thought signature to gemini 3 pro image parts

  • Image editing

  • provider/google: Preserve thoughtSignature through tool execution

  • vertex: Allow 'vertex' as a key for providerOptions

  • Add promptFeedback outputs

  • Prepare search tool for gemini-3-pro-preview

  • Add Google File search tool

  • Add gemini-3-pro-preview and gemini-3-pro-image-preview model IDs

  • vertex: Support 'trafficType' in provider usageMetadata

  • Support imageConfig.aspectRatio configuration for Gemini models

  • Add gemini 3 pro

  • provider/google: Preserve nested empty object schemas in tool parameters to fix "property is not defined" validation errors when using required properties with empty object types

  • ImageModelV3

  • Update gemini 3 model id

  • google: Return request as object

  • Flexible tool output content support

  • Expose raw finish reason

  • google: gemini-3-flash

  • Moved dependency @ai-sdk/test-server to devDependencies

  • @ai-sdk/google: Make title field optional in grounding metadata schema

  • google,google-vertex: Update known model IDs

  • Chore (provider/google): Add preview modelIds for gemini 2.5 flash and lite

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.