@ai-sdk/cohere 2.0.8 → 2.0.9
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 +8 -0
- package/dist/index.d.mts +13 -2
- package/dist/index.d.ts +13 -2
- package/dist/index.js +208 -120
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +211 -122
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -13,15 +13,33 @@ import {
|
|
|
13
13
|
combineHeaders,
|
|
14
14
|
createEventSourceResponseHandler,
|
|
15
15
|
createJsonResponseHandler,
|
|
16
|
+
parseProviderOptions,
|
|
16
17
|
postJsonToApi
|
|
17
18
|
} from "@ai-sdk/provider-utils";
|
|
18
|
-
import { z as
|
|
19
|
+
import { z as z3 } from "zod/v4";
|
|
20
|
+
|
|
21
|
+
// src/cohere-chat-options.ts
|
|
22
|
+
import { z } from "zod/v4";
|
|
23
|
+
var cohereChatModelOptions = z.object({
|
|
24
|
+
/**
|
|
25
|
+
* Configuration for reasoning features (optional)
|
|
26
|
+
*
|
|
27
|
+
* Can be set to an object with the two properties `type` and `tokenBudget`. `type` can be set to `'enabled'` or `'disabled'` (defaults to `'enabled'`).
|
|
28
|
+
* `tokenBudget` is the maximum number of tokens the model can use for thinking, which must be set to a positive integer. The model will stop thinking if it reaches the thinking token budget and will proceed with the response
|
|
29
|
+
*
|
|
30
|
+
* @see https://docs.cohere.com/reference/chat#request.body.thinking
|
|
31
|
+
*/
|
|
32
|
+
thinking: z.object({
|
|
33
|
+
type: z.enum(["enabled", "disabled"]).optional(),
|
|
34
|
+
tokenBudget: z.number().optional()
|
|
35
|
+
}).optional()
|
|
36
|
+
});
|
|
19
37
|
|
|
20
38
|
// src/cohere-error.ts
|
|
21
39
|
import { createJsonErrorResponseHandler } from "@ai-sdk/provider-utils";
|
|
22
|
-
import { z } from "zod/v4";
|
|
23
|
-
var cohereErrorDataSchema =
|
|
24
|
-
message:
|
|
40
|
+
import { z as z2 } from "zod/v4";
|
|
41
|
+
var cohereErrorDataSchema = z2.object({
|
|
42
|
+
message: z2.string()
|
|
25
43
|
});
|
|
26
44
|
var cohereFailedResponseHandler = createJsonErrorResponseHandler({
|
|
27
45
|
errorSchema: cohereErrorDataSchema,
|
|
@@ -232,7 +250,7 @@ var CohereChatLanguageModel = class {
|
|
|
232
250
|
get provider() {
|
|
233
251
|
return this.config.provider;
|
|
234
252
|
}
|
|
235
|
-
getArgs({
|
|
253
|
+
async getArgs({
|
|
236
254
|
prompt,
|
|
237
255
|
maxOutputTokens,
|
|
238
256
|
temperature,
|
|
@@ -244,8 +262,15 @@ var CohereChatLanguageModel = class {
|
|
|
244
262
|
responseFormat,
|
|
245
263
|
seed,
|
|
246
264
|
tools,
|
|
247
|
-
toolChoice
|
|
265
|
+
toolChoice,
|
|
266
|
+
providerOptions
|
|
248
267
|
}) {
|
|
268
|
+
var _a, _b;
|
|
269
|
+
const cohereOptions = (_a = await parseProviderOptions({
|
|
270
|
+
provider: "cohere",
|
|
271
|
+
providerOptions,
|
|
272
|
+
schema: cohereChatModelOptions
|
|
273
|
+
})) != null ? _a : {};
|
|
249
274
|
const {
|
|
250
275
|
messages: chatPrompt,
|
|
251
276
|
documents: cohereDocuments,
|
|
@@ -277,14 +302,21 @@ var CohereChatLanguageModel = class {
|
|
|
277
302
|
tools: cohereTools,
|
|
278
303
|
tool_choice: cohereToolChoice,
|
|
279
304
|
// documents for RAG:
|
|
280
|
-
...cohereDocuments.length > 0 && { documents: cohereDocuments }
|
|
305
|
+
...cohereDocuments.length > 0 && { documents: cohereDocuments },
|
|
306
|
+
// reasoning
|
|
307
|
+
...cohereOptions.thinking && {
|
|
308
|
+
thinking: {
|
|
309
|
+
type: (_b = cohereOptions.thinking.type) != null ? _b : "enabled",
|
|
310
|
+
token_budget: cohereOptions.thinking.tokenBudget
|
|
311
|
+
}
|
|
312
|
+
}
|
|
281
313
|
},
|
|
282
314
|
warnings: [...toolWarnings, ...promptWarnings]
|
|
283
315
|
};
|
|
284
316
|
}
|
|
285
317
|
async doGenerate(options) {
|
|
286
|
-
var _a, _b, _c, _d, _e, _f
|
|
287
|
-
const { args, warnings } = this.getArgs(options);
|
|
318
|
+
var _a, _b, _c, _d, _e, _f;
|
|
319
|
+
const { args, warnings } = await this.getArgs(options);
|
|
288
320
|
const {
|
|
289
321
|
responseHeaders,
|
|
290
322
|
value: response,
|
|
@@ -301,16 +333,23 @@ var CohereChatLanguageModel = class {
|
|
|
301
333
|
fetch: this.config.fetch
|
|
302
334
|
});
|
|
303
335
|
const content = [];
|
|
304
|
-
|
|
305
|
-
|
|
336
|
+
for (const item of (_a = response.message.content) != null ? _a : []) {
|
|
337
|
+
if (item.type === "text" && item.text.length > 0) {
|
|
338
|
+
content.push({ type: "text", text: item.text });
|
|
339
|
+
continue;
|
|
340
|
+
}
|
|
341
|
+
if (item.type === "thinking" && item.thinking.length > 0) {
|
|
342
|
+
content.push({ type: "reasoning", text: item.thinking });
|
|
343
|
+
continue;
|
|
344
|
+
}
|
|
306
345
|
}
|
|
307
|
-
for (const citation of (
|
|
346
|
+
for (const citation of (_b = response.message.citations) != null ? _b : []) {
|
|
308
347
|
content.push({
|
|
309
348
|
type: "source",
|
|
310
349
|
sourceType: "document",
|
|
311
350
|
id: this.config.generateId(),
|
|
312
351
|
mediaType: "text/plain",
|
|
313
|
-
title: ((
|
|
352
|
+
title: ((_d = (_c = citation.sources[0]) == null ? void 0 : _c.document) == null ? void 0 : _d.title) || "Document",
|
|
314
353
|
providerMetadata: {
|
|
315
354
|
cohere: {
|
|
316
355
|
start: citation.start,
|
|
@@ -322,7 +361,7 @@ var CohereChatLanguageModel = class {
|
|
|
322
361
|
}
|
|
323
362
|
});
|
|
324
363
|
}
|
|
325
|
-
for (const toolCall of (
|
|
364
|
+
for (const toolCall of (_e = response.message.tool_calls) != null ? _e : []) {
|
|
326
365
|
content.push({
|
|
327
366
|
type: "tool-call",
|
|
328
367
|
toolCallId: toolCall.id,
|
|
@@ -343,7 +382,7 @@ var CohereChatLanguageModel = class {
|
|
|
343
382
|
request: { body: args },
|
|
344
383
|
response: {
|
|
345
384
|
// TODO timestamp, model id
|
|
346
|
-
id: (
|
|
385
|
+
id: (_f = response.generation_id) != null ? _f : void 0,
|
|
347
386
|
headers: responseHeaders,
|
|
348
387
|
body: rawResponse
|
|
349
388
|
},
|
|
@@ -351,7 +390,7 @@ var CohereChatLanguageModel = class {
|
|
|
351
390
|
};
|
|
352
391
|
}
|
|
353
392
|
async doStream(options) {
|
|
354
|
-
const { args, warnings } = this.getArgs(options);
|
|
393
|
+
const { args, warnings } = await this.getArgs(options);
|
|
355
394
|
const { responseHeaders, value: response } = await postJsonToApi({
|
|
356
395
|
url: `${this.config.baseURL}/chat`,
|
|
357
396
|
headers: combineHeaders(this.config.headers(), options.headers),
|
|
@@ -370,6 +409,7 @@ var CohereChatLanguageModel = class {
|
|
|
370
409
|
totalTokens: void 0
|
|
371
410
|
};
|
|
372
411
|
let pendingToolCall = null;
|
|
412
|
+
let isActiveReasoning = false;
|
|
373
413
|
return {
|
|
374
414
|
stream: response.pipeThrough(
|
|
375
415
|
new TransformStream({
|
|
@@ -390,6 +430,14 @@ var CohereChatLanguageModel = class {
|
|
|
390
430
|
const type = value.type;
|
|
391
431
|
switch (type) {
|
|
392
432
|
case "content-start": {
|
|
433
|
+
if (value.delta.message.content.type === "thinking") {
|
|
434
|
+
controller.enqueue({
|
|
435
|
+
type: "reasoning-start",
|
|
436
|
+
id: String(value.index)
|
|
437
|
+
});
|
|
438
|
+
isActiveReasoning = true;
|
|
439
|
+
return;
|
|
440
|
+
}
|
|
393
441
|
controller.enqueue({
|
|
394
442
|
type: "text-start",
|
|
395
443
|
id: String(value.index)
|
|
@@ -397,6 +445,14 @@ var CohereChatLanguageModel = class {
|
|
|
397
445
|
return;
|
|
398
446
|
}
|
|
399
447
|
case "content-delta": {
|
|
448
|
+
if ("thinking" in value.delta.message.content) {
|
|
449
|
+
controller.enqueue({
|
|
450
|
+
type: "reasoning-delta",
|
|
451
|
+
id: String(value.index),
|
|
452
|
+
delta: value.delta.message.content.thinking
|
|
453
|
+
});
|
|
454
|
+
return;
|
|
455
|
+
}
|
|
400
456
|
controller.enqueue({
|
|
401
457
|
type: "text-delta",
|
|
402
458
|
id: String(value.index),
|
|
@@ -405,6 +461,14 @@ var CohereChatLanguageModel = class {
|
|
|
405
461
|
return;
|
|
406
462
|
}
|
|
407
463
|
case "content-end": {
|
|
464
|
+
if (isActiveReasoning) {
|
|
465
|
+
controller.enqueue({
|
|
466
|
+
type: "reasoning-end",
|
|
467
|
+
id: String(value.index)
|
|
468
|
+
});
|
|
469
|
+
isActiveReasoning = false;
|
|
470
|
+
return;
|
|
471
|
+
}
|
|
408
472
|
controller.enqueue({
|
|
409
473
|
type: "text-end",
|
|
410
474
|
id: String(value.index)
|
|
@@ -500,120 +564,145 @@ var CohereChatLanguageModel = class {
|
|
|
500
564
|
};
|
|
501
565
|
}
|
|
502
566
|
};
|
|
503
|
-
var cohereChatResponseSchema =
|
|
504
|
-
generation_id:
|
|
505
|
-
message:
|
|
506
|
-
role:
|
|
507
|
-
content:
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
567
|
+
var cohereChatResponseSchema = z3.object({
|
|
568
|
+
generation_id: z3.string().nullish(),
|
|
569
|
+
message: z3.object({
|
|
570
|
+
role: z3.string(),
|
|
571
|
+
content: z3.array(
|
|
572
|
+
z3.union([
|
|
573
|
+
z3.object({
|
|
574
|
+
type: z3.literal("text"),
|
|
575
|
+
text: z3.string()
|
|
576
|
+
}),
|
|
577
|
+
z3.object({
|
|
578
|
+
type: z3.literal("thinking"),
|
|
579
|
+
thinking: z3.string()
|
|
580
|
+
})
|
|
581
|
+
])
|
|
512
582
|
).nullish(),
|
|
513
|
-
tool_plan:
|
|
514
|
-
tool_calls:
|
|
515
|
-
|
|
516
|
-
id:
|
|
517
|
-
type:
|
|
518
|
-
function:
|
|
519
|
-
name:
|
|
520
|
-
arguments:
|
|
583
|
+
tool_plan: z3.string().nullish(),
|
|
584
|
+
tool_calls: z3.array(
|
|
585
|
+
z3.object({
|
|
586
|
+
id: z3.string(),
|
|
587
|
+
type: z3.literal("function"),
|
|
588
|
+
function: z3.object({
|
|
589
|
+
name: z3.string(),
|
|
590
|
+
arguments: z3.string()
|
|
521
591
|
})
|
|
522
592
|
})
|
|
523
593
|
).nullish(),
|
|
524
|
-
citations:
|
|
525
|
-
|
|
526
|
-
start:
|
|
527
|
-
end:
|
|
528
|
-
text:
|
|
529
|
-
sources:
|
|
530
|
-
|
|
531
|
-
type:
|
|
532
|
-
id:
|
|
533
|
-
document:
|
|
534
|
-
id:
|
|
535
|
-
text:
|
|
536
|
-
title:
|
|
594
|
+
citations: z3.array(
|
|
595
|
+
z3.object({
|
|
596
|
+
start: z3.number(),
|
|
597
|
+
end: z3.number(),
|
|
598
|
+
text: z3.string(),
|
|
599
|
+
sources: z3.array(
|
|
600
|
+
z3.object({
|
|
601
|
+
type: z3.string().optional(),
|
|
602
|
+
id: z3.string().optional(),
|
|
603
|
+
document: z3.object({
|
|
604
|
+
id: z3.string().optional(),
|
|
605
|
+
text: z3.string(),
|
|
606
|
+
title: z3.string()
|
|
537
607
|
})
|
|
538
608
|
})
|
|
539
609
|
),
|
|
540
|
-
type:
|
|
610
|
+
type: z3.string().optional()
|
|
541
611
|
})
|
|
542
612
|
).nullish()
|
|
543
613
|
}),
|
|
544
|
-
finish_reason:
|
|
545
|
-
usage:
|
|
546
|
-
billed_units:
|
|
547
|
-
input_tokens:
|
|
548
|
-
output_tokens:
|
|
614
|
+
finish_reason: z3.string(),
|
|
615
|
+
usage: z3.object({
|
|
616
|
+
billed_units: z3.object({
|
|
617
|
+
input_tokens: z3.number(),
|
|
618
|
+
output_tokens: z3.number()
|
|
549
619
|
}),
|
|
550
|
-
tokens:
|
|
551
|
-
input_tokens:
|
|
552
|
-
output_tokens:
|
|
620
|
+
tokens: z3.object({
|
|
621
|
+
input_tokens: z3.number(),
|
|
622
|
+
output_tokens: z3.number()
|
|
553
623
|
})
|
|
554
624
|
})
|
|
555
625
|
});
|
|
556
|
-
var cohereChatChunkSchema =
|
|
557
|
-
|
|
558
|
-
type:
|
|
626
|
+
var cohereChatChunkSchema = z3.discriminatedUnion("type", [
|
|
627
|
+
z3.object({
|
|
628
|
+
type: z3.literal("citation-start")
|
|
559
629
|
}),
|
|
560
|
-
|
|
561
|
-
type:
|
|
630
|
+
z3.object({
|
|
631
|
+
type: z3.literal("citation-end")
|
|
562
632
|
}),
|
|
563
|
-
|
|
564
|
-
type:
|
|
565
|
-
index:
|
|
633
|
+
z3.object({
|
|
634
|
+
type: z3.literal("content-start"),
|
|
635
|
+
index: z3.number(),
|
|
636
|
+
delta: z3.object({
|
|
637
|
+
message: z3.object({
|
|
638
|
+
content: z3.union([
|
|
639
|
+
z3.object({
|
|
640
|
+
type: z3.literal("text"),
|
|
641
|
+
text: z3.string()
|
|
642
|
+
}),
|
|
643
|
+
z3.object({
|
|
644
|
+
type: z3.literal("thinking"),
|
|
645
|
+
thinking: z3.string()
|
|
646
|
+
})
|
|
647
|
+
])
|
|
648
|
+
})
|
|
649
|
+
})
|
|
566
650
|
}),
|
|
567
|
-
|
|
568
|
-
type:
|
|
569
|
-
index:
|
|
570
|
-
delta:
|
|
571
|
-
message:
|
|
572
|
-
content:
|
|
573
|
-
|
|
574
|
-
|
|
651
|
+
z3.object({
|
|
652
|
+
type: z3.literal("content-delta"),
|
|
653
|
+
index: z3.number(),
|
|
654
|
+
delta: z3.object({
|
|
655
|
+
message: z3.object({
|
|
656
|
+
content: z3.union([
|
|
657
|
+
z3.object({
|
|
658
|
+
text: z3.string()
|
|
659
|
+
}),
|
|
660
|
+
z3.object({
|
|
661
|
+
thinking: z3.string()
|
|
662
|
+
})
|
|
663
|
+
])
|
|
575
664
|
})
|
|
576
665
|
})
|
|
577
666
|
}),
|
|
578
|
-
|
|
579
|
-
type:
|
|
580
|
-
index:
|
|
667
|
+
z3.object({
|
|
668
|
+
type: z3.literal("content-end"),
|
|
669
|
+
index: z3.number()
|
|
581
670
|
}),
|
|
582
|
-
|
|
583
|
-
type:
|
|
584
|
-
id:
|
|
671
|
+
z3.object({
|
|
672
|
+
type: z3.literal("message-start"),
|
|
673
|
+
id: z3.string().nullish()
|
|
585
674
|
}),
|
|
586
|
-
|
|
587
|
-
type:
|
|
588
|
-
delta:
|
|
589
|
-
finish_reason:
|
|
590
|
-
usage:
|
|
591
|
-
tokens:
|
|
592
|
-
input_tokens:
|
|
593
|
-
output_tokens:
|
|
675
|
+
z3.object({
|
|
676
|
+
type: z3.literal("message-end"),
|
|
677
|
+
delta: z3.object({
|
|
678
|
+
finish_reason: z3.string(),
|
|
679
|
+
usage: z3.object({
|
|
680
|
+
tokens: z3.object({
|
|
681
|
+
input_tokens: z3.number(),
|
|
682
|
+
output_tokens: z3.number()
|
|
594
683
|
})
|
|
595
684
|
})
|
|
596
685
|
})
|
|
597
686
|
}),
|
|
598
687
|
// https://docs.cohere.com/v2/docs/streaming#tool-use-stream-events-for-tool-calling
|
|
599
|
-
|
|
600
|
-
type:
|
|
601
|
-
delta:
|
|
602
|
-
message:
|
|
603
|
-
tool_plan:
|
|
688
|
+
z3.object({
|
|
689
|
+
type: z3.literal("tool-plan-delta"),
|
|
690
|
+
delta: z3.object({
|
|
691
|
+
message: z3.object({
|
|
692
|
+
tool_plan: z3.string()
|
|
604
693
|
})
|
|
605
694
|
})
|
|
606
695
|
}),
|
|
607
|
-
|
|
608
|
-
type:
|
|
609
|
-
delta:
|
|
610
|
-
message:
|
|
611
|
-
tool_calls:
|
|
612
|
-
id:
|
|
613
|
-
type:
|
|
614
|
-
function:
|
|
615
|
-
name:
|
|
616
|
-
arguments:
|
|
696
|
+
z3.object({
|
|
697
|
+
type: z3.literal("tool-call-start"),
|
|
698
|
+
delta: z3.object({
|
|
699
|
+
message: z3.object({
|
|
700
|
+
tool_calls: z3.object({
|
|
701
|
+
id: z3.string(),
|
|
702
|
+
type: z3.literal("function"),
|
|
703
|
+
function: z3.object({
|
|
704
|
+
name: z3.string(),
|
|
705
|
+
arguments: z3.string()
|
|
617
706
|
})
|
|
618
707
|
})
|
|
619
708
|
})
|
|
@@ -622,20 +711,20 @@ var cohereChatChunkSchema = z2.discriminatedUnion("type", [
|
|
|
622
711
|
// A single tool call's `arguments` stream in chunks and must be accumulated
|
|
623
712
|
// in a string and so the full tool object info can only be parsed once we see
|
|
624
713
|
// `tool-call-end`.
|
|
625
|
-
|
|
626
|
-
type:
|
|
627
|
-
delta:
|
|
628
|
-
message:
|
|
629
|
-
tool_calls:
|
|
630
|
-
function:
|
|
631
|
-
arguments:
|
|
714
|
+
z3.object({
|
|
715
|
+
type: z3.literal("tool-call-delta"),
|
|
716
|
+
delta: z3.object({
|
|
717
|
+
message: z3.object({
|
|
718
|
+
tool_calls: z3.object({
|
|
719
|
+
function: z3.object({
|
|
720
|
+
arguments: z3.string()
|
|
632
721
|
})
|
|
633
722
|
})
|
|
634
723
|
})
|
|
635
724
|
})
|
|
636
725
|
}),
|
|
637
|
-
|
|
638
|
-
type:
|
|
726
|
+
z3.object({
|
|
727
|
+
type: z3.literal("tool-call-end")
|
|
639
728
|
})
|
|
640
729
|
]);
|
|
641
730
|
|
|
@@ -646,14 +735,14 @@ import {
|
|
|
646
735
|
import {
|
|
647
736
|
combineHeaders as combineHeaders2,
|
|
648
737
|
createJsonResponseHandler as createJsonResponseHandler2,
|
|
649
|
-
parseProviderOptions,
|
|
738
|
+
parseProviderOptions as parseProviderOptions2,
|
|
650
739
|
postJsonToApi as postJsonToApi2
|
|
651
740
|
} from "@ai-sdk/provider-utils";
|
|
652
|
-
import { z as
|
|
741
|
+
import { z as z5 } from "zod/v4";
|
|
653
742
|
|
|
654
743
|
// src/cohere-embedding-options.ts
|
|
655
|
-
import { z as
|
|
656
|
-
var cohereEmbeddingOptions =
|
|
744
|
+
import { z as z4 } from "zod/v4";
|
|
745
|
+
var cohereEmbeddingOptions = z4.object({
|
|
657
746
|
/**
|
|
658
747
|
* Specifies the type of input passed to the model. Default is `search_query`.
|
|
659
748
|
*
|
|
@@ -662,7 +751,7 @@ var cohereEmbeddingOptions = z3.object({
|
|
|
662
751
|
* - "classification": Used for embeddings passed through a text classifier.
|
|
663
752
|
* - "clustering": Used for embeddings run through a clustering algorithm.
|
|
664
753
|
*/
|
|
665
|
-
inputType:
|
|
754
|
+
inputType: z4.enum(["search_document", "search_query", "classification", "clustering"]).optional(),
|
|
666
755
|
/**
|
|
667
756
|
* Specifies how the API will handle inputs longer than the maximum token length.
|
|
668
757
|
* Default is `END`.
|
|
@@ -671,7 +760,7 @@ var cohereEmbeddingOptions = z3.object({
|
|
|
671
760
|
* - "START": Will discard the start of the input until the remaining input is exactly the maximum input token length for the model.
|
|
672
761
|
* - "END": Will discard the end of the input until the remaining input is exactly the maximum input token length for the model.
|
|
673
762
|
*/
|
|
674
|
-
truncate:
|
|
763
|
+
truncate: z4.enum(["NONE", "START", "END"]).optional()
|
|
675
764
|
});
|
|
676
765
|
|
|
677
766
|
// src/cohere-embedding-model.ts
|
|
@@ -693,7 +782,7 @@ var CohereEmbeddingModel = class {
|
|
|
693
782
|
providerOptions
|
|
694
783
|
}) {
|
|
695
784
|
var _a;
|
|
696
|
-
const embeddingOptions = await
|
|
785
|
+
const embeddingOptions = await parseProviderOptions2({
|
|
697
786
|
provider: "cohere",
|
|
698
787
|
providerOptions,
|
|
699
788
|
schema: cohereEmbeddingOptions
|
|
@@ -737,13 +826,13 @@ var CohereEmbeddingModel = class {
|
|
|
737
826
|
};
|
|
738
827
|
}
|
|
739
828
|
};
|
|
740
|
-
var cohereTextEmbeddingResponseSchema =
|
|
741
|
-
embeddings:
|
|
742
|
-
float:
|
|
829
|
+
var cohereTextEmbeddingResponseSchema = z5.object({
|
|
830
|
+
embeddings: z5.object({
|
|
831
|
+
float: z5.array(z5.array(z5.number()))
|
|
743
832
|
}),
|
|
744
|
-
meta:
|
|
745
|
-
billed_units:
|
|
746
|
-
input_tokens:
|
|
833
|
+
meta: z5.object({
|
|
834
|
+
billed_units: z5.object({
|
|
835
|
+
input_tokens: z5.number()
|
|
747
836
|
})
|
|
748
837
|
})
|
|
749
838
|
});
|