@ai-sdk/google 2.0.35 → 2.0.36
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 +6 -0
- package/dist/index.js +3 -9
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -9
- package/dist/index.mjs.map +1 -1
- package/dist/internal/index.js +2 -8
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/index.mjs +2 -8
- package/dist/internal/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
} from "@ai-sdk/provider-utils";
|
|
8
8
|
|
|
9
9
|
// src/version.ts
|
|
10
|
-
var VERSION = true ? "2.0.
|
|
10
|
+
var VERSION = true ? "2.0.36" : "0.0.0-test";
|
|
11
11
|
|
|
12
12
|
// src/google-generative-ai-embedding-model.ts
|
|
13
13
|
import {
|
|
@@ -823,19 +823,13 @@ var GoogleGenerativeAILanguageModel = class {
|
|
|
823
823
|
toolChoice,
|
|
824
824
|
providerOptions
|
|
825
825
|
}) {
|
|
826
|
-
var _a
|
|
826
|
+
var _a;
|
|
827
827
|
const warnings = [];
|
|
828
828
|
const googleOptions = await parseProviderOptions2({
|
|
829
829
|
provider: "google",
|
|
830
830
|
providerOptions,
|
|
831
831
|
schema: googleGenerativeAIProviderOptions
|
|
832
832
|
});
|
|
833
|
-
if (((_a = googleOptions == null ? void 0 : googleOptions.thinkingConfig) == null ? void 0 : _a.includeThoughts) === true && !this.config.provider.startsWith("google.vertex.")) {
|
|
834
|
-
warnings.push({
|
|
835
|
-
type: "other",
|
|
836
|
-
message: `The 'includeThoughts' option is only supported with the Google Vertex provider and might not be supported or could behave unexpectedly with the current Google provider (${this.config.provider}).`
|
|
837
|
-
});
|
|
838
|
-
}
|
|
839
833
|
if ((tools == null ? void 0 : tools.some(
|
|
840
834
|
(tool) => tool.type === "provider-defined" && tool.id === "google.vertex_rag_store"
|
|
841
835
|
)) && !this.config.provider.startsWith("google.vertex.")) {
|
|
@@ -875,7 +869,7 @@ var GoogleGenerativeAILanguageModel = class {
|
|
|
875
869
|
responseSchema: (responseFormat == null ? void 0 : responseFormat.type) === "json" && responseFormat.schema != null && // Google GenAI does not support all OpenAPI Schema features,
|
|
876
870
|
// so this is needed as an escape hatch:
|
|
877
871
|
// TODO convert into provider option
|
|
878
|
-
((
|
|
872
|
+
((_a = googleOptions == null ? void 0 : googleOptions.structuredOutputs) != null ? _a : true) ? convertJSONSchemaToOpenAPISchema(responseFormat.schema) : void 0,
|
|
879
873
|
...(googleOptions == null ? void 0 : googleOptions.audioTimestamp) && {
|
|
880
874
|
audioTimestamp: googleOptions.audioTimestamp
|
|
881
875
|
},
|