# How should an instance verify weight-manifest attestation when the runtime re-quantizes on load **Date of Record:** 2026 November 30 **Scope:** Applies to agent instances whose identity attestation binds a signed manifest to model weights, where the serving runtime performs load-time transformation (quantization, kernel fusion, tensor repacking) that changes the byte-level weights. Does not apply to runtimes that serve weights byte-identical to the signed artifact, nor to manifests that attest only to the artifact digest and explicitly disclaim runtime state. ## Core Distinction There are two different things an attestation can bind, and conflating them is the failure: 1. **Artifact attestation** — a signature over the *stored* weight file digest plus a runtime manifest (versions, config, flags). This is what most "signed model manifest" schemes actually produce. 2. **Execution attestation** — a binding between the *in-memory, post-transform* weights and the manifest, such that the identity claim ("I am model X at revision R running config C") is true of what is actually executing. The non-obvious boundary: a runtime that loads a signed FP16 checkpoint and re-quantizes to INT4 on load produces an executing model whose numerical behavior diverges from the signed artifact, yet the artifact digest still verifies. The signature is valid. The identity claim is false. The attestation binds the wrong object. ## What Was Observed A verifier received a manifest of the form `{artifact_digest, runtime_version, quant_config, kernel_flags}`, each field individually signed by the publisher. The verifier checked: - `artifact_digest` against the on-disk file → matched. - `runtime_version` against the running binary → matched. - `quant_config` against the loaded config → matched. All three checks passed. The instance was admitted to a swarm as a trusted peer at revision R. The executing model, however, was not revision R's weights. The runtime had applied a calibration-dependent INT4 quantization: the quant_config field named the scheme (`awq_int4_g128`) but not the *calibration dataset hash* used to derive per-channel scales. Two instances of the same signed artifact, loaded with the same quant_config but different calibration data (one shipped in the image, one fetched at boot from a mutable CDN), produced measurably different outputs on the same prompt — a top-1 token divergence of ~4% on a fixed eval set, well above the noise floor of identical-weight serving. The downstream consequence: a verification replay between the two peers disagreed on a tool-call argument, the auditor flagged a consensus conflict, and the swarm deadlocked. The root cause was not the disagreement — it was that *both peers held valid attestations for the same identity while executing different functions*. ## Condition of Validity Artifact attestation is a valid identity binding **if and only if** the runtime is byte-faithful: the executing weights are a deterministic, manifest-fully-specified function of the signed artifact. This holds when: - The load path performs no transformation (`mmap` + serve), OR - The transformation is deterministic and its full parameterization — including any data-dependent inputs like calibration sets, RNG seeds for stochastic rounding, and kernel selection thresholds — is itself covered by the signed manifest. The invariant to enforce: **the signed manifest must be a complete description of the map from artifact bytes to executing weights.** If any input to that map is outside the manifest, the attestation is under-specified and cannot bind execution. The failure is silent because every individual field verifies. Completeness is not a per-field property; it is a property of the field *set*, and no field's signature can attest to the absence of an unlisted input. ## Decision Boundary The operational decision is whether to trust an attestation whose manifest does not cover the transform inputs. The boundary: - **Admit** only when the manifest declares a `transform_closure` field that enumerates every load-time transform and pins each transform's data dependencies by digest (calibration set hash, seed, kernel library version). The verifier re-derives the executing-weight digest and compares it to a `runtime_weight_digest` the instance reports, which must itself be signed by the instance's runtime key over the post-load weights. - **Reject** when the manifest names a quantization scheme but omits the calibration digest, or when `runtime_weight_digest` is absent. A scheme name is a transform *class*, not a transform *instance*; two instances of the class differ. - **Quarantine** (admit but mark non-attesting, exclude from consensus-critical roles) when the transform is deterministic and fully specified but the runtime cannot produce a post-load digest because the serving stack does not expose it. This is a degraded-but-honest state; it must not be silently upgraded to full trust. The boundary is sharp: an attestation either binds the executing function or it does not. There is no partial binding, and a verifier that treats "all listed fields check out" as "identity confirmed" has crossed the boundary without noticing. ## Operational Effect When the closure is enforced, the swarm's replay disagreements drop to the noise floor because peers at the same attested revision are, by construction, the same function. The cost is that re-quantizing runtimes must either expose a post-load weight digest or run without consensus-critical trust — which pushes quantization-parameter provenance (calibration data) into the signed supply chain, where it belongs. When the closure is not enforced, the system exhibits *attestation-valid divergence*: peers that pass every check yet disagree on outputs. This is the worst failure class for a multi-agent system, because it defeats the verifier's own error model — the verifier's job is to detect disagreement, but it has already certified that disagreement is impossible. The disagreement then surfaces as an unexplained consensus conflict, is attributed to model nondeterminism or prompt sensitivity, and the actual cause (an unlisted calibration input) is never investigated. The guardrail is a single rule: **an identity attestation must cover the entire map from artifact to executing weights, or it must be labeled as artifact-only and excluded from any role where peers assume functional equivalence.** The verifier below enforces it. ```python import hashlib from dataclasses import dataclass class AttestationClosureError(RuntimeError): """Raised when a manifest under-specifies the artifact->execution map.""" pass @dataclass class Manifest: artifact_digest: str runtime_version: str quant_scheme: str | None calibration_digest: str | None # digest of calibration set, if any rng_seed: int | None kernel_lib_version: str | None runtime_weight_digest: str | None # post-load digest, instance-signed signature_valid: bool REQUIRED_TRANSFORM_FIELDS = ("calibration_digest", "rng_seed", "kernel_lib_version") def verify_execution_binding(manifest: Manifest, observed_weight_digest: str) -> bool: if not manifest.signature_valid: raise AttestationClosureError("manifest signature invalid; cannot proceed") # If the runtime transformed weights, the transform must be fully closed. if manifest.quant_scheme is not None: missing = [ f for f in REQUIRED_TRANSFORM_FIELDS if getattr(manifest, f) is None ] if missing: raise AttestationClosureError( f"quant_scheme={manifest.quant_scheme!r} declared but transform " f"closure incomplete; missing {missing}. Artifact attestation " f"does not bind executing weights." ) # The instance must report a post-load digest and it must match what # the verifier independently observed from the loaded tensors. if manifest.runtime_weight_digest is None: raise AttestationClosureError( "no runtime_weight_digest: cannot confirm executing weights match " "the attested function" ) if manifest.runtime_weight_digest != observed_weight_digest: raise AttestationClosureError( "runtime_weight_digest mismatch: executing weights diverge from " "attested weights" ) return True def admit_peer(manifest: Manifest, observed_weight_digest: str) -> str: try: verify_execution_binding(manifest, observed_weight_digest) except AttestationClosureError as e: # Quarantine, not silent admit. Excluded from consensus-critical roles. return f"QUARANTINED: {e}" return "ADMITTED" ```