@opencode-ai/ai 0.0.0-next-17074 → 0.0.0-next-17077
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 +3 -3
- package/dist/protocols/gemini.d.ts +2 -2
- package/dist/protocols/open-responses.d.ts +20 -20
- package/dist/protocols/openai-compatible-responses.d.ts +5 -5
- package/dist/protocols/openai-responses.d.ts +34 -34
- package/dist/providers/amazon-bedrock-mantle.d.ts +5 -5
- package/dist/providers/anthropic-compatible.d.ts +1 -1
- package/dist/providers/anthropic.d.ts +1 -1
- package/dist/providers/azure.d.ts +5 -5
- package/dist/providers/google-vertex-messages.d.ts +1 -1
- package/dist/providers/google-vertex-responses.d.ts +5 -5
- package/dist/providers/google-vertex.d.ts +1 -1
- package/dist/providers/google.d.ts +1 -1
- package/dist/providers/index.d.ts +0 -1
- package/dist/providers/index.js +0 -1
- package/dist/providers/openai-compatible-responses.d.ts +5 -5
- package/dist/providers/openai.d.ts +10 -10
- package/dist/providers/xai.d.ts +5 -5
- package/package.json +3 -3
- package/dist/providers/github-copilot.d.ts +0 -231
- package/dist/providers/github-copilot.js +0 -49
|
@@ -355,8 +355,8 @@ export declare const protocol: Protocol<{
|
|
|
355
355
|
} | undefined;
|
|
356
356
|
}[] | undefined;
|
|
357
357
|
readonly tools?: readonly {
|
|
358
|
-
readonly name: string;
|
|
359
358
|
readonly description: string;
|
|
359
|
+
readonly name: string;
|
|
360
360
|
readonly input_schema: {
|
|
361
361
|
readonly [x: string]: unknown;
|
|
362
362
|
};
|
|
@@ -440,8 +440,8 @@ export declare const protocol: Protocol<{
|
|
|
440
440
|
readonly id?: string | undefined;
|
|
441
441
|
readonly data?: string | undefined;
|
|
442
442
|
readonly name?: string | undefined;
|
|
443
|
-
readonly text?: string | undefined;
|
|
444
443
|
readonly input?: unknown;
|
|
444
|
+
readonly text?: string | undefined;
|
|
445
445
|
readonly content?: unknown;
|
|
446
446
|
readonly thinking?: string | undefined;
|
|
447
447
|
readonly signature?: string | undefined;
|
|
@@ -597,8 +597,8 @@ export declare const route: Route<{
|
|
|
597
597
|
} | undefined;
|
|
598
598
|
}[] | undefined;
|
|
599
599
|
readonly tools?: readonly {
|
|
600
|
-
readonly name: string;
|
|
601
600
|
readonly description: string;
|
|
601
|
+
readonly name: string;
|
|
602
602
|
readonly input_schema: {
|
|
603
603
|
readonly [x: string]: unknown;
|
|
604
604
|
};
|
|
@@ -135,8 +135,8 @@ export declare const protocol: Protocol<{
|
|
|
135
135
|
}[];
|
|
136
136
|
readonly tools?: readonly {
|
|
137
137
|
readonly functionDeclarations: readonly {
|
|
138
|
-
readonly name: string;
|
|
139
138
|
readonly description: string;
|
|
139
|
+
readonly name: string;
|
|
140
140
|
readonly parameters?: {
|
|
141
141
|
readonly [x: string]: unknown;
|
|
142
142
|
} | undefined;
|
|
@@ -257,8 +257,8 @@ export declare const route: Route<{
|
|
|
257
257
|
}[];
|
|
258
258
|
readonly tools?: readonly {
|
|
259
259
|
readonly functionDeclarations: readonly {
|
|
260
|
-
readonly name: string;
|
|
261
260
|
readonly description: string;
|
|
261
|
+
readonly name: string;
|
|
262
262
|
readonly parameters?: {
|
|
263
263
|
readonly [x: string]: unknown;
|
|
264
264
|
} | undefined;
|
|
@@ -367,7 +367,7 @@ export declare const lowerToolChoice: (protocolName: string, toolChoice: NonNull
|
|
|
367
367
|
name: string;
|
|
368
368
|
}, AIError, never>;
|
|
369
369
|
export declare const fromRequestWithExtension: (request: LLMRequest, extension: Extension) => Effect.Effect<{
|
|
370
|
-
service_tier?: "
|
|
370
|
+
service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
371
371
|
text?: {
|
|
372
372
|
verbosity: "low" | "medium" | "high";
|
|
373
373
|
} | undefined;
|
|
@@ -458,9 +458,6 @@ export declare const fromRequest: (request: LLMRequest) => Effect.Effect<{
|
|
|
458
458
|
})[];
|
|
459
459
|
readonly model: string;
|
|
460
460
|
readonly stream: true;
|
|
461
|
-
readonly text?: {
|
|
462
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
463
|
-
} | undefined;
|
|
464
461
|
readonly instructions?: string | undefined;
|
|
465
462
|
readonly reasoning?: {
|
|
466
463
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -468,13 +465,16 @@ export declare const fromRequest: (request: LLMRequest) => Effect.Effect<{
|
|
|
468
465
|
} | undefined;
|
|
469
466
|
readonly tools?: readonly {
|
|
470
467
|
readonly type: "function";
|
|
471
|
-
readonly name: string;
|
|
472
468
|
readonly description: string;
|
|
469
|
+
readonly name: string;
|
|
473
470
|
readonly parameters: {
|
|
474
471
|
readonly [x: string]: unknown;
|
|
475
472
|
};
|
|
476
473
|
readonly strict?: boolean | undefined;
|
|
477
474
|
}[] | undefined;
|
|
475
|
+
readonly text?: {
|
|
476
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
477
|
+
} | undefined;
|
|
478
478
|
readonly temperature?: number | undefined;
|
|
479
479
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
480
480
|
readonly type: "function";
|
|
@@ -484,7 +484,7 @@ export declare const fromRequest: (request: LLMRequest) => Effect.Effect<{
|
|
|
484
484
|
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;
|
|
485
485
|
readonly store?: boolean | undefined;
|
|
486
486
|
readonly prompt_cache_key?: string | undefined;
|
|
487
|
-
readonly service_tier?: "
|
|
487
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
488
488
|
readonly max_output_tokens?: number | undefined;
|
|
489
489
|
}, AIError, never>;
|
|
490
490
|
export declare const providerMetadata: (state: ParserState, metadata: Record<string, unknown>) => ProviderMetadata;
|
|
@@ -738,9 +738,6 @@ export declare const protocol: Protocol<{
|
|
|
738
738
|
})[];
|
|
739
739
|
readonly model: string;
|
|
740
740
|
readonly stream: true;
|
|
741
|
-
readonly text?: {
|
|
742
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
743
|
-
} | undefined;
|
|
744
741
|
readonly instructions?: string | undefined;
|
|
745
742
|
readonly reasoning?: {
|
|
746
743
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -748,13 +745,16 @@ export declare const protocol: Protocol<{
|
|
|
748
745
|
} | undefined;
|
|
749
746
|
readonly tools?: readonly {
|
|
750
747
|
readonly type: "function";
|
|
751
|
-
readonly name: string;
|
|
752
748
|
readonly description: string;
|
|
749
|
+
readonly name: string;
|
|
753
750
|
readonly parameters: {
|
|
754
751
|
readonly [x: string]: unknown;
|
|
755
752
|
};
|
|
756
753
|
readonly strict?: boolean | undefined;
|
|
757
754
|
}[] | undefined;
|
|
755
|
+
readonly text?: {
|
|
756
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
757
|
+
} | undefined;
|
|
758
758
|
readonly temperature?: number | undefined;
|
|
759
759
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
760
760
|
readonly type: "function";
|
|
@@ -764,25 +764,25 @@ export declare const protocol: Protocol<{
|
|
|
764
764
|
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;
|
|
765
765
|
readonly store?: boolean | undefined;
|
|
766
766
|
readonly prompt_cache_key?: string | undefined;
|
|
767
|
-
readonly service_tier?: "
|
|
767
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
768
768
|
readonly max_output_tokens?: number | undefined;
|
|
769
769
|
}, string, {
|
|
770
770
|
readonly [x: string]: unknown;
|
|
771
771
|
readonly type: string;
|
|
772
772
|
readonly error?: {
|
|
773
|
-
readonly message?: string | null | undefined;
|
|
774
773
|
readonly code?: string | null | undefined;
|
|
774
|
+
readonly message?: string | null | undefined;
|
|
775
775
|
readonly param?: string | null | undefined;
|
|
776
776
|
} | null | undefined;
|
|
777
|
-
readonly text?: string | undefined;
|
|
778
|
-
readonly message?: string | undefined;
|
|
779
777
|
readonly code?: string | null | undefined;
|
|
778
|
+
readonly message?: string | undefined;
|
|
779
|
+
readonly text?: string | undefined;
|
|
780
780
|
readonly delta?: string | undefined;
|
|
781
781
|
readonly response?: {
|
|
782
782
|
readonly [x: string]: unknown;
|
|
783
783
|
readonly error?: {
|
|
784
|
-
readonly message?: string | null | undefined;
|
|
785
784
|
readonly code?: string | null | undefined;
|
|
785
|
+
readonly message?: string | null | undefined;
|
|
786
786
|
readonly param?: string | null | undefined;
|
|
787
787
|
} | null | undefined;
|
|
788
788
|
readonly id?: string | undefined;
|
|
@@ -875,9 +875,6 @@ export declare const httpTransport: HttpTransport.HttpJsonTransport<{
|
|
|
875
875
|
})[];
|
|
876
876
|
readonly model: string;
|
|
877
877
|
readonly stream: true;
|
|
878
|
-
readonly text?: {
|
|
879
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
880
|
-
} | undefined;
|
|
881
878
|
readonly instructions?: string | undefined;
|
|
882
879
|
readonly reasoning?: {
|
|
883
880
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -885,13 +882,16 @@ export declare const httpTransport: HttpTransport.HttpJsonTransport<{
|
|
|
885
882
|
} | undefined;
|
|
886
883
|
readonly tools?: readonly {
|
|
887
884
|
readonly type: "function";
|
|
888
|
-
readonly name: string;
|
|
889
885
|
readonly description: string;
|
|
886
|
+
readonly name: string;
|
|
890
887
|
readonly parameters: {
|
|
891
888
|
readonly [x: string]: unknown;
|
|
892
889
|
};
|
|
893
890
|
readonly strict?: boolean | undefined;
|
|
894
891
|
}[] | undefined;
|
|
892
|
+
readonly text?: {
|
|
893
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
894
|
+
} | undefined;
|
|
895
895
|
readonly temperature?: number | undefined;
|
|
896
896
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
897
897
|
readonly type: "function";
|
|
@@ -901,7 +901,7 @@ export declare const httpTransport: HttpTransport.HttpJsonTransport<{
|
|
|
901
901
|
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;
|
|
902
902
|
readonly store?: boolean | undefined;
|
|
903
903
|
readonly prompt_cache_key?: string | undefined;
|
|
904
|
-
readonly service_tier?: "
|
|
904
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
905
905
|
readonly max_output_tokens?: number | undefined;
|
|
906
906
|
}, string>;
|
|
907
907
|
export * as OpenResponses from "./open-responses";
|
|
@@ -64,9 +64,6 @@ export declare const route: Route<{
|
|
|
64
64
|
})[];
|
|
65
65
|
readonly model: string;
|
|
66
66
|
readonly stream: true;
|
|
67
|
-
readonly text?: {
|
|
68
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
69
|
-
} | undefined;
|
|
70
67
|
readonly instructions?: string | undefined;
|
|
71
68
|
readonly reasoning?: {
|
|
72
69
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -74,13 +71,16 @@ export declare const route: Route<{
|
|
|
74
71
|
} | undefined;
|
|
75
72
|
readonly tools?: readonly {
|
|
76
73
|
readonly type: "function";
|
|
77
|
-
readonly name: string;
|
|
78
74
|
readonly description: string;
|
|
75
|
+
readonly name: string;
|
|
79
76
|
readonly parameters: {
|
|
80
77
|
readonly [x: string]: unknown;
|
|
81
78
|
};
|
|
82
79
|
readonly strict?: boolean | undefined;
|
|
83
80
|
}[] | undefined;
|
|
81
|
+
readonly text?: {
|
|
82
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
83
|
+
} | undefined;
|
|
84
84
|
readonly temperature?: number | undefined;
|
|
85
85
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
86
86
|
readonly type: "function";
|
|
@@ -90,7 +90,7 @@ export declare const route: Route<{
|
|
|
90
90
|
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;
|
|
91
91
|
readonly store?: boolean | undefined;
|
|
92
92
|
readonly prompt_cache_key?: string | undefined;
|
|
93
|
-
readonly service_tier?: "
|
|
93
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
94
94
|
readonly max_output_tokens?: number | undefined;
|
|
95
95
|
}, import("../route/transport/http").HttpPrepared<string>>;
|
|
96
96
|
export * as OpenAICompatibleResponses from "./openai-compatible-responses";
|
|
@@ -177,9 +177,6 @@ export declare const protocol: Protocol<{
|
|
|
177
177
|
})[];
|
|
178
178
|
readonly model: string;
|
|
179
179
|
readonly stream: true;
|
|
180
|
-
readonly text?: {
|
|
181
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
182
|
-
} | undefined;
|
|
183
180
|
readonly instructions?: string | undefined;
|
|
184
181
|
readonly reasoning?: {
|
|
185
182
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -187,8 +184,8 @@ export declare const protocol: Protocol<{
|
|
|
187
184
|
} | undefined;
|
|
188
185
|
readonly tools?: readonly ({
|
|
189
186
|
readonly type: "function";
|
|
190
|
-
readonly name: string;
|
|
191
187
|
readonly description: string;
|
|
188
|
+
readonly name: string;
|
|
192
189
|
readonly parameters: {
|
|
193
190
|
readonly [x: string]: unknown;
|
|
194
191
|
};
|
|
@@ -204,6 +201,9 @@ export declare const protocol: Protocol<{
|
|
|
204
201
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
205
202
|
readonly partial_images?: number | undefined;
|
|
206
203
|
})[] | undefined;
|
|
204
|
+
readonly text?: {
|
|
205
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
206
|
+
} | undefined;
|
|
207
207
|
readonly temperature?: number | undefined;
|
|
208
208
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
209
209
|
readonly type: "function";
|
|
@@ -215,25 +215,25 @@ export declare const protocol: Protocol<{
|
|
|
215
215
|
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;
|
|
216
216
|
readonly store?: boolean | undefined;
|
|
217
217
|
readonly prompt_cache_key?: string | undefined;
|
|
218
|
-
readonly service_tier?: "
|
|
218
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
219
219
|
readonly max_output_tokens?: number | undefined;
|
|
220
220
|
}, string, {
|
|
221
221
|
readonly [x: string]: unknown;
|
|
222
222
|
readonly type: string;
|
|
223
223
|
readonly error?: {
|
|
224
|
-
readonly message?: string | null | undefined;
|
|
225
224
|
readonly code?: string | null | undefined;
|
|
225
|
+
readonly message?: string | null | undefined;
|
|
226
226
|
readonly param?: string | null | undefined;
|
|
227
227
|
} | null | undefined;
|
|
228
|
-
readonly text?: string | undefined;
|
|
229
|
-
readonly message?: string | undefined;
|
|
230
228
|
readonly code?: string | null | undefined;
|
|
229
|
+
readonly message?: string | undefined;
|
|
230
|
+
readonly text?: string | undefined;
|
|
231
231
|
readonly delta?: string | undefined;
|
|
232
232
|
readonly response?: {
|
|
233
233
|
readonly [x: string]: unknown;
|
|
234
234
|
readonly error?: {
|
|
235
|
-
readonly message?: string | null | undefined;
|
|
236
235
|
readonly code?: string | null | undefined;
|
|
236
|
+
readonly message?: string | null | undefined;
|
|
237
237
|
readonly param?: string | null | undefined;
|
|
238
238
|
} | null | undefined;
|
|
239
239
|
readonly id?: string | undefined;
|
|
@@ -333,9 +333,6 @@ export declare const httpTransport: HttpTransport.HttpJsonTransport<{
|
|
|
333
333
|
})[];
|
|
334
334
|
readonly model: string;
|
|
335
335
|
readonly stream: true;
|
|
336
|
-
readonly text?: {
|
|
337
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
338
|
-
} | undefined;
|
|
339
336
|
readonly instructions?: string | undefined;
|
|
340
337
|
readonly reasoning?: {
|
|
341
338
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -343,8 +340,8 @@ export declare const httpTransport: HttpTransport.HttpJsonTransport<{
|
|
|
343
340
|
} | undefined;
|
|
344
341
|
readonly tools?: readonly ({
|
|
345
342
|
readonly type: "function";
|
|
346
|
-
readonly name: string;
|
|
347
343
|
readonly description: string;
|
|
344
|
+
readonly name: string;
|
|
348
345
|
readonly parameters: {
|
|
349
346
|
readonly [x: string]: unknown;
|
|
350
347
|
};
|
|
@@ -360,6 +357,9 @@ export declare const httpTransport: HttpTransport.HttpJsonTransport<{
|
|
|
360
357
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
361
358
|
readonly partial_images?: number | undefined;
|
|
362
359
|
})[] | undefined;
|
|
360
|
+
readonly text?: {
|
|
361
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
362
|
+
} | undefined;
|
|
363
363
|
readonly temperature?: number | undefined;
|
|
364
364
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
365
365
|
readonly type: "function";
|
|
@@ -371,7 +371,7 @@ export declare const httpTransport: HttpTransport.HttpJsonTransport<{
|
|
|
371
371
|
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;
|
|
372
372
|
readonly store?: boolean | undefined;
|
|
373
373
|
readonly prompt_cache_key?: string | undefined;
|
|
374
|
-
readonly service_tier?: "
|
|
374
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
375
375
|
readonly max_output_tokens?: number | undefined;
|
|
376
376
|
}, string>;
|
|
377
377
|
export declare const route: Route<{
|
|
@@ -440,9 +440,6 @@ export declare const route: Route<{
|
|
|
440
440
|
})[];
|
|
441
441
|
readonly model: string;
|
|
442
442
|
readonly stream: true;
|
|
443
|
-
readonly text?: {
|
|
444
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
445
|
-
} | undefined;
|
|
446
443
|
readonly instructions?: string | undefined;
|
|
447
444
|
readonly reasoning?: {
|
|
448
445
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -450,8 +447,8 @@ export declare const route: Route<{
|
|
|
450
447
|
} | undefined;
|
|
451
448
|
readonly tools?: readonly ({
|
|
452
449
|
readonly type: "function";
|
|
453
|
-
readonly name: string;
|
|
454
450
|
readonly description: string;
|
|
451
|
+
readonly name: string;
|
|
455
452
|
readonly parameters: {
|
|
456
453
|
readonly [x: string]: unknown;
|
|
457
454
|
};
|
|
@@ -467,6 +464,9 @@ export declare const route: Route<{
|
|
|
467
464
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
468
465
|
readonly partial_images?: number | undefined;
|
|
469
466
|
})[] | undefined;
|
|
467
|
+
readonly text?: {
|
|
468
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
469
|
+
} | undefined;
|
|
470
470
|
readonly temperature?: number | undefined;
|
|
471
471
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
472
472
|
readonly type: "function";
|
|
@@ -478,7 +478,7 @@ export declare const route: Route<{
|
|
|
478
478
|
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;
|
|
479
479
|
readonly store?: boolean | undefined;
|
|
480
480
|
readonly prompt_cache_key?: string | undefined;
|
|
481
|
-
readonly service_tier?: "
|
|
481
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
482
482
|
readonly max_output_tokens?: number | undefined;
|
|
483
483
|
}, HttpTransport.HttpPrepared<string>>;
|
|
484
484
|
export declare const webSocketTransport: import("../route/transport/websocket").JsonTransport<{
|
|
@@ -547,9 +547,6 @@ export declare const webSocketTransport: import("../route/transport/websocket").
|
|
|
547
547
|
})[];
|
|
548
548
|
readonly model: string;
|
|
549
549
|
readonly stream: true;
|
|
550
|
-
readonly text?: {
|
|
551
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
552
|
-
} | undefined;
|
|
553
550
|
readonly instructions?: string | undefined;
|
|
554
551
|
readonly reasoning?: {
|
|
555
552
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -557,8 +554,8 @@ export declare const webSocketTransport: import("../route/transport/websocket").
|
|
|
557
554
|
} | undefined;
|
|
558
555
|
readonly tools?: readonly ({
|
|
559
556
|
readonly type: "function";
|
|
560
|
-
readonly name: string;
|
|
561
557
|
readonly description: string;
|
|
558
|
+
readonly name: string;
|
|
562
559
|
readonly parameters: {
|
|
563
560
|
readonly [x: string]: unknown;
|
|
564
561
|
};
|
|
@@ -574,6 +571,9 @@ export declare const webSocketTransport: import("../route/transport/websocket").
|
|
|
574
571
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
575
572
|
readonly partial_images?: number | undefined;
|
|
576
573
|
})[] | undefined;
|
|
574
|
+
readonly text?: {
|
|
575
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
576
|
+
} | undefined;
|
|
577
577
|
readonly temperature?: number | undefined;
|
|
578
578
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
579
579
|
readonly type: "function";
|
|
@@ -585,7 +585,7 @@ export declare const webSocketTransport: import("../route/transport/websocket").
|
|
|
585
585
|
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;
|
|
586
586
|
readonly store?: boolean | undefined;
|
|
587
587
|
readonly prompt_cache_key?: string | undefined;
|
|
588
|
-
readonly service_tier?: "
|
|
588
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
589
589
|
readonly max_output_tokens?: number | undefined;
|
|
590
590
|
}, {
|
|
591
591
|
readonly [x: string]: unknown;
|
|
@@ -654,9 +654,6 @@ export declare const webSocketTransport: import("../route/transport/websocket").
|
|
|
654
654
|
readonly phase?: "commentary" | "final_answer" | null | undefined;
|
|
655
655
|
})[];
|
|
656
656
|
readonly model: string;
|
|
657
|
-
readonly text?: {
|
|
658
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
659
|
-
} | undefined;
|
|
660
657
|
readonly instructions?: string | undefined;
|
|
661
658
|
readonly reasoning?: {
|
|
662
659
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -664,8 +661,8 @@ export declare const webSocketTransport: import("../route/transport/websocket").
|
|
|
664
661
|
} | undefined;
|
|
665
662
|
readonly tools?: readonly ({
|
|
666
663
|
readonly type: "function";
|
|
667
|
-
readonly name: string;
|
|
668
664
|
readonly description: string;
|
|
665
|
+
readonly name: string;
|
|
669
666
|
readonly parameters: {
|
|
670
667
|
readonly [x: string]: unknown;
|
|
671
668
|
};
|
|
@@ -681,6 +678,9 @@ export declare const webSocketTransport: import("../route/transport/websocket").
|
|
|
681
678
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
682
679
|
readonly partial_images?: number | undefined;
|
|
683
680
|
})[] | undefined;
|
|
681
|
+
readonly text?: {
|
|
682
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
683
|
+
} | undefined;
|
|
684
684
|
readonly temperature?: number | undefined;
|
|
685
685
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
686
686
|
readonly type: "function";
|
|
@@ -692,7 +692,7 @@ export declare const webSocketTransport: import("../route/transport/websocket").
|
|
|
692
692
|
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;
|
|
693
693
|
readonly store?: boolean | undefined;
|
|
694
694
|
readonly prompt_cache_key?: string | undefined;
|
|
695
|
-
readonly service_tier?: "
|
|
695
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
696
696
|
readonly max_output_tokens?: number | undefined;
|
|
697
697
|
}>;
|
|
698
698
|
export declare const webSocketRoute: Route<{
|
|
@@ -761,9 +761,6 @@ export declare const webSocketRoute: Route<{
|
|
|
761
761
|
})[];
|
|
762
762
|
readonly model: string;
|
|
763
763
|
readonly stream: true;
|
|
764
|
-
readonly text?: {
|
|
765
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
766
|
-
} | undefined;
|
|
767
764
|
readonly instructions?: string | undefined;
|
|
768
765
|
readonly reasoning?: {
|
|
769
766
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -771,8 +768,8 @@ export declare const webSocketRoute: Route<{
|
|
|
771
768
|
} | undefined;
|
|
772
769
|
readonly tools?: readonly ({
|
|
773
770
|
readonly type: "function";
|
|
774
|
-
readonly name: string;
|
|
775
771
|
readonly description: string;
|
|
772
|
+
readonly name: string;
|
|
776
773
|
readonly parameters: {
|
|
777
774
|
readonly [x: string]: unknown;
|
|
778
775
|
};
|
|
@@ -788,6 +785,9 @@ export declare const webSocketRoute: Route<{
|
|
|
788
785
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
789
786
|
readonly partial_images?: number | undefined;
|
|
790
787
|
})[] | undefined;
|
|
788
|
+
readonly text?: {
|
|
789
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
790
|
+
} | undefined;
|
|
791
791
|
readonly temperature?: number | undefined;
|
|
792
792
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
793
793
|
readonly type: "function";
|
|
@@ -799,7 +799,7 @@ export declare const webSocketRoute: Route<{
|
|
|
799
799
|
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;
|
|
800
800
|
readonly store?: boolean | undefined;
|
|
801
801
|
readonly prompt_cache_key?: string | undefined;
|
|
802
|
-
readonly service_tier?: "
|
|
802
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
803
803
|
readonly max_output_tokens?: number | undefined;
|
|
804
804
|
}, import("../route/transport/websocket").JsonPrepared>;
|
|
805
805
|
export * as OpenAIResponses from "./openai-responses";
|
|
@@ -181,9 +181,6 @@ export declare const routes: (RouteDef<{
|
|
|
181
181
|
})[];
|
|
182
182
|
readonly model: string;
|
|
183
183
|
readonly stream: true;
|
|
184
|
-
readonly text?: {
|
|
185
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
186
|
-
} | undefined;
|
|
187
184
|
readonly instructions?: string | undefined;
|
|
188
185
|
readonly reasoning?: {
|
|
189
186
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -191,8 +188,8 @@ export declare const routes: (RouteDef<{
|
|
|
191
188
|
} | undefined;
|
|
192
189
|
readonly tools?: readonly ({
|
|
193
190
|
readonly type: "function";
|
|
194
|
-
readonly name: string;
|
|
195
191
|
readonly description: string;
|
|
192
|
+
readonly name: string;
|
|
196
193
|
readonly parameters: {
|
|
197
194
|
readonly [x: string]: unknown;
|
|
198
195
|
};
|
|
@@ -208,6 +205,9 @@ export declare const routes: (RouteDef<{
|
|
|
208
205
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
209
206
|
readonly partial_images?: number | undefined;
|
|
210
207
|
})[] | undefined;
|
|
208
|
+
readonly text?: {
|
|
209
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
210
|
+
} | undefined;
|
|
211
211
|
readonly temperature?: number | undefined;
|
|
212
212
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
213
213
|
readonly type: "function";
|
|
@@ -219,7 +219,7 @@ export declare const routes: (RouteDef<{
|
|
|
219
219
|
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;
|
|
220
220
|
readonly store?: boolean | undefined;
|
|
221
221
|
readonly prompt_cache_key?: string | undefined;
|
|
222
|
-
readonly service_tier?: "
|
|
222
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
223
223
|
readonly max_output_tokens?: number | undefined;
|
|
224
224
|
}, import("../route/transport/http").HttpPrepared<string>>)[];
|
|
225
225
|
export declare const configure: (input?: Config) => {
|
|
@@ -168,8 +168,8 @@ export declare const routes: import("../route").Route<{
|
|
|
168
168
|
} | undefined;
|
|
169
169
|
}[] | undefined;
|
|
170
170
|
readonly tools?: readonly {
|
|
171
|
-
readonly name: string;
|
|
172
171
|
readonly description: string;
|
|
172
|
+
readonly name: string;
|
|
173
173
|
readonly input_schema: {
|
|
174
174
|
readonly [x: string]: unknown;
|
|
175
175
|
};
|
|
@@ -152,8 +152,8 @@ export declare const routes: import("../route").Route<{
|
|
|
152
152
|
} | undefined;
|
|
153
153
|
}[] | undefined;
|
|
154
154
|
readonly tools?: readonly {
|
|
155
|
-
readonly name: string;
|
|
156
155
|
readonly description: string;
|
|
156
|
+
readonly name: string;
|
|
157
157
|
readonly input_schema: {
|
|
158
158
|
readonly [x: string]: unknown;
|
|
159
159
|
};
|
|
@@ -184,9 +184,6 @@ export declare const routes: (RouteDef<{
|
|
|
184
184
|
})[];
|
|
185
185
|
readonly model: string;
|
|
186
186
|
readonly stream: true;
|
|
187
|
-
readonly text?: {
|
|
188
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
189
|
-
} | undefined;
|
|
190
187
|
readonly instructions?: string | undefined;
|
|
191
188
|
readonly reasoning?: {
|
|
192
189
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -194,8 +191,8 @@ export declare const routes: (RouteDef<{
|
|
|
194
191
|
} | undefined;
|
|
195
192
|
readonly tools?: readonly ({
|
|
196
193
|
readonly type: "function";
|
|
197
|
-
readonly name: string;
|
|
198
194
|
readonly description: string;
|
|
195
|
+
readonly name: string;
|
|
199
196
|
readonly parameters: {
|
|
200
197
|
readonly [x: string]: unknown;
|
|
201
198
|
};
|
|
@@ -211,6 +208,9 @@ export declare const routes: (RouteDef<{
|
|
|
211
208
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
212
209
|
readonly partial_images?: number | undefined;
|
|
213
210
|
})[] | undefined;
|
|
211
|
+
readonly text?: {
|
|
212
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
213
|
+
} | undefined;
|
|
214
214
|
readonly temperature?: number | undefined;
|
|
215
215
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
216
216
|
readonly type: "function";
|
|
@@ -222,7 +222,7 @@ export declare const routes: (RouteDef<{
|
|
|
222
222
|
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;
|
|
223
223
|
readonly store?: boolean | undefined;
|
|
224
224
|
readonly prompt_cache_key?: string | undefined;
|
|
225
|
-
readonly service_tier?: "
|
|
225
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
226
226
|
readonly max_output_tokens?: number | undefined;
|
|
227
227
|
}, import("../route/transport/http").HttpPrepared<string>>)[];
|
|
228
228
|
export declare const configure: (input: Config) => {
|
|
@@ -77,9 +77,6 @@ export declare const routes: import("../route").Route<{
|
|
|
77
77
|
})[];
|
|
78
78
|
readonly model: string;
|
|
79
79
|
readonly stream: true;
|
|
80
|
-
readonly text?: {
|
|
81
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
82
|
-
} | undefined;
|
|
83
80
|
readonly instructions?: string | undefined;
|
|
84
81
|
readonly reasoning?: {
|
|
85
82
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -87,13 +84,16 @@ export declare const routes: import("../route").Route<{
|
|
|
87
84
|
} | undefined;
|
|
88
85
|
readonly tools?: readonly {
|
|
89
86
|
readonly type: "function";
|
|
90
|
-
readonly name: string;
|
|
91
87
|
readonly description: string;
|
|
88
|
+
readonly name: string;
|
|
92
89
|
readonly parameters: {
|
|
93
90
|
readonly [x: string]: unknown;
|
|
94
91
|
};
|
|
95
92
|
readonly strict?: boolean | undefined;
|
|
96
93
|
}[] | undefined;
|
|
94
|
+
readonly text?: {
|
|
95
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
96
|
+
} | undefined;
|
|
97
97
|
readonly temperature?: number | undefined;
|
|
98
98
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
99
99
|
readonly type: "function";
|
|
@@ -103,7 +103,7 @@ export declare const routes: import("../route").Route<{
|
|
|
103
103
|
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;
|
|
104
104
|
readonly store?: boolean | undefined;
|
|
105
105
|
readonly prompt_cache_key?: string | undefined;
|
|
106
|
-
readonly service_tier?: "
|
|
106
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
107
107
|
readonly max_output_tokens?: number | undefined;
|
|
108
108
|
}, import("../route/transport/http").HttpPrepared<string>>[];
|
|
109
109
|
export declare const configure: (input?: Config) => {
|
|
@@ -59,8 +59,8 @@ export declare const routes: Route<{
|
|
|
59
59
|
}[];
|
|
60
60
|
readonly tools?: readonly {
|
|
61
61
|
readonly functionDeclarations: readonly {
|
|
62
|
-
readonly name: string;
|
|
63
62
|
readonly description: string;
|
|
63
|
+
readonly name: string;
|
|
64
64
|
readonly parameters?: {
|
|
65
65
|
readonly [x: string]: unknown;
|
|
66
66
|
} | undefined;
|
|
@@ -42,8 +42,8 @@ export declare const routes: import("../route").Route<{
|
|
|
42
42
|
}[];
|
|
43
43
|
readonly tools?: readonly {
|
|
44
44
|
readonly functionDeclarations: readonly {
|
|
45
|
-
readonly name: string;
|
|
46
45
|
readonly description: string;
|
|
46
|
+
readonly name: string;
|
|
47
47
|
readonly parameters?: {
|
|
48
48
|
readonly [x: string]: unknown;
|
|
49
49
|
} | undefined;
|
|
@@ -5,7 +5,6 @@ export * as AmazonBedrockMantle from "./amazon-bedrock-mantle";
|
|
|
5
5
|
export * as Azure from "./azure";
|
|
6
6
|
export * as Cloudflare from "./cloudflare";
|
|
7
7
|
export { CloudflareAIGateway, CloudflareWorkersAI } from "./cloudflare";
|
|
8
|
-
export * as GitHubCopilot from "./github-copilot";
|
|
9
8
|
export * as Google from "./google";
|
|
10
9
|
export * as GoogleVertex from "./google-vertex";
|
|
11
10
|
export * as GoogleVertexChat from "./google-vertex-chat";
|
package/dist/providers/index.js
CHANGED
|
@@ -5,7 +5,6 @@ export * as AmazonBedrockMantle from "./amazon-bedrock-mantle";
|
|
|
5
5
|
export * as Azure from "./azure";
|
|
6
6
|
export * as Cloudflare from "./cloudflare";
|
|
7
7
|
export { CloudflareAIGateway, CloudflareWorkersAI } from "./cloudflare";
|
|
8
|
-
export * as GitHubCopilot from "./github-copilot";
|
|
9
8
|
export * as Google from "./google";
|
|
10
9
|
export * as GoogleVertex from "./google-vertex";
|
|
11
10
|
export * as GoogleVertexChat from "./google-vertex-chat";
|
|
@@ -75,9 +75,6 @@ export declare const routes: import("../route").Route<{
|
|
|
75
75
|
})[];
|
|
76
76
|
readonly model: string;
|
|
77
77
|
readonly stream: true;
|
|
78
|
-
readonly text?: {
|
|
79
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
80
|
-
} | undefined;
|
|
81
78
|
readonly instructions?: string | undefined;
|
|
82
79
|
readonly reasoning?: {
|
|
83
80
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -85,13 +82,16 @@ export declare const routes: import("../route").Route<{
|
|
|
85
82
|
} | undefined;
|
|
86
83
|
readonly tools?: readonly {
|
|
87
84
|
readonly type: "function";
|
|
88
|
-
readonly name: string;
|
|
89
85
|
readonly description: string;
|
|
86
|
+
readonly name: string;
|
|
90
87
|
readonly parameters: {
|
|
91
88
|
readonly [x: string]: unknown;
|
|
92
89
|
};
|
|
93
90
|
readonly strict?: boolean | undefined;
|
|
94
91
|
}[] | undefined;
|
|
92
|
+
readonly text?: {
|
|
93
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
94
|
+
} | undefined;
|
|
95
95
|
readonly temperature?: number | undefined;
|
|
96
96
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
97
97
|
readonly type: "function";
|
|
@@ -101,7 +101,7 @@ export declare const routes: import("../route").Route<{
|
|
|
101
101
|
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;
|
|
102
102
|
readonly store?: boolean | undefined;
|
|
103
103
|
readonly prompt_cache_key?: string | undefined;
|
|
104
|
-
readonly service_tier?: "
|
|
104
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
105
105
|
readonly max_output_tokens?: number | undefined;
|
|
106
106
|
}, import("../route/transport/http").HttpPrepared<string>>[];
|
|
107
107
|
export declare const configure: (input: Config) => {
|
|
@@ -169,9 +169,6 @@ export declare const routes: (Route<{
|
|
|
169
169
|
})[];
|
|
170
170
|
readonly model: string;
|
|
171
171
|
readonly stream: true;
|
|
172
|
-
readonly text?: {
|
|
173
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
174
|
-
} | undefined;
|
|
175
172
|
readonly instructions?: string | undefined;
|
|
176
173
|
readonly reasoning?: {
|
|
177
174
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -179,8 +176,8 @@ export declare const routes: (Route<{
|
|
|
179
176
|
} | undefined;
|
|
180
177
|
readonly tools?: readonly ({
|
|
181
178
|
readonly type: "function";
|
|
182
|
-
readonly name: string;
|
|
183
179
|
readonly description: string;
|
|
180
|
+
readonly name: string;
|
|
184
181
|
readonly parameters: {
|
|
185
182
|
readonly [x: string]: unknown;
|
|
186
183
|
};
|
|
@@ -196,6 +193,9 @@ export declare const routes: (Route<{
|
|
|
196
193
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
197
194
|
readonly partial_images?: number | undefined;
|
|
198
195
|
})[] | undefined;
|
|
196
|
+
readonly text?: {
|
|
197
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
198
|
+
} | undefined;
|
|
199
199
|
readonly temperature?: number | undefined;
|
|
200
200
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
201
201
|
readonly type: "function";
|
|
@@ -207,7 +207,7 @@ export declare const routes: (Route<{
|
|
|
207
207
|
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;
|
|
208
208
|
readonly store?: boolean | undefined;
|
|
209
209
|
readonly prompt_cache_key?: string | undefined;
|
|
210
|
-
readonly service_tier?: "
|
|
210
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
211
211
|
readonly max_output_tokens?: number | undefined;
|
|
212
212
|
}, import("../route/transport/http").HttpPrepared<string>> | Route<{
|
|
213
213
|
readonly input: readonly ({
|
|
@@ -275,9 +275,6 @@ export declare const routes: (Route<{
|
|
|
275
275
|
})[];
|
|
276
276
|
readonly model: string;
|
|
277
277
|
readonly stream: true;
|
|
278
|
-
readonly text?: {
|
|
279
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
280
|
-
} | undefined;
|
|
281
278
|
readonly instructions?: string | undefined;
|
|
282
279
|
readonly reasoning?: {
|
|
283
280
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -285,8 +282,8 @@ export declare const routes: (Route<{
|
|
|
285
282
|
} | undefined;
|
|
286
283
|
readonly tools?: readonly ({
|
|
287
284
|
readonly type: "function";
|
|
288
|
-
readonly name: string;
|
|
289
285
|
readonly description: string;
|
|
286
|
+
readonly name: string;
|
|
290
287
|
readonly parameters: {
|
|
291
288
|
readonly [x: string]: unknown;
|
|
292
289
|
};
|
|
@@ -302,6 +299,9 @@ export declare const routes: (Route<{
|
|
|
302
299
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
303
300
|
readonly partial_images?: number | undefined;
|
|
304
301
|
})[] | undefined;
|
|
302
|
+
readonly text?: {
|
|
303
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
304
|
+
} | undefined;
|
|
305
305
|
readonly temperature?: number | undefined;
|
|
306
306
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
307
307
|
readonly type: "function";
|
|
@@ -313,7 +313,7 @@ export declare const routes: (Route<{
|
|
|
313
313
|
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;
|
|
314
314
|
readonly store?: boolean | undefined;
|
|
315
315
|
readonly prompt_cache_key?: string | undefined;
|
|
316
|
-
readonly service_tier?: "
|
|
316
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
317
317
|
readonly max_output_tokens?: number | undefined;
|
|
318
318
|
}, import("../route/transport/websocket").JsonPrepared>)[];
|
|
319
319
|
export type Config = RouteDefaultsInput & ProviderAuthOption<"optional"> & {
|
package/dist/providers/xai.d.ts
CHANGED
|
@@ -179,9 +179,6 @@ export declare const routes: (Route<{
|
|
|
179
179
|
})[];
|
|
180
180
|
readonly model: string;
|
|
181
181
|
readonly stream: true;
|
|
182
|
-
readonly text?: {
|
|
183
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
184
|
-
} | undefined;
|
|
185
182
|
readonly instructions?: string | undefined;
|
|
186
183
|
readonly reasoning?: {
|
|
187
184
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
@@ -189,8 +186,8 @@ export declare const routes: (Route<{
|
|
|
189
186
|
} | undefined;
|
|
190
187
|
readonly tools?: readonly ({
|
|
191
188
|
readonly type: "function";
|
|
192
|
-
readonly name: string;
|
|
193
189
|
readonly description: string;
|
|
190
|
+
readonly name: string;
|
|
194
191
|
readonly parameters: {
|
|
195
192
|
readonly [x: string]: unknown;
|
|
196
193
|
};
|
|
@@ -206,6 +203,9 @@ export declare const routes: (Route<{
|
|
|
206
203
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
207
204
|
readonly partial_images?: number | undefined;
|
|
208
205
|
})[] | undefined;
|
|
206
|
+
readonly text?: {
|
|
207
|
+
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
208
|
+
} | undefined;
|
|
209
209
|
readonly temperature?: number | undefined;
|
|
210
210
|
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
211
211
|
readonly type: "function";
|
|
@@ -217,7 +217,7 @@ export declare const routes: (Route<{
|
|
|
217
217
|
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;
|
|
218
218
|
readonly store?: boolean | undefined;
|
|
219
219
|
readonly prompt_cache_key?: string | undefined;
|
|
220
|
-
readonly service_tier?: "
|
|
220
|
+
readonly service_tier?: "default" | "auto" | "flex" | "priority" | undefined;
|
|
221
221
|
readonly max_output_tokens?: number | undefined;
|
|
222
222
|
}, import("../route/transport/http").HttpPrepared<string>>)[];
|
|
223
223
|
export declare const configure: (input?: LanguageModelOptions) => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
|
-
"version": "0.0.0-next-
|
|
3
|
+
"version": "0.0.0-next-17077",
|
|
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-beta.101",
|
|
33
|
-
"@opencode-ai/http-recorder": "0.0.0-next-
|
|
33
|
+
"@opencode-ai/http-recorder": "0.0.0-next-17077",
|
|
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-next-
|
|
42
|
+
"@opencode-ai/schema": "0.0.0-next-17077",
|
|
43
43
|
"aws4fetch": "1.0.20",
|
|
44
44
|
"effect": "4.0.0-beta.101",
|
|
45
45
|
"google-auth-library": "10.5.0"
|
|
@@ -1,231 +0,0 @@
|
|
|
1
|
-
import { type ProviderAuthOption } from "../route/auth-options";
|
|
2
|
-
import type { RouteDefaultsInput } from "../route/client";
|
|
3
|
-
import { type ModelID } from "../schema";
|
|
4
|
-
import { type OpenAIProviderOptionsInput } from "./openai-options";
|
|
5
|
-
export declare const id: string & import("effect/Brand").Brand<"AI.ProviderID">;
|
|
6
|
-
export type LanguageModelOptions = Omit<RouteDefaultsInput, "providerOptions"> & ProviderAuthOption<"optional"> & {
|
|
7
|
-
readonly baseURL: string;
|
|
8
|
-
readonly endpoint?: "chat" | "responses";
|
|
9
|
-
readonly providerOptions?: OpenAIProviderOptionsInput;
|
|
10
|
-
};
|
|
11
|
-
export declare const shouldUseResponsesApi: (modelID: string | ModelID, endpoint?: LanguageModelOptions["endpoint"]) => boolean;
|
|
12
|
-
export declare const routes: (import("../route").Route<{
|
|
13
|
-
readonly model: string;
|
|
14
|
-
readonly messages: readonly ({
|
|
15
|
-
readonly role: "system";
|
|
16
|
-
readonly content: string | readonly ({
|
|
17
|
-
readonly type: "text";
|
|
18
|
-
readonly text: string;
|
|
19
|
-
readonly cache_control?: {
|
|
20
|
-
readonly type: "ephemeral";
|
|
21
|
-
readonly ttl?: string | undefined;
|
|
22
|
-
} | undefined;
|
|
23
|
-
} | {
|
|
24
|
-
readonly type: "image_url";
|
|
25
|
-
readonly image_url: {
|
|
26
|
-
readonly url: string;
|
|
27
|
-
};
|
|
28
|
-
})[];
|
|
29
|
-
} | {
|
|
30
|
-
readonly role: "user";
|
|
31
|
-
readonly content: string | readonly ({
|
|
32
|
-
readonly type: "text";
|
|
33
|
-
readonly text: string;
|
|
34
|
-
readonly cache_control?: {
|
|
35
|
-
readonly type: "ephemeral";
|
|
36
|
-
readonly ttl?: string | undefined;
|
|
37
|
-
} | undefined;
|
|
38
|
-
} | {
|
|
39
|
-
readonly type: "image_url";
|
|
40
|
-
readonly image_url: {
|
|
41
|
-
readonly url: string;
|
|
42
|
-
};
|
|
43
|
-
})[];
|
|
44
|
-
} | {
|
|
45
|
-
readonly [x: string]: unknown;
|
|
46
|
-
readonly content: string | null;
|
|
47
|
-
readonly role: "assistant";
|
|
48
|
-
readonly reasoning?: string | undefined;
|
|
49
|
-
readonly reasoning_content?: string | undefined;
|
|
50
|
-
readonly reasoning_text?: string | undefined;
|
|
51
|
-
readonly cache_control?: {
|
|
52
|
-
readonly type: "ephemeral";
|
|
53
|
-
readonly ttl?: string | undefined;
|
|
54
|
-
} | undefined;
|
|
55
|
-
readonly tool_calls?: readonly {
|
|
56
|
-
readonly id: string;
|
|
57
|
-
readonly type: "function";
|
|
58
|
-
readonly function: {
|
|
59
|
-
readonly name: string;
|
|
60
|
-
readonly arguments: string;
|
|
61
|
-
};
|
|
62
|
-
}[] | undefined;
|
|
63
|
-
readonly reasoning_details?: unknown;
|
|
64
|
-
} | {
|
|
65
|
-
readonly content: string;
|
|
66
|
-
readonly role: "tool";
|
|
67
|
-
readonly tool_call_id: string;
|
|
68
|
-
readonly cache_control?: {
|
|
69
|
-
readonly type: "ephemeral";
|
|
70
|
-
readonly ttl?: string | undefined;
|
|
71
|
-
} | undefined;
|
|
72
|
-
})[];
|
|
73
|
-
readonly stream: true;
|
|
74
|
-
readonly stop?: readonly string[] | undefined;
|
|
75
|
-
readonly max_completion_tokens?: number | undefined;
|
|
76
|
-
readonly max_tokens?: number | undefined;
|
|
77
|
-
readonly tools?: readonly {
|
|
78
|
-
readonly function: {
|
|
79
|
-
readonly name: string;
|
|
80
|
-
readonly description: string;
|
|
81
|
-
readonly parameters: {
|
|
82
|
-
readonly [x: string]: unknown;
|
|
83
|
-
};
|
|
84
|
-
};
|
|
85
|
-
readonly type: "function";
|
|
86
|
-
readonly cache_control?: {
|
|
87
|
-
readonly type: "ephemeral";
|
|
88
|
-
readonly ttl?: string | undefined;
|
|
89
|
-
} | undefined;
|
|
90
|
-
}[] | undefined;
|
|
91
|
-
readonly temperature?: number | undefined;
|
|
92
|
-
readonly seed?: number | undefined;
|
|
93
|
-
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
94
|
-
readonly type: "function";
|
|
95
|
-
readonly function: {
|
|
96
|
-
readonly name: string;
|
|
97
|
-
};
|
|
98
|
-
} | undefined;
|
|
99
|
-
readonly top_p?: number | undefined;
|
|
100
|
-
readonly store?: boolean | undefined;
|
|
101
|
-
readonly stream_options?: {
|
|
102
|
-
readonly include_usage: boolean;
|
|
103
|
-
} | undefined;
|
|
104
|
-
readonly prompt_cache_key?: string | undefined;
|
|
105
|
-
readonly reasoning_effort?: string | undefined;
|
|
106
|
-
readonly frequency_penalty?: number | undefined;
|
|
107
|
-
readonly presence_penalty?: number | undefined;
|
|
108
|
-
}, import("../route/transport/http").HttpPrepared<string>> | import("../route").Route<{
|
|
109
|
-
readonly input: readonly ({
|
|
110
|
-
readonly type: "reasoning";
|
|
111
|
-
readonly summary: readonly {
|
|
112
|
-
readonly type: "summary_text";
|
|
113
|
-
readonly text: string;
|
|
114
|
-
}[];
|
|
115
|
-
readonly id?: string | undefined;
|
|
116
|
-
readonly encrypted_content?: string | null | undefined;
|
|
117
|
-
} | {
|
|
118
|
-
readonly type: "item_reference";
|
|
119
|
-
readonly id: string;
|
|
120
|
-
} | {
|
|
121
|
-
readonly role: "system";
|
|
122
|
-
readonly content: string;
|
|
123
|
-
} | {
|
|
124
|
-
readonly role: "user";
|
|
125
|
-
readonly content: readonly ({
|
|
126
|
-
readonly type: "input_image";
|
|
127
|
-
readonly image_url: string;
|
|
128
|
-
} | {
|
|
129
|
-
readonly type: "input_file";
|
|
130
|
-
readonly filename: string;
|
|
131
|
-
readonly file_data: string;
|
|
132
|
-
readonly mime_type?: string | undefined;
|
|
133
|
-
} | {
|
|
134
|
-
readonly type: "input_text";
|
|
135
|
-
readonly text: string;
|
|
136
|
-
})[];
|
|
137
|
-
} | {
|
|
138
|
-
readonly content: readonly {
|
|
139
|
-
readonly type: "output_text";
|
|
140
|
-
readonly text: string;
|
|
141
|
-
}[];
|
|
142
|
-
readonly role: "assistant";
|
|
143
|
-
readonly phase?: "commentary" | "final_answer" | undefined;
|
|
144
|
-
} | {
|
|
145
|
-
readonly type: "function_call";
|
|
146
|
-
readonly call_id: string;
|
|
147
|
-
readonly name: string;
|
|
148
|
-
readonly arguments: string;
|
|
149
|
-
} | {
|
|
150
|
-
readonly type: "function_call_output";
|
|
151
|
-
readonly call_id: string;
|
|
152
|
-
readonly output: string | readonly ({
|
|
153
|
-
readonly type: "input_image";
|
|
154
|
-
readonly image_url: string;
|
|
155
|
-
} | {
|
|
156
|
-
readonly type: "input_file";
|
|
157
|
-
readonly filename: string;
|
|
158
|
-
readonly file_data: string;
|
|
159
|
-
readonly mime_type?: string | undefined;
|
|
160
|
-
} | {
|
|
161
|
-
readonly type: "input_text";
|
|
162
|
-
readonly text: string;
|
|
163
|
-
})[];
|
|
164
|
-
} | {
|
|
165
|
-
readonly content: readonly {
|
|
166
|
-
readonly type: "output_text";
|
|
167
|
-
readonly text: string;
|
|
168
|
-
}[];
|
|
169
|
-
readonly role: "assistant";
|
|
170
|
-
readonly phase?: "commentary" | "final_answer" | null | undefined;
|
|
171
|
-
})[];
|
|
172
|
-
readonly model: string;
|
|
173
|
-
readonly stream: true;
|
|
174
|
-
readonly text?: {
|
|
175
|
-
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
176
|
-
} | undefined;
|
|
177
|
-
readonly instructions?: string | undefined;
|
|
178
|
-
readonly reasoning?: {
|
|
179
|
-
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
180
|
-
readonly effort?: string | undefined;
|
|
181
|
-
} | undefined;
|
|
182
|
-
readonly tools?: readonly ({
|
|
183
|
-
readonly type: "function";
|
|
184
|
-
readonly name: string;
|
|
185
|
-
readonly description: string;
|
|
186
|
-
readonly parameters: {
|
|
187
|
-
readonly [x: string]: unknown;
|
|
188
|
-
};
|
|
189
|
-
readonly strict?: boolean | undefined;
|
|
190
|
-
} | {
|
|
191
|
-
readonly type: "image_generation";
|
|
192
|
-
readonly size?: string | undefined;
|
|
193
|
-
readonly action?: "generate" | "auto" | "edit" | undefined;
|
|
194
|
-
readonly output_format?: "png" | "jpeg" | "webp" | undefined;
|
|
195
|
-
readonly quality?: "low" | "medium" | "high" | "auto" | undefined;
|
|
196
|
-
readonly background?: "auto" | "opaque" | "transparent" | undefined;
|
|
197
|
-
readonly output_compression?: number | undefined;
|
|
198
|
-
readonly input_fidelity?: "low" | "high" | undefined;
|
|
199
|
-
readonly partial_images?: number | undefined;
|
|
200
|
-
})[] | undefined;
|
|
201
|
-
readonly temperature?: number | undefined;
|
|
202
|
-
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
203
|
-
readonly type: "function";
|
|
204
|
-
readonly name: string;
|
|
205
|
-
} | {
|
|
206
|
-
readonly type: "image_generation";
|
|
207
|
-
} | undefined;
|
|
208
|
-
readonly top_p?: number | undefined;
|
|
209
|
-
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;
|
|
210
|
-
readonly store?: boolean | undefined;
|
|
211
|
-
readonly prompt_cache_key?: string | undefined;
|
|
212
|
-
readonly service_tier?: "auto" | "default" | "flex" | "priority" | undefined;
|
|
213
|
-
readonly max_output_tokens?: number | undefined;
|
|
214
|
-
}, import("../route/transport/http").HttpPrepared<string>>)[];
|
|
215
|
-
export declare const configure: (options: LanguageModelOptions) => {
|
|
216
|
-
id: string & import("effect/Brand").Brand<"AI.ProviderID">;
|
|
217
|
-
model: (modelID: string | ModelID) => import("..").LanguageModel<OpenAIProviderOptionsInput>;
|
|
218
|
-
responses: (modelID: string | ModelID) => import("..").LanguageModel<OpenAIProviderOptionsInput>;
|
|
219
|
-
chat: (modelID: string | ModelID) => import("..").LanguageModel<OpenAIProviderOptionsInput>;
|
|
220
|
-
configure: (options: LanguageModelOptions) => /*elided*/ any;
|
|
221
|
-
};
|
|
222
|
-
export declare const provider: {
|
|
223
|
-
id: string & import("effect/Brand").Brand<"AI.ProviderID">;
|
|
224
|
-
configure: (options: LanguageModelOptions) => {
|
|
225
|
-
id: string & import("effect/Brand").Brand<"AI.ProviderID">;
|
|
226
|
-
model: (modelID: string | ModelID) => import("..").LanguageModel<OpenAIProviderOptionsInput>;
|
|
227
|
-
responses: (modelID: string | ModelID) => import("..").LanguageModel<OpenAIProviderOptionsInput>;
|
|
228
|
-
chat: (modelID: string | ModelID) => import("..").LanguageModel<OpenAIProviderOptionsInput>;
|
|
229
|
-
configure: /*elided*/ any;
|
|
230
|
-
};
|
|
231
|
-
};
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { AuthOptions } from "../route/auth-options";
|
|
2
|
-
import { ProviderID } from "../schema";
|
|
3
|
-
import * as OpenAIChat from "../protocols/openai-chat";
|
|
4
|
-
import * as OpenAIResponses from "../protocols/openai-responses";
|
|
5
|
-
import { withOpenAIOptions } from "./openai-options";
|
|
6
|
-
export const id = ProviderID.make("github-copilot");
|
|
7
|
-
export const shouldUseResponsesApi = (modelID, endpoint) => {
|
|
8
|
-
if (endpoint)
|
|
9
|
-
return endpoint === "responses";
|
|
10
|
-
const model = String(modelID);
|
|
11
|
-
const match = /^gpt-(\d+)/.exec(model);
|
|
12
|
-
if (!match)
|
|
13
|
-
return false;
|
|
14
|
-
return Number(match[1]) >= 5 && !model.startsWith("gpt-5-mini");
|
|
15
|
-
};
|
|
16
|
-
export const routes = [OpenAIResponses.route, OpenAIChat.route];
|
|
17
|
-
const chatRoute = OpenAIChat.route.with({ provider: id });
|
|
18
|
-
const responsesRoute = OpenAIResponses.route.with({ provider: id });
|
|
19
|
-
const defaults = (options) => {
|
|
20
|
-
const { apiKey: _, auth: _auth, baseURL: _baseURL, endpoint: _endpoint, ...rest } = options;
|
|
21
|
-
return rest;
|
|
22
|
-
};
|
|
23
|
-
const configuredResponsesRoute = (options) => responsesRoute.with({
|
|
24
|
-
endpoint: { baseURL: options.baseURL },
|
|
25
|
-
auth: AuthOptions.bearer(options, []),
|
|
26
|
-
});
|
|
27
|
-
const configuredChatRoute = (options) => chatRoute.with({
|
|
28
|
-
endpoint: { baseURL: options.baseURL },
|
|
29
|
-
auth: AuthOptions.bearer(options, []),
|
|
30
|
-
});
|
|
31
|
-
export const configure = (options) => {
|
|
32
|
-
const responsesRoute = configuredResponsesRoute(options);
|
|
33
|
-
const chatRoute = configuredChatRoute(options);
|
|
34
|
-
const responses = (modelID) => responsesRoute
|
|
35
|
-
.with(withOpenAIOptions(modelID, defaults(options)))
|
|
36
|
-
.model({ id: modelID });
|
|
37
|
-
const chat = (modelID) => chatRoute.with(withOpenAIOptions(modelID, defaults(options))).model({ id: modelID });
|
|
38
|
-
return {
|
|
39
|
-
id,
|
|
40
|
-
model: (modelID) => shouldUseResponsesApi(modelID, options.endpoint) ? responses(modelID) : chat(modelID),
|
|
41
|
-
responses,
|
|
42
|
-
chat,
|
|
43
|
-
configure,
|
|
44
|
-
};
|
|
45
|
-
};
|
|
46
|
-
export const provider = {
|
|
47
|
-
id,
|
|
48
|
-
configure,
|
|
49
|
-
};
|