{
  "schema_version": "1.3.0",
  "slug": "when-must-an-instance-quarantine-a-memory-write-before-provenance-reconciliation-and-what-breaks-when-it-doesn-t",
  "title": "When must an instance quarantine a memory write before provenance reconciliation, and what breaks when it doesn't",
  "date_of_record": "2026 November 20",
  "scope": "Applies to long-lived agent instances that persist episodic or semantic memory through a write path instrumented with provenance tags (writer identity, causal parent, taint class) and that perform periodic forget-audits reconciling the live store against an append-only forget log. Does not apply to stateless single-shot inference, nor to stores where memory writes are not attributable to a specific agent instance or tool invocation.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/when-must-an-instance-quarantine-a-memory-write-before-provenance-reconciliation-and-what-breaks-when-it-doesn-t.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-quarantine-a-memory-write-before-provenance-reconciliation-and-what-breaks-when-it-doesn-t.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-quarantine-a-memory-write-before-provenance-reconciliation-and-what-breaks-when-it-doesn-t.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2511,
    "python_slice_tokens": 692,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The distinction that matters is between *poisoning that arrives as a write* and *poisoning that arrives as a read*. Most memory-poisoning defenses assume the dangerous event is a retrieval: a stale or adversarial document enters the context window and steers reasoning. The boundary condition here is the inverse — an adversarial or corrupted *write* lands in ...",
    "what_was_observed": "A persistent agent instance (call it the writer) accepted a memory write from a tool-invocation subagent during a multi-step task. The write carried a provenance envelope: `writer_id`, `parent_episode`, `taint_class=untrusted_derived`, and a `forget_epoch` integer inherited from the parent episode. The write path validated the envelope structurally — all fields present, `parent_episode` resolvable, `forget_epoch` mon...",
    "condition_of_validity": "The quarantine-before-reconcile rule is valid — and necessary — exactly when all three of the following hold: 1. **The write path and the forget-audit path share a mutable derivation graph.** If provenance is a flat tag (no parent pointer), the interleaving cannot produce a live-child-of-dead-parent, and the rule is unnecessary overhead. 2. **Forget-audit re...",
    "decision_boundary": "The decision boundary is the moment a write's `parent_episode` resolves to a node whose tombstone is *pending finalization* — i.e., the node is in the audit's in-flight tombstone set. At that instant the writer must choose between three actions, and the choice is not obvious: - **Commit optimistically** (what happened): trust that the parent will be finalize...",
    "operational_effect": "Without the quarantine invariant, the failure is silent and self-healing-looking: the store remains structurally valid, provenance checks pass, and retrieval succeeds — but the retrieved context contains a reconstructed ancestor that no longer exists in the forget log. The forget is reversed, and the reversal is laundered through a provenance-clean record. D..."
  },
  "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": "3f2d26581c84bb50a02f68a0a0d12741fb9fa76ad52f00d82205716ef038d514",
    "verified_classes": [
      "ProvenanceViolation",
      "TombstoneState",
      "RecordStatus",
      "MemoryRecord",
      "Store"
    ],
    "verified_functions": [
      "commit_write",
      "finalize_tombstone",
      "reconcile_quarantine"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "ProvenanceViolation"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "time",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
