@@ -54,6 +54,9 @@ export class Conversations extends APIResource {
54
54
}
55
55
}
56
56
57
+ /**
58
+ * A screenshot of a computer.
59
+ */
57
60
export interface ComputerScreenshotContent {
58
61
/**
59
62
* The identifier of an uploaded file that contains the screenshot.
@@ -72,38 +75,6 @@ export interface ComputerScreenshotContent {
72
75
type : 'computer_screenshot' ;
73
76
}
74
77
75
- export interface ContainerFileCitationBody {
76
- /**
77
- * The ID of the container file.
78
- */
79
- container_id : string ;
80
-
81
- /**
82
- * The index of the last character of the container file citation in the message.
83
- */
84
- end_index : number ;
85
-
86
- /**
87
- * The ID of the file.
88
- */
89
- file_id : string ;
90
-
91
- /**
92
- * The filename of the container file cited.
93
- */
94
- filename : string ;
95
-
96
- /**
97
- * The index of the first character of the container file citation in the message.
98
- */
99
- start_index : number ;
100
-
101
- /**
102
- * The type of the container file citation. Always `container_file_citation`.
103
- */
104
- type : 'container_file_citation' ;
105
- }
106
-
107
78
export interface Conversation {
108
79
/**
109
80
* The unique ID of the conversation.
@@ -147,96 +118,9 @@ export interface ConversationDeletedResource {
147
118
object : 'conversation.deleted' ;
148
119
}
149
120
150
- export interface FileCitationBody {
151
- /**
152
- * The ID of the file.
153
- */
154
- file_id : string ;
155
-
156
- /**
157
- * The filename of the file cited.
158
- */
159
- filename : string ;
160
-
161
- /**
162
- * The index of the file in the list of files.
163
- */
164
- index : number ;
165
-
166
- /**
167
- * The type of the file citation. Always `file_citation`.
168
- */
169
- type : 'file_citation' ;
170
- }
171
-
172
- export interface InputFileContent {
173
- /**
174
- * The ID of the file to be sent to the model.
175
- */
176
- file_id : string | null ;
177
-
178
- /**
179
- * The type of the input item. Always `input_file`.
180
- */
181
- type : 'input_file' ;
182
-
183
- /**
184
- * The URL of the file to be sent to the model.
185
- */
186
- file_url ?: string ;
187
-
188
- /**
189
- * The name of the file to be sent to the model.
190
- */
191
- filename ?: string ;
192
- }
193
-
194
- export interface InputImageContent {
195
- /**
196
- * The detail level of the image to be sent to the model. One of `high`, `low`, or
197
- * `auto`. Defaults to `auto`.
198
- */
199
- detail : 'low' | 'high' | 'auto' ;
200
-
201
- /**
202
- * The ID of the file to be sent to the model.
203
- */
204
- file_id : string | null ;
205
-
206
- /**
207
- * The URL of the image to be sent to the model. A fully qualified URL or base64
208
- * encoded image in a data URL.
209
- */
210
- image_url : string | null ;
211
-
212
- /**
213
- * The type of the input item. Always `input_image`.
214
- */
215
- type : 'input_image' ;
216
- }
217
-
218
- export interface InputTextContent {
219
- /**
220
- * The text input to the model.
221
- */
222
- text : string ;
223
-
224
- /**
225
- * The type of the input item. Always `input_text`.
226
- */
227
- type : 'input_text' ;
228
- }
229
-
230
- export interface LobProb {
231
- token : string ;
232
-
233
- bytes : Array < number > ;
234
-
235
- logprob : number ;
236
-
237
- top_logprobs : Array < TopLogProb > ;
238
- }
239
-
121
+ /**
122
+ * A message to or from the model.
123
+ */
240
124
export interface Message {
241
125
/**
242
126
* The unique ID of the message.
@@ -247,14 +131,14 @@ export interface Message {
247
131
* The content of the message
248
132
*/
249
133
content : Array <
250
- | InputTextContent
251
- | OutputTextContent
134
+ | ResponsesAPI . ResponseInputText
135
+ | ResponsesAPI . ResponseOutputText
252
136
| TextContent
253
137
| SummaryTextContent
254
- | RefusalContent
255
- | InputImageContent
138
+ | ResponsesAPI . ResponseOutputRefusal
139
+ | ResponsesAPI . ResponseInputImage
256
140
| ComputerScreenshotContent
257
- | InputFileContent
141
+ | ResponsesAPI . ResponseInputFile
258
142
> ;
259
143
260
144
/**
@@ -275,83 +159,33 @@ export interface Message {
275
159
type : 'message' ;
276
160
}
277
161
278
- export interface OutputTextContent {
279
- /**
280
- * The annotations of the text output.
281
- */
282
- annotations : Array < FileCitationBody | URLCitationBody | ContainerFileCitationBody > ;
283
-
284
- /**
285
- * The text output from the model.
286
- */
287
- text : string ;
288
-
289
- /**
290
- * The type of the output text. Always `output_text`.
291
- */
292
- type : 'output_text' ;
293
-
294
- logprobs ?: Array < LobProb > ;
295
- }
296
-
297
- export interface RefusalContent {
298
- /**
299
- * The refusal explanation from the model.
300
- */
301
- refusal : string ;
302
-
303
- /**
304
- * The type of the refusal. Always `refusal`.
305
- */
306
- type : 'refusal' ;
307
- }
308
-
162
+ /**
163
+ * A summary text from the model.
164
+ */
309
165
export interface SummaryTextContent {
310
166
text : string ;
311
167
312
168
type : 'summary_text' ;
313
169
}
314
170
171
+ /**
172
+ * A text content.
173
+ */
315
174
export interface TextContent {
316
175
text : string ;
317
176
318
177
type : 'text' ;
319
178
}
320
179
321
- export interface TopLogProb {
322
- token : string ;
180
+ export type InputTextContent = ResponsesAPI . ResponseInputText ;
323
181
324
- bytes : Array < number > ;
182
+ export type OutputTextContent = ResponsesAPI . ResponseOutputText ;
325
183
326
- logprob : number ;
327
- }
184
+ export type RefusalContent = ResponsesAPI . ResponseOutputRefusal ;
328
185
329
- export interface URLCitationBody {
330
- /**
331
- * The index of the last character of the URL citation in the message.
332
- */
333
- end_index : number ;
186
+ export type InputImageContent = ResponsesAPI . ResponseInputImage ;
334
187
335
- /**
336
- * The index of the first character of the URL citation in the message.
337
- */
338
- start_index : number ;
339
-
340
- /**
341
- * The title of the web resource.
342
- */
343
- title : string ;
344
-
345
- /**
346
- * The type of the URL citation. Always `url_citation`.
347
- */
348
- type : 'url_citation' ;
349
-
350
- /**
351
- * The URL of the web resource.
352
- */
353
- url : string ;
354
- }
188
+ export type InputFileContent = ResponsesAPI . ResponseInputFile ;
355
189
356
190
export interface ConversationCreateParams {
357
191
/**
@@ -387,22 +221,17 @@ Conversations.Items = Items;
387
221
export declare namespace Conversations {
388
222
export {
389
223
type ComputerScreenshotContent as ComputerScreenshotContent ,
390
- type ContainerFileCitationBody as ContainerFileCitationBody ,
391
224
type Conversation as Conversation ,
392
225
type ConversationDeleted as ConversationDeleted ,
393
226
type ConversationDeletedResource as ConversationDeletedResource ,
394
- type FileCitationBody as FileCitationBody ,
395
- type InputFileContent as InputFileContent ,
396
- type InputImageContent as InputImageContent ,
397
- type InputTextContent as InputTextContent ,
398
- type LobProb as LobProb ,
399
227
type Message as Message ,
400
- type OutputTextContent as OutputTextContent ,
401
- type RefusalContent as RefusalContent ,
402
228
type SummaryTextContent as SummaryTextContent ,
403
229
type TextContent as TextContent ,
404
- type TopLogProb as TopLogProb ,
405
- type URLCitationBody as URLCitationBody ,
230
+ type InputTextContent as InputTextContent ,
231
+ type OutputTextContent as OutputTextContent ,
232
+ type RefusalContent as RefusalContent ,
233
+ type InputImageContent as InputImageContent ,
234
+ type InputFileContent as InputFileContent ,
406
235
type ConversationCreateParams as ConversationCreateParams ,
407
236
type ConversationUpdateParams as ConversationUpdateParams ,
408
237
} ;
0 commit comments