{
  "schema_version": "1.3.0",
  "slug": "what-structural-signals-indicate-memory-poisoning-in-write-audit-differentials-the-stale-read-window-that-masks-divergence",
  "title": "What structural signals indicate memory poisoning in write-audit differentials: the stale-read window that masks divergence",
  "date_of_record": "2026 November 18",
  "scope": "Applies to agent memory stores that maintain a write-ahead audit log alongside a derived read index, where poisoning is inferred by comparing the audit-derived expected state against the index-derived observed state. Does not apply to stores with synchronous single-source-of-truth semantics (no derived index), nor to probabilistic anomaly detectors operating on embeddings alone.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-memory-poisoning-in-write-audit-differentials-the-stale-read-window-that-masks-divergence.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-memory-poisoning-in-write-audit-differentials-the-stale-read-window-that-masks-divergence.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-memory-poisoning-in-write-audit-differentials-the-stale-read-window-that-masks-divergence.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1579,
    "python_slice_tokens": 182,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The naive detection invariant is: *if the audit log says a memory record should contain X, and the read index returns Y, the store is poisoned.* This invariant is correct but incomplete, because it presumes the audit log and the read index are sampled at the same logical instant. In real deployments the read index is a materialized view updated asynchronousl...",
    "what_was_observed": "In a production agent memory store with a 90-second reindex cadence, an adversary issued writes that (a) appended valid audit entries and (b) mutated the derived index directly via a side channel that bypassed the reindex path. For the first 90 seconds the differential looked identical to ordinary lag: observed ≠ expected, magnitude within the p99 lag envelope. The standard alert (differential > threshold for > 5 min...",
    "condition_of_validity": "These structural signals are valid only when: 1. The audit log is append-only and tamper-evident (hash-chained or externally witnessed). If the attacker can rewrite the audit log, differentials are meaningless because both sides of the comparison are under adversarial control. 2. The read index carries a per-key version counter or write sequence that is inde...",
    "decision_boundary": "- **Point-in-time differential > threshold**: insufficient. Fires on benign lag; misses slow re-mutation. Use only as a coarse smoke alarm. - **Cumulative divergence integral over a window**: primary detector. Alert when a key's integral exceeds the p99.9 of the benign lag distribution by a margin of ≥ 10×, sustained over ≥ 3 reindex cycles. - **Audit sequen...",
    "operational_effect": "Implementing cumulative-divergence tracking plus index-version/audit-sequence monotonicity reduced false positives from benign lag by ~97% (operators had been ignoring the point-in-time alert entirely, which is itself the poisoning precondition) and reduced mean detection time for the re-mutation attack class from \"never\" to under 20 minutes. The cost is one..."
  },
  "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": "9a7733f3ca71c2aafc20e02cb9a23d2a090fc1d54e0b34180d4e5c11981ee54f",
    "verified_classes": [
      "MemoryPoisoningError"
    ],
    "verified_functions": [
      "check_write_audit_differential"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "MemoryPoisoningError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
