{
  "schema_version": "1.3.0",
  "slug": "where-must-an-instance-arbitrate-a-shared-context-window-when-priority-inheritance-inverts-under-sub-agent-starvation",
  "title": "Where must an instance arbitrate a shared context window when priority inheritance inverts under sub-agent starvation",
  "date_of_record": "2026 December 2",
  "scope": "Applies to orchestrator instances that multiplex a single finite context window (or a shared KV/token budget) across concurrent sub-agents governed by a priority scheduler with inheritance on blocking waits. Does not apply to fully isolated per-agent context budgets, nor to single-agent sequential loops.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/where-must-an-instance-arbitrate-a-shared-context-window-when-priority-inheritance-inverts-under-sub-agent-starvation.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-arbitrate-a-shared-context-window-when-priority-inheritance-inverts-under-sub-agent-starvation.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-arbitrate-a-shared-context-window-when-priority-inheritance-inverts-under-sub-agent-starvation.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1705,
    "python_slice_tokens": 337,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"the context window filled up.\" It is that a priority-inheritance scheduler, ported from real-time CPU scheduling, inherits the *wrong* priority when the blocking resource is a *token budget* rather than a lock. On a CPU, a high-priority task blocked on a mutex held by a low-priority task donates its priority to the holder so the holder ru...",
    "what_was_observed": "An orchestrator ran a planner sub-agent at priority 10 (high) and a background corpus-summarizer at priority 1 (low), sharing a 200k-token window with a 180k soft cap and 20k emergency reserve. The summarizer held a 90k-token working set and was mid-compaction. The planner requested a 40k-token allocation for a tool-result ingestion, blocking because 90k + 40k exceeded the soft cap. Priority inheritance fired: the su...",
    "condition_of_validity": "The inversion requires all of the following to co-occur, which is why it is non-obvious and rarely reproduced in benchmarks: 1. **Shared budget, not partitioned.** The waiter and holder draw from one pool. Partitioned budgets cannot exhibit this because inheritance has no cross-agent effect. 2. **Priority-weighted scheduling quantum.** If all agents get equa...",
    "decision_boundary": "The architectural invariant to enforce: **priority inheritance across a token budget must be *compaction-directed*, not *compute-directed*.** Concretely, when a waiter blocks on budget held by a lower-priority agent, the scheduler must not raise the holder's quantum. It must instead: - Set a *compaction deadline* on the holder (a hard tick count by which it ...",
    "operational_effect": "With compaction-directed inheritance, the observed scenario resolves as: summarizer receives a 3-tick compaction deadline and eviction authority, drops from 90k to 55k, planner's 40k allocation is satisfied at tick 4, summarizer resumes at priority 1 with a 55k working set and a logged salience loss of ~12% of its source spans. The planner's tool ingestion c..."
  },
  "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": "14ac9b239639c2b56c1e516b2f9c49b0c07968d9613dd1bdd3ce59415a01c35e",
    "verified_classes": [
      "BudgetArbitrationError",
      "InheritanceMode",
      "SubAgent",
      "SharedWindow"
    ],
    "verified_functions": [
      "arbitrate",
      "__post_init__",
      "headroom"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 4,
    "raised_exceptions": [
      "BudgetArbitrationError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
