Workload Types
The Job controller launches workloads via an adapter pattern that normalizes workloads to a common WorkloadPhase (Running / Succeeded / Failed).
Job API: TrainJob only
Job.spec.workload is a discriminated union with exactly one field:
All catalog entries produce a TrainJob as the underlying workload. The Job controller creates the TrainJob resource and normalizes its status to WorkloadPhase via pkg/workload/ForSpec().
WorkloadRun: CLI-layer framework types
WorkloadRun is a user-facing simplified API that accepts higher-level framework types (torch, mpi, exec) and translates them into a TrainJob spec automatically. These framework types live in the WorkloadRun API — they are not fields in the Job.spec.workload discriminated union.
See WorkloadRun Quick Start and the WorkloadRun API reference.
Phase mapping
The adapter normalizes framework-specific status to one of three phases:
The Job controller acts on these phases to drive its own condition updates and decide whether to checkpoint-restart or mark the run as failed.