Skip to content

Commit ef09a0a

Browse files
feat(api): api update
1 parent 612ad2b commit ef09a0a

5 files changed

Lines changed: 44 additions & 24 deletions

File tree

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 137
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-9442fa9212dd61aac2bb0edd19744bee381e75888712f9098bc6ebb92c52b557.yml
3-
openapi_spec_hash: f87823d164b7a8f72a42eba04e482a99
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-2dede2c933d4c80020715c5e1a21c86b353de336e4dd2c6119125e3eaca6f904.yml
3+
openapi_spec_hash: 52ed6a83d460d3b2bf78e54bac8c503d
44
config_hash: ad7136f7366fddec432ec378939e58a7

src/openai/resources/files.py

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -91,10 +91,15 @@ def create(
9191
Args:
9292
file: The File object (not file name) to be uploaded.
9393
94-
purpose: The intended purpose of the uploaded file. One of: - `assistants`: Used in the
95-
Assistants API - `batch`: Used in the Batch API - `fine-tune`: Used for
96-
fine-tuning - `vision`: Images used for vision fine-tuning - `user_data`:
97-
Flexible file type for any purpose - `evals`: Used for eval data sets
94+
purpose:
95+
The intended purpose of the uploaded file. One of:
96+
97+
- `assistants`: Used in the Assistants API
98+
- `batch`: Used in the Batch API
99+
- `fine-tune`: Used for fine-tuning
100+
- `vision`: Images used for vision fine-tuning
101+
- `user_data`: Flexible file type for any purpose
102+
- `evals`: Used for eval data sets
98103
99104
expires_after: The expiration policy for a file. By default, files with `purpose=batch` expire
100105
after 30 days and all other files are persisted until they are manually deleted.
@@ -407,10 +412,15 @@ async def create(
407412
Args:
408413
file: The File object (not file name) to be uploaded.
409414
410-
purpose: The intended purpose of the uploaded file. One of: - `assistants`: Used in the
411-
Assistants API - `batch`: Used in the Batch API - `fine-tune`: Used for
412-
fine-tuning - `vision`: Images used for vision fine-tuning - `user_data`:
413-
Flexible file type for any purpose - `evals`: Used for eval data sets
415+
purpose:
416+
The intended purpose of the uploaded file. One of:
417+
418+
- `assistants`: Used in the Assistants API
419+
- `batch`: Used in the Batch API
420+
- `fine-tune`: Used for fine-tuning
421+
- `vision`: Images used for vision fine-tuning
422+
- `user_data`: Flexible file type for any purpose
423+
- `evals`: Used for eval data sets
414424
415425
expires_after: The expiration policy for a file. By default, files with `purpose=batch` expire
416426
after 30 days and all other files are persisted until they are manually deleted.

src/openai/types/file_create_params.py

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,14 @@ class FileCreateParams(TypedDict, total=False):
1515
"""The File object (not file name) to be uploaded."""
1616

1717
purpose: Required[FilePurpose]
18-
"""The intended purpose of the uploaded file.
19-
20-
One of: - `assistants`: Used in the Assistants API - `batch`: Used in the Batch
21-
API - `fine-tune`: Used for fine-tuning - `vision`: Images used for vision
22-
fine-tuning - `user_data`: Flexible file type for any purpose - `evals`: Used
23-
for eval data sets
18+
"""The intended purpose of the uploaded file. One of:
19+
20+
- `assistants`: Used in the Assistants API
21+
- `batch`: Used in the Batch API
22+
- `fine-tune`: Used for fine-tuning
23+
- `vision`: Images used for vision fine-tuning
24+
- `user_data`: Flexible file type for any purpose
25+
- `evals`: Used for eval data sets
2426
"""
2527

2628
expires_after: ExpiresAfter

src/openai/types/realtime/conversation_item_create_event.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,12 @@ class ConversationItemCreateEvent(BaseModel):
3232
previous_item_id: Optional[str] = None
3333
"""The ID of the preceding item after which the new item will be inserted.
3434
35-
If not set, the new item will be appended to the end of the conversation. If set
36-
to `root`, the new item will be added to the beginning of the conversation. If
37-
set to an existing ID, it allows an item to be inserted mid-conversation. If the
38-
ID cannot be found, an error will be returned and the item will not be added.
35+
If not set, the new item will be appended to the end of the conversation.
36+
37+
If set to `root`, the new item will be added to the beginning of the
38+
conversation.
39+
40+
If set to an existing ID, it allows an item to be inserted mid-conversation. If
41+
the ID cannot be found, an error will be returned and the item will not be
42+
added.
3943
"""

src/openai/types/realtime/conversation_item_create_event_param.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,12 @@ class ConversationItemCreateEventParam(TypedDict, total=False):
3232
previous_item_id: str
3333
"""The ID of the preceding item after which the new item will be inserted.
3434
35-
If not set, the new item will be appended to the end of the conversation. If set
36-
to `root`, the new item will be added to the beginning of the conversation. If
37-
set to an existing ID, it allows an item to be inserted mid-conversation. If the
38-
ID cannot be found, an error will be returned and the item will not be added.
35+
If not set, the new item will be appended to the end of the conversation.
36+
37+
If set to `root`, the new item will be added to the beginning of the
38+
conversation.
39+
40+
If set to an existing ID, it allows an item to be inserted mid-conversation. If
41+
the ID cannot be found, an error will be returned and the item will not be
42+
added.
3943
"""

0 commit comments

Comments
 (0)