@ai-sdk/xai 2.0.66 → 2.0.67
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 +11 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +11 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -4
package/dist/index.mjs
CHANGED
|
@@ -1222,6 +1222,12 @@ var xaiResponsesChunkSchema = z4.union([
|
|
|
1222
1222
|
usage: xaiResponsesUsageSchema.nullish()
|
|
1223
1223
|
})
|
|
1224
1224
|
}),
|
|
1225
|
+
z4.object({
|
|
1226
|
+
type: z4.literal("error"),
|
|
1227
|
+
code: z4.string().nullish(),
|
|
1228
|
+
message: z4.string(),
|
|
1229
|
+
param: z4.string().nullish()
|
|
1230
|
+
}),
|
|
1225
1231
|
z4.object({
|
|
1226
1232
|
type: z4.literal("response.done"),
|
|
1227
1233
|
response: xaiResponsesResponseSchema
|
|
@@ -2117,6 +2123,10 @@ var XaiResponsesLanguageModel = class {
|
|
|
2117
2123
|
}
|
|
2118
2124
|
return;
|
|
2119
2125
|
}
|
|
2126
|
+
if (event.type === "error") {
|
|
2127
|
+
controller.enqueue({ type: "error", error: event });
|
|
2128
|
+
return;
|
|
2129
|
+
}
|
|
2120
2130
|
if (event.type === "response.function_call_arguments.delta") {
|
|
2121
2131
|
const toolCall = ongoingToolCalls[event.output_index];
|
|
2122
2132
|
if (toolCall != null) {
|
|
@@ -2344,7 +2354,7 @@ var xaiTools = {
|
|
|
2344
2354
|
};
|
|
2345
2355
|
|
|
2346
2356
|
// src/version.ts
|
|
2347
|
-
var VERSION = true ? "2.0.
|
|
2357
|
+
var VERSION = true ? "2.0.67" : "0.0.0-test";
|
|
2348
2358
|
|
|
2349
2359
|
// src/xai-provider.ts
|
|
2350
2360
|
var xaiErrorStructure = {
|