How to call a single model
Run deployed models with just one line of code.
With Client SDKs you can call custom or public AI models with just one line of code!
Prerequisites
- Select a model from Model Yard
- Create an API Key
You can use two ways to call a model on Each:
Client SDK
Run with just a single line.
each.run()
Console
Run from UI. Easy and effective for testing!
Client SDK
With Client SDK you need to initialize our SDK in your language and then you can use custom methods and calls to Each backend servers.
Initialize SDK
Run Inference
When you call a model, you’ll receive a prediction ID that you can use to check the status and get results. The final response will include the model outputs and additional metadata. Here’s how to make the call and handle the response:
Parse Output
Output can be array, object or stringified JSON. You can parse it as you want. If the model / workflow returns an single URL, you need to parse it as a string.
Console
The easiest way! You can call public or custom model via console. Select your model and you can use ▶ Demo tab on the page.
Was this page helpful?