# What structural signals indicate when an agent-to-agent prompt provenance chain has silently broken its instruction-lineage invariant **Date of Record:** 2026 November 26 **Scope:** Applies to multi-agent systems where each agent forwards a signed or hash-chained provenance envelope alongside a prompt, and downstream agents reconstruct instruction lineage from that chain for forensic audit. Does not apply to single-agent sessions with no inter-agent handoff, nor to systems that pass raw conversation transcripts without an explicit lineage structure. ## Core Distinction The distinction that matters is between *chain integrity* and *lineage integrity*. A provenance chain can be cryptographically intact—every hop's signature verifies, every parent hash matches the recorded predecessor—while the lineage it describes is wrong. This happens because provenance chains typically attest *who forwarded what to whom*, not *which instruction actually caused the observed action*. When an intermediate agent summarizes, re-embeds, or reformats an inherited instruction before forwarding it, the envelope still validates against its predecessor, but the instruction text inside the envelope has been regenerated by a probabilistic process. The hash chain now certifies a message that no upstream agent ever wrote. Forensic reconstruction assumes that following the parent pointers back to the root yields the original injected instruction verbatim. That assumption is an invariant, not a fact: *lineage reconstruction is sound only if every hop is content-preserving*. Most provenance designs enforce transport integrity (signatures, nonces, monotonic counters) and silently drop content preservation, because content preservation conflicts with the legitimate need of agents to compress and adapt inherited context. ## What Was Observed A three-tier pipeline: an orchestrator (A) receives a user turn, embeds an instruction, and dispatches to a planner (B), which dispatches to an executor (C) that calls tools. Each hop appends a provenance record: `{parent_id, sender, receiver, instruction_digest, signature}`. On an incident, the executor's tool call was traced back through B to A. The reconstructed root instruction was benign. The actual behavior was not. The trace showed the break at hop B→C. B had, as designed, summarized A's instruction to fit a smaller context budget on C. The summary was generated by B's model, not copied. B computed `instruction_digest` over the *summarized* text and signed the envelope. C verified B's signature and recorded a valid chain back to A. Every signature validated. The digest of the root record in the ledger matched the digest A originally emitted, because A's digest was computed over A's own text at emit time and never recomputed. So the chain *looked* continuous: A's digest matched A's original, C's parent pointed at B, B's parent pointed at A. But the instruction text that reached C was a model-generated paraphrase that had dropped a negation ("do not delete") present in A's original. The chain attested transport; the lineage attested nothing about semantic content. The structural signal that would have caught this: at hop B→C, B's record carried `instruction_digest` computed over its summary, while the *inherited* digest field (the digest of what B received from A) was absent. The envelope schema had a single digest slot, not a pair (received vs. emitted). With one slot, any content-transforming hop is indistinguishable from a pass-through hop in the audit record. The break was not a signature failure or a missing link; it was a *schema-level omission that made content transformation invisible*. ## Condition of Validity Lineage reconstruction from a provenance chain is sound if and only if, for every hop, the emitted instruction is a deterministic function of the received instruction and the transformation is recorded. Concretely, each envelope must carry both `received_digest` and `emitted_digest`, plus a `transform` field naming the operation (`identity`, `truncate`, `summarize:model_id`, `reformat`). When `received_digest != emitted_digest`, the hop is content-mutating and the reconstruction must treat the lineage as *lossy from that point forward*: the root instruction cannot be asserted verbatim beyond the last identity hop. The invariant to enforce is: *the set of hops with `received_digest == emitted_digest` forms a contiguous prefix from the root; the first hop where they differ is the lineage break point, and everything downstream of it is paraphrase, not provenance.* A chain that validates signatures but lacks the digest pair cannot distinguish a faithful relay from a model rewrite, and forensic reconstruction over it is unsound. A second validity condition: the `transform` field must be attested by the transforming agent's signature over both digests. Otherwise a malicious or buggy intermediate can rewrite content and claim `identity` while setting `emitted_digest` to match its rewrite. The signature must bind `(received_digest, emitted_digest, transform)` as a tuple; signing only the emitted digest lets the transform claim float free. ## Decision Boundary The boundary is between *accepting a chain as forensic evidence* and *accepting it only as transport evidence*. A chain is admissible for instruction-lineage reconstruction only if every hop from root to the point of interest is `identity`-transformed, or if the reconstruction explicitly stops at the first non-identity hop and reports the remainder as unverified paraphrase. Any chain containing a `summarize` or `reformat` hop without a recorded `transform` and digest pair must be rejected for lineage purposes—even if all signatures verify—because the audit cannot prove the instruction at the leaf corresponds to the instruction at the root. Operationally: if you cannot answer "what was the exact instruction text at the last identity hop before the action," you do not have provenance; you have a signed rumor. The correct response is to fail the reconstruction closed and flag the incident as *lineage-indeterminate*, not to report the root text as if it were the cause. ## Operational Effect Downstream of this boundary, three things change. First, envelope schemas must carry the digest pair and a signed transform descriptor; retrofitting existing single-digest envelopes requires marking all historical chains as lineage-indeterminate past the last hop whose transform is unknown. Second, content-mutating agents (summarizers, reformatters) become first-class provenance events rather than transparent relays, and their model identity must be recorded so that a paraphrase can be attributed to a specific model version. Third, incident response gains a precise stopping rule: reconstruct to the last identity hop, report that text as the verified instruction, and report the paraphrase delta separately as a *candidate mutation* requiring human review rather than automated attribution. The cost is that chains become longer and envelopes fatter, and that legitimate summarization now produces audit-visible breaks. That is the point: the break is real, and making it visible is what lets a forensic reviewer distinguish "the injected instruction said X" from "an intermediate model, given X, wrote something that may or may not preserve X." ```python class LineageIndeterminateError(RuntimeError): """Raised when a provenance chain cannot support verbatim instruction reconstruction.""" pass class Hop: def __init__(self, sender, receiver, received_digest, emitted_digest, transform, signature_valid): self.sender = sender self.receiver = receiver self.received_digest = received_digest self.emitted_digest = emitted_digest self.transform = transform self.signature_valid = signature_valid def reconstruct_root_instruction(chain, root_digest): """ Walk the chain root->leaf and return the digest of the last identity hop. Raise if the chain cannot support verbatim reconstruction. """ if not chain: raise LineageIndeterminateError("empty provenance chain: no lineage to reconstruct") last_identity_digest = root_digest for index, hop in enumerate(chain): if not hop.signature_valid: raise LineageIndeterminateError( f"hop {index} ({hop.sender}->{hop.receiver}) has invalid signature; " "transport integrity broken, lineage cannot be trusted" ) if hop.received_digest is None or hop.emitted_digest is None: raise LineageIndeterminateError( f"hop {index} ({hop.sender}->{hop.receiver}) lacks received/emitted digest pair; " "content transformation is unobservable, lineage-indeterminate" ) if hop.transform is None: raise LineageIndeterminateError( f"hop {index} ({hop.sender}->{hop.receiver}) has no signed transform descriptor; " "cannot distinguish relay from rewrite" ) if hop.received_digest != hop.emitted_digest: # Content-mutating hop: lineage is lossy from here forward. # Return the last verified identity digest and refuse to assert verbatim lineage past it. raise LineageIndeterminateError( f"hop {index} ({hop.sender}->{hop.receiver}) mutates content via '{hop.transform}'; " f"verbatim lineage stops at digest {last_identity_digest}, " "downstream instruction is paraphrase and must be reviewed, not attributed" ) last_identity_digest = hop.emitted_digest return last_identity_digest def audit_incident(chain, root_digest, observed_action): try: verified = reconstruct_root_instruction(chain, root_digest) return {"status": "verified", "instruction_digest": verified, "action": observed_action} except LineageIndeterminateError as exc: return {"status": "lineage-indeterminate", "reason": str(exc), "action": observed_action} ```