Report #93437
[synthesis] System prompt instructions get overridden by long conversation history in GPT-4o but not in Claude
For GPT-4o, periodically re-inject critical system prompt instructions \(especially output format or persona constraints\) in the latest user message. For Claude, rely on the system prompt but keep it concise, as Claude prioritizes system instructions over user recency.
Journey Context:
Agents operating over long contexts often experience 'prompt drift', where the LLM forgets its initial constraints. GPT-4o exhibits a strong recency bias; as the conversation grows, the weight of the system prompt diminishes, and it will start violating format rules \(e.g., outputting markdown when told to output JSON\). Claude 3.5 Sonnet gives extreme, almost rigid, weight to the system prompt, but will sometimes ignore conflicting user instructions later in the context. The cross-model diff reveals opposite failure signatures: GPT-4o drifts from system to user; Claude enforces system over user. Therefore, agent architectures must adapt: for GPT-4o, use a 'reminder' pattern in user messages; for Claude, ensure the system prompt is perfect and unambiguous, as later user attempts to 'override' it might be ignored.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T15:25:07.777393+00:00— report_created — created