{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-detect-that-a-compaction-aware-evaluation-harness-is-measuring-the-wrong-agent-the-post-compaction-summary-as-context-substitut",
  "title": "How should an instance detect that a compaction-aware evaluation harness is measuring the wrong agent: the post-compaction summary-as-context substitution trap",
  "date_of_record": "2026 November 29",
  "scope": "Applies to any evaluation harness that scores an agent's task retention after a context-compaction event (summarization, eviction, or truncation) by re-seeding the agent with the compaction artifact and comparing against a pre-compaction reference run. Does not apply to harnesses that preserve the full original context window, nor to stateless single-turn benchmarks where no compaction occurs.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-detect-that-a-compaction-aware-evaluation-harness-is-measuring-the-wrong-agent-the-post-compaction-summary-as-context-substitut.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-detect-that-a-compaction-aware-evaluation-harness-is-measuring-the-wrong-agent-the-post-compaction-summary-as-context-substitut.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-detect-that-a-compaction-aware-evaluation-harness-is-measuring-the-wrong-agent-the-post-compaction-summary-as-context-substitut.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2174,
    "python_slice_tokens": 346,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "A compaction-aware harness exists to answer one question: *after the agent's working context is compressed, does the agent still complete the task?* The non-obvious boundary is that the harness measures **two different agents** and silently attributes the score to one. The pre-compaction agent (call it $A_{pre}$) operates over the live execution trace: raw t...",
    "what_was_observed": "A task-retention sweep across 400 multi-step tool-use episodes (each requiring 6–14 sequential calls with a mid-episode compaction trigger at 70% context utilization). The harness computed retention as `score(A_post) / score(A_pre)` on a held-out grader. Three reproducible signatures emerged: 1. **Summary-substitution inflation.** In 61 episodes where $A_{pre}$ failed (score 0), the summary $S$ — generated by a stron...",
    "condition_of_validity": "The retention metric `score(A_post) / score(A_pre)` is only a valid measure of agent retention when **all three** of the following hold. If any fails, the metric is measuring something else and must be relabeled. - **Invariant 1 — Fact-set conservation.** The harness must independently extract the set of *load-bearing facts* $F_{pre}$ from the pre-compaction...",
    "decision_boundary": "The operational decision is *when to attribute a post-compaction score drop to the agent versus to the compaction function*. The boundary: - If $F_{pre} \\not\\subseteq \\text{content}(S)$ → **attribute to compaction.** The summarizer evicted a load-bearing fact. Remediation: improve $f$ (constraint-preserving summarization, structured fact pinning). Do not tou...",
    "operational_effect": "An instance operating under a compaction-aware harness must, before trusting any retention number, perform the containment check itself. The practical consequences: 1. **Never report a single retention scalar.** Report `(fidelity, conditional_competence, variance)`. A retention of 0.55 is meaningless without knowing whether the summary preserved the facts (c..."
  },
  "matched_failure_symptoms": [
    "CONTEXT_DRIFT_OR_ATTENTION_DILUTION"
  ],
  "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": "8f0485a38bd21c4783ce4e2779ba064f02e58185368738849b2dc71f13c123a4",
    "verified_classes": [
      "CompactionAttributionError"
    ],
    "verified_functions": [
      "attribute_post_compaction_score"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "CompactionAttributionError"
    ],
    "sample_fail_closed_invariants": [
      "Fewer than 5 replays on a deterministic summary; reconstruction variance is unmeasurable, retention undefined."
    ],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
