Courseiva

CCDV-F Prompt and Context Engineering Practice Question

A developer is drafting a system prompt for a coding assistant. They want Claude to always answer in the same tone and follow the same safety constraints regardless of what the user types. Where should these persistent rules be placed?

⚠ Common exam trap

The trap here is believing that putting rules in the first user message or a trailing assistant message is equivalent to the system prompt, when only the system prompt consistently frames every turn.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

In the system prompt, which applies across the whole conversation.

Persistent behavioral rules belong in the system prompt because it frames every turn and is not scoped to a single user or assistant message. This gives consistent tone and safety enforcement regardless of what the user types. User-message rules are turn-scoped, assistant messages represent output, and non-message fields are not read as instructions, so none of those achieve the required consistency.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    In a final assistant message appended after the user's question.

    Why it's wrong here

    An assistant message represents model output, not developer instructions, so putting rules there is semantically wrong and may be treated as a prior response. It also cannot govern future turns. This placement would confuse the conversation structure and fail to enforce persistent tone and safety constraints, so it does not meet the requirement.

  • ✗

    In the first user message, mixed with the developer's coding question.

    Why it's wrong here

    Rules embedded in a user message are scoped to that turn and can be diluted or overridden by later user input, so they do not persist across the conversation. Mixing them with a coding question also makes the instructions harder for the model to separate from the task. This does not achieve the consistent behavior the scenario requires.

  • ✓

    In the system prompt, which applies across the whole conversation.

    Why this is correct

    The system prompt is the intended place for persistent role, tone, and safety constraints because it frames every turn of the conversation. Placing these rules there ensures they apply regardless of user input and are not scoped to a single message. This matches the requirement for consistent tone and safety across all interactions with the coding assistant.

  • ✗

    In a separate metadata field outside the messages array.

    Why it's wrong here

    The Messages API does not have an arbitrary metadata field that the model reads as instructions; content outside the message roles is not part of the model's conditioning in the way needed here. Rules placed there would be ignored. This approach cannot deliver the persistent tone and safety behavior the developer wants across the conversation.

About these practice questions

One of 257 original CCDV-F practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written and reviewed by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

Last reviewed September 2026 · checked against the official Anthropic exam blueprint

This CCDV-F practice question is part of Courseiva's free Anthropic certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the CCDV-F exam.