Skip to content

TurnModelRetryScheduledParams

turn/modelRetryScheduled params: a durable model-stream retry-scheduled fact folded — the provider backoff behind one model attempt is observable BEFORE the turn terminates, so a streaming client can render “system words · retrying in Ss · attempt N/M” instead of dead air. Non-terminal: it never resolves a turn-wait. The sibling turn/retryScheduled shape at the model layer: same member names and semantics (attempt/nextAttempt/maxAttempts/ retryDelayMs/system/errorKind/httpStatus), minus reason — the row’s words derive from errorKind through the shared gate-off mapping, and the recorded machine message is not user text. The delay is the recorded scheduled backoff, never an absolute fire time — clients derive any countdown locally. sourceRange cites the session stream’s mirror of the task-lifecycle record.

  • attempt
  • errorKind
  • httpStatus
  • maxAttempts
  • nextAttempt
  • retryDelayMs
  • sessionId
  • sourceRange
  • system
  • turnId
  • viewCursor
Source

schema/msp/experimental/msp.schema.json#/types/TurnModelRetryScheduledParams

{
"description": "`turn/modelRetryScheduled` params: a durable model-stream\nretry-scheduled fact folded — the provider backoff behind one model\nattempt is observable BEFORE the turn terminates, so a streaming\nclient can render \"system words · retrying in Ss · attempt N/M\"\ninstead of dead air. Non-terminal: it never resolves a turn-wait.\nThe sibling `turn/retryScheduled` shape at the model layer: same\nmember names and semantics (attempt/nextAttempt/maxAttempts/\nretryDelayMs/system/errorKind/httpStatus), minus `reason` — the\nrow's words derive from `errorKind` through the shared gate-off\nmapping, and the recorded machine message is not user text. The\ndelay is the recorded scheduled backoff, never an absolute fire\ntime — clients derive any countdown locally. `sourceRange` cites\nthe session stream's mirror of the task-lifecycle record.",
"properties": {
"attempt": {
"description": "The failed model attempt (producer-normalized, >= 1).",
"type": "integer"
},
"errorKind": {
"description": "The failing model attempt's durable kind, verbatim (ADR 50047\nD2) — a plain string: the durable vocabulary is open-ended.",
"type": "string"
},
"httpStatus": {
"description": "The failing model attempt's HTTP status (ADR 50047 D2).",
"type": "integer"
},
"maxAttempts": {
"description": "The model-retry chain bound.",
"type": "integer"
},
"nextAttempt": {
"description": "The scheduled model attempt (producer contract: attempt <\nnextAttempt <= maxAttempts; not a schema constraint).",
"type": "integer"
},
"retryDelayMs": {
"description": "The scheduled backoff delay in milliseconds, verbatim from the\ndurable fact.",
"type": "integer"
},
"sessionId": {
"description": "The owning session.",
"type": "string"
},
"sourceRange": {
"$ref": "#/$defs/SourceRange",
"description": "The durable record this event folded from (the session stream's\nmirror of the scheduled model task status; `first == last`)."
},
"system": {
"description": "The failing model attempt's provider system, verbatim\n(ADR 50047 D2) — e.g. `\"meta\"`. Always present from this producer\n(the durable `system` is a required `String`); optional on the wire\nso a future omission folds absent instead of failing the frame.",
"type": "string"
},
"turnId": {
"description": "The running turn whose model attempt is being retried.",
"type": "string"
},
"viewCursor": {
"description": "Opaque, strictly monotonic view cursor.",
"type": "string"
}
},
"required": [
"attempt",
"maxAttempts",
"nextAttempt",
"retryDelayMs",
"sessionId",
"sourceRange",
"turnId",
"viewCursor"
],
"type": "object"
}