Runtime & Integrations · Evaluation Core
The Verdict Engine
The one function that decides a run outcome.
decide_verdict(Sequence[GateInput]) → VerdictPayload is the only verdict path. It
resolves each gate, then takes the run outcome by precedence
blocked > fail >
pass > informational.
This is the implementation behind Verdict
Engine. A GateInput carries the metric’s resolved authority, value, threshold,
direction, and excluded count; the function returns a typed VerdictPayload that every
consumer renders and none recompute.
Per-gate resolution
For each gate whose authority can_gate, the engine blocks rather than guesses when measurement is incomplete:
| Condition | Outcome · reason |
|---|---|
| authority blocked upstream | blocked · the authority reason |
| no aggregated value | blocked · no_measured_value |
| excluded_count > 0 | blocked · incomplete_measurement |
| no approved threshold | blocked · no_approved_threshold |
| value meets threshold | pass |
| value below threshold | fail · below_threshold / above_threshold |
| authority informational | informational (no active gate) |
It fails closed on tampering
VerdictPayload.__post_init__ re-derives the verdict from its gate lists and rejects a
mismatch, and ci_should_fail is fixed as “verdict is fail or blocked.” A consumer
cannot construct a friendlier payload than the gates imply.