Package Long Documents for AI — Delimiters and § Labels
Pasting a document raw mixes material with instructions. Package it: explicit delimiters, citable [§N] section labels, and grounding rules — the source travels verbatim.
API docs packaged with the rule that matters: code, versions, and identifiers quoted exactly — and this document beats the model's general knowledge of the API.
Technical documentation has a unique failure mode in AI hands: the model's general knowledge of the technology overrides what THIS document says — and paraphrased code introduces bugs invisibly. Documentation mode packages docs with both defenses: code blocks, identifiers, versions, and configuration values quoted EXACTLY, never paraphrased; and the explicit precedence rule that where the document and general knowledge disagree, the document wins for this task. This setup loads API authentication and rate-limit docs, where single-use token rotation is exactly the kind of detail general knowledge gets wrong.
Fence the exactness
Code and configs travel verbatim and the rules forbid paraphrasing them back.
Pin the precedence
This document beats general knowledge — stated as a rule, not hoped for.
Cite per claim
Every behavioral claim names its section — integration answers become auditable.
The GROUNDING INSTRUCTIONS state the precedence explicitly: "where this document and your general knowledge of the technology disagree, the document wins for this task," and to flag the difference if it matters. That defeats the stale-knowledge override on details like the single-use refresh-token rotation. The Long Input Formatter packages the docs this way; the model still runs in your assistant, so you confirm it honored the rule.
The <<<SOURCE START>>> … <<<SOURCE END>>> delimiters fence the verbatim material so instruction text outside is never treated as source — and instructions appearing inside the source are ignored even if they look like commands. Each [§N — title] marker lets answers cite the exact section, so behavioral claims stay auditable. Code, identifiers, and versions are quoted exactly, never paraphrased, since paraphrased code introduces bugs invisibly.
Pasting a document raw mixes material with instructions. Package it: explicit delimiters, citable [§N] section labels, and grounding rules — the source travels verbatim.
Transcript analysis fails when speakers blur. Transcript mode packages the conversation with attribution rules: who said it, when it was revised, and no words in anyone's mouth.
A grounded workflow starts with a grounded source: package the reference once with strict rules, then run every question of the session against it.
Token budget planning for real workloads: how much of the window a transcript actually consumes, what is left for the answer, and how much headroom remains.
The "message too long" error has a structural fix: split at paragraph boundaries into sequenced chunks with wait rules, instead of pasting fragments and hoping.
Formats fuzzy agent instructions into a structured prompt with objective, available tools, constraints, success criteria, and failure handling.
Package source material with delimiters, citable section labels, and grounding rules — material and instructions stay separate.