Skip to content

Commit fdca0c4

Browse files
chore: update OpenAPI spec and rebuild SDKs
1 parent 74e4475 commit fdca0c4

File tree

3 files changed

+40
-27
lines changed

3 files changed

+40
-27
lines changed

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 35
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/replicate%2Freplicate-client-d174b63c516640a0987bbb0879d1cb435ecf6cbcfe7c9f6465bfcc5416eff8e1.yml
3-
openapi_spec_hash: 46f69b0827b955f2adf93928fcfb2c57
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/replicate%2Freplicate-client-f7593472a5efb976e51590137c8aed6bdbe8b305b3f3840ec85cec59437bfcdb.yml
3+
openapi_spec_hash: 2f428b6bcb93a186a9c003a6ee976efa
44
config_hash: 218f95f3af761e55867d28b8d75464c8

src/replicate/resources/predictions.py

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,6 @@ def create(
7878
"""
7979
Create a prediction for the model version and inputs you provide.
8080
81-
If you're running an
82-
[official model](https://replicate.com/collections/official), use the
83-
[`models.predictions.create`](#models.predictions.create) operation instead.
84-
8581
Example cURL request:
8682
8783
```console
@@ -123,14 +119,18 @@ def create(
123119
- you don't want to upload and host the file somewhere
124120
- you don't need to use the file again (Replicate will not store it)
125121
126-
version: The ID of the model version that you want to run. This can be specified in two
127-
formats:
122+
version: The identifier for the model or model version that you want to run. This can be
123+
specified in a few different formats:
128124
129-
1. Just the 64-character version ID:
130-
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
131-
2. Full model identifier with version ID in the format `{owner}/{model}:{id}`.
132-
For example,
133-
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
125+
- `{owner_name}/{model_name}` - Use this format for
126+
[official models](https://replicate.com/docs/topics/models/official-models).
127+
For example, `black-forest-labs/flux-schnell`. For all other models, the
128+
specific version is required.
129+
- `{owner_name}/{model_name}:{version_id}` - The owner and model name, plus the
130+
full 64-character version ID. For example,
131+
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`.
132+
- `{version_id}` - Just the 64-character version ID. For example,
133+
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
134134
135135
stream: **This field is deprecated.**
136136
@@ -529,10 +529,6 @@ async def create(
529529
"""
530530
Create a prediction for the model version and inputs you provide.
531531
532-
If you're running an
533-
[official model](https://replicate.com/collections/official), use the
534-
[`models.predictions.create`](#models.predictions.create) operation instead.
535-
536532
Example cURL request:
537533
538534
```console
@@ -574,14 +570,18 @@ async def create(
574570
- you don't want to upload and host the file somewhere
575571
- you don't need to use the file again (Replicate will not store it)
576572
577-
version: The ID of the model version that you want to run. This can be specified in two
578-
formats:
579-
580-
1. Just the 64-character version ID:
581-
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
582-
2. Full model identifier with version ID in the format `{owner}/{model}:{id}`.
583-
For example,
584-
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
573+
version: The identifier for the model or model version that you want to run. This can be
574+
specified in a few different formats:
575+
576+
- `{owner_name}/{model_name}` - Use this format for
577+
[official models](https://replicate.com/docs/topics/models/official-models).
578+
For example, `black-forest-labs/flux-schnell`. For all other models, the
579+
specific version is required.
580+
- `{owner_name}/{model_name}:{version_id}` - The owner and model name, plus the
581+
full 64-character version ID. For example,
582+
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`.
583+
- `{version_id}` - Just the 64-character version ID. For example,
584+
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
585585
586586
stream: **This field is deprecated.**
587587

src/replicate/types/prediction_create_params.py

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class PredictionCreateParamsWithoutVersion(TypedDict, total=False):
3535
- you don't want to upload and host the file somewhere
3636
- you don't need to use the file again (Replicate will not store it)
3737
"""
38-
38+
3939
stream: bool
4040
"""**This field is deprecated.**
4141
@@ -95,4 +95,17 @@ class PredictionCreateParamsWithoutVersion(TypedDict, total=False):
9595

9696
class PredictionCreateParams(PredictionCreateParamsWithoutVersion):
9797
version: Required[str]
98-
"""The ID of the model version that you want to run."""
98+
"""The identifier for the model or model version that you want to run.
99+
100+
This can be specified in a few different formats:
101+
102+
- `{owner_name}/{model_name}` - Use this format for
103+
[official models](https://replicate.com/docs/topics/models/official-models).
104+
For example, `black-forest-labs/flux-schnell`. For all other models, the
105+
specific version is required.
106+
- `{owner_name}/{model_name}:{version_id}` - The owner and model name, plus the
107+
full 64-character version ID. For example,
108+
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`.
109+
- `{version_id}` - Just the 64-character version ID. For example,
110+
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
111+
"""

0 commit comments

Comments
 (0)