Skip to main content

Train Models

With data uploaded the next step is to initiate model training. Model training is the process of teaching a machine learning model to recognize patterns and derive insights from given datasets.

Initiating training of the models entails discarding the existing models and constructing new ones from the ground up. This process is designed to ensure that the models are balanced and accurately reflect the current composition of your data, with an emphasis on the integration of recent data points. Periodically performing a retrain is crucial for sustaining optimal model performance.

The training process must be triggered for each Dataset. The steps for training models are as follows:

  1. Initiate Training: Call POST /start_trainer with a list of Dataset IDs in the body. This endpoint will return a Job ID.
Training payload format
datasetIds
required
Array of strings non-empty

List of unique IDs of the datasets on which the training should be run. The models will be trained from scratch on all uploaded information in the dataset.

object

Details for the webhook endpoint to call when a job finishes.

{
  • "datasetIds": [
    ],
  • "webhook": {}
}
Example request
{
"datasetIds": [
"example-dataset-1",
"example-dataset-2"
],
"webhook": {
"webhookUrl": "https://example.com/webhook/training-complete",
"webhookApiKey": "yourWebhookApiKeyHere"
}
}
  1. Check Status: Use GET /status with the Job ID in the header until it returns 200 with status="success", or employ the webhook functionality as described in the webhook section.

Once the status endpoint indicates "success," the model training is complete for the requested datasets, and the client can move on to generating predictions.