The position
Where an item sits in the window changes whether the model uses it. That effect is real, measured, and different for every model family, task shape and context length. A specification that hard-coded an order would be right for one deployment and wrong for the next, and nobody would be able to tell which.
So CWA takes no position on where items go. It requires only that placement be a profile: versioned, per route, evaluated against that route's tasks, and recorded in every trace. Every placement hint on this site, including the policy-first-chat default, is a tested default for one route, not a claim about models in general.
What the research measures
Serial-position effects are measured, not folklore. Liu et al. tested models on multi-document question answering and key-value retrieval and found a U-shaped curve: accuracy is highest when the relevant passage sits at the beginning of the context (primacy) or at the end (recency), and drops when it sits in the middle. [1]
Later long-context work finds the effect persists and varies. RULER evaluated 17 models and found almost all lose accuracy as context length grows, despite near-perfect scores on simple needle retrieval. [2] NoLiMa finds models do well at the edges of the window when the task is a literal match, but when the answer needs an associative hop, longer contexts pull performance down even at the edges. [3]
Position, length, model family and task interact. No single number describes it, and no single order is safe to bake into a spec.
Provider guidance, by generation
Provider guidance differs and is written per model generation. Both recommendations below are right for their workloads; neither is right for the other's.
Long inputs go early and clearly delimited; instructions and the query follow. The document-analysis profile is this shape.
Repeat instructions before and after the long material; if stated once, above it. Notes that the family needed prompt migration. The long-context-reinforced profile is this shape.
Profile format
A profile is a small YAML file. It carries an id and version, the route it serves, the model family it was evaluated on, an ordered placement with a wrapper rule per slot, and the evaluation that justified promoting it (R-19). A slot may appear twice; the second occurrence is a reinforcement, rendered again. Omitted slots are not rendered.
Profile explorer
Pick two profiles. Each is drawn as the window it produces, in order, coloured by plane. The diff lists what moved. Export either as YAML.
{{ a.principle }}
{{ b.principle }}
Highlighted rows are slots whose position differs between A and B. ↺ marks a reinforcement: the slot has already appeared and is rendered again.
Evaluating a profile
A profile is promoted by evidence from its own route, not by argument. The protocol is short and the trace makes it cheap: because assembly is deterministic (R-23), two profiles applied to the same items differ only in placement, so any change in outcome is attributable to placement alone.
- Liu, Lin, Hewitt, Paranjape, Bevilacqua, Petroni, Liang. “Lost in the Middle: How Language Models Use Long Contexts.” arXiv 2307.03172 (2023); TACL 2024. arxiv.org/abs/2307.03172
- Hsieh et al. “RULER: What’s the Real Context Size of Your Long-Context Language Models?” arXiv 2404.06654 (2024). arxiv.org/abs/2404.06654
- Modarressi et al. “NoLiMa: Long-Context Evaluation Beyond Literal Matching.” arXiv 2502.05167 (2025). arxiv.org/abs/2502.05167
- Anthropic. “Long context prompting tips.” docs.anthropic.com
- OpenAI. “GPT-4.1 Prompting Guide.” developers.openai.com