Model mixing up policy, ticket history and the user message

CCDV-F Prompt & Context Engineering Easy Question 6 of 105

A support agent prompt mixes corporate policy rules, customer ticket history, and the user's current message. The model sometimes treats a complaint in the history as if it were policy.

Which prompt structure most reliably separates the three kinds of content?

Show answer and explanation

DWrap each section in its own XML tag, such as <policy>, <history>, <query>

XML tags let Claude parse a prompt that mixes instructions, context and variable input, and giving each section its own descriptive tag is the documented way to remove that ambiguity. Moving the policy to the system prompt separates it from the other two but leaves the history and the current message merged in one turn, which is the confusion described. Markdown headings are soft delimiters that user-supplied text can imitate. And per-line metadata labels the history without marking where it starts and ends.

Source: platform.claude.com/docs/en/build-with-claude/prompt-engine…

Anonymous, no account needed. Your tally stays in this browser.

Next question Start 5 timed questions Browse all 105 original CCDV-F practice questions