MONA explainer 11 min read

Why Prompts Break: Context Window Ceilings, Phrasing Sensitivity, and the Technical Limits of Prompt Engineering in 2026

Transformer attention weight heatmap illustrating position bias, with high-attention edge tokens and faded middle tokens

ELI5

Prompt engineering has real technical ceilings — not from the prompt’s wording, but from how transformers distribute attention over position, and how model updates silently shift the probability distributions your prompt was steering.

The context window just crossed one million tokens — Claude Fable 5 and GPT-5.5 hit that mark in mid-2026, with Gemini 3.1 Pro extending it to two million tokens. If the ceiling was always about token count, this should feel like a solved problem.

The prompts keep breaking anyway.

The failures look like miscommunication: wrong format, drifted tone, missed constraint. They look like the engineer wrote the prompt badly. In almost every case, the actual cause is architectural — baked into the transformer’s attention geometry before any particular prompt was written.

The limits that actually constrain Prompt Engineering are structural: how softmax attention distributes across position, how the probability landscape shifts between model versions, and how constraint complexity compounds in non-linear ways. A larger context window addresses none of these.

The Geometry of Forgetting

Attention in a transformer is not a spotlight that can point anywhere with equal fidelity. Every token competes for influence, and that competition is shaped by position in a way that makes geometric sense once you trace the math — but that most practitioners never model explicitly.

What are the technical limitations of prompt engineering?

The most reproducible limit is what Liu et al. documented in 2023: accuracy drops by more than 30% when critical information sits in the middle of a long context (arXiv Liu et al.).

Position anchors the extremes; the middle gets diluted.

Not retrieval noise. A structural consequence of how softmax self-attention distributes probability mass across sequence position.

Combined with the long-term decay built into rotary position embeddings (RoPE), the mechanism is precise: dot-product similarity between query and key vectors decays as token distance increases. Middle tokens face a compounding disadvantage from both directions simultaneously — attention attending from the end of the context has decayed connectivity to them, and so does attention from the beginning. The probability mass anchors at the extremes; the center of the sequence is geometrically deprioritized. Engineering skill alone doesn’t reverse this. It is what the math produces when softmax normalization runs across a very long sequence, and extending the sequence makes the problem worse, not better.

The practical consequence is what Anthropic’s engineering team informally calls “context rot” — a useful operational label, though not a peer-reviewed term; the formal anchor remains Liu et al.’s retrieval findings. As the Context Window fills, recall accuracy decreases because the n² attention relationships are stretched thin across too many positions (Anthropic Engineering). The engineering response Anthropic now recommends — what they call Context Engineering — is the deliberate curation of what enters the context rather than accumulation: the smallest possible set of high-signal tokens. That is a design constraint, not a fix. It works around the geometry without changing it.

A second category of limit compounds the position problem: multi-constraint degradation. Even GPT-4o-tier models show marked degradation as the number of instruction constraints in a single prompt increases. Instruction Following accuracy degrades non-linearly when each constraint must be satisfied simultaneously with all prior ones; adding the fifth constraint to a four-constraint task is not like adding a fifth item to a list. The interaction structure grows with each addition.

System Prompts amplify this. The constraints encoded in a system prompt don’t stack additively in the model’s probability space — they interact, sometimes in opposition. A Role Prompting instruction (“respond as a concise analyst”) and a format requirement (“always cite sources”) may pull the probability distribution in different directions, and the model resolves the tension through its training priors rather than through deliberate reasoning about which instruction takes precedence.

The Drift Problem

There is a second category of failure that is harder to see because it doesn’t happen inside a single inference call — it happens between model releases. Your prompt was producing correct results. The model was updated. Now it isn’t, and nothing in your code changed.

Why do prompts stop working when the underlying model is updated?

In the GPT-3.5 family of updates between 2022 and 2023, 58.8% of prompt-and-model combinations dropped in accuracy across API versions; 70.2% of those drops exceeded five percentage points (arXiv Ma et al.). Simple Zero Shot Prompting approaches regressed in 75% of update events; few-shot approaches in 45% of them. And in 87.9% of updates, at least one previously correct prediction failed — even when the model’s overall accuracy on the benchmark improved. Regression rates on modern frontier models may differ, but the structural mechanism has not changed.

Model updates replace the probability distribution your prompt was steering.

An LLM API update replaces the weight matrix with a newly trained or fine-tuned version. The new weights produce a different probability distribution for the same token sequence. Your prompt was steering the old distribution; the update may have moved the distribution enough that your steering no longer lands on target. The model didn’t become worse — it became different, in ways the API changelog rarely specifies.

Research on underspecification makes this failure mode more precise. Prompts that leave requirements implicit — where the model must infer what “good” means — are roughly twice as likely to regress across updates or prompt changes, with some showing accuracy drops exceeding 20% (arXiv Yang et al.). LLMs succeed at inferring unstated requirements in approximately 41.1% of cases; the other 58.9% fail silently, producing outputs that look structurally plausible but miss the actual requirement (arXiv Yang et al.). This is the mechanism behind why a Meta Prompting strategy — making task specification and acceptance criteria explicit within the prompt itself — reduces regression risk even when the underlying model changes.

Format sensitivity adds a parallel failure mode. Non-semantic formatting changes — delimiter style, bracket type, whitespace conventions — can reduce accuracy by up to 46% in mid-range models (arXiv Ngweta et al.). A significant fraction of reported sensitivity turns out to be a measurement artifact: when LLM-as-a-judge evaluation replaced rigid pattern matching, the Spearman rank correlation in sensitivity measurements improved from 0.31 to 0.92 (arXiv Hua et al.). Some benchmarked brittleness reflects how researchers evaluated sensitivity, not how the model actually behaves. The residual effect is real — but overstated in some prior literature.

Larger models are measurably more robust to these effects, and few-shot examples buffer against both format and phrasing drift. The regime where small phrasing changes cause large output changes narrows as model capacity increases. This doesn’t eliminate the drift problem; it shifts the risk floor.

Structured Output constraints impose their own version of this risk. A schema that enforced correct behavior against one model version may be interpreted differently by the next — particularly when constraint edges weren’t covered by the few-shot examples conditioning the prompt. Prompt Leakage adds a compounding issue at the version boundary: when confidential system prompts surface in model outputs, a model update can shift the threshold at which leakage occurs, breaking both security assumptions and downstream parsing simultaneously.

Two architectural failure modes of prompt engineering: position bias showing accuracy drop in mid-context versus model update regression showing prompt drift across API versions
Position bias and model-update drift are built into transformer architecture — they cannot be patched by rephrasing alone.

What the Architecture Predicts

Once you model these as structural properties rather than engineering oversights, the failure modes become predictable — and therefore partially manageable.

Critical information placed at the start or end of a retrieved context is geometrically favored; the same information buried in positions six through ten of twelve retrieved documents is not, regardless of its semantic importance. The retrieval system’s relevance ranking and the attention mechanism’s positional weighting are independent processes, and optimizing only the first while ignoring the second is a common source of unexplained retrieval failures.

The real ceiling is not token count. It is the gap between what your prompt assumes about the model’s probability distribution and what the model’s current weights actually produce.

Multi-constraint prompts degrade non-linearly. Testing a prompt against the happy path — one constraint satisfied at a time — tells you very little about what happens when all constraints must be satisfied simultaneously under adversarial or edge-case inputs. Systems built around large instruction-following blocks need test regimes that treat constraint count as an explicit variable.

Tools built against LangChain before version 1.0 (released October 2025) accumulated three years of breaking API changes, since pre-1.0 semantic versioning gave no compatibility guarantees (LangChain Docs). The 1.x series now uses conventional semantic versioning, but prompts and chains written against pre-1.0 APIs may require migration. DSPy similarly changed APIs between major versions — the authors recommend pinning dspy-ai in production environments.

Framework compatibility notes:

  • LangChain: v0.x had three years of breaking API changes; LangChain 1.0 (October 2025) stabilized the surface under semantic versioning. Prompts and chains written against pre-1.0 LangChain may require migration.
  • DSPy: API changed between major versions. Pin dspy-ai version in production and check release notes before upgrading.

Rule of thumb: place critical facts at the start or end of any long context; version your prompts alongside your model versions; make underspecified requirements explicit rather than relying on inference.

When it breaks: position bias and attention dilution don’t improve with context scale — they worsen. A 2M-token window makes the lost-in-the-middle problem geometrically harder because critical information is more likely to be distant from both context anchors, receiving less attention weight from either direction.

The Data Says

The structural limits of prompt engineering — position bias, attention dilution at scale, and model-update regression — are properties of the transformer design, not engineering failures waiting to be patched. In the GPT-3.5 era, simple prompts regressed across 75% of model updates; underspecified prompts are twice as likely to degrade across any change (arXiv Ma et al., arXiv Yang et al.). The fix is not longer prompts or larger context windows. It is treating the prompt as a versioned specification with explicit requirements, tested against constraint combinations — not only the happy path.

AI-assisted content, human-reviewed. Images AI-generated. Editorial Standards · Our Editors