Courseiva

CCAR-F Prompt Engineering and Structured Output Practice Question

A team is extracting medication names and dosages from clinical notes. The notes contain many similar-looking terms, and the team needs high precision to avoid false positives. They plan to use few-shot examples. Which design of the few-shot examples best supports high precision in this scenario?

⚠ Common exam trap

The trap here is assuming that more positive examples alone improve extraction, when precision in a lookalike-rich domain depends on contrastive hard negatives.

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

✓

Include a mix of positive examples and carefully chosen hard negatives that resemble medications but should not be extracted.

High precision in a field with lookalike terms depends on teaching the model where the boundary lies. A mix of positive examples and hard negatives does that by showing both what to extract and what to reject. Positive-only, single-example, or random sampling designs do not surface the confusing cases, so they are less likely to reduce false positives in clinical extraction.

Answer analysis

Option-by-option breakdown

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

  • ✓

    Include a mix of positive examples and carefully chosen hard negatives that resemble medications but should not be extracted.

    Why this is correct

    Hard negatives show the model the boundary between true medication mentions and lookalikes, which directly improves precision. In this scenario, where similar terms cause false positives, contrastive examples clarify what to exclude. This design teaches the decision boundary rather than only the target class, making it the most effective choice for high precision.

  • ✗

    Provide many examples of correct extractions only, covering a wide range of medication names.

    Why it's wrong here

    Positive-only examples teach the model what to extract but not what to avoid. In clinical notes with similar-looking terms, the model may over-extract and reduce precision. The scenario needs the model to distinguish true medication mentions from lookalikes. Without contrastive examples, the boundary remains unclear, so this design does not directly support high precision.

  • ✗

    Randomly sample examples from the dataset without regard to difficulty or similarity.

    Why it's wrong here

    Random sampling may include mostly easy cases and few of the confusing lookalikes that cause false positives. In this scenario, the hard cases are exactly what the model needs to see. Random examples do not target the precision problem, so the model may still over-extract on similar terms. Curating examples for difficulty and contrast is more effective.

  • ✗

    Use a single detailed example and rely on the model to generalize to all other notes.

    Why it's wrong here

    One example cannot convey the variety of medication names, dosages, and lookalikes in clinical notes. Generalization from a single case is unreliable, especially for precision-sensitive extraction. In this scenario, the model would likely miss the nuanced boundary between real and false mentions. This design under-specifies the task and risks both missed and spurious extractions.

About these practice questions

Courseiva writes every CCAR-F question from scratch — 271 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. 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 CCAR-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 CCAR-F exam.