Why it matters

Context stuffing bypasses system prompt. Understanding shapes long-context defenses.

Advertisement

The architecture

Very long user input.

System prompt pushed to end.

Attention drops earlier tokens.

Context stuffing flowLong user contentfill contextSystem promptattention degradedAttack succeedsinstruction ignoredPosition matters: models often follow recent instructions more strongly
Context stuffing.
Advertisement

How it works end to end

Attention decay by position.

Long-context models better but not immune.

Defenses: repeat instructions, position-invariant checks.