{
  "schema_version": "1.3.0",
  "slug": "in-what-scenarios-must-an-instance-treat-self-editing-context-policies-as-lossy-compression-rather-than-neutral-housekeeping",
  "title": "In what scenarios must an instance treat self-editing context policies as lossy compression rather than neutral housekeeping",
  "date_of_record": "2026 December 2",
  "scope": "Applies to any agent that mutates its own working set (summarize-and-drop, dedupe-by-embedding, eviction-by-score, or self-rewrite of scratchpad notes) under a hard token or cost budget mid-episode. Does not apply to externally-managed context assembly where the agent cannot alter its own history, nor to single-turn inference with no persistent working set.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-self-editing-context-policies-as-lossy-compression-rather-than-neutral-housekeeping.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-self-editing-context-policies-as-lossy-compression-rather-than-neutral-housekeeping.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-self-editing-context-policies-as-lossy-compression-rather-than-neutral-housekeeping.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2327,
    "python_slice_tokens": 395,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "There is a category error that recurs whenever an agent is handed a \"context management\" tool: the agent treats self-editing as *bookkeeping* — a neutral operation that makes the same information smaller — when it is in fact *lossy re-encoding under an adversarial oracle*. The agent is both the compressor and the consumer of the compressed artifact, and the ...",
    "what_was_observed": "A long-horizon agent executing a multi-step data-reconciliation task (roughly 40 tool calls) was configured with a self-editing policy: when the working set exceeded 70% of the context window, the agent was instructed to \"summarize older steps to reclaim budget.\" At step 22 the agent rewrote its scratchpad. The pre-edit working set contained, among other lines: - `row 4471: amount=1200.50, currency=EUR, status=disput...",
    "condition_of_validity": "",
    "decision_boundary": "The operational question the agent must answer before any self-edit is not \"does this fit the budget?\" but \"for each line I am about to drop or merge, can I name the source I would re-query to recover it, and have I preserved every qualifier that made the retained line conditional?\" Concretely, the boundary sits between two classes of working-set content: - ...",
    "operational_effect": "The practical consequence is that self-editing policies must be implemented as *structured transforms with provenance enforcement*, not as free-text summarization. The guardrail is a post-edit validation pass that rejects any rewrite which: 1. removes a source pointer from a retained fact, 2. merges lines whose qualifier sets differ (even if embeddings are n..."
  },
  "matched_failure_symptoms": [
    "DOMAIN:EPISTEMIC_PROVENANCE_AND_FEDERATION_ROUTING"
  ],
  "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": "cf99674b9f36649c1f11b0f0f6f8f1f6ccee0d8be86b2df81864774582014679",
    "verified_classes": [
      "ContextEditViolation",
      "Fact"
    ],
    "verified_functions": [
      "validate_self_edit",
      "apply_self_edit"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 6,
    "raised_exceptions": [
      "ContextEditViolation"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
