@opencode-ai/ai 0.0.0-next-16255 → 0.0.0-next-16273
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/llm.d.ts +60 -60
- package/dist/protocols/anthropic-messages.d.ts +303 -303
- package/dist/protocols/anthropic-messages.js +1 -0
- package/dist/protocols/bedrock-converse.d.ts +246 -242
- package/dist/protocols/gemini.d.ts +136 -132
- package/dist/protocols/gemini.js +1 -0
- package/dist/protocols/open-responses.d.ts +232 -232
- package/dist/protocols/openai-chat.d.ts +147 -141
- package/dist/protocols/openai-chat.js +1 -0
- package/dist/protocols/openai-compatible-chat.d.ts +48 -46
- package/dist/protocols/openai-compatible-responses.d.ts +56 -56
- package/dist/protocols/openai-responses.d.ts +388 -388
- package/dist/protocols/shared.d.ts +5 -4
- package/dist/protocols/shared.js +1 -0
- package/dist/protocols/utils/bedrock-media.d.ts +10 -10
- package/dist/protocols/utils/tool-stream.d.ts +180 -180
- package/dist/providers/amazon-bedrock.d.ts +109 -107
- package/dist/providers/anthropic-compatible.d.ts +145 -145
- package/dist/providers/anthropic.d.ts +145 -145
- package/dist/providers/azure.d.ts +112 -110
- package/dist/providers/cloudflare.d.ts +144 -138
- package/dist/providers/github-copilot.d.ts +112 -110
- package/dist/providers/google-vertex-chat.d.ts +48 -46
- package/dist/providers/google-vertex-messages.d.ts +145 -146
- package/dist/providers/google-vertex-responses.d.ts +56 -56
- package/dist/providers/google-vertex.d.ts +52 -50
- package/dist/providers/google.d.ts +52 -50
- package/dist/providers/openai-compatible-responses.d.ts +56 -56
- package/dist/providers/openai-compatible.d.ts +48 -46
- package/dist/providers/openai.d.ts +176 -174
- package/dist/providers/openrouter.d.ts +147 -141
- package/dist/providers/xai.d.ts +112 -110
- package/dist/route/client.d.ts +60 -60
- package/dist/schema/errors.d.ts +2 -6
- package/dist/schema/errors.js +2 -5
- package/dist/schema/events.d.ts +1117 -1115
- package/dist/schema/messages.d.ts +9 -9
- package/dist/schema/messages.js +3 -4
- package/dist/tool-runtime.js +1 -1
- package/dist/tool.d.ts +5 -4
- package/dist/tool.js +1 -0
- package/package.json +5 -5
|
@@ -89,66 +89,68 @@ declare const OpenRouterBody: Schema.StructWithRest<Schema.Struct<{
|
|
|
89
89
|
export type OpenRouterBody = Schema.Schema.Type<typeof OpenRouterBody>;
|
|
90
90
|
export declare const protocol: Protocol<{
|
|
91
91
|
readonly [x: string]: any;
|
|
92
|
-
readonly
|
|
93
|
-
|
|
94
|
-
readonly
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
readonly
|
|
98
|
-
|
|
99
|
-
readonly
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
readonly
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
92
|
+
readonly model: string;
|
|
93
|
+
readonly messages: readonly ({
|
|
94
|
+
readonly role: "system";
|
|
95
|
+
readonly content: string;
|
|
96
|
+
} | {
|
|
97
|
+
readonly role: "user";
|
|
98
|
+
readonly content: string | readonly ({
|
|
99
|
+
readonly type: "text";
|
|
100
|
+
readonly text: string;
|
|
101
|
+
} | {
|
|
102
|
+
readonly type: "image_url";
|
|
103
|
+
readonly image_url: {
|
|
104
|
+
readonly url: string;
|
|
105
|
+
};
|
|
106
|
+
})[];
|
|
107
|
+
} | {
|
|
107
108
|
readonly [x: string]: unknown;
|
|
108
109
|
readonly content: string | null;
|
|
109
110
|
readonly role: "assistant";
|
|
110
111
|
readonly reasoning?: string | undefined;
|
|
111
|
-
readonly tool_calls?: readonly Schema.Struct.ReadonlySide<{
|
|
112
|
-
readonly id: Schema.String;
|
|
113
|
-
readonly type: Schema.tag<"function">;
|
|
114
|
-
readonly function: Schema.Struct<{
|
|
115
|
-
readonly name: Schema.String;
|
|
116
|
-
readonly arguments: Schema.String;
|
|
117
|
-
}>;
|
|
118
|
-
}, "Type">[] | undefined;
|
|
119
112
|
readonly reasoning_content?: string | undefined;
|
|
120
113
|
readonly reasoning_text?: string | undefined;
|
|
114
|
+
readonly tool_calls?: readonly {
|
|
115
|
+
readonly id: string;
|
|
116
|
+
readonly type: "function";
|
|
117
|
+
readonly function: {
|
|
118
|
+
readonly name: string;
|
|
119
|
+
readonly arguments: string;
|
|
120
|
+
};
|
|
121
|
+
}[] | undefined;
|
|
121
122
|
readonly reasoning_details?: unknown;
|
|
122
|
-
} |
|
|
123
|
-
readonly role:
|
|
124
|
-
readonly tool_call_id:
|
|
125
|
-
readonly content:
|
|
126
|
-
}
|
|
127
|
-
readonly model: string;
|
|
123
|
+
} | {
|
|
124
|
+
readonly role: "tool";
|
|
125
|
+
readonly tool_call_id: string;
|
|
126
|
+
readonly content: string;
|
|
127
|
+
})[];
|
|
128
128
|
readonly stream: true;
|
|
129
129
|
readonly stop?: readonly string[] | undefined;
|
|
130
|
-
readonly tools?: readonly
|
|
131
|
-
readonly type:
|
|
132
|
-
readonly function:
|
|
133
|
-
readonly name:
|
|
134
|
-
readonly description:
|
|
135
|
-
readonly parameters:
|
|
136
|
-
|
|
137
|
-
|
|
130
|
+
readonly tools?: readonly {
|
|
131
|
+
readonly type: "function";
|
|
132
|
+
readonly function: {
|
|
133
|
+
readonly name: string;
|
|
134
|
+
readonly description: string;
|
|
135
|
+
readonly parameters: {
|
|
136
|
+
readonly [x: string]: unknown;
|
|
137
|
+
};
|
|
138
|
+
};
|
|
139
|
+
}[] | undefined;
|
|
138
140
|
readonly temperature?: number | undefined;
|
|
139
141
|
readonly seed?: number | undefined;
|
|
140
142
|
readonly frequency_penalty?: number | undefined;
|
|
141
143
|
readonly max_tokens?: number | undefined;
|
|
142
144
|
readonly presence_penalty?: number | undefined;
|
|
143
|
-
readonly stream_options?:
|
|
144
|
-
readonly include_usage:
|
|
145
|
-
}
|
|
146
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
147
|
-
readonly type:
|
|
148
|
-
readonly function:
|
|
149
|
-
readonly name:
|
|
150
|
-
}
|
|
151
|
-
}
|
|
145
|
+
readonly stream_options?: {
|
|
146
|
+
readonly include_usage: boolean;
|
|
147
|
+
} | undefined;
|
|
148
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
149
|
+
readonly type: "function";
|
|
150
|
+
readonly function: {
|
|
151
|
+
readonly name: string;
|
|
152
|
+
};
|
|
153
|
+
} | undefined;
|
|
152
154
|
readonly top_p?: number | undefined;
|
|
153
155
|
readonly store?: boolean | undefined;
|
|
154
156
|
readonly reasoning_effort?: string | undefined;
|
|
@@ -172,8 +174,10 @@ export declare const protocol: Protocol<{
|
|
|
172
174
|
readonly choices?: readonly {
|
|
173
175
|
readonly delta?: {
|
|
174
176
|
readonly [x: string]: unknown;
|
|
175
|
-
readonly content?: string | null | undefined;
|
|
176
177
|
readonly reasoning?: string | null | undefined;
|
|
178
|
+
readonly reasoning_content?: string | null | undefined;
|
|
179
|
+
readonly reasoning_text?: string | null | undefined;
|
|
180
|
+
readonly content?: string | null | undefined;
|
|
177
181
|
readonly tool_calls?: readonly {
|
|
178
182
|
readonly index: number;
|
|
179
183
|
readonly function?: {
|
|
@@ -182,8 +186,6 @@ export declare const protocol: Protocol<{
|
|
|
182
186
|
} | null | undefined;
|
|
183
187
|
readonly id?: string | null | undefined;
|
|
184
188
|
}[] | null | undefined;
|
|
185
|
-
readonly reasoning_content?: string | null | undefined;
|
|
186
|
-
readonly reasoning_text?: string | null | undefined;
|
|
187
189
|
readonly reasoning_details?: unknown;
|
|
188
190
|
} | null | undefined;
|
|
189
191
|
readonly finish_reason?: string | null | undefined;
|
|
@@ -192,132 +194,136 @@ export declare const protocol: Protocol<{
|
|
|
192
194
|
}, OpenAIChat.ParserState>;
|
|
193
195
|
export declare const route: Route<{
|
|
194
196
|
readonly [x: string]: any;
|
|
195
|
-
readonly
|
|
196
|
-
|
|
197
|
-
readonly
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
readonly
|
|
201
|
-
|
|
202
|
-
readonly
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
readonly
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
197
|
+
readonly model: string;
|
|
198
|
+
readonly messages: readonly ({
|
|
199
|
+
readonly role: "system";
|
|
200
|
+
readonly content: string;
|
|
201
|
+
} | {
|
|
202
|
+
readonly role: "user";
|
|
203
|
+
readonly content: string | readonly ({
|
|
204
|
+
readonly type: "text";
|
|
205
|
+
readonly text: string;
|
|
206
|
+
} | {
|
|
207
|
+
readonly type: "image_url";
|
|
208
|
+
readonly image_url: {
|
|
209
|
+
readonly url: string;
|
|
210
|
+
};
|
|
211
|
+
})[];
|
|
212
|
+
} | {
|
|
210
213
|
readonly [x: string]: unknown;
|
|
211
214
|
readonly content: string | null;
|
|
212
215
|
readonly role: "assistant";
|
|
213
216
|
readonly reasoning?: string | undefined;
|
|
214
|
-
readonly tool_calls?: readonly Schema.Struct.ReadonlySide<{
|
|
215
|
-
readonly id: Schema.String;
|
|
216
|
-
readonly type: Schema.tag<"function">;
|
|
217
|
-
readonly function: Schema.Struct<{
|
|
218
|
-
readonly name: Schema.String;
|
|
219
|
-
readonly arguments: Schema.String;
|
|
220
|
-
}>;
|
|
221
|
-
}, "Type">[] | undefined;
|
|
222
217
|
readonly reasoning_content?: string | undefined;
|
|
223
218
|
readonly reasoning_text?: string | undefined;
|
|
219
|
+
readonly tool_calls?: readonly {
|
|
220
|
+
readonly id: string;
|
|
221
|
+
readonly type: "function";
|
|
222
|
+
readonly function: {
|
|
223
|
+
readonly name: string;
|
|
224
|
+
readonly arguments: string;
|
|
225
|
+
};
|
|
226
|
+
}[] | undefined;
|
|
224
227
|
readonly reasoning_details?: unknown;
|
|
225
|
-
} |
|
|
226
|
-
readonly role:
|
|
227
|
-
readonly tool_call_id:
|
|
228
|
-
readonly content:
|
|
229
|
-
}
|
|
230
|
-
readonly model: string;
|
|
228
|
+
} | {
|
|
229
|
+
readonly role: "tool";
|
|
230
|
+
readonly tool_call_id: string;
|
|
231
|
+
readonly content: string;
|
|
232
|
+
})[];
|
|
231
233
|
readonly stream: true;
|
|
232
234
|
readonly stop?: readonly string[] | undefined;
|
|
233
|
-
readonly tools?: readonly
|
|
234
|
-
readonly type:
|
|
235
|
-
readonly function:
|
|
236
|
-
readonly name:
|
|
237
|
-
readonly description:
|
|
238
|
-
readonly parameters:
|
|
239
|
-
|
|
240
|
-
|
|
235
|
+
readonly tools?: readonly {
|
|
236
|
+
readonly type: "function";
|
|
237
|
+
readonly function: {
|
|
238
|
+
readonly name: string;
|
|
239
|
+
readonly description: string;
|
|
240
|
+
readonly parameters: {
|
|
241
|
+
readonly [x: string]: unknown;
|
|
242
|
+
};
|
|
243
|
+
};
|
|
244
|
+
}[] | undefined;
|
|
241
245
|
readonly temperature?: number | undefined;
|
|
242
246
|
readonly seed?: number | undefined;
|
|
243
247
|
readonly frequency_penalty?: number | undefined;
|
|
244
248
|
readonly max_tokens?: number | undefined;
|
|
245
249
|
readonly presence_penalty?: number | undefined;
|
|
246
|
-
readonly stream_options?:
|
|
247
|
-
readonly include_usage:
|
|
248
|
-
}
|
|
249
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
250
|
-
readonly type:
|
|
251
|
-
readonly function:
|
|
252
|
-
readonly name:
|
|
253
|
-
}
|
|
254
|
-
}
|
|
250
|
+
readonly stream_options?: {
|
|
251
|
+
readonly include_usage: boolean;
|
|
252
|
+
} | undefined;
|
|
253
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
254
|
+
readonly type: "function";
|
|
255
|
+
readonly function: {
|
|
256
|
+
readonly name: string;
|
|
257
|
+
};
|
|
258
|
+
} | undefined;
|
|
255
259
|
readonly top_p?: number | undefined;
|
|
256
260
|
readonly store?: boolean | undefined;
|
|
257
261
|
readonly reasoning_effort?: string | undefined;
|
|
258
262
|
}, import("../route/transport/http").HttpPrepared<string>>;
|
|
259
263
|
export declare const routes: Route<{
|
|
260
264
|
readonly [x: string]: any;
|
|
261
|
-
readonly
|
|
262
|
-
|
|
263
|
-
readonly
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
readonly
|
|
267
|
-
|
|
268
|
-
readonly
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
readonly
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
265
|
+
readonly model: string;
|
|
266
|
+
readonly messages: readonly ({
|
|
267
|
+
readonly role: "system";
|
|
268
|
+
readonly content: string;
|
|
269
|
+
} | {
|
|
270
|
+
readonly role: "user";
|
|
271
|
+
readonly content: string | readonly ({
|
|
272
|
+
readonly type: "text";
|
|
273
|
+
readonly text: string;
|
|
274
|
+
} | {
|
|
275
|
+
readonly type: "image_url";
|
|
276
|
+
readonly image_url: {
|
|
277
|
+
readonly url: string;
|
|
278
|
+
};
|
|
279
|
+
})[];
|
|
280
|
+
} | {
|
|
276
281
|
readonly [x: string]: unknown;
|
|
277
282
|
readonly content: string | null;
|
|
278
283
|
readonly role: "assistant";
|
|
279
284
|
readonly reasoning?: string | undefined;
|
|
280
|
-
readonly tool_calls?: readonly Schema.Struct.ReadonlySide<{
|
|
281
|
-
readonly id: Schema.String;
|
|
282
|
-
readonly type: Schema.tag<"function">;
|
|
283
|
-
readonly function: Schema.Struct<{
|
|
284
|
-
readonly name: Schema.String;
|
|
285
|
-
readonly arguments: Schema.String;
|
|
286
|
-
}>;
|
|
287
|
-
}, "Type">[] | undefined;
|
|
288
285
|
readonly reasoning_content?: string | undefined;
|
|
289
286
|
readonly reasoning_text?: string | undefined;
|
|
287
|
+
readonly tool_calls?: readonly {
|
|
288
|
+
readonly id: string;
|
|
289
|
+
readonly type: "function";
|
|
290
|
+
readonly function: {
|
|
291
|
+
readonly name: string;
|
|
292
|
+
readonly arguments: string;
|
|
293
|
+
};
|
|
294
|
+
}[] | undefined;
|
|
290
295
|
readonly reasoning_details?: unknown;
|
|
291
|
-
} |
|
|
292
|
-
readonly role:
|
|
293
|
-
readonly tool_call_id:
|
|
294
|
-
readonly content:
|
|
295
|
-
}
|
|
296
|
-
readonly model: string;
|
|
296
|
+
} | {
|
|
297
|
+
readonly role: "tool";
|
|
298
|
+
readonly tool_call_id: string;
|
|
299
|
+
readonly content: string;
|
|
300
|
+
})[];
|
|
297
301
|
readonly stream: true;
|
|
298
302
|
readonly stop?: readonly string[] | undefined;
|
|
299
|
-
readonly tools?: readonly
|
|
300
|
-
readonly type:
|
|
301
|
-
readonly function:
|
|
302
|
-
readonly name:
|
|
303
|
-
readonly description:
|
|
304
|
-
readonly parameters:
|
|
305
|
-
|
|
306
|
-
|
|
303
|
+
readonly tools?: readonly {
|
|
304
|
+
readonly type: "function";
|
|
305
|
+
readonly function: {
|
|
306
|
+
readonly name: string;
|
|
307
|
+
readonly description: string;
|
|
308
|
+
readonly parameters: {
|
|
309
|
+
readonly [x: string]: unknown;
|
|
310
|
+
};
|
|
311
|
+
};
|
|
312
|
+
}[] | undefined;
|
|
307
313
|
readonly temperature?: number | undefined;
|
|
308
314
|
readonly seed?: number | undefined;
|
|
309
315
|
readonly frequency_penalty?: number | undefined;
|
|
310
316
|
readonly max_tokens?: number | undefined;
|
|
311
317
|
readonly presence_penalty?: number | undefined;
|
|
312
|
-
readonly stream_options?:
|
|
313
|
-
readonly include_usage:
|
|
314
|
-
}
|
|
315
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
316
|
-
readonly type:
|
|
317
|
-
readonly function:
|
|
318
|
-
readonly name:
|
|
319
|
-
}
|
|
320
|
-
}
|
|
318
|
+
readonly stream_options?: {
|
|
319
|
+
readonly include_usage: boolean;
|
|
320
|
+
} | undefined;
|
|
321
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
322
|
+
readonly type: "function";
|
|
323
|
+
readonly function: {
|
|
324
|
+
readonly name: string;
|
|
325
|
+
};
|
|
326
|
+
} | undefined;
|
|
321
327
|
readonly top_p?: number | undefined;
|
|
322
328
|
readonly store?: boolean | undefined;
|
|
323
329
|
readonly reasoning_effort?: string | undefined;
|
package/dist/providers/xai.d.ts
CHANGED
|
@@ -7,130 +7,132 @@ export type ModelOptions = RouteDefaultsInput & ProviderAuthOption<"optional"> &
|
|
|
7
7
|
};
|
|
8
8
|
export type { XAIImageOptions } from "../protocols/xai-images";
|
|
9
9
|
export declare const routes: (import("../route").Route<{
|
|
10
|
-
readonly
|
|
11
|
-
|
|
12
|
-
readonly
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
readonly
|
|
16
|
-
|
|
17
|
-
readonly
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
readonly
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
10
|
+
readonly model: string;
|
|
11
|
+
readonly messages: readonly ({
|
|
12
|
+
readonly role: "system";
|
|
13
|
+
readonly content: string;
|
|
14
|
+
} | {
|
|
15
|
+
readonly role: "user";
|
|
16
|
+
readonly content: string | readonly ({
|
|
17
|
+
readonly type: "text";
|
|
18
|
+
readonly text: string;
|
|
19
|
+
} | {
|
|
20
|
+
readonly type: "image_url";
|
|
21
|
+
readonly image_url: {
|
|
22
|
+
readonly url: string;
|
|
23
|
+
};
|
|
24
|
+
})[];
|
|
25
|
+
} | {
|
|
25
26
|
readonly [x: string]: unknown;
|
|
26
27
|
readonly content: string | null;
|
|
27
28
|
readonly role: "assistant";
|
|
28
29
|
readonly reasoning?: string | undefined;
|
|
29
|
-
readonly tool_calls?: readonly import("effect/Schema").Struct.ReadonlySide<{
|
|
30
|
-
readonly id: import("effect/Schema").String;
|
|
31
|
-
readonly type: import("effect/Schema").tag<"function">;
|
|
32
|
-
readonly function: import("effect/Schema").Struct<{
|
|
33
|
-
readonly name: import("effect/Schema").String;
|
|
34
|
-
readonly arguments: import("effect/Schema").String;
|
|
35
|
-
}>;
|
|
36
|
-
}, "Type">[] | undefined;
|
|
37
30
|
readonly reasoning_content?: string | undefined;
|
|
38
31
|
readonly reasoning_text?: string | undefined;
|
|
32
|
+
readonly tool_calls?: readonly {
|
|
33
|
+
readonly id: string;
|
|
34
|
+
readonly type: "function";
|
|
35
|
+
readonly function: {
|
|
36
|
+
readonly name: string;
|
|
37
|
+
readonly arguments: string;
|
|
38
|
+
};
|
|
39
|
+
}[] | undefined;
|
|
39
40
|
readonly reasoning_details?: unknown;
|
|
40
|
-
} |
|
|
41
|
-
readonly role:
|
|
42
|
-
readonly tool_call_id:
|
|
43
|
-
readonly content:
|
|
44
|
-
}
|
|
45
|
-
readonly model: string;
|
|
41
|
+
} | {
|
|
42
|
+
readonly role: "tool";
|
|
43
|
+
readonly tool_call_id: string;
|
|
44
|
+
readonly content: string;
|
|
45
|
+
})[];
|
|
46
46
|
readonly stream: true;
|
|
47
47
|
readonly stop?: readonly string[] | undefined;
|
|
48
|
-
readonly tools?: readonly
|
|
49
|
-
readonly type:
|
|
50
|
-
readonly function:
|
|
51
|
-
readonly name:
|
|
52
|
-
readonly description:
|
|
53
|
-
readonly parameters:
|
|
54
|
-
|
|
55
|
-
|
|
48
|
+
readonly tools?: readonly {
|
|
49
|
+
readonly type: "function";
|
|
50
|
+
readonly function: {
|
|
51
|
+
readonly name: string;
|
|
52
|
+
readonly description: string;
|
|
53
|
+
readonly parameters: {
|
|
54
|
+
readonly [x: string]: unknown;
|
|
55
|
+
};
|
|
56
|
+
};
|
|
57
|
+
}[] | undefined;
|
|
56
58
|
readonly temperature?: number | undefined;
|
|
57
59
|
readonly seed?: number | undefined;
|
|
58
60
|
readonly frequency_penalty?: number | undefined;
|
|
59
61
|
readonly max_tokens?: number | undefined;
|
|
60
62
|
readonly presence_penalty?: number | undefined;
|
|
61
|
-
readonly stream_options?:
|
|
62
|
-
readonly include_usage:
|
|
63
|
-
}
|
|
64
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
65
|
-
readonly type:
|
|
66
|
-
readonly function:
|
|
67
|
-
readonly name:
|
|
68
|
-
}
|
|
69
|
-
}
|
|
63
|
+
readonly stream_options?: {
|
|
64
|
+
readonly include_usage: boolean;
|
|
65
|
+
} | undefined;
|
|
66
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
67
|
+
readonly type: "function";
|
|
68
|
+
readonly function: {
|
|
69
|
+
readonly name: string;
|
|
70
|
+
};
|
|
71
|
+
} | undefined;
|
|
70
72
|
readonly top_p?: number | undefined;
|
|
71
73
|
readonly store?: boolean | undefined;
|
|
72
74
|
readonly reasoning_effort?: string | undefined;
|
|
73
75
|
}, import("../route/transport/http").HttpPrepared<string>> | import("../route").Route<{
|
|
74
76
|
readonly input: readonly ({
|
|
75
77
|
readonly type: "reasoning";
|
|
76
|
-
readonly summary: readonly
|
|
77
|
-
readonly type:
|
|
78
|
-
readonly text:
|
|
79
|
-
}
|
|
78
|
+
readonly summary: readonly {
|
|
79
|
+
readonly type: "summary_text";
|
|
80
|
+
readonly text: string;
|
|
81
|
+
}[];
|
|
80
82
|
readonly id?: string | undefined;
|
|
81
83
|
readonly encrypted_content?: string | null | undefined;
|
|
82
|
-
} |
|
|
83
|
-
readonly type:
|
|
84
|
-
readonly id:
|
|
85
|
-
}
|
|
86
|
-
readonly role:
|
|
87
|
-
readonly content:
|
|
88
|
-
}
|
|
89
|
-
readonly role:
|
|
90
|
-
readonly content:
|
|
91
|
-
readonly type:
|
|
92
|
-
readonly
|
|
93
|
-
}
|
|
94
|
-
readonly type:
|
|
95
|
-
readonly
|
|
96
|
-
|
|
97
|
-
readonly
|
|
98
|
-
|
|
99
|
-
readonly
|
|
100
|
-
readonly
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
readonly content: readonly
|
|
104
|
-
readonly type:
|
|
105
|
-
readonly text:
|
|
106
|
-
}
|
|
84
|
+
} | {
|
|
85
|
+
readonly type: "item_reference";
|
|
86
|
+
readonly id: string;
|
|
87
|
+
} | {
|
|
88
|
+
readonly role: "system";
|
|
89
|
+
readonly content: string;
|
|
90
|
+
} | {
|
|
91
|
+
readonly role: "user";
|
|
92
|
+
readonly content: readonly ({
|
|
93
|
+
readonly type: "input_image";
|
|
94
|
+
readonly image_url: string;
|
|
95
|
+
} | {
|
|
96
|
+
readonly type: "input_file";
|
|
97
|
+
readonly filename: string;
|
|
98
|
+
readonly file_data: string;
|
|
99
|
+
readonly mime_type?: string | undefined;
|
|
100
|
+
} | {
|
|
101
|
+
readonly type: "input_text";
|
|
102
|
+
readonly text: string;
|
|
103
|
+
})[];
|
|
104
|
+
} | {
|
|
105
|
+
readonly content: readonly {
|
|
106
|
+
readonly type: "output_text";
|
|
107
|
+
readonly text: string;
|
|
108
|
+
}[];
|
|
107
109
|
readonly role: "assistant";
|
|
108
110
|
readonly phase?: "commentary" | "final_answer" | undefined;
|
|
109
|
-
} |
|
|
110
|
-
readonly type:
|
|
111
|
-
readonly call_id:
|
|
112
|
-
readonly name:
|
|
113
|
-
readonly arguments:
|
|
114
|
-
}
|
|
115
|
-
readonly type:
|
|
116
|
-
readonly call_id:
|
|
117
|
-
readonly output:
|
|
118
|
-
readonly type:
|
|
119
|
-
readonly
|
|
120
|
-
}
|
|
121
|
-
readonly type:
|
|
122
|
-
readonly
|
|
123
|
-
|
|
124
|
-
readonly
|
|
125
|
-
|
|
126
|
-
readonly
|
|
127
|
-
readonly
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
readonly content: readonly
|
|
131
|
-
readonly type:
|
|
132
|
-
readonly text:
|
|
133
|
-
}
|
|
111
|
+
} | {
|
|
112
|
+
readonly type: "function_call";
|
|
113
|
+
readonly call_id: string;
|
|
114
|
+
readonly name: string;
|
|
115
|
+
readonly arguments: string;
|
|
116
|
+
} | {
|
|
117
|
+
readonly type: "function_call_output";
|
|
118
|
+
readonly call_id: string;
|
|
119
|
+
readonly output: string | readonly ({
|
|
120
|
+
readonly type: "input_image";
|
|
121
|
+
readonly image_url: string;
|
|
122
|
+
} | {
|
|
123
|
+
readonly type: "input_file";
|
|
124
|
+
readonly filename: string;
|
|
125
|
+
readonly file_data: string;
|
|
126
|
+
readonly mime_type?: string | undefined;
|
|
127
|
+
} | {
|
|
128
|
+
readonly type: "input_text";
|
|
129
|
+
readonly text: string;
|
|
130
|
+
})[];
|
|
131
|
+
} | {
|
|
132
|
+
readonly content: readonly {
|
|
133
|
+
readonly type: "output_text";
|
|
134
|
+
readonly text: string;
|
|
135
|
+
}[];
|
|
134
136
|
readonly role: "assistant";
|
|
135
137
|
readonly phase?: "commentary" | "final_answer" | null | undefined;
|
|
136
138
|
})[];
|
|
@@ -139,9 +141,10 @@ export declare const routes: (import("../route").Route<{
|
|
|
139
141
|
readonly text?: {
|
|
140
142
|
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
141
143
|
} | undefined;
|
|
144
|
+
readonly instructions?: string | undefined;
|
|
142
145
|
readonly reasoning?: {
|
|
143
|
-
readonly effort?: string | undefined;
|
|
144
146
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
147
|
+
readonly effort?: string | undefined;
|
|
145
148
|
} | undefined;
|
|
146
149
|
readonly tools?: readonly ({
|
|
147
150
|
readonly type: "function";
|
|
@@ -153,25 +156,24 @@ export declare const routes: (import("../route").Route<{
|
|
|
153
156
|
readonly strict?: boolean | undefined;
|
|
154
157
|
} | {
|
|
155
158
|
readonly type: "image_generation";
|
|
156
|
-
readonly output_format?: "png" | "jpeg" | "webp" | undefined;
|
|
157
159
|
readonly size?: string | undefined;
|
|
160
|
+
readonly action?: "generate" | "auto" | "edit" | undefined;
|
|
161
|
+
readonly output_format?: "png" | "jpeg" | "webp" | undefined;
|
|
158
162
|
readonly quality?: "low" | "medium" | "high" | "auto" | undefined;
|
|
159
163
|
readonly background?: "auto" | "opaque" | "transparent" | undefined;
|
|
160
164
|
readonly output_compression?: number | undefined;
|
|
161
|
-
readonly action?: "generate" | "auto" | "edit" | undefined;
|
|
162
165
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
163
166
|
readonly partial_images?: number | undefined;
|
|
164
167
|
})[] | undefined;
|
|
165
168
|
readonly temperature?: number | undefined;
|
|
166
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
167
|
-
readonly type:
|
|
168
|
-
readonly name:
|
|
169
|
-
}
|
|
170
|
-
readonly type:
|
|
171
|
-
}
|
|
169
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
170
|
+
readonly type: "function";
|
|
171
|
+
readonly name: string;
|
|
172
|
+
} | {
|
|
173
|
+
readonly type: "image_generation";
|
|
174
|
+
} | undefined;
|
|
172
175
|
readonly top_p?: number | undefined;
|
|
173
176
|
readonly include?: readonly ("file_search_call.results" | "web_search_call.results" | "web_search_call.action.sources" | "message.input_image.image_url" | "computer_call_output.output.image_url" | "code_interpreter_call.outputs" | "reasoning.encrypted_content" | "message.output_text.logprobs")[] | undefined;
|
|
174
|
-
readonly instructions?: string | undefined;
|
|
175
177
|
readonly store?: boolean | undefined;
|
|
176
178
|
readonly service_tier?: "auto" | "default" | "flex" | "priority" | undefined;
|
|
177
179
|
readonly prompt_cache_key?: string | undefined;
|