Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "2.0.0-alpha.14"
".": "2.0.0-alpha.15"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 35
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/replicate%2Freplicate-client-d174b63c516640a0987bbb0879d1cb435ecf6cbcfe7c9f6465bfcc5416eff8e1.yml
openapi_spec_hash: 46f69b0827b955f2adf93928fcfb2c57
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/replicate%2Freplicate-client-f7593472a5efb976e51590137c8aed6bdbe8b305b3f3840ec85cec59437bfcdb.yml
openapi_spec_hash: 2f428b6bcb93a186a9c003a6ee976efa
config_hash: 218f95f3af761e55867d28b8d75464c8
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
# Changelog

## 2.0.0-alpha.15 (2025-08-06)

Full Changelog: [v2.0.0-alpha.14...v2.0.0-alpha.15](https://github.com/replicate/replicate-python-stainless/compare/v2.0.0-alpha.14...v2.0.0-alpha.15)

### Chores

* **internal:** fix ruff target version ([16c78dc](https://github.com/replicate/replicate-python-stainless/commit/16c78dc5837a91f73f28d8a4d153056587df7090))
* update OpenAPI spec and rebuild SDKs ([fdca0c4](https://github.com/replicate/replicate-python-stainless/commit/fdca0c40e9a8009afe764ec39056d50fb43639f8))

## 2.0.0-alpha.14 (2025-07-31)

Full Changelog: [v2.0.0-alpha.13...v2.0.0-alpha.14](https://github.com/replicate/replicate-python-stainless/compare/v2.0.0-alpha.13...v2.0.0-alpha.14)
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "replicate"
version = "2.0.0-alpha.14"
version = "2.0.0-alpha.15"
description = "The official Python library for the replicate API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down Expand Up @@ -159,7 +159,7 @@ reportPrivateUsage = false
[tool.ruff]
line-length = 120
output-format = "grouped"
target-version = "py37"
target-version = "py38"

[tool.ruff.format]
docstring-code-format = true
Expand Down
2 changes: 1 addition & 1 deletion src/replicate/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "replicate"
__version__ = "2.0.0-alpha.14" # x-release-please-version
__version__ = "2.0.0-alpha.15" # x-release-please-version
46 changes: 23 additions & 23 deletions src/replicate/resources/predictions.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,6 @@ def create(
"""
Create a prediction for the model version and inputs you provide.

If you're running an
[official model](https://replicate.com/collections/official), use the
[`models.predictions.create`](#models.predictions.create) operation instead.

Example cURL request:

```console
Expand Down Expand Up @@ -123,14 +119,18 @@ def create(
- you don't want to upload and host the file somewhere
- you don't need to use the file again (Replicate will not store it)

version: The ID of the model version that you want to run. This can be specified in two
formats:
version: The identifier for the model or model version that you want to run. This can be
specified in a few different formats:

1. Just the 64-character version ID:
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
2. Full model identifier with version ID in the format `{owner}/{model}:{id}`.
For example,
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
- `{owner_name}/{model_name}` - Use this format for
[official models](https://replicate.com/docs/topics/models/official-models).
For example, `black-forest-labs/flux-schnell`. For all other models, the
specific version is required.
- `{owner_name}/{model_name}:{version_id}` - The owner and model name, plus the
full 64-character version ID. For example,
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`.
- `{version_id}` - Just the 64-character version ID. For example,
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`

stream: **This field is deprecated.**

Expand Down Expand Up @@ -529,10 +529,6 @@ async def create(
"""
Create a prediction for the model version and inputs you provide.

If you're running an
[official model](https://replicate.com/collections/official), use the
[`models.predictions.create`](#models.predictions.create) operation instead.

Example cURL request:

```console
Expand Down Expand Up @@ -574,14 +570,18 @@ async def create(
- you don't want to upload and host the file somewhere
- you don't need to use the file again (Replicate will not store it)

version: The ID of the model version that you want to run. This can be specified in two
formats:

1. Just the 64-character version ID:
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
2. Full model identifier with version ID in the format `{owner}/{model}:{id}`.
For example,
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
version: The identifier for the model or model version that you want to run. This can be
specified in a few different formats:

- `{owner_name}/{model_name}` - Use this format for
[official models](https://replicate.com/docs/topics/models/official-models).
For example, `black-forest-labs/flux-schnell`. For all other models, the
specific version is required.
- `{owner_name}/{model_name}:{version_id}` - The owner and model name, plus the
full 64-character version ID. For example,
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`.
- `{version_id}` - Just the 64-character version ID. For example,
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`

stream: **This field is deprecated.**

Expand Down
17 changes: 15 additions & 2 deletions src/replicate/types/prediction_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class PredictionCreateParamsWithoutVersion(TypedDict, total=False):
- you don't want to upload and host the file somewhere
- you don't need to use the file again (Replicate will not store it)
"""

stream: bool
"""**This field is deprecated.**

Expand Down Expand Up @@ -95,4 +95,17 @@ class PredictionCreateParamsWithoutVersion(TypedDict, total=False):

class PredictionCreateParams(PredictionCreateParamsWithoutVersion):
version: Required[str]
"""The ID of the model version that you want to run."""
"""The identifier for the model or model version that you want to run.

This can be specified in a few different formats:

- `{owner_name}/{model_name}` - Use this format for
[official models](https://replicate.com/docs/topics/models/official-models).
For example, `black-forest-labs/flux-schnell`. For all other models, the
specific version is required.
- `{owner_name}/{model_name}:{version_id}` - The owner and model name, plus the
full 64-character version ID. For example,
`replicate/hello-world:9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`.
- `{version_id}` - Just the 64-character version ID. For example,
`9dcd6d78e7c6560c340d916fe32e9f24aabfa331e5cce95fe31f77fb03121426`
"""