@opencode-ai/ai 0.0.0-next-16255 → 0.0.0-next-16273
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/llm.d.ts +60 -60
- package/dist/protocols/anthropic-messages.d.ts +303 -303
- package/dist/protocols/anthropic-messages.js +1 -0
- package/dist/protocols/bedrock-converse.d.ts +246 -242
- package/dist/protocols/gemini.d.ts +136 -132
- package/dist/protocols/gemini.js +1 -0
- package/dist/protocols/open-responses.d.ts +232 -232
- package/dist/protocols/openai-chat.d.ts +147 -141
- package/dist/protocols/openai-chat.js +1 -0
- package/dist/protocols/openai-compatible-chat.d.ts +48 -46
- package/dist/protocols/openai-compatible-responses.d.ts +56 -56
- package/dist/protocols/openai-responses.d.ts +388 -388
- package/dist/protocols/shared.d.ts +5 -4
- package/dist/protocols/shared.js +1 -0
- package/dist/protocols/utils/bedrock-media.d.ts +10 -10
- package/dist/protocols/utils/tool-stream.d.ts +180 -180
- package/dist/providers/amazon-bedrock.d.ts +109 -107
- package/dist/providers/anthropic-compatible.d.ts +145 -145
- package/dist/providers/anthropic.d.ts +145 -145
- package/dist/providers/azure.d.ts +112 -110
- package/dist/providers/cloudflare.d.ts +144 -138
- package/dist/providers/github-copilot.d.ts +112 -110
- package/dist/providers/google-vertex-chat.d.ts +48 -46
- package/dist/providers/google-vertex-messages.d.ts +145 -146
- package/dist/providers/google-vertex-responses.d.ts +56 -56
- package/dist/providers/google-vertex.d.ts +52 -50
- package/dist/providers/google.d.ts +52 -50
- package/dist/providers/openai-compatible-responses.d.ts +56 -56
- package/dist/providers/openai-compatible.d.ts +48 -46
- package/dist/providers/openai.d.ts +176 -174
- package/dist/providers/openrouter.d.ts +147 -141
- package/dist/providers/xai.d.ts +112 -110
- package/dist/route/client.d.ts +60 -60
- package/dist/schema/errors.d.ts +2 -6
- package/dist/schema/errors.js +2 -5
- package/dist/schema/events.d.ts +1117 -1115
- package/dist/schema/messages.d.ts +9 -9
- package/dist/schema/messages.js +3 -4
- package/dist/tool-runtime.js +1 -1
- package/dist/tool.d.ts +5 -4
- package/dist/tool.js +1 -0
- package/package.json +5 -5
|
@@ -25,196 +25,202 @@ export type WorkersAIOptions = WorkersAIURL & RouteDefaultsInput & ProviderAuthO
|
|
|
25
25
|
export declare const aiGatewayBaseURL: (input: GatewayURL) => string;
|
|
26
26
|
export declare const workersAIBaseURL: (input: WorkersAIURL) => string;
|
|
27
27
|
export declare const aiGatewayRoute: import("../route").Route<{
|
|
28
|
-
readonly
|
|
29
|
-
|
|
30
|
-
readonly
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
readonly
|
|
34
|
-
|
|
35
|
-
readonly
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
readonly
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
28
|
+
readonly model: string;
|
|
29
|
+
readonly messages: readonly ({
|
|
30
|
+
readonly role: "system";
|
|
31
|
+
readonly content: string;
|
|
32
|
+
} | {
|
|
33
|
+
readonly role: "user";
|
|
34
|
+
readonly content: string | readonly ({
|
|
35
|
+
readonly type: "text";
|
|
36
|
+
readonly text: string;
|
|
37
|
+
} | {
|
|
38
|
+
readonly type: "image_url";
|
|
39
|
+
readonly image_url: {
|
|
40
|
+
readonly url: string;
|
|
41
|
+
};
|
|
42
|
+
})[];
|
|
43
|
+
} | {
|
|
43
44
|
readonly [x: string]: unknown;
|
|
44
45
|
readonly content: string | null;
|
|
45
46
|
readonly role: "assistant";
|
|
46
47
|
readonly reasoning?: string | undefined;
|
|
47
|
-
readonly tool_calls?: readonly import("effect/Schema").Struct.ReadonlySide<{
|
|
48
|
-
readonly id: import("effect/Schema").String;
|
|
49
|
-
readonly type: import("effect/Schema").tag<"function">;
|
|
50
|
-
readonly function: import("effect/Schema").Struct<{
|
|
51
|
-
readonly name: import("effect/Schema").String;
|
|
52
|
-
readonly arguments: import("effect/Schema").String;
|
|
53
|
-
}>;
|
|
54
|
-
}, "Type">[] | undefined;
|
|
55
48
|
readonly reasoning_content?: string | undefined;
|
|
56
49
|
readonly reasoning_text?: string | undefined;
|
|
50
|
+
readonly tool_calls?: readonly {
|
|
51
|
+
readonly id: string;
|
|
52
|
+
readonly type: "function";
|
|
53
|
+
readonly function: {
|
|
54
|
+
readonly name: string;
|
|
55
|
+
readonly arguments: string;
|
|
56
|
+
};
|
|
57
|
+
}[] | undefined;
|
|
57
58
|
readonly reasoning_details?: unknown;
|
|
58
|
-
} |
|
|
59
|
-
readonly role:
|
|
60
|
-
readonly tool_call_id:
|
|
61
|
-
readonly content:
|
|
62
|
-
}
|
|
63
|
-
readonly model: string;
|
|
59
|
+
} | {
|
|
60
|
+
readonly role: "tool";
|
|
61
|
+
readonly tool_call_id: string;
|
|
62
|
+
readonly content: string;
|
|
63
|
+
})[];
|
|
64
64
|
readonly stream: true;
|
|
65
65
|
readonly stop?: readonly string[] | undefined;
|
|
66
|
-
readonly tools?: readonly
|
|
67
|
-
readonly type:
|
|
68
|
-
readonly function:
|
|
69
|
-
readonly name:
|
|
70
|
-
readonly description:
|
|
71
|
-
readonly parameters:
|
|
72
|
-
|
|
73
|
-
|
|
66
|
+
readonly tools?: readonly {
|
|
67
|
+
readonly type: "function";
|
|
68
|
+
readonly function: {
|
|
69
|
+
readonly name: string;
|
|
70
|
+
readonly description: string;
|
|
71
|
+
readonly parameters: {
|
|
72
|
+
readonly [x: string]: unknown;
|
|
73
|
+
};
|
|
74
|
+
};
|
|
75
|
+
}[] | undefined;
|
|
74
76
|
readonly temperature?: number | undefined;
|
|
75
77
|
readonly seed?: number | undefined;
|
|
76
78
|
readonly frequency_penalty?: number | undefined;
|
|
77
79
|
readonly max_tokens?: number | undefined;
|
|
78
80
|
readonly presence_penalty?: number | undefined;
|
|
79
|
-
readonly stream_options?:
|
|
80
|
-
readonly include_usage:
|
|
81
|
-
}
|
|
82
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
83
|
-
readonly type:
|
|
84
|
-
readonly function:
|
|
85
|
-
readonly name:
|
|
86
|
-
}
|
|
87
|
-
}
|
|
81
|
+
readonly stream_options?: {
|
|
82
|
+
readonly include_usage: boolean;
|
|
83
|
+
} | undefined;
|
|
84
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
85
|
+
readonly type: "function";
|
|
86
|
+
readonly function: {
|
|
87
|
+
readonly name: string;
|
|
88
|
+
};
|
|
89
|
+
} | undefined;
|
|
88
90
|
readonly top_p?: number | undefined;
|
|
89
91
|
readonly store?: boolean | undefined;
|
|
90
92
|
readonly reasoning_effort?: string | undefined;
|
|
91
93
|
}, import("../route/transport/http").HttpPrepared<string>>;
|
|
92
94
|
export declare const workersAIRoute: import("../route").Route<{
|
|
93
|
-
readonly
|
|
94
|
-
|
|
95
|
-
readonly
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
readonly
|
|
99
|
-
|
|
100
|
-
readonly
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
readonly
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
95
|
+
readonly model: string;
|
|
96
|
+
readonly messages: readonly ({
|
|
97
|
+
readonly role: "system";
|
|
98
|
+
readonly content: string;
|
|
99
|
+
} | {
|
|
100
|
+
readonly role: "user";
|
|
101
|
+
readonly content: string | readonly ({
|
|
102
|
+
readonly type: "text";
|
|
103
|
+
readonly text: string;
|
|
104
|
+
} | {
|
|
105
|
+
readonly type: "image_url";
|
|
106
|
+
readonly image_url: {
|
|
107
|
+
readonly url: string;
|
|
108
|
+
};
|
|
109
|
+
})[];
|
|
110
|
+
} | {
|
|
108
111
|
readonly [x: string]: unknown;
|
|
109
112
|
readonly content: string | null;
|
|
110
113
|
readonly role: "assistant";
|
|
111
114
|
readonly reasoning?: string | undefined;
|
|
112
|
-
readonly tool_calls?: readonly import("effect/Schema").Struct.ReadonlySide<{
|
|
113
|
-
readonly id: import("effect/Schema").String;
|
|
114
|
-
readonly type: import("effect/Schema").tag<"function">;
|
|
115
|
-
readonly function: import("effect/Schema").Struct<{
|
|
116
|
-
readonly name: import("effect/Schema").String;
|
|
117
|
-
readonly arguments: import("effect/Schema").String;
|
|
118
|
-
}>;
|
|
119
|
-
}, "Type">[] | undefined;
|
|
120
115
|
readonly reasoning_content?: string | undefined;
|
|
121
116
|
readonly reasoning_text?: string | undefined;
|
|
117
|
+
readonly tool_calls?: readonly {
|
|
118
|
+
readonly id: string;
|
|
119
|
+
readonly type: "function";
|
|
120
|
+
readonly function: {
|
|
121
|
+
readonly name: string;
|
|
122
|
+
readonly arguments: string;
|
|
123
|
+
};
|
|
124
|
+
}[] | undefined;
|
|
122
125
|
readonly reasoning_details?: unknown;
|
|
123
|
-
} |
|
|
124
|
-
readonly role:
|
|
125
|
-
readonly tool_call_id:
|
|
126
|
-
readonly content:
|
|
127
|
-
}
|
|
128
|
-
readonly model: string;
|
|
126
|
+
} | {
|
|
127
|
+
readonly role: "tool";
|
|
128
|
+
readonly tool_call_id: string;
|
|
129
|
+
readonly content: string;
|
|
130
|
+
})[];
|
|
129
131
|
readonly stream: true;
|
|
130
132
|
readonly stop?: readonly string[] | undefined;
|
|
131
|
-
readonly tools?: readonly
|
|
132
|
-
readonly type:
|
|
133
|
-
readonly function:
|
|
134
|
-
readonly name:
|
|
135
|
-
readonly description:
|
|
136
|
-
readonly parameters:
|
|
137
|
-
|
|
138
|
-
|
|
133
|
+
readonly tools?: readonly {
|
|
134
|
+
readonly type: "function";
|
|
135
|
+
readonly function: {
|
|
136
|
+
readonly name: string;
|
|
137
|
+
readonly description: string;
|
|
138
|
+
readonly parameters: {
|
|
139
|
+
readonly [x: string]: unknown;
|
|
140
|
+
};
|
|
141
|
+
};
|
|
142
|
+
}[] | undefined;
|
|
139
143
|
readonly temperature?: number | undefined;
|
|
140
144
|
readonly seed?: number | undefined;
|
|
141
145
|
readonly frequency_penalty?: number | undefined;
|
|
142
146
|
readonly max_tokens?: number | undefined;
|
|
143
147
|
readonly presence_penalty?: number | undefined;
|
|
144
|
-
readonly stream_options?:
|
|
145
|
-
readonly include_usage:
|
|
146
|
-
}
|
|
147
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
148
|
-
readonly type:
|
|
149
|
-
readonly function:
|
|
150
|
-
readonly name:
|
|
151
|
-
}
|
|
152
|
-
}
|
|
148
|
+
readonly stream_options?: {
|
|
149
|
+
readonly include_usage: boolean;
|
|
150
|
+
} | undefined;
|
|
151
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
152
|
+
readonly type: "function";
|
|
153
|
+
readonly function: {
|
|
154
|
+
readonly name: string;
|
|
155
|
+
};
|
|
156
|
+
} | undefined;
|
|
153
157
|
readonly top_p?: number | undefined;
|
|
154
158
|
readonly store?: boolean | undefined;
|
|
155
159
|
readonly reasoning_effort?: string | undefined;
|
|
156
160
|
}, import("../route/transport/http").HttpPrepared<string>>;
|
|
157
161
|
export declare const routes: import("../route").Route<{
|
|
158
|
-
readonly
|
|
159
|
-
|
|
160
|
-
readonly
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
readonly
|
|
164
|
-
|
|
165
|
-
readonly
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
readonly
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
162
|
+
readonly model: string;
|
|
163
|
+
readonly messages: readonly ({
|
|
164
|
+
readonly role: "system";
|
|
165
|
+
readonly content: string;
|
|
166
|
+
} | {
|
|
167
|
+
readonly role: "user";
|
|
168
|
+
readonly content: string | readonly ({
|
|
169
|
+
readonly type: "text";
|
|
170
|
+
readonly text: string;
|
|
171
|
+
} | {
|
|
172
|
+
readonly type: "image_url";
|
|
173
|
+
readonly image_url: {
|
|
174
|
+
readonly url: string;
|
|
175
|
+
};
|
|
176
|
+
})[];
|
|
177
|
+
} | {
|
|
173
178
|
readonly [x: string]: unknown;
|
|
174
179
|
readonly content: string | null;
|
|
175
180
|
readonly role: "assistant";
|
|
176
181
|
readonly reasoning?: string | undefined;
|
|
177
|
-
readonly tool_calls?: readonly import("effect/Schema").Struct.ReadonlySide<{
|
|
178
|
-
readonly id: import("effect/Schema").String;
|
|
179
|
-
readonly type: import("effect/Schema").tag<"function">;
|
|
180
|
-
readonly function: import("effect/Schema").Struct<{
|
|
181
|
-
readonly name: import("effect/Schema").String;
|
|
182
|
-
readonly arguments: import("effect/Schema").String;
|
|
183
|
-
}>;
|
|
184
|
-
}, "Type">[] | undefined;
|
|
185
182
|
readonly reasoning_content?: string | undefined;
|
|
186
183
|
readonly reasoning_text?: string | undefined;
|
|
184
|
+
readonly tool_calls?: readonly {
|
|
185
|
+
readonly id: string;
|
|
186
|
+
readonly type: "function";
|
|
187
|
+
readonly function: {
|
|
188
|
+
readonly name: string;
|
|
189
|
+
readonly arguments: string;
|
|
190
|
+
};
|
|
191
|
+
}[] | undefined;
|
|
187
192
|
readonly reasoning_details?: unknown;
|
|
188
|
-
} |
|
|
189
|
-
readonly role:
|
|
190
|
-
readonly tool_call_id:
|
|
191
|
-
readonly content:
|
|
192
|
-
}
|
|
193
|
-
readonly model: string;
|
|
193
|
+
} | {
|
|
194
|
+
readonly role: "tool";
|
|
195
|
+
readonly tool_call_id: string;
|
|
196
|
+
readonly content: string;
|
|
197
|
+
})[];
|
|
194
198
|
readonly stream: true;
|
|
195
199
|
readonly stop?: readonly string[] | undefined;
|
|
196
|
-
readonly tools?: readonly
|
|
197
|
-
readonly type:
|
|
198
|
-
readonly function:
|
|
199
|
-
readonly name:
|
|
200
|
-
readonly description:
|
|
201
|
-
readonly parameters:
|
|
202
|
-
|
|
203
|
-
|
|
200
|
+
readonly tools?: readonly {
|
|
201
|
+
readonly type: "function";
|
|
202
|
+
readonly function: {
|
|
203
|
+
readonly name: string;
|
|
204
|
+
readonly description: string;
|
|
205
|
+
readonly parameters: {
|
|
206
|
+
readonly [x: string]: unknown;
|
|
207
|
+
};
|
|
208
|
+
};
|
|
209
|
+
}[] | undefined;
|
|
204
210
|
readonly temperature?: number | undefined;
|
|
205
211
|
readonly seed?: number | undefined;
|
|
206
212
|
readonly frequency_penalty?: number | undefined;
|
|
207
213
|
readonly max_tokens?: number | undefined;
|
|
208
214
|
readonly presence_penalty?: number | undefined;
|
|
209
|
-
readonly stream_options?:
|
|
210
|
-
readonly include_usage:
|
|
211
|
-
}
|
|
212
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
213
|
-
readonly type:
|
|
214
|
-
readonly function:
|
|
215
|
-
readonly name:
|
|
216
|
-
}
|
|
217
|
-
}
|
|
215
|
+
readonly stream_options?: {
|
|
216
|
+
readonly include_usage: boolean;
|
|
217
|
+
} | undefined;
|
|
218
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
219
|
+
readonly type: "function";
|
|
220
|
+
readonly function: {
|
|
221
|
+
readonly name: string;
|
|
222
|
+
};
|
|
223
|
+
} | undefined;
|
|
218
224
|
readonly top_p?: number | undefined;
|
|
219
225
|
readonly store?: boolean | undefined;
|
|
220
226
|
readonly reasoning_effort?: string | undefined;
|
|
@@ -10,130 +10,132 @@ export type ModelOptions = Omit<RouteDefaultsInput, "providerOptions"> & Provide
|
|
|
10
10
|
};
|
|
11
11
|
export declare const shouldUseResponsesApi: (modelID: string | ModelID, endpoint?: ModelOptions["endpoint"]) => boolean;
|
|
12
12
|
export declare const routes: (import("../route").Route<{
|
|
13
|
-
readonly
|
|
14
|
-
|
|
15
|
-
readonly
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
readonly
|
|
19
|
-
|
|
20
|
-
readonly
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
readonly
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
13
|
+
readonly model: string;
|
|
14
|
+
readonly messages: readonly ({
|
|
15
|
+
readonly role: "system";
|
|
16
|
+
readonly content: string;
|
|
17
|
+
} | {
|
|
18
|
+
readonly role: "user";
|
|
19
|
+
readonly content: string | readonly ({
|
|
20
|
+
readonly type: "text";
|
|
21
|
+
readonly text: string;
|
|
22
|
+
} | {
|
|
23
|
+
readonly type: "image_url";
|
|
24
|
+
readonly image_url: {
|
|
25
|
+
readonly url: string;
|
|
26
|
+
};
|
|
27
|
+
})[];
|
|
28
|
+
} | {
|
|
28
29
|
readonly [x: string]: unknown;
|
|
29
30
|
readonly content: string | null;
|
|
30
31
|
readonly role: "assistant";
|
|
31
32
|
readonly reasoning?: string | undefined;
|
|
32
|
-
readonly tool_calls?: readonly import("effect/Schema").Struct.ReadonlySide<{
|
|
33
|
-
readonly id: import("effect/Schema").String;
|
|
34
|
-
readonly type: import("effect/Schema").tag<"function">;
|
|
35
|
-
readonly function: import("effect/Schema").Struct<{
|
|
36
|
-
readonly name: import("effect/Schema").String;
|
|
37
|
-
readonly arguments: import("effect/Schema").String;
|
|
38
|
-
}>;
|
|
39
|
-
}, "Type">[] | undefined;
|
|
40
33
|
readonly reasoning_content?: string | undefined;
|
|
41
34
|
readonly reasoning_text?: string | undefined;
|
|
35
|
+
readonly tool_calls?: readonly {
|
|
36
|
+
readonly id: string;
|
|
37
|
+
readonly type: "function";
|
|
38
|
+
readonly function: {
|
|
39
|
+
readonly name: string;
|
|
40
|
+
readonly arguments: string;
|
|
41
|
+
};
|
|
42
|
+
}[] | undefined;
|
|
42
43
|
readonly reasoning_details?: unknown;
|
|
43
|
-
} |
|
|
44
|
-
readonly role:
|
|
45
|
-
readonly tool_call_id:
|
|
46
|
-
readonly content:
|
|
47
|
-
}
|
|
48
|
-
readonly model: string;
|
|
44
|
+
} | {
|
|
45
|
+
readonly role: "tool";
|
|
46
|
+
readonly tool_call_id: string;
|
|
47
|
+
readonly content: string;
|
|
48
|
+
})[];
|
|
49
49
|
readonly stream: true;
|
|
50
50
|
readonly stop?: readonly string[] | undefined;
|
|
51
|
-
readonly tools?: readonly
|
|
52
|
-
readonly type:
|
|
53
|
-
readonly function:
|
|
54
|
-
readonly name:
|
|
55
|
-
readonly description:
|
|
56
|
-
readonly parameters:
|
|
57
|
-
|
|
58
|
-
|
|
51
|
+
readonly tools?: readonly {
|
|
52
|
+
readonly type: "function";
|
|
53
|
+
readonly function: {
|
|
54
|
+
readonly name: string;
|
|
55
|
+
readonly description: string;
|
|
56
|
+
readonly parameters: {
|
|
57
|
+
readonly [x: string]: unknown;
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
}[] | undefined;
|
|
59
61
|
readonly temperature?: number | undefined;
|
|
60
62
|
readonly seed?: number | undefined;
|
|
61
63
|
readonly frequency_penalty?: number | undefined;
|
|
62
64
|
readonly max_tokens?: number | undefined;
|
|
63
65
|
readonly presence_penalty?: number | undefined;
|
|
64
|
-
readonly stream_options?:
|
|
65
|
-
readonly include_usage:
|
|
66
|
-
}
|
|
67
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
68
|
-
readonly type:
|
|
69
|
-
readonly function:
|
|
70
|
-
readonly name:
|
|
71
|
-
}
|
|
72
|
-
}
|
|
66
|
+
readonly stream_options?: {
|
|
67
|
+
readonly include_usage: boolean;
|
|
68
|
+
} | undefined;
|
|
69
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
70
|
+
readonly type: "function";
|
|
71
|
+
readonly function: {
|
|
72
|
+
readonly name: string;
|
|
73
|
+
};
|
|
74
|
+
} | undefined;
|
|
73
75
|
readonly top_p?: number | undefined;
|
|
74
76
|
readonly store?: boolean | undefined;
|
|
75
77
|
readonly reasoning_effort?: string | undefined;
|
|
76
78
|
}, import("../route/transport/http").HttpPrepared<string>> | import("../route").Route<{
|
|
77
79
|
readonly input: readonly ({
|
|
78
80
|
readonly type: "reasoning";
|
|
79
|
-
readonly summary: readonly
|
|
80
|
-
readonly type:
|
|
81
|
-
readonly text:
|
|
82
|
-
}
|
|
81
|
+
readonly summary: readonly {
|
|
82
|
+
readonly type: "summary_text";
|
|
83
|
+
readonly text: string;
|
|
84
|
+
}[];
|
|
83
85
|
readonly id?: string | undefined;
|
|
84
86
|
readonly encrypted_content?: string | null | undefined;
|
|
85
|
-
} |
|
|
86
|
-
readonly type:
|
|
87
|
-
readonly id:
|
|
88
|
-
}
|
|
89
|
-
readonly role:
|
|
90
|
-
readonly content:
|
|
91
|
-
}
|
|
92
|
-
readonly role:
|
|
93
|
-
readonly content:
|
|
94
|
-
readonly type:
|
|
95
|
-
readonly
|
|
96
|
-
}
|
|
97
|
-
readonly type:
|
|
98
|
-
readonly
|
|
99
|
-
|
|
100
|
-
readonly
|
|
101
|
-
|
|
102
|
-
readonly
|
|
103
|
-
readonly
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
readonly content: readonly
|
|
107
|
-
readonly type:
|
|
108
|
-
readonly text:
|
|
109
|
-
}
|
|
87
|
+
} | {
|
|
88
|
+
readonly type: "item_reference";
|
|
89
|
+
readonly id: string;
|
|
90
|
+
} | {
|
|
91
|
+
readonly role: "system";
|
|
92
|
+
readonly content: string;
|
|
93
|
+
} | {
|
|
94
|
+
readonly role: "user";
|
|
95
|
+
readonly content: readonly ({
|
|
96
|
+
readonly type: "input_image";
|
|
97
|
+
readonly image_url: string;
|
|
98
|
+
} | {
|
|
99
|
+
readonly type: "input_file";
|
|
100
|
+
readonly filename: string;
|
|
101
|
+
readonly file_data: string;
|
|
102
|
+
readonly mime_type?: string | undefined;
|
|
103
|
+
} | {
|
|
104
|
+
readonly type: "input_text";
|
|
105
|
+
readonly text: string;
|
|
106
|
+
})[];
|
|
107
|
+
} | {
|
|
108
|
+
readonly content: readonly {
|
|
109
|
+
readonly type: "output_text";
|
|
110
|
+
readonly text: string;
|
|
111
|
+
}[];
|
|
110
112
|
readonly role: "assistant";
|
|
111
113
|
readonly phase?: "commentary" | "final_answer" | undefined;
|
|
112
|
-
} |
|
|
113
|
-
readonly type:
|
|
114
|
-
readonly call_id:
|
|
115
|
-
readonly name:
|
|
116
|
-
readonly arguments:
|
|
117
|
-
}
|
|
118
|
-
readonly type:
|
|
119
|
-
readonly call_id:
|
|
120
|
-
readonly output:
|
|
121
|
-
readonly type:
|
|
122
|
-
readonly
|
|
123
|
-
}
|
|
124
|
-
readonly type:
|
|
125
|
-
readonly
|
|
126
|
-
|
|
127
|
-
readonly
|
|
128
|
-
|
|
129
|
-
readonly
|
|
130
|
-
readonly
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
readonly content: readonly
|
|
134
|
-
readonly type:
|
|
135
|
-
readonly text:
|
|
136
|
-
}
|
|
114
|
+
} | {
|
|
115
|
+
readonly type: "function_call";
|
|
116
|
+
readonly call_id: string;
|
|
117
|
+
readonly name: string;
|
|
118
|
+
readonly arguments: string;
|
|
119
|
+
} | {
|
|
120
|
+
readonly type: "function_call_output";
|
|
121
|
+
readonly call_id: string;
|
|
122
|
+
readonly output: string | readonly ({
|
|
123
|
+
readonly type: "input_image";
|
|
124
|
+
readonly image_url: string;
|
|
125
|
+
} | {
|
|
126
|
+
readonly type: "input_file";
|
|
127
|
+
readonly filename: string;
|
|
128
|
+
readonly file_data: string;
|
|
129
|
+
readonly mime_type?: string | undefined;
|
|
130
|
+
} | {
|
|
131
|
+
readonly type: "input_text";
|
|
132
|
+
readonly text: string;
|
|
133
|
+
})[];
|
|
134
|
+
} | {
|
|
135
|
+
readonly content: readonly {
|
|
136
|
+
readonly type: "output_text";
|
|
137
|
+
readonly text: string;
|
|
138
|
+
}[];
|
|
137
139
|
readonly role: "assistant";
|
|
138
140
|
readonly phase?: "commentary" | "final_answer" | null | undefined;
|
|
139
141
|
})[];
|
|
@@ -142,9 +144,10 @@ export declare const routes: (import("../route").Route<{
|
|
|
142
144
|
readonly text?: {
|
|
143
145
|
readonly verbosity?: "low" | "medium" | "high" | undefined;
|
|
144
146
|
} | undefined;
|
|
147
|
+
readonly instructions?: string | undefined;
|
|
145
148
|
readonly reasoning?: {
|
|
146
|
-
readonly effort?: string | undefined;
|
|
147
149
|
readonly summary?: "auto" | "concise" | "detailed" | undefined;
|
|
150
|
+
readonly effort?: string | undefined;
|
|
148
151
|
} | undefined;
|
|
149
152
|
readonly tools?: readonly ({
|
|
150
153
|
readonly type: "function";
|
|
@@ -156,25 +159,24 @@ export declare const routes: (import("../route").Route<{
|
|
|
156
159
|
readonly strict?: boolean | undefined;
|
|
157
160
|
} | {
|
|
158
161
|
readonly type: "image_generation";
|
|
159
|
-
readonly output_format?: "png" | "jpeg" | "webp" | undefined;
|
|
160
162
|
readonly size?: string | undefined;
|
|
163
|
+
readonly action?: "generate" | "auto" | "edit" | undefined;
|
|
164
|
+
readonly output_format?: "png" | "jpeg" | "webp" | undefined;
|
|
161
165
|
readonly quality?: "low" | "medium" | "high" | "auto" | undefined;
|
|
162
166
|
readonly background?: "auto" | "opaque" | "transparent" | undefined;
|
|
163
167
|
readonly output_compression?: number | undefined;
|
|
164
|
-
readonly action?: "generate" | "auto" | "edit" | undefined;
|
|
165
168
|
readonly input_fidelity?: "low" | "high" | undefined;
|
|
166
169
|
readonly partial_images?: number | undefined;
|
|
167
170
|
})[] | undefined;
|
|
168
171
|
readonly temperature?: number | undefined;
|
|
169
|
-
readonly tool_choice?: "required" | "none" | "auto" |
|
|
170
|
-
readonly type:
|
|
171
|
-
readonly name:
|
|
172
|
-
}
|
|
173
|
-
readonly type:
|
|
174
|
-
}
|
|
172
|
+
readonly tool_choice?: "required" | "none" | "auto" | {
|
|
173
|
+
readonly type: "function";
|
|
174
|
+
readonly name: string;
|
|
175
|
+
} | {
|
|
176
|
+
readonly type: "image_generation";
|
|
177
|
+
} | undefined;
|
|
175
178
|
readonly top_p?: number | undefined;
|
|
176
179
|
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;
|
|
177
|
-
readonly instructions?: string | undefined;
|
|
178
180
|
readonly store?: boolean | undefined;
|
|
179
181
|
readonly service_tier?: "auto" | "default" | "flex" | "priority" | undefined;
|
|
180
182
|
readonly prompt_cache_key?: string | undefined;
|