> For the complete documentation index, see [llms.txt](https://docs.natml.ai/unity/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.natml.ai/unity/api/imlpredictor.md).

# IMLPredictor

Predictors are lightweight primitives for making predictions with one or more [`MLModel`](/unity/api/mlmodel.md) instances. The `IMLPredictor` interface is designed specifically for working with Edge ML models, which make predictions on-device.

## Making Predictions

```csharp
/// <summary>
/// Make a prediction on one or more input features.
/// </summary>
/// <param name="inputs">Input features.</param>
/// <returns>Prediction output.</returns>
TOutput Predict (params MLFeature[] inputs);
```

*This is where the magic happens*. The predictor should convert input features into `MLEdgeFeature` (for edge predictions) or `MLCloudFeature` instances depending on the type of the underlying model. Once the prediction is completed by the model, the predictor should then transform the output features into types that are easily consumed by applications.

{% hint style="success" %}
See [`MLEdgeModel`](/unity/api/mlmodel/mledgemodel.md) for more information on implementing edge predictors.
{% endhint %}

{% hint style="success" %}
See [`MLCloudModel`](/unity/api/mlmodel/mlcloudmodel.md) for more information on implementing cloud predictors.
{% endhint %}
