Kumo Relational
Kumo Relational extends in-context learning from one table to related tables. It predicts a target for task rows using the rows linked to them through primary and foreign keys, without flattening the data into one table.
At a Glance
When to Use It
- Your prediction target is about an entity (a user, an item, a patient) and the evidence is in other tables, such as orders or visits.
- You want to avoid hand-built aggregate features.
- Choose Kumo Tabular when all features already sit in one row.
How It Works
- Intra-table row embeddings. Each related table is embedded with a TabICLv2-style row embedding stack. Context targets are distributed over the relational graph.
- Inter-table message passing. A schema-agnostic GNN exchanges row embeddings along the relationships for
num_hopsrounds, then reads out the rows linked to the task table. - In-context learning. Query task rows attend to labeled context task rows to produce class logits or quantiles.
Describe Your Tables
A RelatedTables object has three parts:
tables: a name for each related table and itsTableTensor.relationships: key joins between tables. Single or composite keys.task_links: exactly one entry point from task rows into a related table.
Columns with the id semantic type define relationships and are not used as features.
Example
This toy example predicts churn for two users from two labeled users and their orders.
With two labeled users, the probabilities only show that the pipeline runs. Real tasks need many more context rows.
Work with Real Data
For real datasets, use SDM’s subgraph samplers to build RelatedTables for each batch of task rows, with CPU (pyg-lib) or CUDA (cugraph) backends.
When two task rows refer to the same entity at different times, add a task ID to composite keys so each row only sees records available at its prediction time.
The RelBench example in the SDM repository shows this end to end. From that example’s directory, run:
Inputs and Limits
- Pass
related_context_tablesandrelated_query_tablestogether; the model requires related tables. - Exactly one task link to an entity table.
- Tables must be two-dimensional.
- One target column per call.
Run as a Service
The Kumo Relational NIM accepts predictive queries through the Structured Data Models Client. Use SDM when you want the model in your own Python process and full control over sampling.