@opencode-ai/ai 0.0.0-dev-18051 → 0.0.0-dev-18053
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/protocols/anthropic-messages.d.ts +250 -14
- package/dist/protocols/anthropic-messages.js +274 -14
- package/dist/protocols/gemini.d.ts +2 -2
- package/dist/protocols/open-responses.d.ts +3 -3
- package/dist/protocols/openai-compatible-responses.d.ts +1 -1
- package/dist/protocols/openai-responses.d.ts +5 -5
- package/dist/protocols/utils/bedrock-media.d.ts +1 -0
- package/dist/protocols/xai-responses.d.ts +1 -1
- package/dist/providers/amazon-bedrock-mantle.d.ts +1 -1
- package/dist/providers/anthropic-compatible.d.ts +72 -3
- package/dist/providers/anthropic.d.ts +72 -3
- package/dist/providers/azure.d.ts +1 -1
- package/dist/providers/google-vertex-messages.d.ts +72 -3
- package/dist/providers/google-vertex-responses.d.ts +1 -1
- package/dist/providers/google-vertex.d.ts +1 -1
- package/dist/providers/google.d.ts +1 -1
- package/dist/providers/openai-compatible-responses.d.ts +1 -1
- package/dist/providers/openai.d.ts +1 -1
- package/dist/schema/messages.d.ts +3 -0
- package/dist/schema/messages.js +1 -0
- package/package.json +3 -3
|
@@ -41,22 +41,46 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
41
41
|
readonly type: "base64";
|
|
42
42
|
readonly media_type: string;
|
|
43
43
|
readonly data: string;
|
|
44
|
+
} | {
|
|
45
|
+
readonly type: "url";
|
|
46
|
+
readonly url: string;
|
|
47
|
+
} | {
|
|
48
|
+
readonly type: "file";
|
|
49
|
+
readonly file_id: string;
|
|
44
50
|
};
|
|
45
51
|
readonly cache_control?: {
|
|
46
52
|
readonly type: "ephemeral";
|
|
47
53
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
48
54
|
} | undefined;
|
|
55
|
+
readonly transformations?: {
|
|
56
|
+
readonly oversized_image?: "error" | "downsize" | undefined;
|
|
57
|
+
} | undefined;
|
|
49
58
|
} | {
|
|
50
59
|
readonly type: "document";
|
|
51
60
|
readonly source: {
|
|
52
61
|
readonly type: "base64";
|
|
53
62
|
readonly media_type: "application/pdf";
|
|
54
63
|
readonly data: string;
|
|
64
|
+
} | {
|
|
65
|
+
readonly type: "text";
|
|
66
|
+
readonly media_type: "text/plain";
|
|
67
|
+
readonly data: string;
|
|
68
|
+
} | {
|
|
69
|
+
readonly type: "url";
|
|
70
|
+
readonly url: string;
|
|
71
|
+
} | {
|
|
72
|
+
readonly type: "file";
|
|
73
|
+
readonly file_id: string;
|
|
55
74
|
};
|
|
75
|
+
readonly title?: string | undefined;
|
|
76
|
+
readonly context?: string | undefined;
|
|
56
77
|
readonly cache_control?: {
|
|
57
78
|
readonly type: "ephemeral";
|
|
58
79
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
59
80
|
} | undefined;
|
|
81
|
+
readonly citations?: {
|
|
82
|
+
readonly enabled: boolean;
|
|
83
|
+
} | undefined;
|
|
60
84
|
} | {
|
|
61
85
|
readonly type: "tool_result";
|
|
62
86
|
readonly content: string | readonly ({
|
|
@@ -72,22 +96,46 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
72
96
|
readonly type: "base64";
|
|
73
97
|
readonly media_type: string;
|
|
74
98
|
readonly data: string;
|
|
99
|
+
} | {
|
|
100
|
+
readonly type: "url";
|
|
101
|
+
readonly url: string;
|
|
102
|
+
} | {
|
|
103
|
+
readonly type: "file";
|
|
104
|
+
readonly file_id: string;
|
|
75
105
|
};
|
|
76
106
|
readonly cache_control?: {
|
|
77
107
|
readonly type: "ephemeral";
|
|
78
108
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
79
109
|
} | undefined;
|
|
110
|
+
readonly transformations?: {
|
|
111
|
+
readonly oversized_image?: "error" | "downsize" | undefined;
|
|
112
|
+
} | undefined;
|
|
80
113
|
} | {
|
|
81
114
|
readonly type: "document";
|
|
82
115
|
readonly source: {
|
|
83
116
|
readonly type: "base64";
|
|
84
117
|
readonly media_type: "application/pdf";
|
|
85
118
|
readonly data: string;
|
|
119
|
+
} | {
|
|
120
|
+
readonly type: "text";
|
|
121
|
+
readonly media_type: "text/plain";
|
|
122
|
+
readonly data: string;
|
|
123
|
+
} | {
|
|
124
|
+
readonly type: "url";
|
|
125
|
+
readonly url: string;
|
|
126
|
+
} | {
|
|
127
|
+
readonly type: "file";
|
|
128
|
+
readonly file_id: string;
|
|
86
129
|
};
|
|
130
|
+
readonly title?: string | undefined;
|
|
131
|
+
readonly context?: string | undefined;
|
|
87
132
|
readonly cache_control?: {
|
|
88
133
|
readonly type: "ephemeral";
|
|
89
134
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
90
135
|
} | undefined;
|
|
136
|
+
readonly citations?: {
|
|
137
|
+
readonly enabled: boolean;
|
|
138
|
+
} | undefined;
|
|
91
139
|
})[];
|
|
92
140
|
readonly tool_use_id: string;
|
|
93
141
|
readonly cache_control?: {
|
|
@@ -159,6 +207,9 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
159
207
|
}[];
|
|
160
208
|
})[];
|
|
161
209
|
readonly stream: true;
|
|
210
|
+
readonly metadata?: {
|
|
211
|
+
readonly user_id?: string | null | undefined;
|
|
212
|
+
} | undefined;
|
|
162
213
|
readonly tools?: readonly {
|
|
163
214
|
readonly description: string;
|
|
164
215
|
readonly name: string;
|
|
@@ -189,6 +240,27 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
189
240
|
} | {
|
|
190
241
|
readonly type: "disabled";
|
|
191
242
|
} | undefined;
|
|
243
|
+
readonly service_tier?: "auto" | "standard_only" | undefined;
|
|
244
|
+
readonly container?: string | {
|
|
245
|
+
readonly id?: string | null | undefined;
|
|
246
|
+
readonly skills?: readonly {
|
|
247
|
+
readonly [x: string]: unknown;
|
|
248
|
+
}[] | null | undefined;
|
|
249
|
+
} | null | undefined;
|
|
250
|
+
readonly inference_geo?: string | null | undefined;
|
|
251
|
+
readonly cache_control?: {
|
|
252
|
+
readonly type: "ephemeral";
|
|
253
|
+
readonly ttl?: "1h" | "5m" | undefined;
|
|
254
|
+
} | undefined;
|
|
255
|
+
readonly output_config?: {
|
|
256
|
+
readonly format?: {
|
|
257
|
+
readonly type: "json_schema";
|
|
258
|
+
readonly schema: {
|
|
259
|
+
readonly [x: string]: unknown;
|
|
260
|
+
};
|
|
261
|
+
} | null | undefined;
|
|
262
|
+
readonly effort?: string | undefined;
|
|
263
|
+
} | undefined;
|
|
192
264
|
readonly tool_choice?: {
|
|
193
265
|
readonly type: "auto" | "none" | "any";
|
|
194
266
|
readonly disable_parallel_tool_use?: boolean | undefined;
|
|
@@ -200,9 +272,6 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
200
272
|
readonly top_p?: number | undefined;
|
|
201
273
|
readonly top_k?: number | undefined;
|
|
202
274
|
readonly stop_sequences?: readonly string[] | undefined;
|
|
203
|
-
readonly output_config?: {
|
|
204
|
-
readonly effort?: string | undefined;
|
|
205
|
-
} | undefined;
|
|
206
275
|
}, import("../route/transport/http.js").HttpPrepared<string>>[];
|
|
207
276
|
export declare const configure: (input: Config) => {
|
|
208
277
|
id: string & import("effect/Brand").Brand<"AI.ProviderID">;
|
|
@@ -25,22 +25,46 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
25
25
|
readonly type: "base64";
|
|
26
26
|
readonly media_type: string;
|
|
27
27
|
readonly data: string;
|
|
28
|
+
} | {
|
|
29
|
+
readonly type: "url";
|
|
30
|
+
readonly url: string;
|
|
31
|
+
} | {
|
|
32
|
+
readonly type: "file";
|
|
33
|
+
readonly file_id: string;
|
|
28
34
|
};
|
|
29
35
|
readonly cache_control?: {
|
|
30
36
|
readonly type: "ephemeral";
|
|
31
37
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
32
38
|
} | undefined;
|
|
39
|
+
readonly transformations?: {
|
|
40
|
+
readonly oversized_image?: "error" | "downsize" | undefined;
|
|
41
|
+
} | undefined;
|
|
33
42
|
} | {
|
|
34
43
|
readonly type: "document";
|
|
35
44
|
readonly source: {
|
|
36
45
|
readonly type: "base64";
|
|
37
46
|
readonly media_type: "application/pdf";
|
|
38
47
|
readonly data: string;
|
|
48
|
+
} | {
|
|
49
|
+
readonly type: "text";
|
|
50
|
+
readonly media_type: "text/plain";
|
|
51
|
+
readonly data: string;
|
|
52
|
+
} | {
|
|
53
|
+
readonly type: "url";
|
|
54
|
+
readonly url: string;
|
|
55
|
+
} | {
|
|
56
|
+
readonly type: "file";
|
|
57
|
+
readonly file_id: string;
|
|
39
58
|
};
|
|
59
|
+
readonly title?: string | undefined;
|
|
60
|
+
readonly context?: string | undefined;
|
|
40
61
|
readonly cache_control?: {
|
|
41
62
|
readonly type: "ephemeral";
|
|
42
63
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
43
64
|
} | undefined;
|
|
65
|
+
readonly citations?: {
|
|
66
|
+
readonly enabled: boolean;
|
|
67
|
+
} | undefined;
|
|
44
68
|
} | {
|
|
45
69
|
readonly type: "tool_result";
|
|
46
70
|
readonly content: string | readonly ({
|
|
@@ -56,22 +80,46 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
56
80
|
readonly type: "base64";
|
|
57
81
|
readonly media_type: string;
|
|
58
82
|
readonly data: string;
|
|
83
|
+
} | {
|
|
84
|
+
readonly type: "url";
|
|
85
|
+
readonly url: string;
|
|
86
|
+
} | {
|
|
87
|
+
readonly type: "file";
|
|
88
|
+
readonly file_id: string;
|
|
59
89
|
};
|
|
60
90
|
readonly cache_control?: {
|
|
61
91
|
readonly type: "ephemeral";
|
|
62
92
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
63
93
|
} | undefined;
|
|
94
|
+
readonly transformations?: {
|
|
95
|
+
readonly oversized_image?: "error" | "downsize" | undefined;
|
|
96
|
+
} | undefined;
|
|
64
97
|
} | {
|
|
65
98
|
readonly type: "document";
|
|
66
99
|
readonly source: {
|
|
67
100
|
readonly type: "base64";
|
|
68
101
|
readonly media_type: "application/pdf";
|
|
69
102
|
readonly data: string;
|
|
103
|
+
} | {
|
|
104
|
+
readonly type: "text";
|
|
105
|
+
readonly media_type: "text/plain";
|
|
106
|
+
readonly data: string;
|
|
107
|
+
} | {
|
|
108
|
+
readonly type: "url";
|
|
109
|
+
readonly url: string;
|
|
110
|
+
} | {
|
|
111
|
+
readonly type: "file";
|
|
112
|
+
readonly file_id: string;
|
|
70
113
|
};
|
|
114
|
+
readonly title?: string | undefined;
|
|
115
|
+
readonly context?: string | undefined;
|
|
71
116
|
readonly cache_control?: {
|
|
72
117
|
readonly type: "ephemeral";
|
|
73
118
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
74
119
|
} | undefined;
|
|
120
|
+
readonly citations?: {
|
|
121
|
+
readonly enabled: boolean;
|
|
122
|
+
} | undefined;
|
|
75
123
|
})[];
|
|
76
124
|
readonly tool_use_id: string;
|
|
77
125
|
readonly cache_control?: {
|
|
@@ -143,6 +191,9 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
143
191
|
}[];
|
|
144
192
|
})[];
|
|
145
193
|
readonly stream: true;
|
|
194
|
+
readonly metadata?: {
|
|
195
|
+
readonly user_id?: string | null | undefined;
|
|
196
|
+
} | undefined;
|
|
146
197
|
readonly tools?: readonly {
|
|
147
198
|
readonly description: string;
|
|
148
199
|
readonly name: string;
|
|
@@ -173,6 +224,27 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
173
224
|
} | {
|
|
174
225
|
readonly type: "disabled";
|
|
175
226
|
} | undefined;
|
|
227
|
+
readonly service_tier?: "auto" | "standard_only" | undefined;
|
|
228
|
+
readonly container?: string | {
|
|
229
|
+
readonly id?: string | null | undefined;
|
|
230
|
+
readonly skills?: readonly {
|
|
231
|
+
readonly [x: string]: unknown;
|
|
232
|
+
}[] | null | undefined;
|
|
233
|
+
} | null | undefined;
|
|
234
|
+
readonly inference_geo?: string | null | undefined;
|
|
235
|
+
readonly cache_control?: {
|
|
236
|
+
readonly type: "ephemeral";
|
|
237
|
+
readonly ttl?: "1h" | "5m" | undefined;
|
|
238
|
+
} | undefined;
|
|
239
|
+
readonly output_config?: {
|
|
240
|
+
readonly format?: {
|
|
241
|
+
readonly type: "json_schema";
|
|
242
|
+
readonly schema: {
|
|
243
|
+
readonly [x: string]: unknown;
|
|
244
|
+
};
|
|
245
|
+
} | null | undefined;
|
|
246
|
+
readonly effort?: string | undefined;
|
|
247
|
+
} | undefined;
|
|
176
248
|
readonly tool_choice?: {
|
|
177
249
|
readonly type: "auto" | "none" | "any";
|
|
178
250
|
readonly disable_parallel_tool_use?: boolean | undefined;
|
|
@@ -184,9 +256,6 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
184
256
|
readonly top_p?: number | undefined;
|
|
185
257
|
readonly top_k?: number | undefined;
|
|
186
258
|
readonly stop_sequences?: readonly string[] | undefined;
|
|
187
|
-
readonly output_config?: {
|
|
188
|
-
readonly effort?: string | undefined;
|
|
189
|
-
} | undefined;
|
|
190
259
|
}, import("../route/transport/http.js").HttpPrepared<string>>[];
|
|
191
260
|
export type Config = RouteDefaultsInput & ProviderAuthOption<"optional"> & {
|
|
192
261
|
readonly baseURL?: string;
|
|
@@ -217,6 +217,7 @@ export declare const routes: (RouteDef<{
|
|
|
217
217
|
readonly verbosity?: import("../protocols/utils/open-responses-options.js").TextVerbosity | undefined;
|
|
218
218
|
} | undefined;
|
|
219
219
|
readonly temperature?: number | undefined;
|
|
220
|
+
readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
|
|
220
221
|
readonly tool_choice?: "required" | "auto" | "none" | {
|
|
221
222
|
readonly type: "function";
|
|
222
223
|
readonly name: string;
|
|
@@ -242,7 +243,6 @@ export declare const routes: (RouteDef<{
|
|
|
242
243
|
readonly presence_penalty?: number | undefined;
|
|
243
244
|
readonly safety_identifier?: string | undefined;
|
|
244
245
|
readonly top_logprobs?: number | undefined;
|
|
245
|
-
readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
|
|
246
246
|
readonly max_output_tokens?: number | undefined;
|
|
247
247
|
readonly max_tool_calls?: number | undefined;
|
|
248
248
|
readonly parallel_tool_calls?: boolean | undefined;
|
|
@@ -23,6 +23,9 @@ export interface Settings extends ProviderPackage.Settings {
|
|
|
23
23
|
}
|
|
24
24
|
export declare const routes: Route<{
|
|
25
25
|
anthropic_version: "vertex-2023-10-16";
|
|
26
|
+
metadata?: {
|
|
27
|
+
readonly user_id?: string | null | undefined;
|
|
28
|
+
} | undefined;
|
|
26
29
|
max_tokens: number;
|
|
27
30
|
tools?: readonly {
|
|
28
31
|
readonly description: string;
|
|
@@ -58,22 +61,46 @@ export declare const routes: Route<{
|
|
|
58
61
|
readonly type: "base64";
|
|
59
62
|
readonly media_type: string;
|
|
60
63
|
readonly data: string;
|
|
64
|
+
} | {
|
|
65
|
+
readonly type: "url";
|
|
66
|
+
readonly url: string;
|
|
67
|
+
} | {
|
|
68
|
+
readonly type: "file";
|
|
69
|
+
readonly file_id: string;
|
|
61
70
|
};
|
|
62
71
|
readonly cache_control?: {
|
|
63
72
|
readonly type: "ephemeral";
|
|
64
73
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
65
74
|
} | undefined;
|
|
75
|
+
readonly transformations?: {
|
|
76
|
+
readonly oversized_image?: "error" | "downsize" | undefined;
|
|
77
|
+
} | undefined;
|
|
66
78
|
} | {
|
|
67
79
|
readonly type: "document";
|
|
68
80
|
readonly source: {
|
|
69
81
|
readonly type: "base64";
|
|
70
82
|
readonly media_type: "application/pdf";
|
|
71
83
|
readonly data: string;
|
|
84
|
+
} | {
|
|
85
|
+
readonly type: "text";
|
|
86
|
+
readonly media_type: "text/plain";
|
|
87
|
+
readonly data: string;
|
|
88
|
+
} | {
|
|
89
|
+
readonly type: "url";
|
|
90
|
+
readonly url: string;
|
|
91
|
+
} | {
|
|
92
|
+
readonly type: "file";
|
|
93
|
+
readonly file_id: string;
|
|
72
94
|
};
|
|
95
|
+
readonly title?: string | undefined;
|
|
96
|
+
readonly context?: string | undefined;
|
|
73
97
|
readonly cache_control?: {
|
|
74
98
|
readonly type: "ephemeral";
|
|
75
99
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
76
100
|
} | undefined;
|
|
101
|
+
readonly citations?: {
|
|
102
|
+
readonly enabled: boolean;
|
|
103
|
+
} | undefined;
|
|
77
104
|
} | {
|
|
78
105
|
readonly type: "tool_result";
|
|
79
106
|
readonly content: string | readonly ({
|
|
@@ -89,22 +116,46 @@ export declare const routes: Route<{
|
|
|
89
116
|
readonly type: "base64";
|
|
90
117
|
readonly media_type: string;
|
|
91
118
|
readonly data: string;
|
|
119
|
+
} | {
|
|
120
|
+
readonly type: "url";
|
|
121
|
+
readonly url: string;
|
|
122
|
+
} | {
|
|
123
|
+
readonly type: "file";
|
|
124
|
+
readonly file_id: string;
|
|
92
125
|
};
|
|
93
126
|
readonly cache_control?: {
|
|
94
127
|
readonly type: "ephemeral";
|
|
95
128
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
96
129
|
} | undefined;
|
|
130
|
+
readonly transformations?: {
|
|
131
|
+
readonly oversized_image?: "error" | "downsize" | undefined;
|
|
132
|
+
} | undefined;
|
|
97
133
|
} | {
|
|
98
134
|
readonly type: "document";
|
|
99
135
|
readonly source: {
|
|
100
136
|
readonly type: "base64";
|
|
101
137
|
readonly media_type: "application/pdf";
|
|
102
138
|
readonly data: string;
|
|
139
|
+
} | {
|
|
140
|
+
readonly type: "text";
|
|
141
|
+
readonly media_type: "text/plain";
|
|
142
|
+
readonly data: string;
|
|
143
|
+
} | {
|
|
144
|
+
readonly type: "url";
|
|
145
|
+
readonly url: string;
|
|
146
|
+
} | {
|
|
147
|
+
readonly type: "file";
|
|
148
|
+
readonly file_id: string;
|
|
103
149
|
};
|
|
150
|
+
readonly title?: string | undefined;
|
|
151
|
+
readonly context?: string | undefined;
|
|
104
152
|
readonly cache_control?: {
|
|
105
153
|
readonly type: "ephemeral";
|
|
106
154
|
readonly ttl?: "1h" | "5m" | undefined;
|
|
107
155
|
} | undefined;
|
|
156
|
+
readonly citations?: {
|
|
157
|
+
readonly enabled: boolean;
|
|
158
|
+
} | undefined;
|
|
108
159
|
})[];
|
|
109
160
|
readonly tool_use_id: string;
|
|
110
161
|
readonly cache_control?: {
|
|
@@ -187,6 +238,27 @@ export declare const routes: Route<{
|
|
|
187
238
|
} | {
|
|
188
239
|
readonly type: "disabled";
|
|
189
240
|
} | undefined;
|
|
241
|
+
service_tier?: "auto" | "standard_only" | undefined;
|
|
242
|
+
container?: string | {
|
|
243
|
+
readonly id?: string | null | undefined;
|
|
244
|
+
readonly skills?: readonly {
|
|
245
|
+
readonly [x: string]: unknown;
|
|
246
|
+
}[] | null | undefined;
|
|
247
|
+
} | null | undefined;
|
|
248
|
+
inference_geo?: string | null | undefined;
|
|
249
|
+
cache_control?: {
|
|
250
|
+
readonly type: "ephemeral";
|
|
251
|
+
readonly ttl?: "1h" | "5m" | undefined;
|
|
252
|
+
} | undefined;
|
|
253
|
+
output_config?: {
|
|
254
|
+
readonly format?: {
|
|
255
|
+
readonly type: "json_schema";
|
|
256
|
+
readonly schema: {
|
|
257
|
+
readonly [x: string]: unknown;
|
|
258
|
+
};
|
|
259
|
+
} | null | undefined;
|
|
260
|
+
readonly effort?: string | undefined;
|
|
261
|
+
} | undefined;
|
|
190
262
|
tool_choice?: {
|
|
191
263
|
readonly type: "auto" | "none" | "any";
|
|
192
264
|
readonly disable_parallel_tool_use?: boolean | undefined;
|
|
@@ -198,9 +270,6 @@ export declare const routes: Route<{
|
|
|
198
270
|
top_p?: number | undefined;
|
|
199
271
|
top_k?: number | undefined;
|
|
200
272
|
stop_sequences?: readonly string[] | undefined;
|
|
201
|
-
output_config?: {
|
|
202
|
-
readonly effort?: string | undefined;
|
|
203
|
-
} | undefined;
|
|
204
273
|
}, import("../route/transport/http.js").HttpPrepared<string>>[];
|
|
205
274
|
export declare const configure: (input?: Config) => {
|
|
206
275
|
id: string & import("effect/Brand").Brand<"AI.ProviderID">;
|
|
@@ -107,6 +107,7 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
107
107
|
readonly verbosity?: import("../protocols/utils/open-responses-options.js").TextVerbosity | undefined;
|
|
108
108
|
} | undefined;
|
|
109
109
|
readonly temperature?: number | undefined;
|
|
110
|
+
readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
|
|
110
111
|
readonly tool_choice?: "required" | "auto" | "none" | {
|
|
111
112
|
readonly type: "function";
|
|
112
113
|
readonly name: string;
|
|
@@ -130,7 +131,6 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
130
131
|
readonly presence_penalty?: number | undefined;
|
|
131
132
|
readonly safety_identifier?: string | undefined;
|
|
132
133
|
readonly top_logprobs?: number | undefined;
|
|
133
|
-
readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
|
|
134
134
|
readonly max_output_tokens?: number | undefined;
|
|
135
135
|
readonly max_tool_calls?: number | undefined;
|
|
136
136
|
readonly parallel_tool_calls?: boolean | undefined;
|
|
@@ -68,6 +68,7 @@ export declare const routes: Route<{
|
|
|
68
68
|
} | undefined;
|
|
69
69
|
}[];
|
|
70
70
|
}[] | undefined;
|
|
71
|
+
readonly serviceTier?: string | undefined;
|
|
71
72
|
readonly toolConfig?: {
|
|
72
73
|
readonly functionCallingConfig: {
|
|
73
74
|
readonly mode: "AUTO" | "NONE" | "ANY";
|
|
@@ -79,7 +80,6 @@ export declare const routes: Route<{
|
|
|
79
80
|
readonly category: string;
|
|
80
81
|
readonly threshold: string;
|
|
81
82
|
}[] | undefined;
|
|
82
|
-
readonly serviceTier?: string | undefined;
|
|
83
83
|
readonly labels?: {
|
|
84
84
|
readonly [x: string]: string;
|
|
85
85
|
} | undefined;
|
|
@@ -49,6 +49,7 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
49
49
|
} | undefined;
|
|
50
50
|
}[];
|
|
51
51
|
}[] | undefined;
|
|
52
|
+
readonly serviceTier?: string | undefined;
|
|
52
53
|
readonly toolConfig?: {
|
|
53
54
|
readonly functionCallingConfig: {
|
|
54
55
|
readonly mode: "AUTO" | "NONE" | "ANY";
|
|
@@ -60,7 +61,6 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
60
61
|
readonly category: string;
|
|
61
62
|
readonly threshold: string;
|
|
62
63
|
}[] | undefined;
|
|
63
|
-
readonly serviceTier?: string | undefined;
|
|
64
64
|
readonly labels?: {
|
|
65
65
|
readonly [x: string]: string;
|
|
66
66
|
} | undefined;
|
|
@@ -105,6 +105,7 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
105
105
|
readonly verbosity?: import("../protocols/utils/open-responses-options.js").TextVerbosity | undefined;
|
|
106
106
|
} | undefined;
|
|
107
107
|
readonly temperature?: number | undefined;
|
|
108
|
+
readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
|
|
108
109
|
readonly tool_choice?: "required" | "auto" | "none" | {
|
|
109
110
|
readonly type: "function";
|
|
110
111
|
readonly name: string;
|
|
@@ -128,7 +129,6 @@ export declare const routes: import("../route/client.js").Route<{
|
|
|
128
129
|
readonly presence_penalty?: number | undefined;
|
|
129
130
|
readonly safety_identifier?: string | undefined;
|
|
130
131
|
readonly top_logprobs?: number | undefined;
|
|
131
|
-
readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
|
|
132
132
|
readonly max_output_tokens?: number | undefined;
|
|
133
133
|
readonly max_tool_calls?: number | undefined;
|
|
134
134
|
readonly parallel_tool_calls?: boolean | undefined;
|
|
@@ -202,6 +202,7 @@ export declare const routes: (Route<{
|
|
|
202
202
|
readonly verbosity?: import("../protocols/utils/open-responses-options.js").TextVerbosity | undefined;
|
|
203
203
|
} | undefined;
|
|
204
204
|
readonly temperature?: number | undefined;
|
|
205
|
+
readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
|
|
205
206
|
readonly tool_choice?: "required" | "auto" | "none" | {
|
|
206
207
|
readonly type: "function";
|
|
207
208
|
readonly name: string;
|
|
@@ -227,7 +228,6 @@ export declare const routes: (Route<{
|
|
|
227
228
|
readonly presence_penalty?: number | undefined;
|
|
228
229
|
readonly safety_identifier?: string | undefined;
|
|
229
230
|
readonly top_logprobs?: number | undefined;
|
|
230
|
-
readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
|
|
231
231
|
readonly max_output_tokens?: number | undefined;
|
|
232
232
|
readonly max_tool_calls?: number | undefined;
|
|
233
233
|
readonly parallel_tool_calls?: boolean | undefined;
|
|
@@ -34,6 +34,7 @@ export declare const MediaPart: Schema.Struct<{
|
|
|
34
34
|
readonly mediaType: Schema.String;
|
|
35
35
|
readonly data: Schema.Union<readonly [Schema.String, Schema.Uint8Array]>;
|
|
36
36
|
readonly filename: Schema.optional<Schema.String>;
|
|
37
|
+
readonly cache: Schema.optional<typeof CacheHint>;
|
|
37
38
|
readonly metadata: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
|
|
38
39
|
}>;
|
|
39
40
|
export type MediaPart = Schema.Schema.Type<typeof MediaPart>;
|
|
@@ -175,6 +176,7 @@ export declare const ContentPart: Schema.toTaggedUnion<"type", readonly [Schema.
|
|
|
175
176
|
readonly mediaType: Schema.String;
|
|
176
177
|
readonly data: Schema.Union<readonly [Schema.String, Schema.Uint8Array]>;
|
|
177
178
|
readonly filename: Schema.optional<Schema.String>;
|
|
179
|
+
readonly cache: Schema.optional<typeof CacheHint>;
|
|
178
180
|
readonly metadata: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
|
|
179
181
|
}>, Schema.Struct<{
|
|
180
182
|
readonly type: Schema.Literal<"tool-call">;
|
|
@@ -247,6 +249,7 @@ declare const Message_base: Schema.Class<Message, Schema.Struct<{
|
|
|
247
249
|
readonly mediaType: Schema.String;
|
|
248
250
|
readonly data: Schema.Union<readonly [Schema.String, Schema.Uint8Array]>;
|
|
249
251
|
readonly filename: Schema.optional<Schema.String>;
|
|
252
|
+
readonly cache: Schema.optional<typeof CacheHint>;
|
|
250
253
|
readonly metadata: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
|
|
251
254
|
}>, Schema.Struct<{
|
|
252
255
|
readonly type: Schema.Literal<"tool-call">;
|
package/dist/schema/messages.js
CHANGED
|
@@ -33,6 +33,7 @@ export const MediaPart = Schema.Struct({
|
|
|
33
33
|
mediaType: Schema.String,
|
|
34
34
|
data: Schema.Union([Schema.String, Schema.Uint8Array]),
|
|
35
35
|
filename: Schema.optional(Schema.String),
|
|
36
|
+
cache: Schema.optional(CacheHint),
|
|
36
37
|
metadata: Schema.optional(Schema.Record(Schema.String, Schema.Unknown)),
|
|
37
38
|
}).annotate({ identifier: "LLM.Content.Media" });
|
|
38
39
|
const isToolResultValue = (value) => isRecord(value) &&
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
|
-
"version": "0.0.0-dev-
|
|
3
|
+
"version": "0.0.0-dev-18053",
|
|
4
4
|
"name": "@opencode-ai/ai",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"@clack/prompts": "1.0.0-alpha.1",
|
|
32
32
|
"@effect/platform-node": "4.0.0-rc.111",
|
|
33
|
-
"@opencode-ai/http-recorder": "0.0.0-dev-
|
|
33
|
+
"@opencode-ai/http-recorder": "0.0.0-dev-18053",
|
|
34
34
|
"@tsconfig/bun": "1.0.9",
|
|
35
35
|
"@types/bun": "1.3.13",
|
|
36
36
|
"@typescript/native-preview": "7.0.0-dev.20251207.1",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"dependencies": {
|
|
40
40
|
"@smithy/eventstream-codec": "4.2.14",
|
|
41
41
|
"@smithy/util-utf8": "4.2.2",
|
|
42
|
-
"@opencode-ai/schema": "0.0.0-dev-
|
|
42
|
+
"@opencode-ai/schema": "0.0.0-dev-18053",
|
|
43
43
|
"aws4fetch": "1.0.20",
|
|
44
44
|
"effect": "4.0.0-rc.111",
|
|
45
45
|
"google-auth-library": "10.5.0"
|