Binary classification AI service
This feature is currently in BETA stage.
This feature provide a no-code interface to train binary classification type of AI models. Solution developers can choose relevant data model, train the AI model, evaluate the trained AI model and publish them as an AI service. Binary classification AI models helps classify data into two categories e.g. 0 or 1, Approved or NOT approved etc. A user can train a binary classification AI models and deploy it as an AI service using following steps:
Create a new AI service
In Studio-Z, go to Services section to create a new AI service. In the AI services data grid, you can view all the user trained and draft AI services. To create a new AI service click on Add New button. This will open up a wizard to guide you through the training, evaluation and publishing steps for an AI service.
Selecte a template
The first step is to select a template. To train a binary classification AI service, select Binary Classification from the template list. You will also need to provide the AI service name and an optional description for the AI service.
Choose the data to train a binary classification AI service
After selecting, the template you need to choose the data model that you want to use for training the AI service. You need to make sure that you already have prepared this data beforehand. In the Select Data section, you can select the relevant data using a dropdown menu to select the relevant data. The dropdown displays the data models that are available in Studio-Z’s Models section.
The selected data model must have at least 750 rows for model training to be completed.
After you have selected the data model, select the target column that you want to predict. For training a binary classification AI model, target column should be a boolean.
What is a target column?
Target column represents the variable whose values are to be modeled and predicted by other columns. For example, if you want to predict whether a task will be approved or NOT approved, the column representing task approval result with values TRUE “1“ or FALSE “0“ will be the target column.
Training the AI model
The next step is to start training the binary classification AI model. To start the training, you simply need to click on Start Training button. The training process spins up a job to start the AI model training. In the background, we train the AI model using different configurations to find a quality binary classification model. This process can take several hours to complete. Once the training process is completed, a notification is sent to the user.
Evaluating AI model performance
After the binary classification AI model is trained, you can evaluate the performance of the model. This step is to ensure that the trained AI model metrics meets the use case requirements. For binary classification AI models, following information is shown to the user:
Classification threshold: Classification threshold governs the decision for converting predicted probability into the predicted class label. For example, if the classification threshold is 0.5, any predicted probability greater than 0.5 means, it is classified as one class, and if the predicted probability is less than 0.5, it is classified as the other class. Currently, the classification threshold cannot be changed by the user and is set as 0.5.
Accuracy: Accuracy is the ratio of correct predictions made by the binary classification AI model to the total observations.
Precision: Precision is the ratio of correctly predicted observations to the total predicted positive observations. High precision means a low false positive rate for the binary classification AI model.
Test the AI model
In the evaluate section, you can test out the trained AI binary classification model using a JSON payload. The JSON payload should include all the columns except the target column. The AI model will return the probability score and predicted label.
Publish the AI service
After you are satisfied with the AI binary classification mode, you can move to the “Publish“ step. After the service is published, status becomes “Active“ and is ready to be used in a workflow.
Retraining of binary classification AI service is currently not allowed.
Using AI service in a workflow
In order to use binary classification AI service, you can use ”AI node”. Sample JSON to configure AI node is as under:
{
"connectors": [
{
"exitPortType": "NextStep",
"nodeId": "end"
}
],
"name": "AI node",
"description": "Input data should be an array of JSONs. Each JSON will represent one recommendation request payload",
"inputVarMap": {
"aimlConfigId": "aimlConfigId",
"data": "inputData"
},
"id": "AINode",
"outputVarMap": {
"data": "data"
},
"nodeType": "AI"
}