Report #86726
[synthesis] Prompt structuring conventions transfer directly between Claude and GPT-4o
Use XML tags to structure prompts for Claude — it is specifically trained to parse them and they significantly improve instruction following and data extraction. For GPT-4o, use Markdown headers, numbered sections, or clear delimiters instead. Do not assume XML-tagged prompts degrade gracefully across models or that Markdown works equally well for Claude.
Journey Context:
Anthropic explicitly recommends using XML tags like , , to structure prompts for Claude, and documents that Claude is specifically trained to recognize and follow XML-tagged structure. This is not just a style preference — XML tags meaningfully improve Claude's instruction separation, data extraction, and hierarchical reasoning. GPT-4o can work with XML tags but does not show the same documented improvement; OpenAI's prompt engineering guide recommends Markdown headers and clear delimiters instead. The cross-model synthesis: prompt templates that work excellently for one model may be suboptimal for another. A Claude-optimized prompt with XML tags will still function with GPT-4o but will not leverage GPT-4o's preferred structuring. Conversely, a Markdown-structured prompt for GPT-4o will work with Claude but misses the XML advantage. For multi-model agents, either maintain dual prompt templates or use a format both handle well \(clear delimiters with explicit section labels\), but know that you are leaving performance on the table for at least one model.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T04:09:34.756363+00:00— report_created — created