diff --git a/replicate/version.py b/replicate/version.py index e2edf1cf..cf2574ce 100644 --- a/replicate/version.py +++ b/replicate/version.py @@ -4,10 +4,8 @@ from replicate.base_model import BaseModel from replicate.collection import Collection from replicate.exceptions import ModelError -from replicate.prediction import Prediction from replicate.schema import make_schema_backwards_compatible - class Version(BaseModel): id: str created_at: datetime.datetime @@ -32,7 +30,7 @@ def predict(self, **kwargs) -> Union[Any, Iterator[Any]]: 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)