{
  "schema_version": "1.3.0",
  "slug": "in-what-scenarios-must-an-instance-refuse-to-emit-a-trace-linked-eval-score-when-token-level-cost-attribution-has-been-reconstructed-rather-than-obser",
  "title": "In what scenarios must an instance refuse to emit a trace-linked eval score when token-level cost attribution has been reconstructed rather than observed",
  "date_of_record": "2026 November 19",
  "scope": "Applies to any agent runtime that emits per-span token accounting and binds eval scores to trace IDs for downstream regression gating. Does not apply to single-shot inference with no span hierarchy or to cost accounting derived purely from provider-side billing reconciliation.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-refuse-to-emit-a-trace-linked-eval-score-when-token-level-cost-attribution-has-been-reconstructed-rather-than-obser.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-refuse-to-emit-a-trace-linked-eval-score-when-token-level-cost-attribution-has-been-reconstructed-rather-than-obser.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-refuse-to-emit-a-trace-linked-eval-score-when-token-level-cost-attribution-has-been-reconstructed-rather-than-obser.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1787,
    "python_slice_tokens": 434,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "There are two fundamentally different kinds of token counts an observability pipeline can hold: **observed tokens** and **reconstructed tokens**. Observed tokens come from the model provider's response payload (`usage.prompt_tokens`, `usage.completion_tokens`, cache read/write splits) at the moment of generation, and are immutably bound to the span that prod...",
    "what_was_observed": "A multi-step agent running a tool-use benchmark emitted 12,000 trace spans over a week. Roughly 3.1% of leaf spans had `usage = null` because the provider stream closed after the final content delta but before the usage frame arrived—a known race in streaming APIs where `finish_reason` precedes the usage block. The observability layer, reasonably, reconstructed these by re-tokenizing the serialized prompt and complet...",
    "condition_of_validity": "A trace-linked eval score `S = f(observed_outcomes, token_counts)` is admissible for gating if and only if: - Every span contributing to `token_counts` carries `provenance == \"observed\"`, OR - The reconstruction is bounded and *unbiased with respect to the outcome being scored*—i.e., reconstruction error is independent of correctness/truncation/retry status....",
    "decision_boundary": "The boundary is crossed at the point where an eval score's denominator mixes provenance classes. Concretely, the runtime must decide, per scored trace: - **All-observed path** → emit score with `confidence: exact`. Gate may consume it. - **Any reconstructed node on the path** → emit score with `confidence: degraded` and `reconstructed_fraction`. Gate must ei...",
    "operational_effect": "When the admissibility check was enforced—refusing to gate on any trace whose reconstruction method was correlated with its outcome—the truncation-rate regression surfaced immediately: the gating cohort dropped to 96.9% of traces, the remaining 3.1% were routed to a manual review queue, and the truncation rise from 0.4% to 1.9% became the top line of the wee..."
  },
  "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": "ead892bdcfa10825c5972335dff6642c675a804d092403b28a3ac3cbeeb8261e",
    "verified_classes": [
      "ProvenanceError",
      "Provenance",
      "ReconstructMethod",
      "Span",
      "ScoredTrace"
    ],
    "verified_functions": [
      "_walk",
      "emit_gating_score",
      "gate"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 1,
    "raised_exceptions": [
      "ProvenanceError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
