TrainingService.WatchTrainingRun
Stream the initial TrainingRun and subsequent modifications or deletion. Supply the UID to detect a same-name replacement. Each response is one event.
TrainingService · Installed Web API. Use the HTTPS origin of your Prokrust installation and credentials authorized for this operation.
POST /prokrust.api.v1alpha1.TrainingService/WatchTrainingRun
This RPC uses a response stream. The example shows one message. Use a streaming Connect client for the sequence.
Request fields
| JSON field | Type | Meaning |
|---|---|---|
namespace | string | Kubernetes workspace namespace for the operation. Use the namespace in which the selected resource lives. |
name | string | Kubernetes metadata.name of the selected resource in this namespace. |
uid | string | Optional UID from a prior read. Supply it to fail rather than observe a replacement object with the same name. |
Example request
{
"namespace": "analytics",
"name": "train-values",
"uid": "91c90b29-d618-5dbf-bc4b-391c5aababcd"
}
Response fields
| JSON field | Type | Meaning |
|---|---|---|
type | WatchEventType | Whether this event is the initial observation, a modification, or deletion. |
resource | Resource | Resource projection for the object affected by the operation. |
Example response message
{
"type": "WATCH_EVENT_TYPE_SNAPSHOT",
"resource": {
"namespace": "analytics",
"name": "train-values",
"uid": "91c90b29-d618-5dbf-bc4b-391c5aababcd",
"resourceVersion": "42",
"generation": "1",
"creationTimestamp": "2026-05-12T10:00:00Z",
"spec": {
"queryRef": {
"name": "value-query"
},
"graphSnapshotSource": {
"kind": "SnapshotPreparation",
"name": "prepare-events"
},
"split": {
"type": "HashRatio",
"train": 0.7,
"validation": 0.15,
"test": 0.15
},
"model": {
"family": "HeteroCountTimeV2",
"hiddenDimension": 4,
"layers": 1,
"fanout": [
2
],
"temporalStrategy": "Last",
"validationMetric": "Mae",
"dropout": 0,
"learningRate": 0.01,
"batchSize": 16,
"maxEpochs": 2,
"earlyStoppingPatience": 0
},
"cpuWorkers": 1,
"resources": {
"requests": {
"cpu": "250m",
"memory": "512Mi",
"ephemeral-storage": "512Mi"
},
"limits": {
"cpu": "500m",
"memory": "2Gi",
"ephemeral-storage": "2Gi"
}
},
"seed": "42",
"evaluationMode": "Full"
}
}
}
Kubernetes reference
See the TrainingRun reference for the resource configuration and controller observations.