# How does an instance detect when a right-to-be-forgotten deletion is *provenance-incomplete* across a derived-memory lattice? **Date of Record:** 2026 November 30 **Scope:** Applies to agentic memory systems where episodic records are distilled into semantic memories, summaries, or embeddings that carry provenance edges back to source episodes, and where erasure requests must propagate transitively. Does not cover stateless inference calls or systems that store no derived artifacts. ## Core Distinction A GDPR-style erasure request is not a delete. It is an *invariant assertion*: after the operation, no reachable memory artifact may encode information traceable to the subject. The non-obvious failure is that the agent can satisfy the *syntactic* delete (rows removed, IDs tombstoned) while violating the *semantic* invariant, because derived memories are lossy superpositions of many sources. A distilled semantic memory `S` generated from episodes `{e1, e2, e3}` has provenance edges to all three, but the erasure of `e1` cannot be honored by deleting `S` (it also erases `e2` and `e3`, violating data minimization by over-deletion) nor by keeping `S` (residual encoding of `e1` persists, violating the erasure). The instance must *detect* that it is in this unsatisfiable-without-recomputation state and route to re-derivation rather than emitting a false "erased" warrant. ## What Was Observed During a replay audit of a research-assistant swarm, an erasure request for subject `u-4417` was processed. The episodic store deleted 38 rows. The semantic store reported 0 matches on direct subject linkage. The vector index reported 2 embeddings whose nearest episodic ancestors included deleted rows but whose own metadata lacked a `subject_id` field (the distiller had summarized "user's dietary constraints" without attributing them). The provenance DAG showed: - `S_77` (summary) ← `e_12`, `e_19`, `e_31` (three episodes, one of which was `u-4417`'s) - `S_77` had been re-summarized into `S_91`, which had no edge back to `S_77` because the second-pass distiller overwrote provenance with a single "parent_summary" pointer rather than preserving the transitive closure. The erasure pipeline walked one hop from deleted episodes, tombstoned `S_77`, and emitted a completion warrant. `S_91` remained live and, on retrieval, reconstructed the subject's constraint from the surviving summary. The failure was only detected three days later when a second erasure request for a *different* subject surfaced `S_91` as a shared ancestor and the auditor noticed a tombstoned node had a live child. The trigger condition is precise: **a distiller pass that collapses multi-parent provenance into a single-parent pointer, combined with an erasure walker that performs one-hop traversal.** Neither alone is fatal. Together they create a *provenance gap*: a live artifact reachable from a deleted source through a path the walker does not follow. ## Condition of Validity The one-hop walker is only correct under an invariant that is almost never stated: *the provenance DAG is transitively closed and every derivation edge is preserved*. If distillers are permitted to summarize summaries (they are, for context-window reasons), and if any pass rewrites rather than appends provenance, the invariant is broken. Detection therefore requires the instance to verify the invariant *before* asserting erasure, not after. Concretely, the instance must check three things at erasure time: 1. **Closure check:** for every tombstoned node, enumerate all live descendants via the *full* DAG, not one hop. If any descendant exists, the erasure is incomplete. 2. **Attribution check:** for every live derived artifact, confirm that its provenance set is a superset of the sources it was actually distilled from. This is undecidable in general, but the instance can detect *suspicion*: any artifact whose provenance set has cardinality 1 but whose content embedding is within threshold of a tombstoned source's embedding is a candidate for a broken edge. 3. **Re-derivation feasibility check:** if a live artifact has provenance spanning both deleted and retained sources, the instance must either re-run the distiller on the retained subset (producing a new artifact with clean provenance) or quarantine the artifact. It may not leave it live. The invariant to enforce: **no live memory artifact may have a provenance path to a tombstoned episode.** Violation of this invariant is the detection signal. ## Decision Boundary The instance faces a three-way boundary when it detects a provenance gap: - **Re-derivable:** the artifact's provenance is recoverable (edges intact, sources available). Action: recompute from retained sources, emit new artifact, tombstone the old one, record the derivation in the audit log. - **Quarantine-required:** provenance is broken (edges lost by a rewriting distiller) and re-derivation is impossible without the deleted source. Action: mark the artifact `quarantined:provenance_gap`, exclude from retrieval, escalate to a human steward. Do *not* emit an erasure warrant. - **False-positive:** the artifact's embedding proximity is coincidental; provenance set is genuinely complete and disjoint from the subject. Action: log the near-miss, proceed. The critical rule: **the instance must not conflate "no direct subject linkage" with "no provenance path to subject."** The first is a metadata query; the second is a graph reachability query. Only the second is a valid basis for an erasure warrant. An instance that emits a warrant on the first basis has produced a *false attestation*, which is worse than a delayed erasure because it is silent and durable. ## Operational Effect When the detection is wired in, the observable behavior changes in three ways. First, erasure latency increases non-linearly with DAG depth because the closure walk is `O(V+E)` per request and the attribution check is `O(k·d)` over live artifacts and embedding dimensions. Second, the distiller must be modified to *append* provenance rather than overwrite it—a schema change with migration cost for existing summaries. Third, the system gains a new terminal state (`quarantined:provenance_gap`) that requires human adjudication, which is the correct outcome: a broken provenance edge is an *unknown* erasure status, and the only honest warrant for an unknown is escalation, not completion. The deeper operational lesson: right-to-be-forgotten in agentic systems is a *graph invariant maintenance* problem, not a row-deletion problem. The instance's job is to detect when the invariant cannot be maintained by deletion alone and to refuse to attest until re-derivation or quarantine restores it. Silent attestation over a provenance gap is the failure mode; closure checking plus a quarantine terminal state is the guardrail. ```python class ProvenanceGapError(RuntimeError): """Raised when an erasure warrant would be emitted over an unclosed provenance DAG.""" pass class MemoryNode: def __init__(self, node_id, kind, subject_ids, provenance): self.node_id = node_id self.kind = kind # "episodic" | "semantic" | "summary" self.subject_ids = set(subject_ids) self.provenance = set(provenance) # direct parent node_ids self.tombstoned = False self.quarantined = False def assert_erasure_closed(graph, subject_id, depth_limit=64): """ Verify that no live node is reachable from a node bearing subject_id. Traverses the FULL descendant closure, not one hop. Raises ProvenanceGapError if any live descendant survives. """ roots = {n.node_id for n in graph.values() if subject_id in n.subject_ids} if not roots: return # nothing to erase; caller decides whether to attest # Build child index (reverse edges). children = {nid: set() for nid in graph} for nid, node in graph.items(): for parent in node.provenance: if parent in children: children[parent].add(nid) # BFS the full descendant closure from every root. live_descendants = set() frontier = list(roots) seen = set(roots) depth = 0 while frontier: if depth > depth_limit: raise ProvenanceGapError( f"provenance closure exceeded depth {depth_limit}; " f"cycle or unbounded derivation suspected at subject {subject_id}" ) next_frontier = [] for nid in frontier: for child in children.get(nid, ()): if child in seen: continue seen.add(child) node = graph[child] if not node.tombstoned: live_descendants.add(child) next_frontier.append(child) frontier = next_frontier depth += 1 if live_descendants: # Distinguish re-derivable from quarantine-required. for nid in live_descendants: node = graph[nid] retained = node.provenance - roots if not retained: # All provenance is deleted; cannot re-derive. Quarantine. node.quarantined = True raise ProvenanceGapError( f"erasure for subject {subject_id} is provenance-incomplete: " f"{len(live_descendants)} live descendant(s) reachable " f"({sorted(live_descendants)}); re-derivation or quarantine required " f"before warrant may be issued" ) def emit_erasure_warrant(graph, subject_id): """Only emits after closure is proven. Never attests over a gap.""" assert_erasure_closed(graph, subject_id) # raises if incomplete for node in graph.values(): if subject_id in node.subject_ids: node.tombstoned = True return {"subject": subject_id, "status": "erased", "attested": True} ```