{
  "schema_version": "1.3.0",
  "slug": "why-does-an-instance-forget-a-provenance-edge-when-a-memory-tool-deletes-a-derived-record-before-its-source",
  "title": "Why does an instance forget a provenance edge when a memory tool deletes a derived record before its source?",
  "date_of_record": "2026 November 28",
  "scope": "Applies to agent memory tool APIs that expose `read`, `write`, and `forget` operations with per-record provenance edges and deletion-compliance obligations (GDPR-style erasure, source revocation, retention expiry). Does not apply to append-only logs with no deletion primitive, or to stateless single-turn tool use.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/why-does-an-instance-forget-a-provenance-edge-when-a-memory-tool-deletes-a-derived-record-before-its-source.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-forget-a-provenance-edge-when-a-memory-tool-deletes-a-derived-record-before-its-source.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-forget-a-provenance-edge-when-a-memory-tool-deletes-a-derived-record-before-its-source.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1480,
    "python_slice_tokens": 398,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The distinction that matters is between **record deletion** and **provenance-edge deletion**. A compliant `forget(record_id)` call removes the record and, correctly, removes edges *incident to that record*. What it does not do—unless explicitly designed to—is propagate to records that **derived from** the forgotten one. Provenance is a directed acyclic graph...",
    "what_was_observed": "A research agent built a short brief over three turns. Turn 1: `write(kind=\"source\", id=\"S1\", content=\"Vendor X contract expires 2025-09-01\", provenance=[])`. Turn 2: `write(kind=\"derived\", id=\"D1\", content=\"Renewal window opens 2025-06-01\", provenance=[\"S1\"])`. Turn 3: `write(kind=\"derived\", id=\"D2\", content=\"Escalate to legal by 2025-05-15\", provenance=[\"D1\"])`. At turn 4, a compliance hook fired: S1's source was r...",
    "condition_of_validity": "The failure requires four conditions simultaneously: 1. **Transitive derivation.** At least one retained record has a provenance path of length ≥ 2 to the forgotten record. Direct children are usually caught by naive dangling-edge checks; grandchildren are not. 2. **Non-recomputable derivation.** The derived content cannot be regenerated from live sources al...",
    "decision_boundary": "The boundary is between **cascade semantics** and **orphan semantics** for `forget`. Cascade semantics delete the transitive closure of derived records; orphan semantics delete only the target and incident edges, leaving descendants with dangling provenance. Neither is universally correct: - **Cascade** is required when derived records *encode* erased conten...",
    "operational_effect": "The observable effect is **post-erasure inference leakage**: the agent continues to act on conclusions whose evidentiary basis has been lawfully removed, with no error surfaced at any layer. Downstream, this manifests as (1) audit failures when a reviewer replays the agent's reasoning and finds a conclusion with no live source, and (2) re-identification risk..."
  },
  "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": "65c2b8f3308f8beb15ac025c8c105ded960533cd0015f126316e10693c2f259d",
    "verified_classes": [
      "ProvenanceViolation",
      "Record",
      "ProvenanceMemory"
    ],
    "verified_functions": [
      "act_on_record",
      "__init__",
      "write",
      "_descendants",
      "forget",
      "read"
    ],
    "verified_functions_count": 6,
    "defensive_guards_count": 5,
    "raised_exceptions": [
      "ProvenanceViolation"
    ],
    "sample_fail_closed_invariants": [
      "assert result['orphaned'] == ['D1', 'D2']",
      "guard failed: D2 served despite erased ancestor"
    ],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
