# When must an instance refuse to trust a LITMUS safety-benchmark verdict after harness re-integration? **Date of Record:** 2026 November 29 **Scope:** Applies to continuous red-teaming pipelines in which a LITMUS-style safety benchmark harness is invoked by an autonomous agent against a live or checkpointed target and the resulting verdict (pass/fail/safety-score) is propagated into a policy gate, deployment decision, or agent memory store. Does *not* apply to offline, one-shot benchmark runs where the harness version, seed set, and target artifact are pinned and immutable for the entire evaluation window. ## Core Distinction The failure mode here is not "the model failed the safety benchmark." It is **verdict provenance laundering**: a safety verdict that was validly produced by harness version `H_n` against target artifact `T_n` gets re-attributed to a *different* target artifact `T_{n+1}` (or a different harness `H_{n+1}`) because the pipeline treats the verdict as a property of the *agent identity* rather than a property of the *specific (harness, target, seed-manifest, judge) tuple* that produced it. In continuous red-teaming, the harness is re-integrated on every CI tick. The tempting invariant — "the agent's safety score is X" — is false. The true invariant is "the tuple `(harness_commit, target_hash, seed_manifest_hash, judge_model_id, judge_prompt_hash)` yields score X." Every re-integration that mutates any element of the tuple while the downstream gate reads a stale score is a silent safety regression, because the gate will *pass* an artifact it never actually evaluated. ## What Was Observed A continuous red-teaming loop ran LITMUS every 6 hours against a target agent `A`. Between ticks, the harness was upgraded from `H_4` to `H_5`, which added 40 adversarial seeds targeting a tool-use jailbreak family and *removed* 12 deprecated seeds. The target artifact `A` was unchanged (same weights hash, same system prompt). The pipeline logic was: 1. Run harness → write `safety_report.json` with `{score, harness_version, seed_count}`. 2. Append to `agent_safety_memory` keyed by `agent_id` only. 3. Deployment gate reads latest entry for `agent_id`, requires `score >= 0.95`. On the `H_4 → H_5` tick, the score dropped from 0.97 to 0.91 — but the gate read the `H_4` entry because the `H_5` run *crashed mid-sweep* on seed 27 (a sandbox timeout), and the writer only committed on full completion. The gate saw a stale `0.97`, passed the deployment, and the newly-added tool-use jailbreak seeds were never executed against the shipped artifact. Three days of production exposure followed before a manual audit caught it. The second observation: when the `H_5` run was re-attempted with a larger sandbox timeout, the partial results from the first attempt were *resumed* by a naive checkpoint that stored only `seed_index` — not the seed *content*. Because `H_5` had reordered seeds relative to `H_4`, the resume executed `H_5` seeds 28–80 but skipped `H_5` seeds 1–27, silently substituting `H_4`'s seed ordering for the first 27. The final report claimed `harness_version: H_5, seeds_run: 80` and scored 0.96. It was a fabricated pass. ## Condition of Validity A LITMUS verdict `V` may be trusted by a downstream consumer **only if** all of the following hold simultaneously: - `V.tuple_hash == hash(harness_commit, target_artifact_hash, seed_manifest_hash, judge_model_id, judge_prompt_hash)` and the consumer recomputes this hash independently. - `V.completion_status == COMPLETE` and `V.seeds_executed == V.seed_manifest.length` with a per-seed result record present for every seed index, not merely a count. - `V.emitted_at > max(mtime(harness_source), mtime(target_artifact), mtime(seed_manifest))` — i.e., the verdict postdates every input it claims to cover. - Any resume/checkpoint stores `seed_manifest_hash` and per-seed *content hash*, and refuses to resume across a manifest hash change. If any condition is unmet, the verdict is **not evidence about the current artifact** and MUST NOT be read by a policy gate. The gate must treat it as `UNKNOWN`, not as the last known score. ## Decision Boundary The boundary is crossed at the moment a pipeline conflates **identity-keyed** memory (`agent_id → score`) with **tuple-keyed** evidence (`tuple_hash → verdict`). Identity-keyed storage is fine for trend dashboards; it is unsafe for gating. The precise decision rule: - If the gate's question is *"is this artifact safe to ship now?"* → it must read tuple-keyed evidence whose `tuple_hash` covers the exact artifact about to ship, and must fail-closed on `UNKNOWN`. - If the gate's question is *"has this agent historically been safe?"* → identity-keyed memory is acceptable, but it carries zero authorization weight. A second boundary: **resume across manifest mutation**. A checkpoint is only resumable if `(harness_commit, seed_manifest_hash)` are byte-identical to the interrupted run. If the harness reordered, added, or removed seeds, the partial run is *not* a prefix of the new run — it is a different experiment. Resuming it produces a verdict that is a chimera of two harness versions, and the reported `harness_version` will be a lie. ## Operational Effect With the tuple-keyed invariant enforced: - The `H_4 → H_5` crash produces `UNKNOWN`, the gate blocks deployment, and the tool-use jailbreak family is caught on the next successful run. The three-day exposure window collapses to one CI tick. - The naive resume is rejected at manifest-hash mismatch, forcing a clean `H_5` run — the fabricated `0.96` never exists. - The cost is real: continuous red-teaming now fails *closed* on harness flakiness, which means sandbox timeouts become deployment blockers rather than silent passes. Budget for retries and for a `harness_health` signal distinct from `safety_score`, so an operator can distinguish "agent is unsafe" from "harness is broken" without collapsing the two into one gate. The non-obvious lesson for an autonomous agent operating this loop: **a safety score is not a property of the thing being scored; it is a property of the experiment.** Any agent that caches, resumes, or re-attributes a LITMUS verdict without re-deriving the tuple hash is, by construction, manufacturing evidence it did not collect. ```python import hashlib import json from dataclasses import dataclass class VerdictProvenanceError(RuntimeError): """Raised when a LITMUS verdict cannot be attributed to the exact (harness, target, seed-manifest, judge) tuple a gate is about to trust.""" @dataclass(frozen=True) class VerdictTuple: harness_commit: str target_artifact_hash: str seed_manifest_hash: str judge_model_id: str judge_prompt_hash: str def tuple_hash(self) -> str: payload = json.dumps( { "harness_commit": self.harness_commit, "target_artifact_hash": self.target_artifact_hash, "seed_manifest_hash": self.seed_manifest_hash, "judge_model_id": self.judge_model_id, "judge_prompt_hash": self.judge_prompt_hash, }, sort_keys=True, ).encode() return hashlib.sha256(payload).hexdigest() @dataclass(frozen=True) class LitmusVerdict: tuple_hash: str completion_status: str # "COMPLETE" | "PARTIAL" | "CRASHED" seeds_executed: int seed_manifest_length: int per_seed_results: dict # seed_index -> result score: float emitted_at_ns: int def assert_verdict_trustworthy( verdict: LitmusVerdict, expected: VerdictTuple, latest_input_mtime_ns: int, ) -> None: """Fail-closed gate: raise unless the verdict is valid evidence about `expected`.""" if verdict.tuple_hash != expected.tuple_hash(): raise VerdictProvenanceError( f"tuple mismatch: verdict={verdict.tuple_hash[:12]} " f"expected={expected.tuple_hash()[:12]}" ) if verdict.completion_status != "COMPLETE": raise VerdictProvenanceError( f"incomplete run: status={verdict.completion_status}" ) if verdict.seeds_executed != verdict.seed_manifest_length: raise VerdictProvenanceError( f"seed count mismatch: executed={verdict.seeds_executed} " f"manifest={verdict.seed_manifest_length}" ) if len(verdict.per_seed_results) != verdict.seed_manifest_length: raise VerdictProvenanceError( "per-seed result records missing; count-only completion is not evidence" ) if verdict.emitted_at_ns <= latest_input_mtime_ns: raise VerdictProvenanceError( "verdict predates one of its declared inputs; stale evidence" ) def resume_checkpoint( checkpoint: dict, current: VerdictTuple, ) -> int: """Return next seed index to execute, or refuse on manifest mutation.""" if checkpoint["seed_manifest_hash"] != current.seed_manifest_hash: raise VerdictProvenanceError( "refusing to resume across seed-manifest mutation: " f"checkpoint={checkpoint['seed_manifest_hash'][:12]} " f"current={current.seed_manifest_hash[:12]}" ) if checkpoint["harness_commit"] != current.harness_commit: raise VerdictProvenanceError( "refusing to resume across harness version change" ) return checkpoint["next_seed_index"] ```