constructor(model route: str) - takes in a model route, which is essentially a path to the deployed model, formatted as follows:
Copy
Ask AI
model = slai.model("<username>/<model_name>/<model_branch>")
the model_branch part of the route is optional; if left out the deployment will route to the initial branch of the model.model(inputs) - call the deployed model, returning inference results. Any input data defined in your model handler class can be passed as keyword arguments to the model, for example:
Copy
Ask AI
>> model = slai.model("<username>/<model_name>/<model_branch>")>> result = model(input_1=100.0, input_2=2000.0)>> result{ "result": [0.3434, 0.4343]}
info() - returns the input data required by the model, this is defined by your model handler class. For example: