@opencode/ai 0.0.0-dev-1302 → 0.0.0-dev-1304
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/dist/cache-policy.js +4 -2
- package/dist/llm.d.ts +4 -1
- package/dist/llm.js +10 -1
- package/dist/protocols/alibaba-messages.d.ts +24 -2
- package/dist/protocols/alibaba-responses.d.ts +26 -0
- package/dist/protocols/anthropic-messages.d.ts +70 -6
- package/dist/protocols/anthropic-messages.js +74 -9
- package/dist/protocols/meta-messages.d.ts +24 -2
- package/dist/protocols/meta-responses.d.ts +52 -0
- package/dist/protocols/open-responses.d.ts +250 -24
- package/dist/protocols/open-responses.js +40 -24
- package/dist/protocols/openai-compatible-responses.d.ts +26 -0
- package/dist/protocols/openai-freeform.d.ts +1 -1
- package/dist/protocols/openai-freeform.js +9 -5
- package/dist/protocols/openai-responses.d.ts +153 -0
- package/dist/protocols/openai-responses.js +68 -7
- package/dist/protocols/utils/gateway-protocol.js +1 -0
- package/dist/protocols/utils/responses-compaction.js +7 -3
- package/dist/protocols/xai-responses.d.ts +26 -0
- package/dist/protocols/zai-messages.d.ts +24 -2
- package/dist/providers/alibaba.d.ts +50 -2
- package/dist/providers/amazon-bedrock-mantle.d.ts +50 -2
- package/dist/providers/anthropic-compatible.d.ts +24 -2
- package/dist/providers/anthropic.d.ts +24 -2
- package/dist/providers/azure.d.ts +76 -2
- package/dist/providers/cloudflare-ai-gateway.d.ts +100 -4
- package/dist/providers/digitalocean.d.ts +26 -0
- package/dist/providers/google-vertex-messages.d.ts +24 -2
- package/dist/providers/google-vertex-messages.js +1 -0
- package/dist/providers/google-vertex-responses.d.ts +26 -0
- package/dist/providers/meta.d.ts +50 -2
- package/dist/providers/minimax.d.ts +50 -2
- package/dist/providers/moonshot.d.ts +50 -2
- package/dist/providers/openai-compatible-responses.d.ts +26 -0
- package/dist/providers/openai.d.ts +26 -0
- package/dist/providers/openrouter.d.ts +26 -0
- package/dist/providers/venice.d.ts +26 -0
- package/dist/providers/zai-coding-plan.d.ts +50 -2
- package/dist/public.d.ts +2 -2
- package/dist/public.js +1 -1
- package/dist/route/client.d.ts +2 -0
- package/dist/route/client.js +5 -1
- package/dist/route/protocol.d.ts +3 -0
- package/dist/schema/events.d.ts +5 -0
- package/dist/schema/messages.d.ts +24 -1
- package/dist/schema/messages.js +26 -2
- package/dist/schema/options.d.ts +10 -2
- package/dist/tool-updates.d.ts +34 -0
- package/dist/tool-updates.js +93 -0
- package/dist/tool.d.ts +6 -1
- package/dist/tool.js +1 -1
- package/package.json +3 -3
|
@@ -29,6 +29,32 @@ declare const responsesRoute: Route<{
|
|
|
29
29
|
readonly reasoning: {
|
|
30
30
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
31
31
|
};
|
|
32
|
+
} | {
|
|
33
|
+
readonly type: "additional_tools";
|
|
34
|
+
readonly role: "developer";
|
|
35
|
+
readonly tools: readonly ({
|
|
36
|
+
readonly type: "custom";
|
|
37
|
+
readonly name: string;
|
|
38
|
+
readonly description: string;
|
|
39
|
+
readonly format: {
|
|
40
|
+
readonly type: "text";
|
|
41
|
+
} | {
|
|
42
|
+
readonly type: "grammar";
|
|
43
|
+
readonly syntax: "lark" | "regex";
|
|
44
|
+
readonly definition: string;
|
|
45
|
+
};
|
|
46
|
+
} | {
|
|
47
|
+
readonly type: "function";
|
|
48
|
+
readonly name: string;
|
|
49
|
+
readonly description: string;
|
|
50
|
+
readonly parameters: {
|
|
51
|
+
readonly [x: string]: unknown;
|
|
52
|
+
};
|
|
53
|
+
readonly strict?: boolean | undefined;
|
|
54
|
+
} | {
|
|
55
|
+
readonly [x: string]: unknown;
|
|
56
|
+
readonly type: string;
|
|
57
|
+
})[];
|
|
32
58
|
} | {
|
|
33
59
|
readonly type: "message";
|
|
34
60
|
readonly role: "system";
|
|
@@ -483,14 +509,36 @@ export declare const routes: (Route<{
|
|
|
483
509
|
})[];
|
|
484
510
|
} | {
|
|
485
511
|
readonly role: "system";
|
|
486
|
-
readonly content: readonly {
|
|
512
|
+
readonly content: readonly ({
|
|
513
|
+
readonly type: "tool_addition";
|
|
514
|
+
readonly tool: {
|
|
515
|
+
readonly type: "tool_definition";
|
|
516
|
+
readonly definition: {
|
|
517
|
+
readonly name: string;
|
|
518
|
+
readonly description: string;
|
|
519
|
+
readonly input_schema: {
|
|
520
|
+
readonly [x: string]: unknown;
|
|
521
|
+
};
|
|
522
|
+
readonly cache_control?: {
|
|
523
|
+
readonly type: "ephemeral";
|
|
524
|
+
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
525
|
+
} | undefined;
|
|
526
|
+
};
|
|
527
|
+
};
|
|
528
|
+
} | {
|
|
529
|
+
readonly type: "tool_removal";
|
|
530
|
+
readonly tool: {
|
|
531
|
+
readonly type: "tool_reference";
|
|
532
|
+
readonly name: string;
|
|
533
|
+
};
|
|
534
|
+
} | {
|
|
487
535
|
readonly type: "text";
|
|
488
536
|
readonly text: string;
|
|
489
537
|
readonly cache_control?: {
|
|
490
538
|
readonly type: "ephemeral";
|
|
491
539
|
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
492
540
|
} | undefined;
|
|
493
|
-
}[];
|
|
541
|
+
})[];
|
|
494
542
|
readonly output_config?: {
|
|
495
543
|
readonly effort: string;
|
|
496
544
|
} | undefined;
|
|
@@ -742,6 +790,32 @@ export declare const routes: (Route<{
|
|
|
742
790
|
readonly reasoning: {
|
|
743
791
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
744
792
|
};
|
|
793
|
+
} | {
|
|
794
|
+
readonly type: "additional_tools";
|
|
795
|
+
readonly role: "developer";
|
|
796
|
+
readonly tools: readonly ({
|
|
797
|
+
readonly type: "custom";
|
|
798
|
+
readonly name: string;
|
|
799
|
+
readonly description: string;
|
|
800
|
+
readonly format: {
|
|
801
|
+
readonly type: "text";
|
|
802
|
+
} | {
|
|
803
|
+
readonly type: "grammar";
|
|
804
|
+
readonly syntax: "lark" | "regex";
|
|
805
|
+
readonly definition: string;
|
|
806
|
+
};
|
|
807
|
+
} | {
|
|
808
|
+
readonly type: "function";
|
|
809
|
+
readonly name: string;
|
|
810
|
+
readonly description: string;
|
|
811
|
+
readonly parameters: {
|
|
812
|
+
readonly [x: string]: unknown;
|
|
813
|
+
};
|
|
814
|
+
readonly strict?: boolean | undefined;
|
|
815
|
+
} | {
|
|
816
|
+
readonly [x: string]: unknown;
|
|
817
|
+
readonly type: string;
|
|
818
|
+
})[];
|
|
745
819
|
} | {
|
|
746
820
|
readonly type: "message";
|
|
747
821
|
readonly role: "system";
|
|
@@ -35,6 +35,32 @@ export declare const responsesRoute: import("../route.js").Route<{
|
|
|
35
35
|
readonly reasoning: {
|
|
36
36
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
37
37
|
};
|
|
38
|
+
} | {
|
|
39
|
+
readonly type: "additional_tools";
|
|
40
|
+
readonly role: "developer";
|
|
41
|
+
readonly tools: readonly ({
|
|
42
|
+
readonly type: "custom";
|
|
43
|
+
readonly name: string;
|
|
44
|
+
readonly description: string;
|
|
45
|
+
readonly format: {
|
|
46
|
+
readonly type: "text";
|
|
47
|
+
} | {
|
|
48
|
+
readonly type: "grammar";
|
|
49
|
+
readonly syntax: "lark" | "regex";
|
|
50
|
+
readonly definition: string;
|
|
51
|
+
};
|
|
52
|
+
} | {
|
|
53
|
+
readonly type: "function";
|
|
54
|
+
readonly name: string;
|
|
55
|
+
readonly description: string;
|
|
56
|
+
readonly parameters: {
|
|
57
|
+
readonly [x: string]: unknown;
|
|
58
|
+
};
|
|
59
|
+
readonly strict?: boolean | undefined;
|
|
60
|
+
} | {
|
|
61
|
+
readonly [x: string]: unknown;
|
|
62
|
+
readonly type: string;
|
|
63
|
+
})[];
|
|
38
64
|
} | {
|
|
39
65
|
readonly type: "message";
|
|
40
66
|
readonly role: "system";
|
|
@@ -490,14 +516,36 @@ export declare const messagesRoute: import("../route.js").Route<{
|
|
|
490
516
|
})[];
|
|
491
517
|
} | {
|
|
492
518
|
readonly role: "system";
|
|
493
|
-
readonly content: readonly {
|
|
519
|
+
readonly content: readonly ({
|
|
520
|
+
readonly type: "tool_addition";
|
|
521
|
+
readonly tool: {
|
|
522
|
+
readonly type: "tool_definition";
|
|
523
|
+
readonly definition: {
|
|
524
|
+
readonly name: string;
|
|
525
|
+
readonly description: string;
|
|
526
|
+
readonly input_schema: {
|
|
527
|
+
readonly [x: string]: unknown;
|
|
528
|
+
};
|
|
529
|
+
readonly cache_control?: {
|
|
530
|
+
readonly type: "ephemeral";
|
|
531
|
+
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
532
|
+
} | undefined;
|
|
533
|
+
};
|
|
534
|
+
};
|
|
535
|
+
} | {
|
|
536
|
+
readonly type: "tool_removal";
|
|
537
|
+
readonly tool: {
|
|
538
|
+
readonly type: "tool_reference";
|
|
539
|
+
readonly name: string;
|
|
540
|
+
};
|
|
541
|
+
} | {
|
|
494
542
|
readonly type: "text";
|
|
495
543
|
readonly text: string;
|
|
496
544
|
readonly cache_control?: {
|
|
497
545
|
readonly type: "ephemeral";
|
|
498
546
|
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
499
547
|
} | undefined;
|
|
500
|
-
}[];
|
|
548
|
+
})[];
|
|
501
549
|
readonly output_config?: {
|
|
502
550
|
readonly effort: string;
|
|
503
551
|
} | undefined;
|
|
@@ -973,14 +1021,36 @@ export declare const routes: (import("../route.js").Route<{
|
|
|
973
1021
|
})[];
|
|
974
1022
|
} | {
|
|
975
1023
|
readonly role: "system";
|
|
976
|
-
readonly content: readonly {
|
|
1024
|
+
readonly content: readonly ({
|
|
1025
|
+
readonly type: "tool_addition";
|
|
1026
|
+
readonly tool: {
|
|
1027
|
+
readonly type: "tool_definition";
|
|
1028
|
+
readonly definition: {
|
|
1029
|
+
readonly name: string;
|
|
1030
|
+
readonly description: string;
|
|
1031
|
+
readonly input_schema: {
|
|
1032
|
+
readonly [x: string]: unknown;
|
|
1033
|
+
};
|
|
1034
|
+
readonly cache_control?: {
|
|
1035
|
+
readonly type: "ephemeral";
|
|
1036
|
+
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
1037
|
+
} | undefined;
|
|
1038
|
+
};
|
|
1039
|
+
};
|
|
1040
|
+
} | {
|
|
1041
|
+
readonly type: "tool_removal";
|
|
1042
|
+
readonly tool: {
|
|
1043
|
+
readonly type: "tool_reference";
|
|
1044
|
+
readonly name: string;
|
|
1045
|
+
};
|
|
1046
|
+
} | {
|
|
977
1047
|
readonly type: "text";
|
|
978
1048
|
readonly text: string;
|
|
979
1049
|
readonly cache_control?: {
|
|
980
1050
|
readonly type: "ephemeral";
|
|
981
1051
|
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
982
1052
|
} | undefined;
|
|
983
|
-
}[];
|
|
1053
|
+
})[];
|
|
984
1054
|
readonly output_config?: {
|
|
985
1055
|
readonly effort: string;
|
|
986
1056
|
} | undefined;
|
|
@@ -1232,6 +1302,32 @@ export declare const routes: (import("../route.js").Route<{
|
|
|
1232
1302
|
readonly reasoning: {
|
|
1233
1303
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
1234
1304
|
};
|
|
1305
|
+
} | {
|
|
1306
|
+
readonly type: "additional_tools";
|
|
1307
|
+
readonly role: "developer";
|
|
1308
|
+
readonly tools: readonly ({
|
|
1309
|
+
readonly type: "custom";
|
|
1310
|
+
readonly name: string;
|
|
1311
|
+
readonly description: string;
|
|
1312
|
+
readonly format: {
|
|
1313
|
+
readonly type: "text";
|
|
1314
|
+
} | {
|
|
1315
|
+
readonly type: "grammar";
|
|
1316
|
+
readonly syntax: "lark" | "regex";
|
|
1317
|
+
readonly definition: string;
|
|
1318
|
+
};
|
|
1319
|
+
} | {
|
|
1320
|
+
readonly type: "function";
|
|
1321
|
+
readonly name: string;
|
|
1322
|
+
readonly description: string;
|
|
1323
|
+
readonly parameters: {
|
|
1324
|
+
readonly [x: string]: unknown;
|
|
1325
|
+
};
|
|
1326
|
+
readonly strict?: boolean | undefined;
|
|
1327
|
+
} | {
|
|
1328
|
+
readonly [x: string]: unknown;
|
|
1329
|
+
readonly type: string;
|
|
1330
|
+
})[];
|
|
1235
1331
|
} | {
|
|
1236
1332
|
readonly type: "message";
|
|
1237
1333
|
readonly role: "system";
|
|
@@ -450,6 +450,32 @@ export declare const routes: (Route<{
|
|
|
450
450
|
readonly reasoning: {
|
|
451
451
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
452
452
|
};
|
|
453
|
+
} | {
|
|
454
|
+
readonly type: "additional_tools";
|
|
455
|
+
readonly role: "developer";
|
|
456
|
+
readonly tools: readonly ({
|
|
457
|
+
readonly type: "custom";
|
|
458
|
+
readonly name: string;
|
|
459
|
+
readonly description: string;
|
|
460
|
+
readonly format: {
|
|
461
|
+
readonly type: "text";
|
|
462
|
+
} | {
|
|
463
|
+
readonly type: "grammar";
|
|
464
|
+
readonly syntax: "lark" | "regex";
|
|
465
|
+
readonly definition: string;
|
|
466
|
+
};
|
|
467
|
+
} | {
|
|
468
|
+
readonly type: "function";
|
|
469
|
+
readonly name: string;
|
|
470
|
+
readonly description: string;
|
|
471
|
+
readonly parameters: {
|
|
472
|
+
readonly [x: string]: unknown;
|
|
473
|
+
};
|
|
474
|
+
readonly strict?: boolean | undefined;
|
|
475
|
+
} | {
|
|
476
|
+
readonly [x: string]: unknown;
|
|
477
|
+
readonly type: string;
|
|
478
|
+
})[];
|
|
453
479
|
} | {
|
|
454
480
|
readonly type: "message";
|
|
455
481
|
readonly role: "system";
|
|
@@ -248,14 +248,36 @@ export declare const routes: Route<{
|
|
|
248
248
|
})[];
|
|
249
249
|
} | {
|
|
250
250
|
readonly role: "system";
|
|
251
|
-
readonly content: readonly {
|
|
251
|
+
readonly content: readonly ({
|
|
252
|
+
readonly type: "tool_addition";
|
|
253
|
+
readonly tool: {
|
|
254
|
+
readonly type: "tool_definition";
|
|
255
|
+
readonly definition: {
|
|
256
|
+
readonly name: string;
|
|
257
|
+
readonly description: string;
|
|
258
|
+
readonly input_schema: {
|
|
259
|
+
readonly [x: string]: unknown;
|
|
260
|
+
};
|
|
261
|
+
readonly cache_control?: {
|
|
262
|
+
readonly type: "ephemeral";
|
|
263
|
+
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
264
|
+
} | undefined;
|
|
265
|
+
};
|
|
266
|
+
};
|
|
267
|
+
} | {
|
|
268
|
+
readonly type: "tool_removal";
|
|
269
|
+
readonly tool: {
|
|
270
|
+
readonly type: "tool_reference";
|
|
271
|
+
readonly name: string;
|
|
272
|
+
};
|
|
273
|
+
} | {
|
|
252
274
|
readonly type: "text";
|
|
253
275
|
readonly text: string;
|
|
254
276
|
readonly cache_control?: {
|
|
255
277
|
readonly type: "ephemeral";
|
|
256
278
|
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
257
279
|
} | undefined;
|
|
258
|
-
}[];
|
|
280
|
+
})[];
|
|
259
281
|
readonly output_config?: {
|
|
260
282
|
readonly effort: string;
|
|
261
283
|
} | undefined;
|
|
@@ -27,6 +27,7 @@ const route = Route.make({
|
|
|
27
27
|
},
|
|
28
28
|
stream: AnthropicMessages.protocol.stream,
|
|
29
29
|
supportsEffortUpdates: AnthropicMessages.protocol.supportsEffortUpdates,
|
|
30
|
+
toolUpdates: AnthropicMessages.protocol.toolUpdates,
|
|
30
31
|
}),
|
|
31
32
|
endpoint: Endpoint.path(({ request }) => `/${request.model.id}:streamRawPredict`),
|
|
32
33
|
auth: Auth.none,
|
|
@@ -24,6 +24,32 @@ export declare const routes: Route<{
|
|
|
24
24
|
readonly reasoning: {
|
|
25
25
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
26
26
|
};
|
|
27
|
+
} | {
|
|
28
|
+
readonly type: "additional_tools";
|
|
29
|
+
readonly role: "developer";
|
|
30
|
+
readonly tools: readonly ({
|
|
31
|
+
readonly type: "custom";
|
|
32
|
+
readonly name: string;
|
|
33
|
+
readonly description: string;
|
|
34
|
+
readonly format: {
|
|
35
|
+
readonly type: "text";
|
|
36
|
+
} | {
|
|
37
|
+
readonly type: "grammar";
|
|
38
|
+
readonly syntax: "lark" | "regex";
|
|
39
|
+
readonly definition: string;
|
|
40
|
+
};
|
|
41
|
+
} | {
|
|
42
|
+
readonly type: "function";
|
|
43
|
+
readonly name: string;
|
|
44
|
+
readonly description: string;
|
|
45
|
+
readonly parameters: {
|
|
46
|
+
readonly [x: string]: unknown;
|
|
47
|
+
};
|
|
48
|
+
readonly strict?: boolean | undefined;
|
|
49
|
+
} | {
|
|
50
|
+
readonly [x: string]: unknown;
|
|
51
|
+
readonly type: string;
|
|
52
|
+
})[];
|
|
27
53
|
} | {
|
|
28
54
|
readonly type: "message";
|
|
29
55
|
readonly role: "system";
|
package/dist/providers/meta.d.ts
CHANGED
|
@@ -45,6 +45,32 @@ export declare const routes: (Route<{
|
|
|
45
45
|
readonly reasoning: {
|
|
46
46
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
47
47
|
};
|
|
48
|
+
} | {
|
|
49
|
+
readonly type: "additional_tools";
|
|
50
|
+
readonly role: "developer";
|
|
51
|
+
readonly tools: readonly ({
|
|
52
|
+
readonly type: "custom";
|
|
53
|
+
readonly name: string;
|
|
54
|
+
readonly description: string;
|
|
55
|
+
readonly format: {
|
|
56
|
+
readonly type: "text";
|
|
57
|
+
} | {
|
|
58
|
+
readonly type: "grammar";
|
|
59
|
+
readonly syntax: "lark" | "regex";
|
|
60
|
+
readonly definition: string;
|
|
61
|
+
};
|
|
62
|
+
} | {
|
|
63
|
+
readonly type: "function";
|
|
64
|
+
readonly name: string;
|
|
65
|
+
readonly description: string;
|
|
66
|
+
readonly parameters: {
|
|
67
|
+
readonly [x: string]: unknown;
|
|
68
|
+
};
|
|
69
|
+
readonly strict?: boolean | undefined;
|
|
70
|
+
} | {
|
|
71
|
+
readonly [x: string]: unknown;
|
|
72
|
+
readonly type: string;
|
|
73
|
+
})[];
|
|
48
74
|
} | {
|
|
49
75
|
readonly type: "message";
|
|
50
76
|
readonly role: "system";
|
|
@@ -638,14 +664,36 @@ export declare const routes: (Route<{
|
|
|
638
664
|
})[];
|
|
639
665
|
} | {
|
|
640
666
|
readonly role: "system";
|
|
641
|
-
readonly content: readonly {
|
|
667
|
+
readonly content: readonly ({
|
|
668
|
+
readonly type: "tool_addition";
|
|
669
|
+
readonly tool: {
|
|
670
|
+
readonly type: "tool_definition";
|
|
671
|
+
readonly definition: {
|
|
672
|
+
readonly name: string;
|
|
673
|
+
readonly description: string;
|
|
674
|
+
readonly input_schema: {
|
|
675
|
+
readonly [x: string]: unknown;
|
|
676
|
+
};
|
|
677
|
+
readonly cache_control?: {
|
|
678
|
+
readonly type: "ephemeral";
|
|
679
|
+
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
680
|
+
} | undefined;
|
|
681
|
+
};
|
|
682
|
+
};
|
|
683
|
+
} | {
|
|
684
|
+
readonly type: "tool_removal";
|
|
685
|
+
readonly tool: {
|
|
686
|
+
readonly type: "tool_reference";
|
|
687
|
+
readonly name: string;
|
|
688
|
+
};
|
|
689
|
+
} | {
|
|
642
690
|
readonly type: "text";
|
|
643
691
|
readonly text: string;
|
|
644
692
|
readonly cache_control?: {
|
|
645
693
|
readonly type: "ephemeral";
|
|
646
694
|
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
647
695
|
} | undefined;
|
|
648
|
-
}[];
|
|
696
|
+
})[];
|
|
649
697
|
readonly output_config?: {
|
|
650
698
|
readonly effort: string;
|
|
651
699
|
} | undefined;
|
|
@@ -265,14 +265,36 @@ export declare const routes: (Route<{
|
|
|
265
265
|
})[];
|
|
266
266
|
} | {
|
|
267
267
|
readonly role: "system";
|
|
268
|
-
readonly content: readonly {
|
|
268
|
+
readonly content: readonly ({
|
|
269
|
+
readonly type: "tool_addition";
|
|
270
|
+
readonly tool: {
|
|
271
|
+
readonly type: "tool_definition";
|
|
272
|
+
readonly definition: {
|
|
273
|
+
readonly name: string;
|
|
274
|
+
readonly description: string;
|
|
275
|
+
readonly input_schema: {
|
|
276
|
+
readonly [x: string]: unknown;
|
|
277
|
+
};
|
|
278
|
+
readonly cache_control?: {
|
|
279
|
+
readonly type: "ephemeral";
|
|
280
|
+
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
281
|
+
} | undefined;
|
|
282
|
+
};
|
|
283
|
+
};
|
|
284
|
+
} | {
|
|
285
|
+
readonly type: "tool_removal";
|
|
286
|
+
readonly tool: {
|
|
287
|
+
readonly type: "tool_reference";
|
|
288
|
+
readonly name: string;
|
|
289
|
+
};
|
|
290
|
+
} | {
|
|
269
291
|
readonly type: "text";
|
|
270
292
|
readonly text: string;
|
|
271
293
|
readonly cache_control?: {
|
|
272
294
|
readonly type: "ephemeral";
|
|
273
295
|
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
274
296
|
} | undefined;
|
|
275
|
-
}[];
|
|
297
|
+
})[];
|
|
276
298
|
readonly output_config?: {
|
|
277
299
|
readonly effort: string;
|
|
278
300
|
} | undefined;
|
|
@@ -350,6 +372,32 @@ export declare const routes: (Route<{
|
|
|
350
372
|
readonly reasoning: {
|
|
351
373
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
352
374
|
};
|
|
375
|
+
} | {
|
|
376
|
+
readonly type: "additional_tools";
|
|
377
|
+
readonly role: "developer";
|
|
378
|
+
readonly tools: readonly ({
|
|
379
|
+
readonly type: "custom";
|
|
380
|
+
readonly name: string;
|
|
381
|
+
readonly description: string;
|
|
382
|
+
readonly format: {
|
|
383
|
+
readonly type: "text";
|
|
384
|
+
} | {
|
|
385
|
+
readonly type: "grammar";
|
|
386
|
+
readonly syntax: "lark" | "regex";
|
|
387
|
+
readonly definition: string;
|
|
388
|
+
};
|
|
389
|
+
} | {
|
|
390
|
+
readonly type: "function";
|
|
391
|
+
readonly name: string;
|
|
392
|
+
readonly description: string;
|
|
393
|
+
readonly parameters: {
|
|
394
|
+
readonly [x: string]: unknown;
|
|
395
|
+
};
|
|
396
|
+
readonly strict?: boolean | undefined;
|
|
397
|
+
} | {
|
|
398
|
+
readonly [x: string]: unknown;
|
|
399
|
+
readonly type: string;
|
|
400
|
+
})[];
|
|
353
401
|
} | {
|
|
354
402
|
readonly type: "message";
|
|
355
403
|
readonly role: "system";
|
|
@@ -260,14 +260,36 @@ export declare const routes: (Route<{
|
|
|
260
260
|
})[];
|
|
261
261
|
} | {
|
|
262
262
|
readonly role: "system";
|
|
263
|
-
readonly content: readonly {
|
|
263
|
+
readonly content: readonly ({
|
|
264
|
+
readonly type: "tool_addition";
|
|
265
|
+
readonly tool: {
|
|
266
|
+
readonly type: "tool_definition";
|
|
267
|
+
readonly definition: {
|
|
268
|
+
readonly name: string;
|
|
269
|
+
readonly description: string;
|
|
270
|
+
readonly input_schema: {
|
|
271
|
+
readonly [x: string]: unknown;
|
|
272
|
+
};
|
|
273
|
+
readonly cache_control?: {
|
|
274
|
+
readonly type: "ephemeral";
|
|
275
|
+
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
276
|
+
} | undefined;
|
|
277
|
+
};
|
|
278
|
+
};
|
|
279
|
+
} | {
|
|
280
|
+
readonly type: "tool_removal";
|
|
281
|
+
readonly tool: {
|
|
282
|
+
readonly type: "tool_reference";
|
|
283
|
+
readonly name: string;
|
|
284
|
+
};
|
|
285
|
+
} | {
|
|
264
286
|
readonly type: "text";
|
|
265
287
|
readonly text: string;
|
|
266
288
|
readonly cache_control?: {
|
|
267
289
|
readonly type: "ephemeral";
|
|
268
290
|
readonly ttl?: `${number}d` | `${number}h` | `${number}m` | `${number}ms` | `${number}s` | undefined;
|
|
269
291
|
} | undefined;
|
|
270
|
-
}[];
|
|
292
|
+
})[];
|
|
271
293
|
readonly output_config?: {
|
|
272
294
|
readonly effort: string;
|
|
273
295
|
} | undefined;
|
|
@@ -345,6 +367,32 @@ export declare const routes: (Route<{
|
|
|
345
367
|
readonly reasoning: {
|
|
346
368
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
347
369
|
};
|
|
370
|
+
} | {
|
|
371
|
+
readonly type: "additional_tools";
|
|
372
|
+
readonly role: "developer";
|
|
373
|
+
readonly tools: readonly ({
|
|
374
|
+
readonly type: "custom";
|
|
375
|
+
readonly name: string;
|
|
376
|
+
readonly description: string;
|
|
377
|
+
readonly format: {
|
|
378
|
+
readonly type: "text";
|
|
379
|
+
} | {
|
|
380
|
+
readonly type: "grammar";
|
|
381
|
+
readonly syntax: "lark" | "regex";
|
|
382
|
+
readonly definition: string;
|
|
383
|
+
};
|
|
384
|
+
} | {
|
|
385
|
+
readonly type: "function";
|
|
386
|
+
readonly name: string;
|
|
387
|
+
readonly description: string;
|
|
388
|
+
readonly parameters: {
|
|
389
|
+
readonly [x: string]: unknown;
|
|
390
|
+
};
|
|
391
|
+
readonly strict?: boolean | undefined;
|
|
392
|
+
} | {
|
|
393
|
+
readonly [x: string]: unknown;
|
|
394
|
+
readonly type: string;
|
|
395
|
+
})[];
|
|
348
396
|
} | {
|
|
349
397
|
readonly type: "message";
|
|
350
398
|
readonly role: "system";
|
|
@@ -21,6 +21,32 @@ export declare const routes: import("../route.js").Route<{
|
|
|
21
21
|
readonly reasoning: {
|
|
22
22
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
23
23
|
};
|
|
24
|
+
} | {
|
|
25
|
+
readonly type: "additional_tools";
|
|
26
|
+
readonly role: "developer";
|
|
27
|
+
readonly tools: readonly ({
|
|
28
|
+
readonly type: "custom";
|
|
29
|
+
readonly name: string;
|
|
30
|
+
readonly description: string;
|
|
31
|
+
readonly format: {
|
|
32
|
+
readonly type: "text";
|
|
33
|
+
} | {
|
|
34
|
+
readonly type: "grammar";
|
|
35
|
+
readonly syntax: "lark" | "regex";
|
|
36
|
+
readonly definition: string;
|
|
37
|
+
};
|
|
38
|
+
} | {
|
|
39
|
+
readonly type: "function";
|
|
40
|
+
readonly name: string;
|
|
41
|
+
readonly description: string;
|
|
42
|
+
readonly parameters: {
|
|
43
|
+
readonly [x: string]: unknown;
|
|
44
|
+
};
|
|
45
|
+
readonly strict?: boolean | undefined;
|
|
46
|
+
} | {
|
|
47
|
+
readonly [x: string]: unknown;
|
|
48
|
+
readonly type: string;
|
|
49
|
+
})[];
|
|
24
50
|
} | {
|
|
25
51
|
readonly type: "message";
|
|
26
52
|
readonly role: "system";
|
|
@@ -194,6 +194,32 @@ export declare const routes: (Route<{
|
|
|
194
194
|
readonly reasoning: {
|
|
195
195
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
196
196
|
};
|
|
197
|
+
} | {
|
|
198
|
+
readonly type: "additional_tools";
|
|
199
|
+
readonly role: "developer";
|
|
200
|
+
readonly tools: readonly ({
|
|
201
|
+
readonly type: "custom";
|
|
202
|
+
readonly name: string;
|
|
203
|
+
readonly description: string;
|
|
204
|
+
readonly format: {
|
|
205
|
+
readonly type: "text";
|
|
206
|
+
} | {
|
|
207
|
+
readonly type: "grammar";
|
|
208
|
+
readonly syntax: "lark" | "regex";
|
|
209
|
+
readonly definition: string;
|
|
210
|
+
};
|
|
211
|
+
} | {
|
|
212
|
+
readonly type: "function";
|
|
213
|
+
readonly name: string;
|
|
214
|
+
readonly description: string;
|
|
215
|
+
readonly parameters: {
|
|
216
|
+
readonly [x: string]: unknown;
|
|
217
|
+
};
|
|
218
|
+
readonly strict?: boolean | undefined;
|
|
219
|
+
} | {
|
|
220
|
+
readonly [x: string]: unknown;
|
|
221
|
+
readonly type: string;
|
|
222
|
+
})[];
|
|
197
223
|
} | {
|
|
198
224
|
readonly type: "message";
|
|
199
225
|
readonly role: "system";
|
|
@@ -747,6 +747,32 @@ export declare const routes: (Route<{
|
|
|
747
747
|
readonly reasoning: {
|
|
748
748
|
readonly effort: import("../schema/options.js").ReasoningEffort;
|
|
749
749
|
};
|
|
750
|
+
} | {
|
|
751
|
+
readonly type: "additional_tools";
|
|
752
|
+
readonly role: "developer";
|
|
753
|
+
readonly tools: readonly ({
|
|
754
|
+
readonly type: "custom";
|
|
755
|
+
readonly name: string;
|
|
756
|
+
readonly description: string;
|
|
757
|
+
readonly format: {
|
|
758
|
+
readonly type: "text";
|
|
759
|
+
} | {
|
|
760
|
+
readonly type: "grammar";
|
|
761
|
+
readonly syntax: "lark" | "regex";
|
|
762
|
+
readonly definition: string;
|
|
763
|
+
};
|
|
764
|
+
} | {
|
|
765
|
+
readonly type: "function";
|
|
766
|
+
readonly name: string;
|
|
767
|
+
readonly description: string;
|
|
768
|
+
readonly parameters: {
|
|
769
|
+
readonly [x: string]: unknown;
|
|
770
|
+
};
|
|
771
|
+
readonly strict?: boolean | undefined;
|
|
772
|
+
} | {
|
|
773
|
+
readonly [x: string]: unknown;
|
|
774
|
+
readonly type: string;
|
|
775
|
+
})[];
|
|
750
776
|
} | {
|
|
751
777
|
readonly type: "message";
|
|
752
778
|
readonly role: "system";
|