@ai-sdk/openai 2.0.85 → 2.0.86

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.
@@ -287,10 +287,12 @@ var openaiChatResponseSchema = lazyValidator(
287
287
  annotations: z2.array(
288
288
  z2.object({
289
289
  type: z2.literal("url_citation"),
290
- start_index: z2.number(),
291
- end_index: z2.number(),
292
- url: z2.string(),
293
- title: z2.string()
290
+ url_citation: z2.object({
291
+ start_index: z2.number(),
292
+ end_index: z2.number(),
293
+ url: z2.string(),
294
+ title: z2.string()
295
+ })
294
296
  })
295
297
  ).nullish()
296
298
  }),
@@ -354,10 +356,12 @@ var openaiChatChunkSchema = lazyValidator(
354
356
  annotations: z2.array(
355
357
  z2.object({
356
358
  type: z2.literal("url_citation"),
357
- start_index: z2.number(),
358
- end_index: z2.number(),
359
- url: z2.string(),
360
- title: z2.string()
359
+ url_citation: z2.object({
360
+ start_index: z2.number(),
361
+ end_index: z2.number(),
362
+ url: z2.string(),
363
+ title: z2.string()
364
+ })
361
365
  })
362
366
  ).nullish()
363
367
  }).nullish(),
@@ -816,8 +820,8 @@ var OpenAIChatLanguageModel = class {
816
820
  type: "source",
817
821
  sourceType: "url",
818
822
  id: generateId(),
819
- url: annotation.url,
820
- title: annotation.title
823
+ url: annotation.url_citation.url,
824
+ title: annotation.url_citation.title
821
825
  });
822
826
  }
823
827
  const completionTokenDetails = (_d = response.usage) == null ? void 0 : _d.completion_tokens_details;
@@ -1046,8 +1050,8 @@ var OpenAIChatLanguageModel = class {
1046
1050
  type: "source",
1047
1051
  sourceType: "url",
1048
1052
  id: generateId(),
1049
- url: annotation.url,
1050
- title: annotation.title
1053
+ url: annotation.url_citation.url,
1054
+ title: annotation.url_citation.title
1051
1055
  });
1052
1056
  }
1053
1057
  }