Skip to content

CCDV-F · Domain 6: Prompt and Context Engineering · 15% of the exam

Task 6.4: Grounding and Source Citation

Requests that answer only from the supplied documents, cite them and say "not found" when the answer is not there, and the choice between sending the whole corpus and retrieving passages by size, cost and freshness.

Study it

Sample questions

Try each one before opening the answer. Every option is explained, with the Anthropic documentation page that proves it.

Question 1 · choose 1

Your support assistant returns search_result blocks from two sources in each tool result: your knowledge base and a public forum. Answers must cite the passages they rely on. A developer set citations to enabled on the knowledge-base results only and left the forum results without a citations field. What should the request do instead?

  1. ASet citations to enabled once at the top level of the request instead of on the blocks
  2. BKeep the knowledge-base setting and add citations disabled explicitly to every forum result
  3. CSet citations to enabled on every search_result block in the request, forum results included
  4. DRemove citations from all blocks and ask Claude to name its sources in the text of its answer
Show the answer and why
  • ASet citations to enabled once at the top level of the request instead of on the blocks

    Incorrect

    Citations are configured on each search_result block through its citations field.

  • BKeep the knowledge-base setting and add citations disabled explicitly to every forum result

    Incorrect

    That still mixes settings, and all search results in a request must use the same one.

  • CSet citations to enabled on every search_result block in the request, forum results included

    Correct

    Citations are disabled by default, and all search results in one request must share the same setting.

  • DRemove citations from all blocks and ask Claude to name its sources in the text of its answer

    Incorrect

    Prompted source names are not citations tied to the passages.

Citations on search results are disabled by default and are turned on with each block's citations field. All search results in a request must use the same setting, so enable citations on every search_result block when answers must cite them.

Question 2 · choose 1

Your app answers questions about meeting transcripts and must cite whole speaker turns, never fragments of a turn. Each transcript is sent as a plain text document with citations enabled, and the citations often point to single sentences inside a turn. How should you send the transcripts?

  1. AAs PDF documents generated from the transcripts, so that citations point to whole pages
  2. BAs custom content documents with one content block per speaker turn
  3. CAs plain text documents with a context field that lists the speaker turns
  4. DAs one plain text document per transcript with a title naming the meeting
Show the answer and why
  • AAs PDF documents generated from the transcripts, so that citations point to whole pages

    Incorrect

    PDF text is also chunked into sentences, so citations stay at sentence granularity.

  • BAs custom content documents with one content block per speaker turn

    Correct

    Custom content is used as provided, with no further chunking, so each turn is the smallest citable unit.

  • CAs plain text documents with a context field that lists the speaker turns

    Incorrect

    The context field is passed to the model but is not used toward cited content.

  • DAs one plain text document per transcript with a title naming the meeting

    Incorrect

    Plain text is chunked into sentences whatever its title.

Document contents are chunked to define the minimum granularity of citations: plain text and PDFs into sentences, while custom content documents use your content blocks as they are. To cite whole speaker turns, put each turn in its own content block.

Question 3 · choose 1

Your PDF manuals include wiring diagrams as images, and you send them as PDF documents with citations enabled. Users expect answers about a diagram to cite the diagram itself. What should you expect?

  1. AClaude can't cite images in PDFs; citations point to the extracted text
  2. BCitations point to the image's position on the page as a bounding box around it
  3. CEach diagram becomes its own citable chunk, like a sentence
  4. DCitations work for images only if the PDF is under ten pages
Show the answer and why
  • AClaude can't cite images in PDFs; citations point to the extracted text

    Correct

    The API extracts PDF text and chunks it into sentences; images are not citable.

  • BCitations point to the image's position on the page as a bounding box around it

    Incorrect

    PDF citations come from extracted text; images in PDFs can't be cited.

  • CEach diagram becomes its own citable chunk, like a sentence

    Incorrect

    Chunks come from the extracted text, not from images.

  • DCitations work for images only if the PDF is under ten pages

    Incorrect

    Page count does not make images citable.

For PDFs, the API extracts the text and chunks it into sentences, and Claude can't cite images in PDFs. Citations point to passages of the extracted text.

Question 4 · choose 1

Your chat UI streams Claude's answers about uploaded documents that have citations enabled. The client renders each text_delta from the content_block_delta events, and the finished answers show no citations, although the same request without streaming returns citations on its text blocks. What should the client do?

  1. AWait for the message_delta event, which carries the full list of citations for the response
  2. BHandle citations_delta deltas and append each citation to the current text block
  3. CTurn off streaming for cited answers, because streamed responses never carry any citations
  4. DParse the text_delta strings for source markers that Claude writes into the answer text
Show the answer and why
  • AWait for the message_delta event, which carries the full list of citations for the response

    Incorrect

    Citations arrive inside content_block_delta events, one citation per delta.

  • BHandle citations_delta deltas and append each citation to the current text block

    Correct

    Each citations_delta carries a single citation to add to the citations list of the current text block.

  • CTurn off streaming for cited answers, because streamed responses never carry any citations

    Incorrect

    Streamed responses carry citations as citations_delta deltas.

  • DParse the text_delta strings for source markers that Claude writes into the answer text

    Incorrect

    Citations come as structured citations_delta deltas, not as markers inside the text.

For streaming responses, citations arrive as a citations_delta delta type inside content_block_delta events, next to the text_delta deltas that carry the text. Each citations_delta contains a single citation to add to the citations list on the current text content block.

Practice domain 6 →Practice all domains →