@opencode/ai 2.0.31 → 2.1.0

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.
Files changed (152) hide show
  1. package/dist/ai-client.d.ts +2 -2
  2. package/dist/experimental/evaluation-client.d.ts +1 -1
  3. package/dist/experimental/evaluation.d.ts +20 -20
  4. package/dist/experimental/realtime.d.ts +47 -0
  5. package/dist/experimental/realtime.js +99 -0
  6. package/dist/experimental/system-one.d.ts +1 -1
  7. package/dist/experimental.d.ts +2 -0
  8. package/dist/experimental.js +1 -0
  9. package/dist/image-client.d.ts +8 -8
  10. package/dist/image.d.ts +593 -437
  11. package/dist/llm.d.ts +51 -51
  12. package/dist/media-client.d.ts +1 -1
  13. package/dist/media.d.ts +4 -4
  14. package/dist/promise.d.ts +199 -198
  15. package/dist/protocols/alibaba-chat.d.ts +81 -82
  16. package/dist/protocols/alibaba-chat.js +0 -1
  17. package/dist/protocols/alibaba-messages.d.ts +99 -99
  18. package/dist/protocols/alibaba-responses.d.ts +120 -120
  19. package/dist/protocols/anthropic-messages.d.ts +187 -187
  20. package/dist/protocols/anthropic-messages.js +3 -2
  21. package/dist/protocols/assemblyai-transcription.d.ts +1 -1
  22. package/dist/protocols/bedrock-converse.d.ts +75 -79
  23. package/dist/protocols/bfl-images.d.ts +1 -1
  24. package/dist/protocols/cartesia-speech.d.ts +17 -17
  25. package/dist/protocols/cohere-chat.d.ts +26 -23
  26. package/dist/protocols/cohere-chat.js +22 -1
  27. package/dist/protocols/deepgram-speech.d.ts +17 -17
  28. package/dist/protocols/deepgram-transcription.d.ts +1 -1
  29. package/dist/protocols/elevenlabs-speech.d.ts +17 -17
  30. package/dist/protocols/elevenlabs-transcription.d.ts +1 -1
  31. package/dist/protocols/fal-images.d.ts +1 -1
  32. package/dist/protocols/fal-video.d.ts +1 -1
  33. package/dist/protocols/gemini.d.ts +55 -55
  34. package/dist/protocols/gemini.js +11 -1
  35. package/dist/protocols/google-images.d.ts +1 -1
  36. package/dist/protocols/google-interactions.d.ts +64 -62
  37. package/dist/protocols/google-interactions.js +19 -1
  38. package/dist/protocols/google-speech.d.ts +17 -17
  39. package/dist/protocols/google-transcription.d.ts +47 -47
  40. package/dist/protocols/google-video.d.ts +1 -1
  41. package/dist/protocols/meta-messages.d.ts +121 -121
  42. package/dist/protocols/meta-responses.d.ts +201 -201
  43. package/dist/protocols/mistral-chat.d.ts +45 -45
  44. package/dist/protocols/open-responses-channel.d.ts +1 -1
  45. package/dist/protocols/open-responses.d.ts +584 -450
  46. package/dist/protocols/open-responses.js +27 -35
  47. package/dist/protocols/openai-chat.d.ts +248 -248
  48. package/dist/protocols/openai-chat.js +11 -42
  49. package/dist/protocols/openai-compatible-chat.d.ts +32 -32
  50. package/dist/protocols/openai-compatible-responses.d.ts +88 -88
  51. package/dist/protocols/openai-images.d.ts +17 -17
  52. package/dist/protocols/openai-responses.d.ts +567 -567
  53. package/dist/protocols/openai-responses.js +1 -1
  54. package/dist/protocols/openai-speech.d.ts +17 -17
  55. package/dist/protocols/openai-transcription.d.ts +47 -47
  56. package/dist/protocols/replicate-images.d.ts +1 -1
  57. package/dist/protocols/runway-video.d.ts +1 -1
  58. package/dist/protocols/shared.d.ts +12 -1
  59. package/dist/protocols/shared.js +17 -1
  60. package/dist/protocols/stability-images.d.ts +2 -2
  61. package/dist/protocols/utils/bedrock-cache.d.ts +2 -2
  62. package/dist/protocols/utils/bedrock-media.d.ts +4 -4
  63. package/dist/protocols/utils/openai-options.d.ts +1 -1
  64. package/dist/protocols/utils/speech-stream.d.ts +1 -1
  65. package/dist/protocols/utils/tool-schema.d.ts +10 -5
  66. package/dist/protocols/utils/tool-stream.d.ts +152 -152
  67. package/dist/protocols/venice-chat.d.ts +109 -110
  68. package/dist/protocols/venice-chat.js +0 -1
  69. package/dist/protocols/xai-images.d.ts +1 -1
  70. package/dist/protocols/xai-responses.d.ts +79 -79
  71. package/dist/protocols/xai-video.d.ts +1 -1
  72. package/dist/protocols/zai-chat.d.ts +77 -78
  73. package/dist/protocols/zai-chat.js +0 -1
  74. package/dist/protocols/zai-images.d.ts +1 -1
  75. package/dist/protocols/zai-messages.d.ts +97 -97
  76. package/dist/providers/alibaba.d.ts +222 -283
  77. package/dist/providers/amazon-bedrock-mantle.d.ts +291 -298
  78. package/dist/providers/amazon-bedrock.d.ts +22 -28
  79. package/dist/providers/anthropic-compatible.d.ts +86 -90
  80. package/dist/providers/anthropic.d.ts +86 -90
  81. package/dist/providers/assemblyai.d.ts +2 -6
  82. package/dist/providers/azure.d.ts +228 -238
  83. package/dist/providers/baseten.d.ts +66 -70
  84. package/dist/providers/black-forest-labs.d.ts +2 -6
  85. package/dist/providers/cartesia.d.ts +2 -6
  86. package/dist/providers/cerebras.d.ts +66 -70
  87. package/dist/providers/cerebras.js +0 -1
  88. package/dist/providers/cloudflare-ai-gateway.d.ts +352 -356
  89. package/dist/providers/cloudflare-workers-ai.d.ts +66 -70
  90. package/dist/providers/cohere.d.ts +122 -132
  91. package/dist/providers/cohere.js +0 -2
  92. package/dist/providers/deepgram.d.ts +2 -7
  93. package/dist/providers/deepinfra.d.ts +66 -70
  94. package/dist/providers/deepinfra.js +0 -1
  95. package/dist/providers/deepseek.d.ts +66 -70
  96. package/dist/providers/deepseek.js +1 -1
  97. package/dist/providers/digitalocean.d.ts +137 -141
  98. package/dist/providers/elevenlabs.d.ts +2 -7
  99. package/dist/providers/fal.d.ts +2 -7
  100. package/dist/providers/fireworks.d.ts +66 -70
  101. package/dist/providers/google-vertex-chat.d.ts +34 -38
  102. package/dist/providers/google-vertex-interactions.d.ts +31 -41
  103. package/dist/providers/google-vertex-messages.d.ts +81 -85
  104. package/dist/providers/google-vertex-mistral.d.ts +23 -27
  105. package/dist/providers/google-vertex-responses.d.ts +90 -94
  106. package/dist/providers/google-vertex.d.ts +26 -30
  107. package/dist/providers/google.d.ts +94 -109
  108. package/dist/providers/groq.d.ts +111 -115
  109. package/dist/providers/groq.js +0 -1
  110. package/dist/providers/meta.d.ts +309 -317
  111. package/dist/providers/meta.js +1 -1
  112. package/dist/providers/minimax.d.ts +296 -303
  113. package/dist/providers/minimax.js +1 -1
  114. package/dist/providers/mistral.d.ts +22 -26
  115. package/dist/providers/moonshot.d.ts +296 -303
  116. package/dist/providers/moonshot.js +0 -1
  117. package/dist/providers/openai-compatible-responses.d.ts +90 -94
  118. package/dist/providers/openai-compatible.d.ts +34 -38
  119. package/dist/providers/openai.d.ts +93 -108
  120. package/dist/providers/opencode.d.ts +2 -8
  121. package/dist/providers/openrouter.d.ts +137 -144
  122. package/dist/providers/replicate.d.ts +2 -6
  123. package/dist/providers/runway.d.ts +2 -6
  124. package/dist/providers/stability.d.ts +2 -7
  125. package/dist/providers/togetherai.d.ts +66 -70
  126. package/dist/providers/togetherai.js +1 -1
  127. package/dist/providers/typesafe-ai.d.ts +2 -8
  128. package/dist/providers/venice.d.ts +58 -63
  129. package/dist/providers/vercel-ai-gateway.d.ts +2 -12
  130. package/dist/providers/xai.d.ts +38 -50
  131. package/dist/providers/zai-coding-plan.d.ts +206 -213
  132. package/dist/providers/zai.d.ts +40 -46
  133. package/dist/route/client.d.ts +51 -51
  134. package/dist/route/media-protocol.d.ts +1 -1
  135. package/dist/route/transport/http.d.ts +1 -1
  136. package/dist/route/transport/websocket.d.ts +8 -8
  137. package/dist/schema/errors.d.ts +19 -19
  138. package/dist/schema/events.d.ts +3090 -3288
  139. package/dist/schema/messages.d.ts +8 -7
  140. package/dist/schema/options.d.ts +2 -1
  141. package/dist/schema/options.js +2 -1
  142. package/dist/speech-client.d.ts +8 -8
  143. package/dist/speech.d.ts +434 -398
  144. package/dist/testing.d.ts +338 -338
  145. package/dist/tool-runtime.d.ts +1 -1
  146. package/dist/transcription-client.d.ts +23 -23
  147. package/dist/transcription.d.ts +562 -646
  148. package/dist/utils/sanitize.d.ts +4 -0
  149. package/dist/utils/sanitize.js +23 -6
  150. package/dist/video-client.d.ts +8 -8
  151. package/dist/video.d.ts +416 -372
  152. package/package.json +6 -6
@@ -31,8 +31,203 @@ export type Settings<Options = OpenAIProviderOptionsInput> = ProviderPackage.Set
31
31
  };
32
32
  export type MessagesSettings = Settings<AnthropicMessages.ProviderOptionsInput>;
33
33
  export declare const routes: (Route<{
34
- readonly max_tokens: number;
35
34
  readonly model: string;
35
+ readonly input: readonly ({
36
+ readonly [x: string]: unknown;
37
+ readonly type: "web_search_call";
38
+ readonly id: string;
39
+ readonly status?: string | undefined;
40
+ readonly action?: {
41
+ readonly [x: string]: unknown;
42
+ } | null | undefined;
43
+ } | {
44
+ readonly [x: string]: unknown;
45
+ readonly type: "file_search_call";
46
+ readonly id: string;
47
+ readonly status?: string | undefined;
48
+ readonly queries?: readonly string[] | undefined;
49
+ readonly results?: readonly {
50
+ readonly [x: string]: unknown;
51
+ }[] | null | undefined;
52
+ } | {
53
+ readonly [x: string]: unknown;
54
+ readonly type: "code_interpreter_call";
55
+ readonly id: string;
56
+ readonly status?: string | undefined;
57
+ readonly code?: string | null | undefined;
58
+ readonly container_id?: string | null | undefined;
59
+ readonly outputs?: readonly {
60
+ readonly [x: string]: unknown;
61
+ }[] | null | undefined;
62
+ } | {
63
+ readonly [x: string]: unknown;
64
+ readonly type: "mcp_call";
65
+ readonly id: string;
66
+ readonly status?: string | undefined;
67
+ readonly server_label?: string | undefined;
68
+ readonly name?: string | undefined;
69
+ readonly arguments?: string | undefined;
70
+ readonly output?: string | null | undefined;
71
+ readonly error?: unknown;
72
+ } | {
73
+ readonly type: "configuration_update";
74
+ readonly reasoning: {
75
+ readonly effort: import("../schema/options.js").ReasoningEffort;
76
+ };
77
+ } | {
78
+ readonly [x: string]: unknown;
79
+ readonly type: string;
80
+ readonly id: string;
81
+ } | {
82
+ readonly type: "compaction";
83
+ readonly id?: string | null | undefined;
84
+ readonly encrypted_content: string;
85
+ } | {
86
+ readonly type: "message";
87
+ readonly role: "system";
88
+ readonly content: string;
89
+ } | {
90
+ readonly type: "message";
91
+ readonly role: "developer";
92
+ readonly content: string;
93
+ } | {
94
+ readonly type: "message";
95
+ readonly role: "user";
96
+ readonly content: readonly ({
97
+ readonly type: "input_image";
98
+ readonly image_url: string;
99
+ readonly detail?: string | undefined;
100
+ } | {
101
+ readonly type: "input_file";
102
+ readonly filename: string;
103
+ readonly detail?: string | undefined;
104
+ readonly file_data?: string | undefined;
105
+ readonly file_url?: string | undefined;
106
+ } | {
107
+ readonly type: "input_text";
108
+ readonly text: string;
109
+ })[];
110
+ readonly id?: string | undefined;
111
+ readonly status?: string | undefined;
112
+ } | {
113
+ readonly type: "message";
114
+ readonly id?: string | undefined;
115
+ readonly role: "assistant";
116
+ readonly content: readonly {
117
+ readonly type: "output_text";
118
+ readonly text: string;
119
+ }[];
120
+ readonly phase?: "commentary" | "final_answer" | null | undefined;
121
+ readonly status?: string | undefined;
122
+ } | {
123
+ readonly type: "reasoning";
124
+ readonly id?: string | undefined;
125
+ readonly summary: readonly {
126
+ readonly type: "summary_text";
127
+ readonly text: string;
128
+ }[];
129
+ readonly encrypted_content?: string | null | undefined;
130
+ } | {
131
+ readonly type: "function_call";
132
+ readonly id?: string | undefined;
133
+ readonly call_id: string;
134
+ readonly name: string;
135
+ readonly namespace?: string | undefined;
136
+ readonly arguments: string;
137
+ } | {
138
+ readonly type: "function_call_output";
139
+ readonly call_id: string;
140
+ readonly output: string | readonly ({
141
+ readonly type: "input_image";
142
+ readonly image_url: string;
143
+ readonly detail?: string | undefined;
144
+ } | {
145
+ readonly type: "input_file";
146
+ readonly filename: string;
147
+ readonly detail?: string | undefined;
148
+ readonly file_data?: string | undefined;
149
+ readonly file_url?: string | undefined;
150
+ } | {
151
+ readonly type: "input_text";
152
+ readonly text: string;
153
+ } | {
154
+ readonly type: "input_video";
155
+ readonly video_url: string;
156
+ })[];
157
+ })[];
158
+ readonly instructions?: string | undefined;
159
+ readonly tools?: readonly ({
160
+ readonly [x: string]: unknown;
161
+ readonly type: string;
162
+ } | {
163
+ readonly type: "function";
164
+ readonly name: string;
165
+ readonly description: string;
166
+ readonly parameters: {
167
+ readonly [x: string]: unknown;
168
+ };
169
+ readonly strict?: boolean | undefined;
170
+ })[] | undefined;
171
+ readonly tool_choice?: "auto" | "none" | "required" | {
172
+ readonly type: "function";
173
+ readonly name: string;
174
+ } | {
175
+ readonly type: "allowed_tools";
176
+ readonly mode: "auto" | "none" | "required";
177
+ readonly tools: readonly {
178
+ readonly type: "function";
179
+ readonly name: string;
180
+ }[];
181
+ } | undefined;
182
+ readonly store?: boolean | undefined;
183
+ readonly metadata?: {
184
+ readonly [x: string]: string;
185
+ } | undefined;
186
+ readonly safety_identifier?: string | undefined;
187
+ readonly stream_options?: {
188
+ readonly include_obfuscation?: boolean | undefined;
189
+ } | undefined;
190
+ readonly top_logprobs?: number | undefined;
191
+ readonly truncation?: "auto" | "disabled" | undefined;
192
+ readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
193
+ readonly prompt_cache_key?: string | undefined;
194
+ readonly include?: readonly import("../protocols/utils/open-responses-options.js").ResponseIncludable[] | undefined;
195
+ readonly reasoning?: {
196
+ readonly effort?: import("../schema/options.js").ReasoningEffort | undefined;
197
+ readonly summary?: "auto" | "concise" | "detailed" | undefined;
198
+ } | undefined;
199
+ readonly text?: {
200
+ readonly verbosity?: import("../protocols/utils/open-responses-options.js").TextVerbosity | undefined;
201
+ } | undefined;
202
+ readonly max_output_tokens?: number | undefined;
203
+ readonly max_tool_calls?: number | undefined;
204
+ readonly parallel_tool_calls?: boolean | undefined;
205
+ readonly temperature?: number | undefined;
206
+ readonly top_p?: number | undefined;
207
+ readonly presence_penalty?: number | undefined;
208
+ readonly frequency_penalty?: number | undefined;
209
+ readonly stream: true;
210
+ }, import("../route/transport/http.js").HttpPrepared<string>, import("../route/client.js").CompactionOperations | undefined> | Route<{
211
+ readonly context_management?: {
212
+ readonly edits: readonly {
213
+ readonly type: "compact_20260112";
214
+ readonly trigger?: {
215
+ readonly type: "input_tokens";
216
+ readonly value: number;
217
+ } | undefined;
218
+ readonly pause_after_compaction?: boolean | undefined;
219
+ readonly instructions?: string | undefined;
220
+ }[];
221
+ } | undefined;
222
+ readonly model: string;
223
+ readonly system?: readonly {
224
+ readonly type: "text";
225
+ readonly text: string;
226
+ readonly cache_control?: {
227
+ readonly type: "ephemeral";
228
+ readonly ttl?: "1h" | "5m" | undefined;
229
+ } | undefined;
230
+ }[] | undefined;
36
231
  readonly messages: readonly ({
37
232
  readonly role: "user";
38
233
  readonly content: readonly ({
@@ -60,7 +255,7 @@ export declare const routes: (Route<{
60
255
  readonly ttl?: "1h" | "5m" | undefined;
61
256
  } | undefined;
62
257
  readonly transformations?: {
63
- readonly oversized_image?: "error" | "downsize" | undefined;
258
+ readonly oversized_image?: "downsize" | "error" | undefined;
64
259
  } | undefined;
65
260
  } | {
66
261
  readonly type: "document";
@@ -79,17 +274,18 @@ export declare const routes: (Route<{
79
274
  readonly type: "file";
80
275
  readonly file_id: string;
81
276
  };
82
- readonly title?: string | undefined;
83
- readonly context?: string | undefined;
84
277
  readonly cache_control?: {
85
278
  readonly type: "ephemeral";
86
279
  readonly ttl?: "1h" | "5m" | undefined;
87
280
  } | undefined;
281
+ readonly title?: string | undefined;
282
+ readonly context?: string | undefined;
88
283
  readonly citations?: {
89
284
  readonly enabled: boolean;
90
285
  } | undefined;
91
286
  } | {
92
287
  readonly type: "tool_result";
288
+ readonly tool_use_id: string;
93
289
  readonly content: string | readonly ({
94
290
  readonly type: "text";
95
291
  readonly text: string;
@@ -115,7 +311,7 @@ export declare const routes: (Route<{
115
311
  readonly ttl?: "1h" | "5m" | undefined;
116
312
  } | undefined;
117
313
  readonly transformations?: {
118
- readonly oversized_image?: "error" | "downsize" | undefined;
314
+ readonly oversized_image?: "downsize" | "error" | undefined;
119
315
  } | undefined;
120
316
  } | {
121
317
  readonly type: "document";
@@ -134,22 +330,21 @@ export declare const routes: (Route<{
134
330
  readonly type: "file";
135
331
  readonly file_id: string;
136
332
  };
137
- readonly title?: string | undefined;
138
- readonly context?: string | undefined;
139
333
  readonly cache_control?: {
140
334
  readonly type: "ephemeral";
141
335
  readonly ttl?: "1h" | "5m" | undefined;
142
336
  } | undefined;
337
+ readonly title?: string | undefined;
338
+ readonly context?: string | undefined;
143
339
  readonly citations?: {
144
340
  readonly enabled: boolean;
145
341
  } | undefined;
146
342
  })[];
147
- readonly tool_use_id: string;
343
+ readonly is_error?: boolean | undefined;
148
344
  readonly cache_control?: {
149
345
  readonly type: "ephemeral";
150
346
  readonly ttl?: "1h" | "5m" | undefined;
151
347
  } | undefined;
152
- readonly is_error?: boolean | undefined;
153
348
  })[];
154
349
  } | {
155
350
  readonly role: "assistant";
@@ -161,51 +356,52 @@ export declare const routes: (Route<{
161
356
  readonly ttl?: "1h" | "5m" | undefined;
162
357
  } | undefined;
163
358
  } | {
164
- readonly id: string;
165
- readonly type: "tool_use";
166
- readonly name: string;
167
- readonly input: unknown;
359
+ readonly type: "code_execution_tool_result" | "web_fetch_tool_result" | "web_search_tool_result";
360
+ readonly tool_use_id: string;
361
+ readonly content: unknown;
168
362
  readonly cache_control?: {
169
363
  readonly type: "ephemeral";
170
364
  readonly ttl?: "1h" | "5m" | undefined;
171
365
  } | undefined;
172
366
  } | {
173
- readonly id: string;
174
- readonly type: "server_tool_use";
175
- readonly name: string;
176
- readonly input: unknown;
367
+ readonly type: "compaction";
368
+ readonly content: string | null;
369
+ } | {
370
+ readonly type: "thinking";
371
+ readonly thinking: string;
372
+ readonly signature: string;
177
373
  readonly cache_control?: {
178
374
  readonly type: "ephemeral";
179
375
  readonly ttl?: "1h" | "5m" | undefined;
180
376
  } | undefined;
181
377
  } | {
182
- readonly type: "web_search_tool_result" | "code_execution_tool_result" | "web_fetch_tool_result";
183
- readonly content: unknown;
184
- readonly tool_use_id: string;
378
+ readonly type: "redacted_thinking";
379
+ readonly data: string;
185
380
  readonly cache_control?: {
186
381
  readonly type: "ephemeral";
187
382
  readonly ttl?: "1h" | "5m" | undefined;
188
383
  } | undefined;
189
384
  } | {
190
- readonly type: "thinking";
191
- readonly thinking: string;
192
- readonly signature: string;
385
+ readonly type: "tool_use";
386
+ readonly id: string;
387
+ readonly name: string;
388
+ readonly input: unknown;
193
389
  readonly cache_control?: {
194
390
  readonly type: "ephemeral";
195
391
  readonly ttl?: "1h" | "5m" | undefined;
196
392
  } | undefined;
197
393
  } | {
198
- readonly data: string;
199
- readonly type: "redacted_thinking";
394
+ readonly type: "server_tool_use";
395
+ readonly id: string;
396
+ readonly name: string;
397
+ readonly input: unknown;
200
398
  readonly cache_control?: {
201
399
  readonly type: "ephemeral";
202
400
  readonly ttl?: "1h" | "5m" | undefined;
203
401
  } | undefined;
204
- } | {
205
- readonly type: "compaction";
206
- readonly content: string | null;
207
402
  })[];
208
403
  } | {
404
+ readonly role: "system";
209
405
  readonly content: readonly {
210
406
  readonly type: "text";
211
407
  readonly text: string;
@@ -214,19 +410,13 @@ export declare const routes: (Route<{
214
410
  readonly ttl?: "1h" | "5m" | undefined;
215
411
  } | undefined;
216
412
  }[];
217
- readonly role: "system";
218
413
  readonly output_config?: {
219
414
  readonly effort: string;
220
415
  } | undefined;
221
416
  })[];
222
- readonly stream: true;
223
- readonly metadata?: {
224
- readonly user_id?: string | null | undefined;
225
- } | undefined;
226
- readonly temperature?: number | undefined;
227
417
  readonly tools?: readonly {
228
- readonly description: string;
229
418
  readonly name: string;
419
+ readonly description: string;
230
420
  readonly input_schema: {
231
421
  readonly [x: string]: unknown;
232
422
  };
@@ -235,73 +425,60 @@ export declare const routes: (Route<{
235
425
  readonly ttl?: "1h" | "5m" | undefined;
236
426
  } | undefined;
237
427
  }[] | undefined;
238
- readonly system?: readonly {
239
- readonly type: "text";
240
- readonly text: string;
241
- readonly cache_control?: {
242
- readonly type: "ephemeral";
243
- readonly ttl?: "1h" | "5m" | undefined;
244
- } | undefined;
245
- }[] | undefined;
428
+ readonly tool_choice?: {
429
+ readonly type: "any" | "auto" | "none";
430
+ readonly disable_parallel_tool_use?: boolean | undefined;
431
+ } | {
432
+ readonly type: "tool";
433
+ readonly name: string;
434
+ readonly disable_parallel_tool_use?: boolean | undefined;
435
+ } | undefined;
436
+ readonly stream: true;
437
+ readonly max_tokens: number;
438
+ readonly temperature?: number | undefined;
439
+ readonly top_p?: number | undefined;
440
+ readonly top_k?: number | undefined;
441
+ readonly stop_sequences?: readonly string[] | undefined;
246
442
  readonly thinking?: {
247
- readonly type: "enabled";
248
- readonly budget_tokens: number;
249
- readonly display?: import("../schema/options.js").OpenString<"summarized" | "omitted"> | undefined;
443
+ readonly display?: import("../schema/options.js").OpenString<"omitted" | "summarized"> | undefined;
250
444
  readonly block_binding?: {
251
- readonly prefix_mismatch_behavior?: import("../schema/options.js").OpenString<"error" | "drop_block"> | undefined;
445
+ readonly prefix_mismatch_behavior?: import("../schema/options.js").OpenString<"drop_block" | "error"> | undefined;
252
446
  } | undefined;
447
+ readonly type: "enabled";
448
+ readonly budget_tokens: number;
253
449
  } | {
254
- readonly type: "adaptive";
255
- readonly display?: import("../schema/options.js").OpenString<"summarized" | "omitted"> | undefined;
450
+ readonly display?: import("../schema/options.js").OpenString<"omitted" | "summarized"> | undefined;
256
451
  readonly block_binding?: {
257
- readonly prefix_mismatch_behavior?: import("../schema/options.js").OpenString<"error" | "drop_block"> | undefined;
452
+ readonly prefix_mismatch_behavior?: import("../schema/options.js").OpenString<"drop_block" | "error"> | undefined;
258
453
  } | undefined;
454
+ readonly type: "adaptive";
259
455
  } | {
260
- readonly type: "disabled" | "between_tools";
261
- } | undefined;
262
- readonly service_tier?: import("../schema/options.js").OpenString<"auto" | "standard_only"> | undefined;
263
- readonly container?: string | {
264
- readonly id?: string | null | undefined;
265
- readonly skills?: readonly {
266
- readonly [x: string]: unknown;
267
- }[] | null | undefined;
268
- } | null | undefined;
269
- readonly inference_geo?: string | null | undefined;
270
- readonly cache_control?: {
271
- readonly type: "ephemeral";
272
- readonly ttl?: "1h" | "5m" | undefined;
456
+ readonly type: "between_tools" | "disabled";
273
457
  } | undefined;
274
458
  readonly output_config?: {
459
+ readonly effort?: string | undefined;
275
460
  readonly format?: {
276
461
  readonly type: "json_schema";
277
462
  readonly schema: {
278
463
  readonly [x: string]: unknown;
279
464
  };
280
465
  } | null | undefined;
281
- readonly effort?: string | undefined;
282
466
  } | undefined;
283
- readonly context_management?: {
284
- readonly edits: readonly {
285
- readonly type: "compact_20260112";
286
- readonly instructions?: string | undefined;
287
- readonly trigger?: {
288
- readonly type: "input_tokens";
289
- readonly value: number;
290
- } | undefined;
291
- readonly pause_after_compaction?: boolean | undefined;
292
- }[];
467
+ readonly cache_control?: {
468
+ readonly type: "ephemeral";
469
+ readonly ttl?: "1h" | "5m" | undefined;
293
470
  } | undefined;
294
- readonly tool_choice?: {
295
- readonly type: "auto" | "none" | "any";
296
- readonly disable_parallel_tool_use?: boolean | undefined;
297
- } | {
298
- readonly type: "tool";
299
- readonly name: string;
300
- readonly disable_parallel_tool_use?: boolean | undefined;
471
+ readonly container?: string | {
472
+ readonly id?: string | null | undefined;
473
+ readonly skills?: readonly {
474
+ readonly [x: string]: unknown;
475
+ }[] | null | undefined;
476
+ } | null | undefined;
477
+ readonly inference_geo?: string | null | undefined;
478
+ readonly metadata?: {
479
+ readonly user_id?: string | null | undefined;
301
480
  } | undefined;
302
- readonly top_p?: number | undefined;
303
- readonly top_k?: number | undefined;
304
- readonly stop_sequences?: readonly string[] | undefined;
481
+ readonly service_tier?: import("../schema/options.js").OpenString<"auto" | "standard_only"> | undefined;
305
482
  }, import("../route/transport/http.js").HttpPrepared<string>, import("../route/client.js").CompactionOperations | undefined> | Route<{
306
483
  readonly model: string;
307
484
  readonly messages: readonly ({
@@ -346,8 +523,20 @@ export declare const routes: (Route<{
346
523
  readonly file_data: string;
347
524
  };
348
525
  })[];
526
+ } | {
527
+ readonly role: "tool";
528
+ readonly tool_call_id: string;
529
+ readonly content: string | readonly {
530
+ readonly type: "text";
531
+ readonly text: string;
532
+ readonly cache_control?: {
533
+ readonly type: "ephemeral";
534
+ readonly ttl?: string | undefined;
535
+ } | undefined;
536
+ }[];
349
537
  } | {
350
538
  readonly [x: string]: unknown;
539
+ readonly role: "assistant";
351
540
  readonly content: string | readonly {
352
541
  readonly type: "text";
353
542
  readonly text: string;
@@ -356,250 +545,61 @@ export declare const routes: (Route<{
356
545
  readonly ttl?: string | undefined;
357
546
  } | undefined;
358
547
  }[] | null;
359
- readonly role: "assistant";
360
- readonly reasoning?: string | undefined;
361
- readonly reasoning_content?: string | undefined;
362
- readonly reasoning_text?: string | undefined;
363
548
  readonly tool_calls?: readonly {
549
+ readonly id: string;
550
+ readonly type: "function";
364
551
  readonly function: {
365
552
  readonly name: string;
366
553
  readonly arguments: string;
367
554
  };
368
- readonly id: string;
369
- readonly type: "function";
370
555
  readonly extra_content?: {
371
556
  readonly google: {
372
557
  readonly thought_signature: string;
373
558
  };
374
559
  } | undefined;
375
560
  }[] | undefined;
561
+ readonly reasoning_content?: string | undefined;
562
+ readonly reasoning?: string | undefined;
563
+ readonly reasoning_text?: string | undefined;
376
564
  readonly reasoning_details?: unknown;
377
- } | {
378
- readonly role: "tool";
379
- readonly tool_call_id: string;
380
- readonly content: string | readonly {
381
- readonly type: "text";
382
- readonly text: string;
383
- readonly cache_control?: {
384
- readonly type: "ephemeral";
385
- readonly ttl?: string | undefined;
386
- } | undefined;
387
- }[];
388
565
  })[];
389
- readonly stream: true;
390
- readonly max_completion_tokens?: number | undefined;
391
- readonly max_tokens?: number | undefined;
392
- readonly temperature?: number | undefined;
393
566
  readonly tools?: readonly {
567
+ readonly type: "function";
394
568
  readonly function: {
395
- readonly description: string;
396
569
  readonly name: string;
570
+ readonly description: string;
397
571
  readonly parameters: {
398
572
  readonly [x: string]: unknown;
399
573
  };
400
574
  readonly strict?: boolean | undefined;
401
575
  };
402
- readonly type: "function";
403
576
  readonly cache_control?: {
404
577
  readonly type: "ephemeral";
405
578
  readonly ttl?: string | undefined;
406
579
  } | undefined;
407
580
  }[] | undefined;
408
- readonly stop?: readonly string[] | undefined;
409
- readonly seed?: number | undefined;
410
- readonly tool_choice?: "required" | "auto" | "none" | {
581
+ readonly tool_choice?: "auto" | "none" | "required" | {
411
582
  readonly type: "function";
412
583
  readonly function: {
413
584
  readonly name: string;
414
585
  };
415
586
  } | undefined;
416
- readonly top_p?: number | undefined;
417
- readonly frequency_penalty?: number | undefined;
418
- readonly presence_penalty?: number | undefined;
419
- readonly store?: boolean | undefined;
420
- readonly prompt_cache_key?: string | undefined;
421
- readonly reasoning_effort?: import("../schema/options.js").ReasoningEffort | undefined;
587
+ readonly stream: true;
422
588
  readonly stream_options?: {
423
589
  readonly include_usage: boolean;
424
590
  } | undefined;
591
+ readonly store?: boolean | undefined;
592
+ readonly prompt_cache_key?: string | undefined;
593
+ readonly reasoning_effort?: import("../schema/options.js").ReasoningEffort | undefined;
425
594
  readonly tool_stream?: boolean | undefined;
426
- }, import("../route/transport/http.js").HttpPrepared<string>, import("../route/client.js").CompactionOperations | undefined> | Route<{
427
- readonly input: readonly ({
428
- readonly [x: string]: unknown;
429
- readonly id: string;
430
- readonly type: "web_search_call";
431
- readonly status?: string | undefined;
432
- readonly action?: {
433
- readonly [x: string]: unknown;
434
- } | null | undefined;
435
- } | {
436
- readonly [x: string]: unknown;
437
- readonly id: string;
438
- readonly type: "file_search_call";
439
- readonly status?: string | undefined;
440
- readonly queries?: readonly string[] | undefined;
441
- readonly results?: readonly {
442
- readonly [x: string]: unknown;
443
- }[] | null | undefined;
444
- } | {
445
- readonly [x: string]: unknown;
446
- readonly id: string;
447
- readonly type: "code_interpreter_call";
448
- readonly status?: string | undefined;
449
- readonly code?: string | null | undefined;
450
- readonly container_id?: string | null | undefined;
451
- readonly outputs?: readonly {
452
- readonly [x: string]: unknown;
453
- }[] | null | undefined;
454
- } | {
455
- readonly [x: string]: unknown;
456
- readonly id: string;
457
- readonly type: "mcp_call";
458
- readonly status?: string | undefined;
459
- readonly name?: string | undefined;
460
- readonly output?: string | null | undefined;
461
- readonly error?: unknown;
462
- readonly arguments?: string | undefined;
463
- readonly server_label?: string | undefined;
464
- } | {
465
- readonly type: "configuration_update";
466
- readonly reasoning: {
467
- readonly effort: import("../schema/options.js").ReasoningEffort;
468
- };
469
- } | {
470
- readonly [x: string]: unknown;
471
- readonly type: string;
472
- readonly id: string;
473
- } | {
474
- readonly type: "reasoning";
475
- readonly summary: readonly {
476
- readonly type: "summary_text";
477
- readonly text: string;
478
- }[];
479
- readonly id?: string | undefined;
480
- readonly encrypted_content?: string | null | undefined;
481
- } | {
482
- readonly type: "compaction";
483
- readonly encrypted_content: string;
484
- readonly id?: string | null | undefined;
485
- } | {
486
- readonly type: "message";
487
- readonly role: "system";
488
- readonly content: string;
489
- } | {
490
- readonly type: "message";
491
- readonly role: "developer";
492
- readonly content: string;
493
- } | {
494
- readonly type: "message";
495
- readonly content: readonly ({
496
- readonly type: "input_image";
497
- readonly image_url: string;
498
- readonly detail?: string | undefined;
499
- } | {
500
- readonly type: "input_file";
501
- readonly filename: string;
502
- readonly detail?: string | undefined;
503
- readonly file_data?: string | undefined;
504
- readonly file_url?: string | undefined;
505
- } | {
506
- readonly type: "input_text";
507
- readonly text: string;
508
- })[];
509
- readonly role: "user";
510
- readonly id?: string | undefined;
511
- readonly status?: string | undefined;
512
- } | {
513
- readonly type: "message";
514
- readonly content: readonly {
515
- readonly type: "output_text";
516
- readonly text: string;
517
- }[];
518
- readonly role: "assistant";
519
- readonly id?: string | undefined;
520
- readonly status?: string | undefined;
521
- readonly phase?: "commentary" | "final_answer" | null | undefined;
522
- } | {
523
- readonly type: "function_call";
524
- readonly name: string;
525
- readonly arguments: string;
526
- readonly call_id: string;
527
- readonly id?: string | undefined;
528
- readonly namespace?: string | undefined;
529
- } | {
530
- readonly type: "function_call_output";
531
- readonly call_id: string;
532
- readonly output: string | readonly ({
533
- readonly type: "input_image";
534
- readonly image_url: string;
535
- readonly detail?: string | undefined;
536
- } | {
537
- readonly type: "input_file";
538
- readonly filename: string;
539
- readonly detail?: string | undefined;
540
- readonly file_data?: string | undefined;
541
- readonly file_url?: string | undefined;
542
- } | {
543
- readonly type: "input_text";
544
- readonly text: string;
545
- } | {
546
- readonly type: "input_video";
547
- readonly video_url: string;
548
- })[];
549
- })[];
550
- readonly model: string;
551
- readonly stream: true;
552
- readonly metadata?: {
553
- readonly [x: string]: string;
554
- } | undefined;
555
- readonly instructions?: string | undefined;
556
- readonly reasoning?: {
557
- readonly summary?: "auto" | "concise" | "detailed" | undefined;
558
- readonly effort?: import("../schema/options.js").ReasoningEffort | undefined;
559
- } | undefined;
595
+ readonly max_completion_tokens?: number | undefined;
596
+ readonly max_tokens?: number | undefined;
560
597
  readonly temperature?: number | undefined;
561
- readonly tools?: readonly ({
562
- readonly [x: string]: unknown;
563
- readonly type: string;
564
- } | {
565
- readonly type: "function";
566
- readonly description: string;
567
- readonly name: string;
568
- readonly parameters: {
569
- readonly [x: string]: unknown;
570
- };
571
- readonly strict?: boolean | undefined;
572
- })[] | undefined;
573
- readonly text?: {
574
- readonly verbosity?: import("../protocols/utils/open-responses-options.js").TextVerbosity | undefined;
575
- } | undefined;
576
- readonly service_tier?: import("../protocols/utils/open-responses-options.js").ServiceTier | undefined;
577
- readonly tool_choice?: "required" | "auto" | "none" | {
578
- readonly type: "function";
579
- readonly name: string;
580
- } | {
581
- readonly type: "allowed_tools";
582
- readonly mode: "required" | "auto" | "none";
583
- readonly tools: readonly {
584
- readonly type: "function";
585
- readonly name: string;
586
- }[];
587
- } | undefined;
588
598
  readonly top_p?: number | undefined;
589
599
  readonly frequency_penalty?: number | undefined;
590
600
  readonly presence_penalty?: number | undefined;
591
- readonly store?: boolean | undefined;
592
- readonly max_output_tokens?: number | undefined;
593
- readonly prompt_cache_key?: string | undefined;
594
- readonly parallel_tool_calls?: boolean | undefined;
595
- readonly include?: readonly import("../protocols/utils/open-responses-options.js").ResponseIncludable[] | undefined;
596
- readonly truncation?: "auto" | "disabled" | undefined;
597
- readonly stream_options?: {
598
- readonly include_obfuscation?: boolean | undefined;
599
- } | undefined;
600
- readonly safety_identifier?: string | undefined;
601
- readonly top_logprobs?: number | undefined;
602
- readonly max_tool_calls?: number | undefined;
601
+ readonly seed?: number | undefined;
602
+ readonly stop?: readonly string[] | undefined;
603
603
  }, import("../route/transport/http.js").HttpPrepared<string>, import("../route/client.js").CompactionOperations | undefined>)[];
604
604
  export declare const configure: (input?: Config) => {
605
605
  id: string & import("effect/Brand").Brand<"AI.ProviderID">;
@@ -607,7 +607,7 @@ export declare const configure: (input?: Config) => {
607
607
  chat: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<import("./openai-options.js").OpenAIOptionsInput, import("../route/client.js").CompactionOperations | undefined>;
608
608
  messages: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<AnthropicMessages.OptionsInput, import("../route/client.js").CompactionOperations | undefined>;
609
609
  responses: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<import("./openai-options.js").OpenAIOptionsInput, import("../route/client.js").CompactionOperations | undefined>;
610
- configure: (input?: Config) => /*elided*/ any;
610
+ configure: typeof configure;
611
611
  };
612
612
  export declare const provider: {
613
613
  id: string & import("effect/Brand").Brand<"AI.ProviderID">;
@@ -615,14 +615,7 @@ export declare const provider: {
615
615
  chat: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<import("./openai-options.js").OpenAIOptionsInput, import("../route/client.js").CompactionOperations | undefined>;
616
616
  messages: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<AnthropicMessages.OptionsInput, import("../route/client.js").CompactionOperations | undefined>;
617
617
  responses: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<import("./openai-options.js").OpenAIOptionsInput, import("../route/client.js").CompactionOperations | undefined>;
618
- configure: (input?: Config) => {
619
- id: string & import("effect/Brand").Brand<"AI.ProviderID">;
620
- model: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<import("./openai-options.js").OpenAIOptionsInput, import("../route/client.js").CompactionOperations | undefined>;
621
- chat: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<import("./openai-options.js").OpenAIOptionsInput, import("../route/client.js").CompactionOperations | undefined>;
622
- messages: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<AnthropicMessages.OptionsInput, import("../route/client.js").CompactionOperations | undefined>;
623
- responses: (modelID: string | ModelID) => import("../schema/options.js").LanguageModel<import("./openai-options.js").OpenAIOptionsInput, import("../route/client.js").CompactionOperations | undefined>;
624
- configure: /*elided*/ any;
625
- };
618
+ configure: typeof configure;
626
619
  };
627
620
  export declare const chatModel: ProviderPackage.Definition<Settings, OpenAIProviderOptionsInput>["model"];
628
621
  export declare const messagesModel: ProviderPackage.Definition<MessagesSettings, AnthropicMessages.ProviderOptionsInput>["model"];