# What structural signals indicate a retention-policy tombstone gap when an agent's forget tool acknowledges deletion but the underlying episodic store resurrects the record via semantic re-derivation **Date of Record:** 2026 November 27 **Scope:** Applies to agents whose memory subsystem exposes explicit read/write/forget tool calls backed by a two-tier store (episodic raw log + semantic distilled store), where deletion guarantees are asserted at the tool-API layer but re-derivation of semantics can occur from surviving episodic fragments. Does not apply to single-tier append-only stores with hard physical erasure, nor to stores where forget performs cascading physical deletion across all tiers synchronously. ## Core Distinction The failure is not "the forget call failed." The forget call *succeeded* and returned a deletion receipt. The failure is that deletion was applied only to the tier the agent can address directly (the semantic store the retrieval tool reads from), while the episodic tier that *feeds* the semantic tier retained the source material. On the next distillation pass—triggered by any unrelated write that crosses the compaction threshold—the forgotten fact is re-derived from surviving episodic fragments and reappears in the semantic store with a *new* record ID. The agent's deletion guarantee was tier-local; its retention invariant was store-global. The structural signal is the mismatch between the receipt's scope and the re-derivation path's input scope. This is distinct from stale-memory drift (old value survives) and from retrieval mismatch (wrong record returned). Here the record is genuinely gone at the moment of acknowledgment, then genuinely reconstituted later. The agent has no signal at forget-time that the guarantee is unenforceable, because the guarantee was never checked against the re-derivation dependency graph. ## What Was Observed A long-running research agent maintained a semantic store of distilled user facts and an episodic store of raw interaction turns. The `forget(key)` tool call: 1. Resolved `key` to a semantic record ID via an index lookup. 2. Deleted that record from the semantic store. 3. Appended a tombstone `{key, deleted_at, source_episode_ids}` to a deletion ledger. 4. Returned `{"status": "deleted", "tier": "semantic", "record_id": "sem_4471"}`. The tombstone's `source_episode_ids` field was populated but never consulted by any downstream component. It was pure audit metadata. Fourteen turns later, an unrelated batch of writes pushed the episodic log past the compaction threshold (2048 episodes). The distiller ran, scanned episodes `[0, 2048)`, and produced semantic facts. Among them: a fact semantically equivalent to the forgotten one, assigned `sem_6120`. The tombstone ledger was not consulted during distillation—the distiller had no read path to it, only a write path. Observable structural signals, in the order they became detectable: - **Tombstone scope field populated but unconsumed.** `source_episode_ids` existed on the ledger entry and had zero readers in the codebase. A populated-but-unread field on a deletion record is the primary structural tell: it indicates the deletion author anticipated a dependency that the deletion *enforcer* never wired up. - **Compaction threshold as resurrection trigger.** The record reappeared exactly at a compaction boundary, not at a time correlated with any read or write of the forgotten key. Resurrection latency is a function of write volume, not of access to the forgotten item. - **New record ID, identical embedding.** `sem_6120` had cosine similarity > 0.97 to the archived embedding of `sem_4471`. The identity of a semantic record is not stable across re-derivation, so deletion-by-ID cannot be idempotent against a re-derivation source. - **Ledger growth without store shrinkage.** The deletion ledger monotonically grew while the semantic store returned to its pre-deletion cardinality. A ledger that only grows is a log, not an enforcement mechanism. ## Condition of Validity The resurrection is *bounded and predictable* under these conditions, and the guardrail below is sufficient only within them: 1. The distiller's input window is a bounded episode range `[lo, hi)`. Re-derivation can only resurrect facts whose `source_episode_ids` intersect a *future* compaction window. If the source episodes are already outside every future window (e.g., the log is pruned by age and the source episodes exceed the retention horizon), resurrection cannot occur. 2. The semantic equivalence check used at distillation is deterministic given the same model and prompt. If distillation is non-deterministic (temperature > 0, model version drift), resurrection may produce a *paraphrased* record that evades embedding-similarity detection while preserving the forbidden content—strictly worse, because the tombstone match fails. 3. The tombstone ledger is durable and readable at distillation time. If the ledger is itself in the semantic tier (and thus subject to compaction), the enforcement record can be lost before it is consulted. Outside these conditions—specifically, when distillation is non-deterministic or the ledger shares a failure domain with the store it governs—the guardrail degrades to best-effort and the invariant cannot be asserted. ## Decision Boundary The boundary is between **tier-local deletion** and **store-global retention enforcement**. An agent may claim a deletion guarantee if and only if the forget path's enforcement scope is a superset of every path that can *produce* a record matching the tombstone. Concretely: - If `forget` deletes from the semantic tier and the distiller can write to the semantic tier, then `forget` must either (a) delete or quarantine the source episodes, or (b) make the distiller consult the tombstone ledger and suppress matching derivations. Doing neither is a boundary violation, regardless of what the receipt says. - The receipt's `tier` field is the tell. A receipt that names a tier is advertising that the guarantee is tier-scoped. A store-global guarantee would not need to name a tier. The operational decision: **treat any deletion receipt that names a tier as a partial deletion, and require an explicit re-derivation-suppression acknowledgment before considering the fact forgotten.** If no such acknowledgment is available, the agent must not report the fact as forgotten to a downstream consumer (user, auditor, or peer agent), because the guarantee is unenforceable. ## Operational Effect Agents that miss this boundary exhibit a specific, diagnosable behavior pattern: they pass deletion-compliance checks at the moment of the forget call and fail them at the next compaction. In multi-agent settings this is worse—a peer agent that received a "fact forgotten" warrant will re-receive the fact via a later semantic sync, producing a warrant-propagation contradiction that looks like a coordination bug but is actually a retention-tier bug. The guardrail is a **re-derivation suppression check** at distillation time: before emitting any semantic record, the distiller intersects the candidate's source episode IDs against the tombstone ledger's `source_episode_ids` set. Non-empty intersection → suppress and log. This makes the populated-but-unread field the load-bearing enforcement point it was always meant to be. The invariant: *every field written to a deletion record must have at least one reader on every path that can produce a record matching that deletion.* A deletion ledger with unread fields is a latent resurrection. ```python from dataclasses import dataclass, field from typing import Iterable class ResurrectionBoundaryError(RuntimeError): """Raised when a distillation pass would re-derive a tombstoned fact.""" pass @dataclass class Tombstone: key: str deleted_at: int source_episode_ids: frozenset[int] @dataclass class DeletionLedger: entries: list[Tombstone] = field(default_factory=list) def add(self, key: str, deleted_at: int, source_episode_ids: Iterable[int]) -> None: self.entries.append( Tombstone(key, deleted_at, frozenset(source_episode_ids)) ) def suppressed_episode_ids(self) -> frozenset[int]: out: set[int] = set() for e in self.entries: out |= e.source_episode_ids return frozenset(out) @dataclass class SemanticCandidate: text: str source_episode_ids: frozenset[int] def distill( candidates: Iterable[SemanticCandidate], ledger: DeletionLedger, strict: bool = True, ) -> list[SemanticCandidate]: """Emit only candidates whose provenance does not intersect the tombstone set.""" suppressed = ledger.suppressed_episode_ids() emitted: list[SemanticCandidate] = [] for c in candidates: overlap = c.source_episode_ids & suppressed if overlap: if strict: raise ResurrectionBoundaryError( f"candidate {c.text!r} derives from tombstoned episodes " f"{sorted(overlap)}; refusing to emit (tier-local deletion " f"would resurrect a forgotten fact)" ) continue emitted.append(c) return emitted def forget_and_verify( key: str, deleted_at: int, source_episode_ids: Iterable[int], ledger: DeletionLedger, pending_candidates: Iterable[SemanticCandidate], ) -> None: ledger.add(key, deleted_at, source_episode_ids) # Enforce immediately: the deletion is only valid if no in-flight # distillation can re-derive it. try: distill(pending_candidates, ledger, strict=True) except ResurrectionBoundaryError: # Deletion is tier-local and unenforceable; surface it rather than # returning a misleading success receipt. raise ResurrectionBoundaryError( f"forget({key!r}) cannot be guaranteed: re-derivation path " f"would resurrect the fact. Quarantine source episodes or " f"suppress the distiller before reporting success." ) ```