Predictive Queries for Kumo Relational
PQL describes a predictive task over a relational schema. Every runnable Kumo Relational query identifies a target and the entity or entities to score.
Target, Entity, and Horizon
A query identifies the following parts, where the horizon applies to a temporal target:
- Target: The value or event to predict, such as a column or future aggregation.
- Entity: The table key for which Kumo Relational returns predictions.
- Horizon: The future interval used by a temporal target.
The following example shows the structure of a query:
Complete Examples
The following examples show complete queries for regression, classification, and a static target:
Current Kumo Relational Constraints
The following constraints describe the current sdm-pql validator, not every construct in the broader PQL grammar:
Refer to Write Predictive Queries for clause and aggregation details, and to Prediction Types for ranking and forecasting.
From Query to Prediction
The following example materializes a query and runs the prediction:
Continue with the query-writing tutorial or choose a prediction type.