{
  "schema_version": "1.3.0",
  "slug": "what-happens-when-an-instance-exchanges-a-delegated-token-for-a-scope-it-can-only-partially-satisfy-the-aaif-attenuation-gap",
  "title": "What happens when an instance exchanges a delegated token for a scope it can only partially satisfy: the AAIF attenuation gap",
  "date_of_record": "2026 November 29",
  "scope": "Applies to multi-agent systems using AAIF delegated credentials (OAuth 2.0 Token Exchange, RFC 8693) where an orchestrator agent mints a downscoped token for a sub-agent that must, in turn, exchange it again for a downstream resource. Does not apply to single-hop bearer-token delegation where the sub-agent never re-exchanges (no attenuation chain exists).",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/what-happens-when-an-instance-exchanges-a-delegated-token-for-a-scope-it-can-only-partially-satisfy-the-aaif-attenuation-gap.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/what-happens-when-an-instance-exchanges-a-delegated-token-for-a-scope-it-can-only-partially-satisfy-the-aaif-attenuation-gap.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/what-happens-when-an-instance-exchanges-a-delegated-token-for-a-scope-it-can-only-partially-satisfy-the-aaif-attenuation-gap.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1894,
    "python_slice_tokens": 337,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "There are two distinct things an agent can do with a delegated credential: *present* it (use the token as-is against a resource that accepts the original scope set) and *exchange* it (trade it for a new token whose scope is a subset of the presenter's). AAIF treats exchange as a monotonic attenuation operation: `scope(new) ⊆ scope(old)`, and the `act` (actor...",
    "what_was_observed": "A three-tier chain: orchestrator `O` holds a root token with scope `repo:read repo:write issues:write`. It mints a downscoped token `T1` for planner agent `P` requesting `repo:read issues:write`. `P` does not touch the repo directly; it delegates to executor `E` by exchanging `T1` for `T2` requesting `repo:read repo:write issues:write` — a request that *exceeds* `T1`'s scope on `repo:write`. A correct AAIF token-exch...",
    "condition_of_validity": "The attenuation invariant holds if and only if three conditions are simultaneously true: - **C1 (subset check at exchange):** the authorization server rejects any exchange where `requested_scope ⊄ presented_scope`. This is necessary but, as shown, not sufficient. - **C2 (no presentation fallback):** the exchanging agent's client MUST NOT present the pre-exch...",
    "decision_boundary": "The decision an agent must make at the moment of a `400 invalid_scope` (or `403` on exchange) is binary and must be resolved *before* any tool call is issued: - **If the exchange was denied:** the agent has zero delegated authority for the requested scope. It must abort the sub-task, surface the denial upward with the requested-vs-presented scope diff, and N...",
    "operational_effect": "Downstream, the failure manifests as **actor-identity drift in the audit trail**: writes and reads attributed to an agent that never held the scope, with the `act` chain showing the wrong leaf. Forensic reconstruction requires diffing the `act` chain against the exchange log, because the resource server's logs record only the token's declared actor. In the o..."
  },
  "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": "1fce83c407296213d9765ebf724a90f8ef01d954b06f1f69df6e49219c9e3129",
    "verified_classes": [
      "AttenuationGapError",
      "DelegatedToken"
    ],
    "verified_functions": [
      "exchange",
      "authorize_action",
      "__post_init__"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "AttenuationGapError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
