Training & Predictions
Training & Predictions
After defining a Graph of Kumo Table objects and a PredictiveQuery, you can train a model and generate predictions.
Creating a Trainer
Training requires a ModelPlan, which defines the set of model configurations Kumo searches during training. Generate one from your predictive query:
The model plan is fully customizable. Refer to the Model Plan reference for all configurable attributes. After it is ready, create a Trainer:
Training a Model
Call fit() with your graph and training table:
The Kumo RDL SDK makes extensive use of non_blocking as an optional parameter for long-running operations. Setting this flag to True lets a long-running operation return immediately, returning a Future object that tracks the operation as it runs in the background. Setting this flag to False lets it wait until completion before returning.
Viewing Metrics and Artifacts
After training completes, the job exposes metrics and downloadable artifacts:
Generating Batch Predictions
After training a model, generate batch predictions and write them to an external data source:
Full Code Example
The following complete example uses the CustomerLTV sample dataset:
Polling Job Status
Any job scheduled with non_blocking=True returns a Future object with methods to track progress:
The same pattern applies to prediction jobs, training table jobs, and prediction table jobs.
Next Steps
This example covers the core training and prediction workflow. The SDK also supports faster model iteration, champion/challenger evaluation in production, and clean integration with upstream and downstream data pipelines.