Claude Certified Architect – Foundations Practice Question 46: Prompt Chaining Pipeline

Claude Certified Architect, Foundations · Test 5 · question 6 of 10

Prompt Engineering & Structured Outputmedium

A single prompt asks Claude to read a contract, extract all obligations, classify each by risk, and write an executive summary with a risk table. Results are inconsistent: sometimes obligations are missed, and when the summary is wrong the team cannot tell which part of the task failed. The steps are fixed and always run in the same order. What is the best redesign?

Select one answer
Show answer and explanation

Answer:

  • A. Split the work into sequential calls (extract, classify, summarize), passing each output to the next, with programmatic checks between steps.

This is prompt chaining: decomposing a task with fixed, cleanly separable subtasks into sequential calls, where each call processes the previous output and code can validate between steps. It trades some latency for accuracy because each call is simpler, and it makes the pipeline debuggable: each step is a separate API call, so you can log, evaluate or branch at any point and see exactly which stage failed. Anthropic's prompting guidance notes explicit chaining is still valuable when you need to inspect intermediate outputs or enforce a pipeline structure.

B is wrong because emphasis and more rules do not give visibility into intermediate steps, and a heavier single prompt tends to make the multi-part task harder, not easier. C is wrong because voting (parallelization) helps confidence on a single judgement, but it multiplies cost, does not address the missed obligations from an overloaded prompt, and still leaves failures undiagnosable. D is wrong because the steps are known in advance and fixed, so the added unpredictability, cost and latency of an agent is unwarranted; a workflow is the simpler fit.

Reference: Prompting best practices (Chain complex prompts)

Practice Test 5 ›

Study guides for Claude Certified Architect, Foundations