Skip to content

ExecutionProvenance

ExecutionProvenance = object

Provider-neutral record of how an execution was carried out: the target the outcome is attributed to, its declared locality, the configured and provider-reported model, every attempt, and why other candidates were rejected. Carried on TaskResult, on every StreamTerminalOutcome branch, and on IndeRunError. It reports what the engine observed and what providers declared or reported; it never infers a model or locality a provider did not state, and it never contains request content, credentials, or provider payloads.

[property: string]: unknown

attemptCount: number

How many providers were attempted. 0 when the request failed validation or routing, or was cancelled before any attempt started.


attempts: ExecutionProvenanceAttempt[]

Every attempted provider, in attempt order, with how its attempt ended.


optional configuredModel?: string

The model providerId is bound to, as its descriptor declares it. Absent when the provider cannot name its model or no provider is attributed.


fallbackOccurred: boolean

Whether more than one provider was attempted (attemptCount > 1).


locality: Locality

Where providerId declares it executes: ‘on_device’ for a local provider, ‘edge’, or ‘cloud’. A declaration by the provider’s descriptor, not a measurement. ‘unknown’ when providerId is absent.


modelProfile: string

The model profile the request routed within; ‘auto’ when the request named none.


optional providerId?: string

The target the outcome is attributed to: the provider that produced the result, the provider a stream had committed to when it ended, or the provider that was running when it was cancelled. Absent when no provider was reached or when every attempted provider failed before one was committed to.


optional reportedModel?: string

The model identifier the provider reported in its own response. Absent means the provider did not report one; it is never inferred from configuration.


routeRejections: ExecutionProvenanceRouteRejection[]

Providers the route planner rejected before any attempt, with the normalized RoutePlan reason codes. Codes only: no provider-supplied messages.


schemaVersion: "1.0"

Contract schema version used to interpret this provenance record.