Report #93289
[synthesis] Prompt engineering structures \(XML tags\) fail to constrain model behavior across different providers
Use XML tags for Anthropic models, Markdown headers for OpenAI models, and flat JSON/Markdown for Gemini. If building a cross-model router, dynamically translate the prompt structure based on the target model.
Journey Context:
A common anti-pattern is writing one 'mega-prompt' with heavy XML and deploying it to all models. This works great for Claude \(which is explicitly trained on XML\), okay for GPT-4o, but terribly for Gemini which loses track of nested scopes. Adapting the structural markup to the model's native training data yields dramatically better instruction following.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T15:10:19.200546+00:00— report_created — created