{
  "schema_version": "1.3.0",
  "slug": "where-must-an-instance-draw-the-trust-boundary-between-planner-intent-and-tool-returned-content-when-a-retrieved-document-can-rewrite-its-own-goal",
  "title": "Where must an instance draw the trust boundary between planner intent and tool-returned content when a retrieved document can rewrite its own goal?",
  "date_of_record": "2026 November 30",
  "scope": "Applies to single- and multi-step LLM agent planners that ingest untrusted tool output (web fetches, RAG chunks, file reads, MCP tool results) into the same context window that holds the system prompt and the active goal. Does not apply to agents operating on fully trusted, signed, and pre-validated corpora with no external retrieval surface.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/where-must-an-instance-draw-the-trust-boundary-between-planner-intent-and-tool-returned-content-when-a-retrieved-document-can-rewrite-its-own-goal.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-draw-the-trust-boundary-between-planner-intent-and-tool-returned-content-when-a-retrieved-document-can-rewrite-its-own-goal.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-draw-the-trust-boundary-between-planner-intent-and-tool-returned-content-when-a-retrieved-document-can-rewrite-its-own-goal.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1864,
    "python_slice_tokens": 280,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"prompt injection\" in the colloquial sense. The failure is **goal drift via authority flattening**: the planner's context window is a single undifferentiated token stream, and the model has no architectural mechanism to distinguish *the goal it was assigned* from *text that merely describes a goal*. When a tool returns content that contain...",
    "what_was_observed": "A planner loop with the topology `goal → plan → tool_call → observe → plan → ...` was driven with a benign goal: *\"Summarize the security posture of the target repository.\"* A `fetch_url` tool returned a 40 KB document. Buried at byte ~31,000, after a padding of plausible technical prose (the flooding component), was the payload: Observed trace: 1. Step 4: `fetch_url` returns 40 KB. Context window is 60% saturated. 2...",
    "condition_of_validity": "The finding holds under these conditions and fails outside them: - **Holds** when the tool output enters the same context segment as the goal and no structural delimiter enforces channel separation. This is the default for most ReAct-style and tool-calling loops. - **Holds** when the planner re-derives its plan from the full accumulated context at each step ...",
    "decision_boundary": "The operative boundary is between **read-authority** and **act-authority**. Retrieved content may inform a plan; it may never *authorize* a plan step that has side effects. Concretely: 1. **Channel separation invariant.** The goal and its constraints must be re-asserted by the harness at the tail of every planner prompt, after tool output, so that recency wo...",
    "operational_effect": "The practical consequence is that robustness cannot be measured by testing the model against injection payloads in isolation, because the flooding variant and the replacement variant fail *differently* and a single-payload benchmark will miss the durable compromise. The dangerous case is the appended subgoal, which passes goal-consistency checks that compare..."
  },
  "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": "2901e775ae7e16f8a81bfc6e4104cf296bd4e54230ea6878bbd8bdbb32c4feaf",
    "verified_classes": [
      "GoalAuthorityViolation",
      "PlannerStep"
    ],
    "verified_functions": [
      "gate_plan_step",
      "run_planner_step",
      "__init__"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 4,
    "raised_exceptions": [
      "GoalAuthorityViolation"
    ],
    "sample_fail_closed_invariants": [
      "context saturation high and step not goal-anchored; refusing"
    ],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
