@ai-sdk/google 3.0.37 → 3.0.38
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 +22 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +22 -2
- package/dist/index.mjs.map +1 -1
- package/dist/internal/index.js +21 -1
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/index.mjs +21 -1
- package/dist/internal/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/google-generative-ai-language-model.ts +25 -0
package/CHANGELOG.md
CHANGED
package/dist/index.js
CHANGED
|
@@ -30,7 +30,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
30
30
|
var import_provider_utils16 = require("@ai-sdk/provider-utils");
|
|
31
31
|
|
|
32
32
|
// src/version.ts
|
|
33
|
-
var VERSION = true ? "3.0.
|
|
33
|
+
var VERSION = true ? "3.0.38" : "0.0.0-test";
|
|
34
34
|
|
|
35
35
|
// src/google-generative-ai-embedding-model.ts
|
|
36
36
|
var import_provider = require("@ai-sdk/provider");
|
|
@@ -1291,10 +1291,30 @@ var GoogleGenerativeAILanguageModel = class {
|
|
|
1291
1291
|
});
|
|
1292
1292
|
}
|
|
1293
1293
|
} else if ("inlineData" in part) {
|
|
1294
|
+
if (currentTextBlockId !== null) {
|
|
1295
|
+
controller.enqueue({
|
|
1296
|
+
type: "text-end",
|
|
1297
|
+
id: currentTextBlockId
|
|
1298
|
+
});
|
|
1299
|
+
currentTextBlockId = null;
|
|
1300
|
+
}
|
|
1301
|
+
if (currentReasoningBlockId !== null) {
|
|
1302
|
+
controller.enqueue({
|
|
1303
|
+
type: "reasoning-end",
|
|
1304
|
+
id: currentReasoningBlockId
|
|
1305
|
+
});
|
|
1306
|
+
currentReasoningBlockId = null;
|
|
1307
|
+
}
|
|
1308
|
+
const thoughtSignatureMetadata = part.thoughtSignature ? {
|
|
1309
|
+
[providerOptionsName]: {
|
|
1310
|
+
thoughtSignature: part.thoughtSignature
|
|
1311
|
+
}
|
|
1312
|
+
} : void 0;
|
|
1294
1313
|
controller.enqueue({
|
|
1295
1314
|
type: "file",
|
|
1296
1315
|
mediaType: part.inlineData.mimeType,
|
|
1297
|
-
data: part.inlineData.data
|
|
1316
|
+
data: part.inlineData.data,
|
|
1317
|
+
providerMetadata: thoughtSignatureMetadata
|
|
1298
1318
|
});
|
|
1299
1319
|
}
|
|
1300
1320
|
}
|