Files
2026-07-13 13:22:34 +08:00

18 lines
362 B
Python

from mlflow.models import set_model
from mlflow.pyfunc import PythonModel
class StreamableModel(PythonModel):
def __init__(self):
pass
def predict(self, context, model_input, params=None):
pass
def predict_stream(self, context, model_input, params=None):
yield "test1"
yield "test2"
set_model(StreamableModel())