Document toolboxDocument toolbox

ML Single Model Evaluator

This unit is a Processor unit type.

Note that this unit is not available in your domain by default. Contact Devo for access to the corresponding Machine Learning permissions management features.

The ML Single Model Evaluator provides the results of applying the selected ML model to the input data. The model can evaluate models to the input event, such as classifyng the input into categories, detecting anomalies, and more.
When you have more than one model in your domain, you will need to create a Single Model Evaluator for each one, as it matches the model name.

This unit is linked to the ML Update Notifier unit to garner data on updates made on Machine Learning models in the domain.

If a more up-to-date model is detected, an event enters via the model port to signal the unit to update.

Events enter via the data port providing the attributes to be evaluated by the model.

The model will be used to evaluate the events, and the result of the evaluation will be emitted as events via the out port.

If the event entering the data port does not contain the attributes expected by the model as input (same name and type, the order is not important), then they will exit via the discarded port.

If an error occurs, the input event is enriched with new fields describing the problem, and the event is sent through the error port.

Configuration

After dragging this unit into the Flow canvas, double-click it to access its configuration options. The following table describes the configuration options of this unit:

Tab

Field

Description

Tab

Field

Description

General

Name

Enter a name for the unit. It must start with a letter, and cannot contain spaces. Only letters, numbers, and underscores are allowed.

Description

Enter a description for the unit.

Model Name

Enter the name of the Machine Learning model you wish to apply to your data events or select the model that you uploaded in Model Management.

Use a separate Single Model Evaluator unit for each individual model.

Out result field

Enter the name of the output event field containing the results of the model evaluation on the input data.

Overwrite

Toggle ON to overwrite an input field if one should already exist with the same name.

Input ports

Port

Description

Port

Description

data

Events providing the attributes to be evaluated by the model.

model

Events signalling that a model has been updated.

Output ports

Port

Description

Port

Description

out

Outputs events successfully detecting updates.

error

Outputs events that contain errors, enriched with standard error fields.

discarded

Outputs events containing information on fields that did not match.

Example

Imagine you trained a model to classify a flower into one of three species of Iris (Iris setosa, Iris virginica, and Iris versicolor) based on four features (length and width of sepals and petals), and uploaded it Devo as "iriscb1645798232340", defining the four features as floats, with these names: field_0, field_1, field_2, and field_3.

You can now use the ML Single Model to classify new flowers using their length and width of sepals and petals. To mock the dataset of the new flowers you want to classify, you can use a Tick unit that will give you some random data to test.

Then, add an ML Single Model Evaluator to the canvas and link the data port to the out port of the Tick unit. Finally, add an ML Update Notifier unit to the canvas and link its data port to the model port of the ML Single Model Evaluator unit.

In the Tick unit properties, go to the Fields tab and click the + icon to configure the fields of the model to check. The names and types must match exactly with those of the ML model. In this Iris Petal example, configure the following 4 fields:

In the ML Single Model Evaluator unit, enter the name of the Model to check for updates, as well as the name for the output event.

You can try this flow by downloading the following JSON file and uploading it to your domain using the Import option.

In order for this Flow to work, you must have previously trained the corresponding model.