@langchain/xai 1.4.17 → 1.4.18
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/CHANGELOG.md +7 -0
- package/dist/chat_models/completions.cjs +1 -1
- package/dist/chat_models/completions.d.cts +9 -10
- package/dist/chat_models/completions.d.cts.map +1 -1
- package/dist/chat_models/completions.d.ts +9 -10
- package/dist/chat_models/completions.d.ts.map +1 -1
- package/dist/chat_models/completions.js +1 -1
- package/dist/chat_models/responses-types.d.cts +94 -95
- package/dist/chat_models/responses-types.d.cts.map +1 -1
- package/dist/chat_models/responses-types.d.ts +94 -95
- package/dist/chat_models/responses-types.d.ts.map +1 -1
- package/dist/chat_models/responses.cjs +1 -1
- package/dist/chat_models/responses.d.cts +2 -2
- package/dist/chat_models/responses.d.cts.map +1 -1
- package/dist/chat_models/responses.d.ts +2 -2
- package/dist/chat_models/responses.d.ts.map +1 -1
- package/dist/chat_models/responses.js +1 -1
- package/dist/live_search.d.cts +7 -8
- package/dist/live_search.d.cts.map +1 -1
- package/dist/live_search.d.ts +7 -8
- package/dist/live_search.d.ts.map +1 -1
- package/dist/tools/code_execution.d.cts +3 -4
- package/dist/tools/code_execution.d.cts.map +1 -1
- package/dist/tools/code_execution.d.ts +3 -4
- package/dist/tools/code_execution.d.ts.map +1 -1
- package/dist/tools/collections_search.d.cts +4 -5
- package/dist/tools/collections_search.d.cts.map +1 -1
- package/dist/tools/collections_search.d.ts +4 -5
- package/dist/tools/collections_search.d.ts.map +1 -1
- package/dist/tools/index.d.cts +1 -2
- package/dist/tools/index.d.cts.map +1 -1
- package/dist/tools/index.d.ts +1 -2
- package/dist/tools/index.d.ts.map +1 -1
- package/dist/tools/live_search.d.cts +10 -11
- package/dist/tools/live_search.d.cts.map +1 -1
- package/dist/tools/live_search.d.ts +10 -11
- package/dist/tools/live_search.d.ts.map +1 -1
- package/dist/tools/web_search.d.cts +4 -5
- package/dist/tools/web_search.d.cts.map +1 -1
- package/dist/tools/web_search.d.ts +4 -5
- package/dist/tools/web_search.d.ts.map +1 -1
- package/dist/tools/x_search.d.cts +4 -5
- package/dist/tools/x_search.d.cts.map +1 -1
- package/dist/tools/x_search.d.ts +4 -5
- package/dist/tools/x_search.d.ts.map +1 -1
- package/package.json +6 -6
|
@@ -3,7 +3,7 @@ import { BaseChatModelCallOptions, BaseChatModelParams } from "@langchain/core/l
|
|
|
3
3
|
/**
|
|
4
4
|
* Text input content item.
|
|
5
5
|
*/
|
|
6
|
-
interface XAIResponsesInputTextItem {
|
|
6
|
+
export interface XAIResponsesInputTextItem {
|
|
7
7
|
type: "input_text";
|
|
8
8
|
/** The text content. */
|
|
9
9
|
text: string;
|
|
@@ -12,7 +12,7 @@ interface XAIResponsesInputTextItem {
|
|
|
12
12
|
* Image input content item.
|
|
13
13
|
* Note: Storing/fetching images is not fully supported.
|
|
14
14
|
*/
|
|
15
|
-
interface XAIResponsesInputImageItem {
|
|
15
|
+
export interface XAIResponsesInputImageItem {
|
|
16
16
|
type: "input_image";
|
|
17
17
|
/** Public URL of the image. */
|
|
18
18
|
image_url: string;
|
|
@@ -22,7 +22,7 @@ interface XAIResponsesInputImageItem {
|
|
|
22
22
|
/**
|
|
23
23
|
* File input content item.
|
|
24
24
|
*/
|
|
25
|
-
interface XAIResponsesInputFileItem {
|
|
25
|
+
export interface XAIResponsesInputFileItem {
|
|
26
26
|
type: "input_file";
|
|
27
27
|
/** File ID from the Files API. */
|
|
28
28
|
file_id: string;
|
|
@@ -30,11 +30,11 @@ interface XAIResponsesInputFileItem {
|
|
|
30
30
|
/**
|
|
31
31
|
* Union type for all input content items.
|
|
32
32
|
*/
|
|
33
|
-
type XAIResponsesInputContentItem = XAIResponsesInputTextItem | XAIResponsesInputImageItem | XAIResponsesInputFileItem;
|
|
33
|
+
export type XAIResponsesInputContentItem = XAIResponsesInputTextItem | XAIResponsesInputImageItem | XAIResponsesInputFileItem;
|
|
34
34
|
/**
|
|
35
35
|
* Function tool call from a previous response.
|
|
36
36
|
*/
|
|
37
|
-
interface XAIResponsesFunctionToolCall {
|
|
37
|
+
export interface XAIResponsesFunctionToolCall {
|
|
38
38
|
type: "function_call";
|
|
39
39
|
/** The ID of the tool call. */
|
|
40
40
|
id: string;
|
|
@@ -48,7 +48,7 @@ interface XAIResponsesFunctionToolCall {
|
|
|
48
48
|
/**
|
|
49
49
|
* Web search tool call from a previous response.
|
|
50
50
|
*/
|
|
51
|
-
interface XAIResponsesWebSearchToolCall {
|
|
51
|
+
export interface XAIResponsesWebSearchToolCall {
|
|
52
52
|
type: "web_search_call";
|
|
53
53
|
/** The ID of the tool call. */
|
|
54
54
|
id: string;
|
|
@@ -58,7 +58,7 @@ interface XAIResponsesWebSearchToolCall {
|
|
|
58
58
|
/**
|
|
59
59
|
* Code interpreter tool call from a previous response.
|
|
60
60
|
*/
|
|
61
|
-
interface XAIResponsesCodeInterpreterToolCall {
|
|
61
|
+
export interface XAIResponsesCodeInterpreterToolCall {
|
|
62
62
|
type: "code_interpreter_call";
|
|
63
63
|
/** The ID of the tool call. */
|
|
64
64
|
id: string;
|
|
@@ -70,7 +70,7 @@ interface XAIResponsesCodeInterpreterToolCall {
|
|
|
70
70
|
/**
|
|
71
71
|
* MCP tool call from a previous response.
|
|
72
72
|
*/
|
|
73
|
-
interface XAIResponsesMcpToolCall {
|
|
73
|
+
export interface XAIResponsesMcpToolCall {
|
|
74
74
|
type: "mcp_call";
|
|
75
75
|
/** The ID of the tool call. */
|
|
76
76
|
id: string;
|
|
@@ -82,11 +82,11 @@ interface XAIResponsesMcpToolCall {
|
|
|
82
82
|
/**
|
|
83
83
|
* Union type for all tool calls from previous responses.
|
|
84
84
|
*/
|
|
85
|
-
type XAIResponsesToolCall = XAIResponsesFunctionToolCall | XAIResponsesWebSearchToolCall | XAIResponsesCodeInterpreterToolCall | XAIResponsesMcpToolCall;
|
|
85
|
+
export type XAIResponsesToolCall = XAIResponsesFunctionToolCall | XAIResponsesWebSearchToolCall | XAIResponsesCodeInterpreterToolCall | XAIResponsesMcpToolCall;
|
|
86
86
|
/**
|
|
87
87
|
* Log probability information for a token.
|
|
88
88
|
*/
|
|
89
|
-
interface XAIResponsesLogprobToken {
|
|
89
|
+
export interface XAIResponsesLogprobToken {
|
|
90
90
|
/** The token string. */
|
|
91
91
|
token: string;
|
|
92
92
|
/** The log probability of the token. */
|
|
@@ -97,7 +97,7 @@ interface XAIResponsesLogprobToken {
|
|
|
97
97
|
/**
|
|
98
98
|
* Log probability content item.
|
|
99
99
|
*/
|
|
100
|
-
interface XAIResponsesLogprobContent {
|
|
100
|
+
export interface XAIResponsesLogprobContent {
|
|
101
101
|
/** The token. */
|
|
102
102
|
token: string;
|
|
103
103
|
/** The log probability. */
|
|
@@ -110,7 +110,7 @@ interface XAIResponsesLogprobContent {
|
|
|
110
110
|
/**
|
|
111
111
|
* Log probabilities from a previous response.
|
|
112
112
|
*/
|
|
113
|
-
interface XAIResponsesLogprobs {
|
|
113
|
+
export interface XAIResponsesLogprobs {
|
|
114
114
|
/** Log probability content. */
|
|
115
115
|
content?: XAIResponsesLogprobContent[];
|
|
116
116
|
}
|
|
@@ -118,7 +118,7 @@ interface XAIResponsesLogprobs {
|
|
|
118
118
|
* Previous response structure that can be included in the input array.
|
|
119
119
|
* Used for multi-turn conversations with assistant outputs.
|
|
120
120
|
*/
|
|
121
|
-
interface XAIResponsesPreviousResponse {
|
|
121
|
+
export interface XAIResponsesPreviousResponse {
|
|
122
122
|
/** The type identifier for previous response. */
|
|
123
123
|
type: "message";
|
|
124
124
|
/** The role for previous assistant responses. */
|
|
@@ -135,7 +135,7 @@ interface XAIResponsesPreviousResponse {
|
|
|
135
135
|
/**
|
|
136
136
|
* Function tool call output to provide results back to the model.
|
|
137
137
|
*/
|
|
138
|
-
interface XAIResponsesFunctionToolOutput {
|
|
138
|
+
export interface XAIResponsesFunctionToolOutput {
|
|
139
139
|
type: "function_call_output";
|
|
140
140
|
/** The ID of the tool call this output is for. */
|
|
141
141
|
call_id: string;
|
|
@@ -145,15 +145,15 @@ interface XAIResponsesFunctionToolOutput {
|
|
|
145
145
|
/**
|
|
146
146
|
* Union type for tool outputs that can be included in input.
|
|
147
147
|
*/
|
|
148
|
-
type XAIResponsesToolOutput = XAIResponsesFunctionToolOutput;
|
|
148
|
+
export type XAIResponsesToolOutput = XAIResponsesFunctionToolOutput;
|
|
149
149
|
/**
|
|
150
150
|
* Message role types.
|
|
151
151
|
*/
|
|
152
|
-
type XAIResponsesMessageRole = "user" | "assistant" | "system" | "developer";
|
|
152
|
+
export type XAIResponsesMessageRole = "user" | "assistant" | "system" | "developer";
|
|
153
153
|
/**
|
|
154
154
|
* Message input to the model.
|
|
155
155
|
*/
|
|
156
|
-
interface XAIResponsesMessage {
|
|
156
|
+
export interface XAIResponsesMessage {
|
|
157
157
|
/** The role of the message author. */
|
|
158
158
|
role: XAIResponsesMessageRole;
|
|
159
159
|
/** Text, image, or audio input. Can be a string or array of content items. */
|
|
@@ -165,24 +165,24 @@ interface XAIResponsesMessage {
|
|
|
165
165
|
* Union type for all items that can appear in the input array.
|
|
166
166
|
* Includes messages, previous responses, and tool outputs.
|
|
167
167
|
*/
|
|
168
|
-
type XAIResponsesInputItem = XAIResponsesMessage | XAIResponsesPreviousResponse | XAIResponsesToolOutput;
|
|
168
|
+
export type XAIResponsesInputItem = XAIResponsesMessage | XAIResponsesPreviousResponse | XAIResponsesToolOutput;
|
|
169
169
|
/**
|
|
170
170
|
* Input type - can be a string or array of input items.
|
|
171
171
|
* The array can contain messages, previous responses, and tool outputs.
|
|
172
172
|
*/
|
|
173
|
-
type XAIResponsesInput = string | XAIResponsesInputItem[];
|
|
173
|
+
export type XAIResponsesInput = string | XAIResponsesInputItem[];
|
|
174
174
|
/**
|
|
175
175
|
* Reasoning effort level.
|
|
176
176
|
*/
|
|
177
|
-
type XAIResponsesReasoningEffort = "low" | "medium" | "high";
|
|
177
|
+
export type XAIResponsesReasoningEffort = "low" | "medium" | "high";
|
|
178
178
|
/**
|
|
179
179
|
* Reasoning summary style.
|
|
180
180
|
*/
|
|
181
|
-
type XAIResponsesReasoningSummary = "auto" | "concise" | "detailed";
|
|
181
|
+
export type XAIResponsesReasoningSummary = "auto" | "concise" | "detailed";
|
|
182
182
|
/**
|
|
183
183
|
* Reasoning configuration for reasoning models.
|
|
184
184
|
*/
|
|
185
|
-
interface XAIResponsesReasoning {
|
|
185
|
+
export interface XAIResponsesReasoning {
|
|
186
186
|
/** The effort level for reasoning. Defaults to `medium`. */
|
|
187
187
|
effort?: XAIResponsesReasoningEffort;
|
|
188
188
|
/** The summary style for reasoning output. */
|
|
@@ -191,7 +191,7 @@ interface XAIResponsesReasoning {
|
|
|
191
191
|
/**
|
|
192
192
|
* X (Twitter) search source configuration.
|
|
193
193
|
*/
|
|
194
|
-
interface XAIResponsesSearchSourceX {
|
|
194
|
+
export interface XAIResponsesSearchSourceX {
|
|
195
195
|
type: "x";
|
|
196
196
|
/** X handles to include in search. */
|
|
197
197
|
included_x_handles?: string[];
|
|
@@ -205,7 +205,7 @@ interface XAIResponsesSearchSourceX {
|
|
|
205
205
|
/**
|
|
206
206
|
* Web search source configuration.
|
|
207
207
|
*/
|
|
208
|
-
interface XAIResponsesSearchSourceWeb {
|
|
208
|
+
export interface XAIResponsesSearchSourceWeb {
|
|
209
209
|
type: "web";
|
|
210
210
|
/** Whitelist of allowed websites (max 5). */
|
|
211
211
|
allowed_websites?: string[];
|
|
@@ -219,7 +219,7 @@ interface XAIResponsesSearchSourceWeb {
|
|
|
219
219
|
/**
|
|
220
220
|
* RSS/News search source configuration.
|
|
221
221
|
*/
|
|
222
|
-
interface XAIResponsesSearchSourceRss {
|
|
222
|
+
export interface XAIResponsesSearchSourceRss {
|
|
223
223
|
type: "rss";
|
|
224
224
|
/** Links of RSS feeds. */
|
|
225
225
|
links?: string[];
|
|
@@ -227,16 +227,16 @@ interface XAIResponsesSearchSourceRss {
|
|
|
227
227
|
/**
|
|
228
228
|
* Union type for all search sources.
|
|
229
229
|
*/
|
|
230
|
-
type XAIResponsesSearchSource = XAIResponsesSearchSourceX | XAIResponsesSearchSourceWeb | XAIResponsesSearchSourceRss;
|
|
230
|
+
export type XAIResponsesSearchSource = XAIResponsesSearchSourceX | XAIResponsesSearchSourceWeb | XAIResponsesSearchSourceRss;
|
|
231
231
|
/**
|
|
232
232
|
* Search mode options.
|
|
233
233
|
*/
|
|
234
|
-
type XAIResponsesSearchMode = "off" | "on" | "auto";
|
|
234
|
+
export type XAIResponsesSearchMode = "off" | "on" | "auto";
|
|
235
235
|
/**
|
|
236
236
|
* Search parameters configuration.
|
|
237
237
|
* Takes precedence over `web_search_preview` tool.
|
|
238
238
|
*/
|
|
239
|
-
interface XAIResponsesSearchParameters {
|
|
239
|
+
export interface XAIResponsesSearchParameters {
|
|
240
240
|
/** Start date for search results (ISO-8601 YYYY-MM-DD). */
|
|
241
241
|
from_date?: string;
|
|
242
242
|
/** End date for search results (ISO-8601 YYYY-MM-DD). */
|
|
@@ -253,19 +253,19 @@ interface XAIResponsesSearchParameters {
|
|
|
253
253
|
/**
|
|
254
254
|
* Plain text format.
|
|
255
255
|
*/
|
|
256
|
-
interface XAIResponsesTextFormatText {
|
|
256
|
+
export interface XAIResponsesTextFormatText {
|
|
257
257
|
type: "text";
|
|
258
258
|
}
|
|
259
259
|
/**
|
|
260
260
|
* JSON object format.
|
|
261
261
|
*/
|
|
262
|
-
interface XAIResponsesTextFormatJsonObject {
|
|
262
|
+
export interface XAIResponsesTextFormatJsonObject {
|
|
263
263
|
type: "json_object";
|
|
264
264
|
}
|
|
265
265
|
/**
|
|
266
266
|
* JSON schema format.
|
|
267
267
|
*/
|
|
268
|
-
interface XAIResponsesTextFormatJsonSchema {
|
|
268
|
+
export interface XAIResponsesTextFormatJsonSchema {
|
|
269
269
|
type: "json_schema";
|
|
270
270
|
/** JSON schema definition. */
|
|
271
271
|
schema: Record<string, unknown>;
|
|
@@ -275,18 +275,18 @@ interface XAIResponsesTextFormatJsonSchema {
|
|
|
275
275
|
/**
|
|
276
276
|
* Union type for all text response formats.
|
|
277
277
|
*/
|
|
278
|
-
type XAIResponsesTextFormat = XAIResponsesTextFormatText | XAIResponsesTextFormatJsonObject | XAIResponsesTextFormatJsonSchema;
|
|
278
|
+
export type XAIResponsesTextFormat = XAIResponsesTextFormatText | XAIResponsesTextFormatJsonObject | XAIResponsesTextFormatJsonSchema;
|
|
279
279
|
/**
|
|
280
280
|
* Text response configuration.
|
|
281
281
|
*/
|
|
282
|
-
interface XAIResponsesText {
|
|
282
|
+
export interface XAIResponsesText {
|
|
283
283
|
/** The format for text response. */
|
|
284
284
|
format?: XAIResponsesTextFormat;
|
|
285
285
|
}
|
|
286
286
|
/**
|
|
287
287
|
* Function tool parameters using JSON Schema.
|
|
288
288
|
*/
|
|
289
|
-
interface XAIResponsesFunctionToolFunction {
|
|
289
|
+
export interface XAIResponsesFunctionToolFunction {
|
|
290
290
|
/** The name of the function. */
|
|
291
291
|
name: string;
|
|
292
292
|
/** A description of what the function does. */
|
|
@@ -297,7 +297,7 @@ interface XAIResponsesFunctionToolFunction {
|
|
|
297
297
|
/**
|
|
298
298
|
* Function tool definition.
|
|
299
299
|
*/
|
|
300
|
-
interface XAIResponsesFunctionTool {
|
|
300
|
+
export interface XAIResponsesFunctionTool {
|
|
301
301
|
type: "function";
|
|
302
302
|
/** The function definition. */
|
|
303
303
|
function: XAIResponsesFunctionToolFunction;
|
|
@@ -306,7 +306,7 @@ interface XAIResponsesFunctionTool {
|
|
|
306
306
|
* Web search tool definition.
|
|
307
307
|
* Enables the model to search the web and browse pages for real-time information.
|
|
308
308
|
*/
|
|
309
|
-
interface XAIResponsesWebSearchTool {
|
|
309
|
+
export interface XAIResponsesWebSearchTool {
|
|
310
310
|
type: "web_search";
|
|
311
311
|
/** Domains to exclusively include in the search (max 5). */
|
|
312
312
|
allowed_domains?: string[];
|
|
@@ -318,7 +318,7 @@ interface XAIResponsesWebSearchTool {
|
|
|
318
318
|
/**
|
|
319
319
|
* X search tool definition.
|
|
320
320
|
*/
|
|
321
|
-
interface XAIResponsesXSearchTool {
|
|
321
|
+
export interface XAIResponsesXSearchTool {
|
|
322
322
|
type: "x_search";
|
|
323
323
|
/** X handles to allow in search. */
|
|
324
324
|
allowed_x_handles?: string[];
|
|
@@ -336,7 +336,7 @@ interface XAIResponsesXSearchTool {
|
|
|
336
336
|
/**
|
|
337
337
|
* File search tool definition.
|
|
338
338
|
*/
|
|
339
|
-
interface XAIResponsesFileSearchTool {
|
|
339
|
+
export interface XAIResponsesFileSearchTool {
|
|
340
340
|
type: "file_search";
|
|
341
341
|
/** List of vector store IDs to search. */
|
|
342
342
|
vector_store_ids?: string[];
|
|
@@ -344,13 +344,13 @@ interface XAIResponsesFileSearchTool {
|
|
|
344
344
|
/**
|
|
345
345
|
* Code interpreter tool definition.
|
|
346
346
|
*/
|
|
347
|
-
interface XAIResponsesCodeInterpreterTool {
|
|
347
|
+
export interface XAIResponsesCodeInterpreterTool {
|
|
348
348
|
type: "code_interpreter";
|
|
349
349
|
}
|
|
350
350
|
/**
|
|
351
351
|
* MCP (Model Context Protocol) tool definition.
|
|
352
352
|
*/
|
|
353
|
-
interface XAIResponsesMcpTool {
|
|
353
|
+
export interface XAIResponsesMcpTool {
|
|
354
354
|
type: "mcp";
|
|
355
355
|
/** The URL of the MCP server. */
|
|
356
356
|
server_url: string;
|
|
@@ -360,15 +360,15 @@ interface XAIResponsesMcpTool {
|
|
|
360
360
|
/**
|
|
361
361
|
* Union type for all tool definitions.
|
|
362
362
|
*/
|
|
363
|
-
type XAIResponsesTool = XAIResponsesFunctionTool | XAIResponsesWebSearchTool | XAIResponsesXSearchTool | XAIResponsesFileSearchTool | XAIResponsesCodeInterpreterTool | XAIResponsesMcpTool;
|
|
363
|
+
export type XAIResponsesTool = XAIResponsesFunctionTool | XAIResponsesWebSearchTool | XAIResponsesXSearchTool | XAIResponsesFileSearchTool | XAIResponsesCodeInterpreterTool | XAIResponsesMcpTool;
|
|
364
364
|
/**
|
|
365
365
|
* String tool choice options.
|
|
366
366
|
*/
|
|
367
|
-
type XAIResponsesToolChoiceString = "none" | "auto" | "required";
|
|
367
|
+
export type XAIResponsesToolChoiceString = "none" | "auto" | "required";
|
|
368
368
|
/**
|
|
369
369
|
* Function tool choice object.
|
|
370
370
|
*/
|
|
371
|
-
interface XAIResponsesToolChoiceFunction {
|
|
371
|
+
export interface XAIResponsesToolChoiceFunction {
|
|
372
372
|
type: "function";
|
|
373
373
|
function: {
|
|
374
374
|
/** The name of the function to call. */
|
|
@@ -378,15 +378,15 @@ interface XAIResponsesToolChoiceFunction {
|
|
|
378
378
|
/**
|
|
379
379
|
* Tool choice configuration.
|
|
380
380
|
*/
|
|
381
|
-
type XAIResponsesToolChoice = XAIResponsesToolChoiceString | XAIResponsesToolChoiceFunction;
|
|
381
|
+
export type XAIResponsesToolChoice = XAIResponsesToolChoiceString | XAIResponsesToolChoiceFunction;
|
|
382
382
|
/**
|
|
383
383
|
* Additional output data to include in the response.
|
|
384
384
|
*/
|
|
385
|
-
type XAIResponsesInclude = "reasoning.encrypted_content";
|
|
385
|
+
export type XAIResponsesInclude = "reasoning.encrypted_content";
|
|
386
386
|
/**
|
|
387
387
|
* xAI Responses API request body parameters.
|
|
388
388
|
*/
|
|
389
|
-
interface XAIResponsesCreateParams {
|
|
389
|
+
export interface XAIResponsesCreateParams {
|
|
390
390
|
/**
|
|
391
391
|
* The input passed to the model.
|
|
392
392
|
* Can be text (string) or an array of message objects.
|
|
@@ -506,27 +506,27 @@ interface XAIResponsesCreateParams {
|
|
|
506
506
|
/**
|
|
507
507
|
* Streaming variant of the request params.
|
|
508
508
|
*/
|
|
509
|
-
interface XAIResponsesCreateParamsStreaming extends XAIResponsesCreateParams {
|
|
509
|
+
export interface XAIResponsesCreateParamsStreaming extends XAIResponsesCreateParams {
|
|
510
510
|
stream: true;
|
|
511
511
|
}
|
|
512
512
|
/**
|
|
513
513
|
* Non-streaming variant of the request params.
|
|
514
514
|
*/
|
|
515
|
-
interface XAIResponsesCreateParamsNonStreaming extends XAIResponsesCreateParams {
|
|
515
|
+
export interface XAIResponsesCreateParamsNonStreaming extends XAIResponsesCreateParams {
|
|
516
516
|
stream?: false;
|
|
517
517
|
}
|
|
518
518
|
/**
|
|
519
519
|
* Response status values.
|
|
520
520
|
*/
|
|
521
|
-
type XAIResponsesStatus = "completed" | "in_progress" | "incomplete";
|
|
521
|
+
export type XAIResponsesStatus = "completed" | "in_progress" | "incomplete";
|
|
522
522
|
/**
|
|
523
523
|
* Response object type literal.
|
|
524
524
|
*/
|
|
525
|
-
type XAIResponsesObjectType = "response";
|
|
525
|
+
export type XAIResponsesObjectType = "response";
|
|
526
526
|
/**
|
|
527
527
|
* Text output item in the response.
|
|
528
528
|
*/
|
|
529
|
-
interface XAIResponsesOutputTextItem {
|
|
529
|
+
export interface XAIResponsesOutputTextItem {
|
|
530
530
|
type: "message";
|
|
531
531
|
/** The role of the message (always assistant for outputs). */
|
|
532
532
|
role: "assistant";
|
|
@@ -540,7 +540,7 @@ interface XAIResponsesOutputTextItem {
|
|
|
540
540
|
/**
|
|
541
541
|
* Text content in an output message.
|
|
542
542
|
*/
|
|
543
|
-
interface XAIResponsesOutputTextContent {
|
|
543
|
+
export interface XAIResponsesOutputTextContent {
|
|
544
544
|
type: "output_text";
|
|
545
545
|
/** The text content. */
|
|
546
546
|
text: string;
|
|
@@ -550,7 +550,7 @@ interface XAIResponsesOutputTextContent {
|
|
|
550
550
|
/**
|
|
551
551
|
* Refusal content in an output message.
|
|
552
552
|
*/
|
|
553
|
-
interface XAIResponsesOutputRefusalContent {
|
|
553
|
+
export interface XAIResponsesOutputRefusalContent {
|
|
554
554
|
type: "refusal";
|
|
555
555
|
/** The refusal message. */
|
|
556
556
|
refusal: string;
|
|
@@ -558,11 +558,11 @@ interface XAIResponsesOutputRefusalContent {
|
|
|
558
558
|
/**
|
|
559
559
|
* Union type for output content items.
|
|
560
560
|
*/
|
|
561
|
-
type XAIResponsesOutputContent = XAIResponsesOutputTextContent | XAIResponsesOutputRefusalContent;
|
|
561
|
+
export type XAIResponsesOutputContent = XAIResponsesOutputTextContent | XAIResponsesOutputRefusalContent;
|
|
562
562
|
/**
|
|
563
563
|
* Citation annotation for web search results.
|
|
564
564
|
*/
|
|
565
|
-
interface XAIResponsesUrlCitationAnnotation {
|
|
565
|
+
export interface XAIResponsesUrlCitationAnnotation {
|
|
566
566
|
type: "url_citation";
|
|
567
567
|
/** Start index in the text. */
|
|
568
568
|
start_index: number;
|
|
@@ -576,7 +576,7 @@ interface XAIResponsesUrlCitationAnnotation {
|
|
|
576
576
|
/**
|
|
577
577
|
* File citation annotation.
|
|
578
578
|
*/
|
|
579
|
-
interface XAIResponsesFileCitationAnnotation {
|
|
579
|
+
export interface XAIResponsesFileCitationAnnotation {
|
|
580
580
|
type: "file_citation";
|
|
581
581
|
/** Start index in the text. */
|
|
582
582
|
start_index: number;
|
|
@@ -590,11 +590,11 @@ interface XAIResponsesFileCitationAnnotation {
|
|
|
590
590
|
/**
|
|
591
591
|
* Union type for all annotation types.
|
|
592
592
|
*/
|
|
593
|
-
type XAIResponsesAnnotation = XAIResponsesUrlCitationAnnotation | XAIResponsesFileCitationAnnotation;
|
|
593
|
+
export type XAIResponsesAnnotation = XAIResponsesUrlCitationAnnotation | XAIResponsesFileCitationAnnotation;
|
|
594
594
|
/**
|
|
595
595
|
* Function call output item.
|
|
596
596
|
*/
|
|
597
|
-
interface XAIResponsesOutputFunctionCall {
|
|
597
|
+
export interface XAIResponsesOutputFunctionCall {
|
|
598
598
|
type: "function_call";
|
|
599
599
|
/** The ID of the function call. */
|
|
600
600
|
id: string;
|
|
@@ -610,7 +610,7 @@ interface XAIResponsesOutputFunctionCall {
|
|
|
610
610
|
/**
|
|
611
611
|
* Web search call output item.
|
|
612
612
|
*/
|
|
613
|
-
interface XAIResponsesOutputWebSearchCall {
|
|
613
|
+
export interface XAIResponsesOutputWebSearchCall {
|
|
614
614
|
type: "web_search_call";
|
|
615
615
|
/** The ID of the web search call. */
|
|
616
616
|
id: string;
|
|
@@ -620,7 +620,7 @@ interface XAIResponsesOutputWebSearchCall {
|
|
|
620
620
|
/**
|
|
621
621
|
* File search call output item.
|
|
622
622
|
*/
|
|
623
|
-
interface XAIResponsesOutputFileSearchCall {
|
|
623
|
+
export interface XAIResponsesOutputFileSearchCall {
|
|
624
624
|
type: "file_search_call";
|
|
625
625
|
/** The ID of the file search call. */
|
|
626
626
|
id: string;
|
|
@@ -634,7 +634,7 @@ interface XAIResponsesOutputFileSearchCall {
|
|
|
634
634
|
/**
|
|
635
635
|
* File search result item.
|
|
636
636
|
*/
|
|
637
|
-
interface XAIResponsesFileSearchResult {
|
|
637
|
+
export interface XAIResponsesFileSearchResult {
|
|
638
638
|
/** The file ID. */
|
|
639
639
|
file_id: string;
|
|
640
640
|
/** The filename. */
|
|
@@ -647,7 +647,7 @@ interface XAIResponsesFileSearchResult {
|
|
|
647
647
|
/**
|
|
648
648
|
* Code interpreter call output item.
|
|
649
649
|
*/
|
|
650
|
-
interface XAIResponsesOutputCodeInterpreterCall {
|
|
650
|
+
export interface XAIResponsesOutputCodeInterpreterCall {
|
|
651
651
|
type: "code_interpreter_call";
|
|
652
652
|
/** The ID of the code interpreter call. */
|
|
653
653
|
id: string;
|
|
@@ -661,7 +661,7 @@ interface XAIResponsesOutputCodeInterpreterCall {
|
|
|
661
661
|
/**
|
|
662
662
|
* Code interpreter result item.
|
|
663
663
|
*/
|
|
664
|
-
interface XAIResponsesCodeInterpreterResult {
|
|
664
|
+
export interface XAIResponsesCodeInterpreterResult {
|
|
665
665
|
type: "logs" | "image";
|
|
666
666
|
/** The log output (for type "logs"). */
|
|
667
667
|
logs?: string;
|
|
@@ -676,7 +676,7 @@ interface XAIResponsesCodeInterpreterResult {
|
|
|
676
676
|
/**
|
|
677
677
|
* MCP call output item.
|
|
678
678
|
*/
|
|
679
|
-
interface XAIResponsesOutputMcpCall {
|
|
679
|
+
export interface XAIResponsesOutputMcpCall {
|
|
680
680
|
type: "mcp_call";
|
|
681
681
|
/** The ID of the MCP call. */
|
|
682
682
|
id: string;
|
|
@@ -690,7 +690,7 @@ interface XAIResponsesOutputMcpCall {
|
|
|
690
690
|
/**
|
|
691
691
|
* Reasoning output item.
|
|
692
692
|
*/
|
|
693
|
-
interface XAIResponsesOutputReasoning {
|
|
693
|
+
export interface XAIResponsesOutputReasoning {
|
|
694
694
|
type: "reasoning";
|
|
695
695
|
/** The ID of the reasoning item. */
|
|
696
696
|
id?: string;
|
|
@@ -702,7 +702,7 @@ interface XAIResponsesOutputReasoning {
|
|
|
702
702
|
/**
|
|
703
703
|
* Reasoning summary item.
|
|
704
704
|
*/
|
|
705
|
-
interface XAIResponsesReasoningSummaryItem {
|
|
705
|
+
export interface XAIResponsesReasoningSummaryItem {
|
|
706
706
|
type: "summary_text";
|
|
707
707
|
/** The summary text. */
|
|
708
708
|
text: string;
|
|
@@ -710,11 +710,11 @@ interface XAIResponsesReasoningSummaryItem {
|
|
|
710
710
|
/**
|
|
711
711
|
* Union type for all response output items.
|
|
712
712
|
*/
|
|
713
|
-
type XAIResponsesOutputItem = XAIResponsesOutputTextItem | XAIResponsesOutputFunctionCall | XAIResponsesOutputWebSearchCall | XAIResponsesOutputFileSearchCall | XAIResponsesOutputCodeInterpreterCall | XAIResponsesOutputMcpCall | XAIResponsesOutputReasoning;
|
|
713
|
+
export type XAIResponsesOutputItem = XAIResponsesOutputTextItem | XAIResponsesOutputFunctionCall | XAIResponsesOutputWebSearchCall | XAIResponsesOutputFileSearchCall | XAIResponsesOutputCodeInterpreterCall | XAIResponsesOutputMcpCall | XAIResponsesOutputReasoning;
|
|
714
714
|
/**
|
|
715
715
|
* Token usage information for the response.
|
|
716
716
|
*/
|
|
717
|
-
interface XAIResponsesUsage {
|
|
717
|
+
export interface XAIResponsesUsage {
|
|
718
718
|
/** Number of tokens in the input/prompt. */
|
|
719
719
|
input_tokens: number;
|
|
720
720
|
/** Number of tokens in the output/completion. */
|
|
@@ -735,18 +735,18 @@ interface XAIResponsesUsage {
|
|
|
735
735
|
/**
|
|
736
736
|
* Reason for incomplete response.
|
|
737
737
|
*/
|
|
738
|
-
type XAIResponsesIncompleteReason = "max_output_tokens" | "content_filter" | "turn_limit" | "tool_use_limit";
|
|
738
|
+
export type XAIResponsesIncompleteReason = "max_output_tokens" | "content_filter" | "turn_limit" | "tool_use_limit";
|
|
739
739
|
/**
|
|
740
740
|
* Details about why a response is incomplete.
|
|
741
741
|
*/
|
|
742
|
-
interface XAIResponsesIncompleteDetails {
|
|
742
|
+
export interface XAIResponsesIncompleteDetails {
|
|
743
743
|
/** The reason the response is incomplete. */
|
|
744
744
|
reason?: XAIResponsesIncompleteReason;
|
|
745
745
|
}
|
|
746
746
|
/**
|
|
747
747
|
* Debug output information (when available).
|
|
748
748
|
*/
|
|
749
|
-
interface XAIResponsesDebugOutput {
|
|
749
|
+
export interface XAIResponsesDebugOutput {
|
|
750
750
|
/** Debug model information. */
|
|
751
751
|
model_info?: Record<string, unknown>;
|
|
752
752
|
/** Additional debug data. */
|
|
@@ -755,7 +755,7 @@ interface XAIResponsesDebugOutput {
|
|
|
755
755
|
/**
|
|
756
756
|
* Reasoning configuration echoed in the response.
|
|
757
757
|
*/
|
|
758
|
-
interface XAIResponsesReasoningResponse {
|
|
758
|
+
export interface XAIResponsesReasoningResponse {
|
|
759
759
|
/** The effort level used for reasoning. */
|
|
760
760
|
effort?: XAIResponsesReasoningEffort;
|
|
761
761
|
/** The summary style used. */
|
|
@@ -764,7 +764,7 @@ interface XAIResponsesReasoningResponse {
|
|
|
764
764
|
/**
|
|
765
765
|
* xAI Responses API response body.
|
|
766
766
|
*/
|
|
767
|
-
interface XAIResponse {
|
|
767
|
+
export interface XAIResponse {
|
|
768
768
|
/**
|
|
769
769
|
* Unique ID of the response.
|
|
770
770
|
*/
|
|
@@ -865,14 +865,14 @@ interface XAIResponse {
|
|
|
865
865
|
/**
|
|
866
866
|
* Base streaming event structure.
|
|
867
867
|
*/
|
|
868
|
-
interface XAIResponsesStreamEventBase {
|
|
868
|
+
export interface XAIResponsesStreamEventBase {
|
|
869
869
|
/** The type of the streaming event. */
|
|
870
870
|
type: string;
|
|
871
871
|
}
|
|
872
872
|
/**
|
|
873
873
|
* Response created event.
|
|
874
874
|
*/
|
|
875
|
-
interface XAIResponsesStreamEventCreated extends XAIResponsesStreamEventBase {
|
|
875
|
+
export interface XAIResponsesStreamEventCreated extends XAIResponsesStreamEventBase {
|
|
876
876
|
type: "response.created";
|
|
877
877
|
/** The response object. */
|
|
878
878
|
response: XAIResponse;
|
|
@@ -880,7 +880,7 @@ interface XAIResponsesStreamEventCreated extends XAIResponsesStreamEventBase {
|
|
|
880
880
|
/**
|
|
881
881
|
* Response in progress event.
|
|
882
882
|
*/
|
|
883
|
-
interface XAIResponsesStreamEventInProgress extends XAIResponsesStreamEventBase {
|
|
883
|
+
export interface XAIResponsesStreamEventInProgress extends XAIResponsesStreamEventBase {
|
|
884
884
|
type: "response.in_progress";
|
|
885
885
|
/** The response object. */
|
|
886
886
|
response: XAIResponse;
|
|
@@ -888,7 +888,7 @@ interface XAIResponsesStreamEventInProgress extends XAIResponsesStreamEventBase
|
|
|
888
888
|
/**
|
|
889
889
|
* Response completed event.
|
|
890
890
|
*/
|
|
891
|
-
interface XAIResponsesStreamEventCompleted extends XAIResponsesStreamEventBase {
|
|
891
|
+
export interface XAIResponsesStreamEventCompleted extends XAIResponsesStreamEventBase {
|
|
892
892
|
type: "response.completed";
|
|
893
893
|
/** The completed response object. */
|
|
894
894
|
response: XAIResponse;
|
|
@@ -896,7 +896,7 @@ interface XAIResponsesStreamEventCompleted extends XAIResponsesStreamEventBase {
|
|
|
896
896
|
/**
|
|
897
897
|
* Response failed event.
|
|
898
898
|
*/
|
|
899
|
-
interface XAIResponsesStreamEventFailed extends XAIResponsesStreamEventBase {
|
|
899
|
+
export interface XAIResponsesStreamEventFailed extends XAIResponsesStreamEventBase {
|
|
900
900
|
type: "response.failed";
|
|
901
901
|
/** The failed response object. */
|
|
902
902
|
response: XAIResponse;
|
|
@@ -911,7 +911,7 @@ interface XAIResponsesStreamEventFailed extends XAIResponsesStreamEventBase {
|
|
|
911
911
|
/**
|
|
912
912
|
* Response incomplete event.
|
|
913
913
|
*/
|
|
914
|
-
interface XAIResponsesStreamEventIncomplete extends XAIResponsesStreamEventBase {
|
|
914
|
+
export interface XAIResponsesStreamEventIncomplete extends XAIResponsesStreamEventBase {
|
|
915
915
|
type: "response.incomplete";
|
|
916
916
|
/** The incomplete response object. */
|
|
917
917
|
response: XAIResponse;
|
|
@@ -919,7 +919,7 @@ interface XAIResponsesStreamEventIncomplete extends XAIResponsesStreamEventBase
|
|
|
919
919
|
/**
|
|
920
920
|
* Output item added event.
|
|
921
921
|
*/
|
|
922
|
-
interface XAIResponsesStreamEventOutputItemAdded extends XAIResponsesStreamEventBase {
|
|
922
|
+
export interface XAIResponsesStreamEventOutputItemAdded extends XAIResponsesStreamEventBase {
|
|
923
923
|
type: "response.output_item.added";
|
|
924
924
|
/** The index of the output item. */
|
|
925
925
|
output_index: number;
|
|
@@ -929,7 +929,7 @@ interface XAIResponsesStreamEventOutputItemAdded extends XAIResponsesStreamEvent
|
|
|
929
929
|
/**
|
|
930
930
|
* Output item done event.
|
|
931
931
|
*/
|
|
932
|
-
interface XAIResponsesStreamEventOutputItemDone extends XAIResponsesStreamEventBase {
|
|
932
|
+
export interface XAIResponsesStreamEventOutputItemDone extends XAIResponsesStreamEventBase {
|
|
933
933
|
type: "response.output_item.done";
|
|
934
934
|
/** The index of the output item. */
|
|
935
935
|
output_index: number;
|
|
@@ -939,7 +939,7 @@ interface XAIResponsesStreamEventOutputItemDone extends XAIResponsesStreamEventB
|
|
|
939
939
|
/**
|
|
940
940
|
* Content part added event.
|
|
941
941
|
*/
|
|
942
|
-
interface XAIResponsesStreamEventContentPartAdded extends XAIResponsesStreamEventBase {
|
|
942
|
+
export interface XAIResponsesStreamEventContentPartAdded extends XAIResponsesStreamEventBase {
|
|
943
943
|
type: "response.content_part.added";
|
|
944
944
|
/** The index of the output item. */
|
|
945
945
|
output_index: number;
|
|
@@ -951,7 +951,7 @@ interface XAIResponsesStreamEventContentPartAdded extends XAIResponsesStreamEven
|
|
|
951
951
|
/**
|
|
952
952
|
* Content part done event.
|
|
953
953
|
*/
|
|
954
|
-
interface XAIResponsesStreamEventContentPartDone extends XAIResponsesStreamEventBase {
|
|
954
|
+
export interface XAIResponsesStreamEventContentPartDone extends XAIResponsesStreamEventBase {
|
|
955
955
|
type: "response.content_part.done";
|
|
956
956
|
/** The index of the output item. */
|
|
957
957
|
output_index: number;
|
|
@@ -963,7 +963,7 @@ interface XAIResponsesStreamEventContentPartDone extends XAIResponsesStreamEvent
|
|
|
963
963
|
/**
|
|
964
964
|
* Text delta event (streaming text).
|
|
965
965
|
*/
|
|
966
|
-
interface XAIResponsesStreamEventTextDelta extends XAIResponsesStreamEventBase {
|
|
966
|
+
export interface XAIResponsesStreamEventTextDelta extends XAIResponsesStreamEventBase {
|
|
967
967
|
type: "response.output_text.delta";
|
|
968
968
|
/** The index of the output item. */
|
|
969
969
|
output_index: number;
|
|
@@ -975,7 +975,7 @@ interface XAIResponsesStreamEventTextDelta extends XAIResponsesStreamEventBase {
|
|
|
975
975
|
/**
|
|
976
976
|
* Text done event.
|
|
977
977
|
*/
|
|
978
|
-
interface XAIResponsesStreamEventTextDone extends XAIResponsesStreamEventBase {
|
|
978
|
+
export interface XAIResponsesStreamEventTextDone extends XAIResponsesStreamEventBase {
|
|
979
979
|
type: "response.output_text.done";
|
|
980
980
|
/** The index of the output item. */
|
|
981
981
|
output_index: number;
|
|
@@ -987,7 +987,7 @@ interface XAIResponsesStreamEventTextDone extends XAIResponsesStreamEventBase {
|
|
|
987
987
|
/**
|
|
988
988
|
* Function call arguments delta event.
|
|
989
989
|
*/
|
|
990
|
-
interface XAIResponsesStreamEventFunctionCallArgumentsDelta extends XAIResponsesStreamEventBase {
|
|
990
|
+
export interface XAIResponsesStreamEventFunctionCallArgumentsDelta extends XAIResponsesStreamEventBase {
|
|
991
991
|
type: "response.function_call_arguments.delta";
|
|
992
992
|
/** The index of the output item. */
|
|
993
993
|
output_index: number;
|
|
@@ -999,7 +999,7 @@ interface XAIResponsesStreamEventFunctionCallArgumentsDelta extends XAIResponses
|
|
|
999
999
|
/**
|
|
1000
1000
|
* Function call arguments done event.
|
|
1001
1001
|
*/
|
|
1002
|
-
interface XAIResponsesStreamEventFunctionCallArgumentsDone extends XAIResponsesStreamEventBase {
|
|
1002
|
+
export interface XAIResponsesStreamEventFunctionCallArgumentsDone extends XAIResponsesStreamEventBase {
|
|
1003
1003
|
type: "response.function_call_arguments.done";
|
|
1004
1004
|
/** The index of the output item. */
|
|
1005
1005
|
output_index: number;
|
|
@@ -1011,7 +1011,7 @@ interface XAIResponsesStreamEventFunctionCallArgumentsDone extends XAIResponsesS
|
|
|
1011
1011
|
/**
|
|
1012
1012
|
* Reasoning summary text delta event.
|
|
1013
1013
|
*/
|
|
1014
|
-
interface XAIResponsesStreamEventReasoningSummaryTextDelta extends XAIResponsesStreamEventBase {
|
|
1014
|
+
export interface XAIResponsesStreamEventReasoningSummaryTextDelta extends XAIResponsesStreamEventBase {
|
|
1015
1015
|
type: "response.reasoning_summary_text.delta";
|
|
1016
1016
|
/** The index of the output item. */
|
|
1017
1017
|
output_index: number;
|
|
@@ -1023,7 +1023,7 @@ interface XAIResponsesStreamEventReasoningSummaryTextDelta extends XAIResponsesS
|
|
|
1023
1023
|
/**
|
|
1024
1024
|
* Reasoning summary text done event.
|
|
1025
1025
|
*/
|
|
1026
|
-
interface XAIResponsesStreamEventReasoningSummaryTextDone extends XAIResponsesStreamEventBase {
|
|
1026
|
+
export interface XAIResponsesStreamEventReasoningSummaryTextDone extends XAIResponsesStreamEventBase {
|
|
1027
1027
|
type: "response.reasoning_summary_text.done";
|
|
1028
1028
|
/** The index of the output item. */
|
|
1029
1029
|
output_index: number;
|
|
@@ -1035,7 +1035,7 @@ interface XAIResponsesStreamEventReasoningSummaryTextDone extends XAIResponsesSt
|
|
|
1035
1035
|
/**
|
|
1036
1036
|
* Error event.
|
|
1037
1037
|
*/
|
|
1038
|
-
interface XAIResponsesStreamEventError extends XAIResponsesStreamEventBase {
|
|
1038
|
+
export interface XAIResponsesStreamEventError extends XAIResponsesStreamEventBase {
|
|
1039
1039
|
type: "error";
|
|
1040
1040
|
/** Error code. */
|
|
1041
1041
|
code?: string;
|
|
@@ -1047,11 +1047,11 @@ interface XAIResponsesStreamEventError extends XAIResponsesStreamEventBase {
|
|
|
1047
1047
|
/**
|
|
1048
1048
|
* Union type for all streaming events.
|
|
1049
1049
|
*/
|
|
1050
|
-
type XAIResponsesStreamEvent = XAIResponsesStreamEventCreated | XAIResponsesStreamEventInProgress | XAIResponsesStreamEventCompleted | XAIResponsesStreamEventFailed | XAIResponsesStreamEventIncomplete | XAIResponsesStreamEventOutputItemAdded | XAIResponsesStreamEventOutputItemDone | XAIResponsesStreamEventContentPartAdded | XAIResponsesStreamEventContentPartDone | XAIResponsesStreamEventTextDelta | XAIResponsesStreamEventTextDone | XAIResponsesStreamEventFunctionCallArgumentsDelta | XAIResponsesStreamEventFunctionCallArgumentsDone | XAIResponsesStreamEventReasoningSummaryTextDelta | XAIResponsesStreamEventReasoningSummaryTextDone | XAIResponsesStreamEventError;
|
|
1050
|
+
export type XAIResponsesStreamEvent = XAIResponsesStreamEventCreated | XAIResponsesStreamEventInProgress | XAIResponsesStreamEventCompleted | XAIResponsesStreamEventFailed | XAIResponsesStreamEventIncomplete | XAIResponsesStreamEventOutputItemAdded | XAIResponsesStreamEventOutputItemDone | XAIResponsesStreamEventContentPartAdded | XAIResponsesStreamEventContentPartDone | XAIResponsesStreamEventTextDelta | XAIResponsesStreamEventTextDone | XAIResponsesStreamEventFunctionCallArgumentsDelta | XAIResponsesStreamEventFunctionCallArgumentsDone | XAIResponsesStreamEventReasoningSummaryTextDelta | XAIResponsesStreamEventReasoningSummaryTextDone | XAIResponsesStreamEventError;
|
|
1051
1051
|
/**
|
|
1052
1052
|
* Call options for ChatXAIResponses.
|
|
1053
1053
|
*/
|
|
1054
|
-
interface ChatXAIResponsesCallOptions extends BaseChatModelCallOptions {
|
|
1054
|
+
export interface ChatXAIResponsesCallOptions extends BaseChatModelCallOptions {
|
|
1055
1055
|
/**
|
|
1056
1056
|
* Configuration options for a text response from the model.
|
|
1057
1057
|
*/
|
|
@@ -1100,7 +1100,7 @@ interface ChatXAIResponsesCallOptions extends BaseChatModelCallOptions {
|
|
|
1100
1100
|
/**
|
|
1101
1101
|
* Input configuration for ChatXAIResponses constructor.
|
|
1102
1102
|
*/
|
|
1103
|
-
interface ChatXAIResponsesInput extends BaseChatModelParams {
|
|
1103
|
+
export interface ChatXAIResponsesInput extends BaseChatModelParams {
|
|
1104
1104
|
/**
|
|
1105
1105
|
* The xAI API key to use for requests.
|
|
1106
1106
|
* @default process.env.XAI_API_KEY
|
|
@@ -1171,7 +1171,6 @@ interface ChatXAIResponsesInput extends BaseChatModelParams {
|
|
|
1171
1171
|
/**
|
|
1172
1172
|
* Invocation parameters for ChatXAIResponses (request params without input).
|
|
1173
1173
|
*/
|
|
1174
|
-
type ChatXAIResponsesInvocationParams = Omit<XAIResponsesCreateParams, "input">;
|
|
1174
|
+
export type ChatXAIResponsesInvocationParams = Omit<XAIResponsesCreateParams, "input">;
|
|
1175
1175
|
//#endregion
|
|
1176
|
-
export { ChatXAIResponsesCallOptions, ChatXAIResponsesInput, ChatXAIResponsesInvocationParams, XAIResponse, XAIResponsesAnnotation, XAIResponsesCodeInterpreterResult, XAIResponsesCodeInterpreterTool, XAIResponsesCodeInterpreterToolCall, XAIResponsesCreateParams, XAIResponsesCreateParamsNonStreaming, XAIResponsesCreateParamsStreaming, XAIResponsesDebugOutput, XAIResponsesFileCitationAnnotation, XAIResponsesFileSearchResult, XAIResponsesFileSearchTool, XAIResponsesFunctionTool, XAIResponsesFunctionToolCall, XAIResponsesFunctionToolFunction, XAIResponsesFunctionToolOutput, XAIResponsesInclude, XAIResponsesIncompleteDetails, XAIResponsesIncompleteReason, XAIResponsesInput, XAIResponsesInputContentItem, XAIResponsesInputFileItem, XAIResponsesInputImageItem, XAIResponsesInputItem, XAIResponsesInputTextItem, XAIResponsesLogprobContent, XAIResponsesLogprobToken, XAIResponsesLogprobs, XAIResponsesMcpTool, XAIResponsesMcpToolCall, XAIResponsesMessage, XAIResponsesMessageRole, XAIResponsesObjectType, XAIResponsesOutputCodeInterpreterCall, XAIResponsesOutputContent, XAIResponsesOutputFileSearchCall, XAIResponsesOutputFunctionCall, XAIResponsesOutputItem, XAIResponsesOutputMcpCall, XAIResponsesOutputReasoning, XAIResponsesOutputRefusalContent, XAIResponsesOutputTextContent, XAIResponsesOutputTextItem, XAIResponsesOutputWebSearchCall, XAIResponsesPreviousResponse, XAIResponsesReasoning, XAIResponsesReasoningEffort, XAIResponsesReasoningResponse, XAIResponsesReasoningSummary, XAIResponsesReasoningSummaryItem, XAIResponsesSearchMode, XAIResponsesSearchParameters, XAIResponsesSearchSource, XAIResponsesSearchSourceRss, XAIResponsesSearchSourceWeb, XAIResponsesSearchSourceX, XAIResponsesStatus, XAIResponsesStreamEvent, XAIResponsesStreamEventBase, XAIResponsesStreamEventCompleted, XAIResponsesStreamEventContentPartAdded, XAIResponsesStreamEventContentPartDone, XAIResponsesStreamEventCreated, XAIResponsesStreamEventError, XAIResponsesStreamEventFailed, XAIResponsesStreamEventFunctionCallArgumentsDelta, XAIResponsesStreamEventFunctionCallArgumentsDone, XAIResponsesStreamEventInProgress, XAIResponsesStreamEventIncomplete, XAIResponsesStreamEventOutputItemAdded, XAIResponsesStreamEventOutputItemDone, XAIResponsesStreamEventReasoningSummaryTextDelta, XAIResponsesStreamEventReasoningSummaryTextDone, XAIResponsesStreamEventTextDelta, XAIResponsesStreamEventTextDone, XAIResponsesText, XAIResponsesTextFormat, XAIResponsesTextFormatJsonObject, XAIResponsesTextFormatJsonSchema, XAIResponsesTextFormatText, XAIResponsesTool, XAIResponsesToolCall, XAIResponsesToolChoice, XAIResponsesToolChoiceFunction, XAIResponsesToolChoiceString, XAIResponsesToolOutput, XAIResponsesUrlCitationAnnotation, XAIResponsesUsage, XAIResponsesWebSearchTool, XAIResponsesWebSearchToolCall, XAIResponsesXSearchTool };
|
|
1177
1176
|
//# sourceMappingURL=responses-types.d.ts.map
|