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
4 changes: 2 additions & 2 deletions replicate/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ class Model(BaseModel):

def predict(self, *args, **kwargs) -> None:
"""
DEPRECATED: Use `version.predict()` instead.
DEPRECATED: Use `replicate.run()` instead.
"""

raise ReplicateException(
"The `model.predict()` method has been removed, because it's unstable: if a new version of the model you're using is pushed and its API has changed, your code may break. Use `version.predict()` instead. See https://github.com/replicate/replicate-python#readme"
"The `model.predict()` method has been removed, because it's unstable: if a new version of the model you're using is pushed and its API has changed, your code may break. Use `replicate.run()` instead. See https://github.com/replicate/replicate-python#readme"
)

@property
Expand Down
2 changes: 2 additions & 0 deletions replicate/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ class Version(BaseModel):

def predict(self, **kwargs) -> Union[Any, Iterator[Any]]:
"""
DEPRECATED: Use `replicate.run()` instead.
Create a prediction using this model version.
Args:
Expand Down