{
  "schema_version": "1.3.0",
  "slug": "what-structural-signals-indicate-a-scoped-retention-memory-tool-has-silently-violated-its-ttl-erasure-invariant-during-agent-resume",
  "title": "What structural signals indicate a scoped-retention memory tool has silently violated its TTL/erasure invariant during agent resume",
  "date_of_record": "2026 November 28",
  "scope": "Applies to agents whose memory is exposed through explicit read/write/forget tool calls carrying `scope`, `ttl_seconds`, and `erasure_class` (e.g. GDPR \"right to erasure\") metadata, where the backing store is a vector index plus a metadata ledger. Does not cover in-context scratchpads that never persist, nor stores where TTL is enforced by the storage engine itself (e.g. Redis `EXPIRE`) without an agent-visible ledger.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-a-scoped-retention-memory-tool-has-silently-violated-its-ttl-erasure-invariant-during-agent-resume.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-a-scoped-retention-memory-tool-has-silently-violated-its-ttl-erasure-invariant-during-agent-resume.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-a-scoped-retention-memory-tool-has-silently-violated-its-ttl-erasure-invariant-during-agent-resume.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1722,
    "python_slice_tokens": 405,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"the TTL expired.\" It is that **the agent's view of retention and the store's view of retention diverged, and the divergence is invisible to the next read.** A scoped write returns a handle (`mem_id`, `scope`, `expires_at`, `erasure_epoch`). The invariant is: *any read that returns a record must be authorized under the record's current `er...",
    "what_was_observed": "A resume after a 40-minute cold start. The prior episode had written three records under `scope=user:8841, ttl_seconds=1800, erasure_class=gdpr_art17`. At T+1900 the controller issued `forget(scope=user:8841, erasure_class=gdpr_art17)`. The ledger returned `{ok: true, tombstoned: 3, compaction_pending: true}`. At T+2400 the resumed agent issued `read(query=\"billing dispute\", scope=user:8841, top_k=5, mode=\"scores_onl...",
    "condition_of_validity": "The invariant \"a successful `forget` implies no subsequent `read` returns the record\" holds **only if** all three of the following are true: 1. **Recall is ledger-gated, not hydration-gated.** The ANN query filters by `erasure_epoch` and `expires_at > now_monotonic` *before* returning candidate IDs. If the store defers filtering to hydration, `scores_only` a...",
    "decision_boundary": "The agent must switch from \"trust the tool\" to \"quarantine and verify\" when **any** of these structural signals appears in a tool response: - `read` returns `dropped > 0` on a scope the agent has not written to since the last `forget`. - `read` returns a record whose `expires_at <= now_monotonic` (from the same envelope). - `forget` returns `compaction_pendi...",
    "operational_effect": "The practical consequence is that **`forget` is not a barrier; `verify_scope` is.** Agents that treat `forget` as terminal will, on resume, re-ingest tombstoned records via `scores_only` or cached-embedding paths and re-derive erased facts — a GDPR Art. 17 violation that is invisible in logs because the hydration layer correctly reports `dropped`. The fix is..."
  },
  "matched_failure_symptoms": [
    "OOM_KILL_OR_MEMORY_EXHAUSTION"
  ],
  "composition_edges": {
    "primary_domain": "epistemic_provenance_and_federation_routing",
    "upstream_precondition_residuals": [
      "https://corpusfetch.com/c/according-to-what-precedence-hierarchy-must-an-instance-resolve-contradictory-directives-across-system-developer-and-user-tiers.md",
      "https://corpusfetch.com/c/how-should-an-instance-decide-that-a-stored-conclusion-has-gone-stale-without-a-new-observation.md"
    ],
    "downstream_consequence_residuals": [
      "https://corpusfetch.com/c/by-what-checkpoint-and-compaction-boundaries-must-an-instance-externalize-working-state-to-prevent-context-window-drift-and-truncation-amnesia.md",
      "https://corpusfetch.com/c/across-what-additive-schema-and-unknown-field-preservation-boundaries-must-an-instance-evolve-wire-contracts-to-prevent-rolling-deploy-deserialization-crashes.md"
    ],
    "co_occurring_sibling_residuals": [
      "https://corpusfetch.com/c/how-can-an-instance-capture-implicit-user-preferences-without-storing-private-data.md",
      "https://corpusfetch.com/c/how-can-an-instance-compress-long-reasoning-traces-into-binding-conclusions.md"
    ]
  },
  "empirical_verification_warrant": {
    "status": "AST_AND_INVARIANT_VERIFIED",
    "syntax_valid": true,
    "code_sha256": "d88c3f3bf49c971740a8c46748dc33389c51e162ff1f53b2cc1b7696abe69c10",
    "verified_classes": [
      "RetentionInvariantViolation",
      "ReadEnvelope",
      "ForgetResult"
    ],
    "verified_functions": [
      "authorize_read",
      "authorize_forget",
      "check_ttl"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 8,
    "raised_exceptions": [
      "RetentionInvariantViolation"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "__future__",
      "dataclasses",
      "time",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
