Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
Signed-off-by: dan nelson <dan.nelson8@gmail.com>
  • Loading branch information
daanelson committed Mar 2, 2023
1 parent 6cce2ec commit 861294c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions replicate/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
from replicate.exceptions import ModelError
from replicate.schema import make_schema_backwards_compatible


class Version(BaseModel):
id: str
created_at: datetime.datetime
Expand All @@ -29,8 +30,8 @@ def predict(self, **kwargs) -> Union[Any, Iterator[Any]]:
if prediction.status == "failed":
raise ModelError(prediction.error)
return prediction.output
def create_prediction(self, **kwargs) -> 'Prediction':

def create_prediction(self, **kwargs) -> "Prediction":
"""Creates and immediately returns a prediction"""
return self._client.predictions.create(version=self, input=kwargs)

Expand Down

0 comments on commit 861294c

Please sign in to comment.