@ai-sdk/google 3.0.0-beta.20 → 3.0.0-beta.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # @ai-sdk/google
2
2
 
3
+ ## 3.0.0-beta.21
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [6306603]
8
+ - @ai-sdk/provider-utils@4.0.0-beta.16
9
+
3
10
  ## 3.0.0-beta.20
4
11
 
5
12
  ### Patch Changes
package/dist/index.d.mts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as _ai_sdk_provider_utils from '@ai-sdk/provider-utils';
2
- import { InferValidator, FetchFunction } from '@ai-sdk/provider-utils';
2
+ import { InferSchema, FetchFunction } from '@ai-sdk/provider-utils';
3
3
  import { ProviderV3, LanguageModelV3, ImageModelV3, EmbeddingModelV3 } from '@ai-sdk/provider';
4
4
 
5
5
  declare const googleErrorDataSchema: _ai_sdk_provider_utils.LazySchema<{
@@ -9,7 +9,7 @@ declare const googleErrorDataSchema: _ai_sdk_provider_utils.LazySchema<{
9
9
  status: string;
10
10
  };
11
11
  }>;
12
- type GoogleErrorData = InferValidator<typeof googleErrorDataSchema>;
12
+ type GoogleErrorData = InferSchema<typeof googleErrorDataSchema>;
13
13
 
14
14
  type GoogleGenerativeAIModelId = 'gemini-1.5-flash' | 'gemini-1.5-flash-latest' | 'gemini-1.5-flash-001' | 'gemini-1.5-flash-002' | 'gemini-1.5-flash-8b' | 'gemini-1.5-flash-8b-latest' | 'gemini-1.5-flash-8b-001' | 'gemini-1.5-pro' | 'gemini-1.5-pro-latest' | 'gemini-1.5-pro-001' | 'gemini-1.5-pro-002' | 'gemini-2.0-flash' | 'gemini-2.0-flash-001' | 'gemini-2.0-flash-live-001' | 'gemini-2.0-flash-lite' | 'gemini-2.0-pro-exp-02-05' | 'gemini-2.0-flash-thinking-exp-01-21' | 'gemini-2.0-flash-exp' | 'gemini-2.5-pro' | 'gemini-2.5-flash' | 'gemini-2.5-flash-image-preview' | 'gemini-2.5-flash-lite' | 'gemini-2.5-flash-lite-preview-09-2025' | 'gemini-2.5-flash-preview-04-17' | 'gemini-2.5-flash-preview-09-2025' | 'gemini-pro-latest' | 'gemini-flash-latest' | 'gemini-flash-lite-latest' | 'gemini-2.5-pro-exp-03-25' | 'gemini-exp-1206' | 'gemma-3-12b-it' | 'gemma-3-27b-it' | (string & {});
15
15
  declare const googleGenerativeAIProviderOptions: _ai_sdk_provider_utils.LazySchema<{
@@ -29,7 +29,7 @@ declare const googleGenerativeAIProviderOptions: _ai_sdk_provider_utils.LazySche
29
29
  labels?: Record<string, string> | undefined;
30
30
  mediaResolution?: "MEDIA_RESOLUTION_UNSPECIFIED" | "MEDIA_RESOLUTION_LOW" | "MEDIA_RESOLUTION_MEDIUM" | "MEDIA_RESOLUTION_HIGH" | undefined;
31
31
  }>;
32
- type GoogleGenerativeAIProviderOptions = InferValidator<typeof googleGenerativeAIProviderOptions>;
32
+ type GoogleGenerativeAIProviderOptions = InferSchema<typeof googleGenerativeAIProviderOptions>;
33
33
 
34
34
  declare const responseSchema: _ai_sdk_provider_utils.LazySchema<{
35
35
  candidates: {
@@ -126,9 +126,9 @@ declare const responseSchema: _ai_sdk_provider_utils.LazySchema<{
126
126
  }[] | null | undefined;
127
127
  } | null | undefined;
128
128
  }>;
129
- type GroundingMetadataSchema = NonNullable<InferValidator<typeof responseSchema>['candidates'][number]['groundingMetadata']>;
130
- type UrlContextMetadataSchema = NonNullable<InferValidator<typeof responseSchema>['candidates'][number]['urlContextMetadata']>;
131
- type SafetyRatingSchema = NonNullable<InferValidator<typeof responseSchema>['candidates'][number]['safetyRatings']>[number];
129
+ type GroundingMetadataSchema = NonNullable<InferSchema<typeof responseSchema>['candidates'][number]['groundingMetadata']>;
130
+ type UrlContextMetadataSchema = NonNullable<InferSchema<typeof responseSchema>['candidates'][number]['urlContextMetadata']>;
131
+ type SafetyRatingSchema = NonNullable<InferSchema<typeof responseSchema>['candidates'][number]['safetyRatings']>[number];
132
132
 
133
133
  type GoogleGenerativeAIGroundingMetadata = GroundingMetadataSchema;
134
134
  type GoogleGenerativeAIUrlContextMetadata = UrlContextMetadataSchema;
@@ -151,14 +151,14 @@ declare const googleImageProviderOptionsSchema: _ai_sdk_provider_utils.LazySchem
151
151
  personGeneration?: "dont_allow" | "allow_adult" | "allow_all" | null | undefined;
152
152
  aspectRatio?: "1:1" | "3:4" | "4:3" | "9:16" | "16:9" | null | undefined;
153
153
  }>;
154
- type GoogleGenerativeAIImageProviderOptions = InferValidator<typeof googleImageProviderOptionsSchema>;
154
+ type GoogleGenerativeAIImageProviderOptions = InferSchema<typeof googleImageProviderOptionsSchema>;
155
155
 
156
156
  type GoogleGenerativeAIEmbeddingModelId = 'gemini-embedding-001' | 'text-embedding-004' | (string & {});
157
157
  declare const googleGenerativeAIEmbeddingProviderOptions: _ai_sdk_provider_utils.LazySchema<{
158
158
  outputDimensionality?: number | undefined;
159
159
  taskType?: "SEMANTIC_SIMILARITY" | "CLASSIFICATION" | "CLUSTERING" | "RETRIEVAL_DOCUMENT" | "RETRIEVAL_QUERY" | "QUESTION_ANSWERING" | "FACT_VERIFICATION" | "CODE_RETRIEVAL_QUERY" | undefined;
160
160
  }>;
161
- type GoogleGenerativeAIEmbeddingProviderOptions = InferValidator<typeof googleGenerativeAIEmbeddingProviderOptions>;
161
+ type GoogleGenerativeAIEmbeddingProviderOptions = InferSchema<typeof googleGenerativeAIEmbeddingProviderOptions>;
162
162
 
163
163
  declare const googleTools: {
164
164
  /**
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as _ai_sdk_provider_utils from '@ai-sdk/provider-utils';
2
- import { InferValidator, FetchFunction } from '@ai-sdk/provider-utils';
2
+ import { InferSchema, FetchFunction } from '@ai-sdk/provider-utils';
3
3
  import { ProviderV3, LanguageModelV3, ImageModelV3, EmbeddingModelV3 } from '@ai-sdk/provider';
4
4
 
5
5
  declare const googleErrorDataSchema: _ai_sdk_provider_utils.LazySchema<{
@@ -9,7 +9,7 @@ declare const googleErrorDataSchema: _ai_sdk_provider_utils.LazySchema<{
9
9
  status: string;
10
10
  };
11
11
  }>;
12
- type GoogleErrorData = InferValidator<typeof googleErrorDataSchema>;
12
+ type GoogleErrorData = InferSchema<typeof googleErrorDataSchema>;
13
13
 
14
14
  type GoogleGenerativeAIModelId = 'gemini-1.5-flash' | 'gemini-1.5-flash-latest' | 'gemini-1.5-flash-001' | 'gemini-1.5-flash-002' | 'gemini-1.5-flash-8b' | 'gemini-1.5-flash-8b-latest' | 'gemini-1.5-flash-8b-001' | 'gemini-1.5-pro' | 'gemini-1.5-pro-latest' | 'gemini-1.5-pro-001' | 'gemini-1.5-pro-002' | 'gemini-2.0-flash' | 'gemini-2.0-flash-001' | 'gemini-2.0-flash-live-001' | 'gemini-2.0-flash-lite' | 'gemini-2.0-pro-exp-02-05' | 'gemini-2.0-flash-thinking-exp-01-21' | 'gemini-2.0-flash-exp' | 'gemini-2.5-pro' | 'gemini-2.5-flash' | 'gemini-2.5-flash-image-preview' | 'gemini-2.5-flash-lite' | 'gemini-2.5-flash-lite-preview-09-2025' | 'gemini-2.5-flash-preview-04-17' | 'gemini-2.5-flash-preview-09-2025' | 'gemini-pro-latest' | 'gemini-flash-latest' | 'gemini-flash-lite-latest' | 'gemini-2.5-pro-exp-03-25' | 'gemini-exp-1206' | 'gemma-3-12b-it' | 'gemma-3-27b-it' | (string & {});
15
15
  declare const googleGenerativeAIProviderOptions: _ai_sdk_provider_utils.LazySchema<{
@@ -29,7 +29,7 @@ declare const googleGenerativeAIProviderOptions: _ai_sdk_provider_utils.LazySche
29
29
  labels?: Record<string, string> | undefined;
30
30
  mediaResolution?: "MEDIA_RESOLUTION_UNSPECIFIED" | "MEDIA_RESOLUTION_LOW" | "MEDIA_RESOLUTION_MEDIUM" | "MEDIA_RESOLUTION_HIGH" | undefined;
31
31
  }>;
32
- type GoogleGenerativeAIProviderOptions = InferValidator<typeof googleGenerativeAIProviderOptions>;
32
+ type GoogleGenerativeAIProviderOptions = InferSchema<typeof googleGenerativeAIProviderOptions>;
33
33
 
34
34
  declare const responseSchema: _ai_sdk_provider_utils.LazySchema<{
35
35
  candidates: {
@@ -126,9 +126,9 @@ declare const responseSchema: _ai_sdk_provider_utils.LazySchema<{
126
126
  }[] | null | undefined;
127
127
  } | null | undefined;
128
128
  }>;
129
- type GroundingMetadataSchema = NonNullable<InferValidator<typeof responseSchema>['candidates'][number]['groundingMetadata']>;
130
- type UrlContextMetadataSchema = NonNullable<InferValidator<typeof responseSchema>['candidates'][number]['urlContextMetadata']>;
131
- type SafetyRatingSchema = NonNullable<InferValidator<typeof responseSchema>['candidates'][number]['safetyRatings']>[number];
129
+ type GroundingMetadataSchema = NonNullable<InferSchema<typeof responseSchema>['candidates'][number]['groundingMetadata']>;
130
+ type UrlContextMetadataSchema = NonNullable<InferSchema<typeof responseSchema>['candidates'][number]['urlContextMetadata']>;
131
+ type SafetyRatingSchema = NonNullable<InferSchema<typeof responseSchema>['candidates'][number]['safetyRatings']>[number];
132
132
 
133
133
  type GoogleGenerativeAIGroundingMetadata = GroundingMetadataSchema;
134
134
  type GoogleGenerativeAIUrlContextMetadata = UrlContextMetadataSchema;
@@ -151,14 +151,14 @@ declare const googleImageProviderOptionsSchema: _ai_sdk_provider_utils.LazySchem
151
151
  personGeneration?: "dont_allow" | "allow_adult" | "allow_all" | null | undefined;
152
152
  aspectRatio?: "1:1" | "3:4" | "4:3" | "9:16" | "16:9" | null | undefined;
153
153
  }>;
154
- type GoogleGenerativeAIImageProviderOptions = InferValidator<typeof googleImageProviderOptionsSchema>;
154
+ type GoogleGenerativeAIImageProviderOptions = InferSchema<typeof googleImageProviderOptionsSchema>;
155
155
 
156
156
  type GoogleGenerativeAIEmbeddingModelId = 'gemini-embedding-001' | 'text-embedding-004' | (string & {});
157
157
  declare const googleGenerativeAIEmbeddingProviderOptions: _ai_sdk_provider_utils.LazySchema<{
158
158
  outputDimensionality?: number | undefined;
159
159
  taskType?: "SEMANTIC_SIMILARITY" | "CLASSIFICATION" | "CLUSTERING" | "RETRIEVAL_DOCUMENT" | "RETRIEVAL_QUERY" | "QUESTION_ANSWERING" | "FACT_VERIFICATION" | "CODE_RETRIEVAL_QUERY" | undefined;
160
160
  }>;
161
- type GoogleGenerativeAIEmbeddingProviderOptions = InferValidator<typeof googleGenerativeAIEmbeddingProviderOptions>;
161
+ type GoogleGenerativeAIEmbeddingProviderOptions = InferSchema<typeof googleGenerativeAIEmbeddingProviderOptions>;
162
162
 
163
163
  declare const googleTools: {
164
164
  /**
package/dist/index.js CHANGED
@@ -30,7 +30,7 @@ module.exports = __toCommonJS(src_exports);
30
30
  var import_provider_utils11 = require("@ai-sdk/provider-utils");
31
31
 
32
32
  // src/version.ts
33
- var VERSION = true ? "3.0.0-beta.20" : "0.0.0-test";
33
+ var VERSION = true ? "3.0.0-beta.21" : "0.0.0-test";
34
34
 
35
35
  // src/google-generative-ai-embedding-model.ts
36
36
  var import_provider = require("@ai-sdk/provider");