Rubric
Contents — domains, guide and mocks

End-to-end architecture

CCAR-P 1.212 min read · checked 21 September 2026

Task statementDesign end-to-end architectures (input, processing, output, feedback loops)

The four parts of every Claude solution

  1. Inputcapture, clean, check, add context
  2. Processingprompt, Claude, tools, code
  3. Outputstructure, validate, review, deliver
  4. Feedbackmeasure, capture corrections, learn

Production failures become eval cases → prompt or design change → regression test → release

The model call is one box of four. Most production failures start in the other three — and the loop back is what makes the system improve rather than drift.

Input: what reaches the model, and in what state

Enterprise inputs are messy: email threads with signatures and disclaimers, scanned PDFs, call transcripts, web forms, records spread over three systems. The input stage decides what Claude sees. It has four jobs. Capture the input from its channel (webhook, queue, scheduled pull, user interface). Clean it — strip boilerplate, split attachments, convert formats. Check it — size limits, required fields, language, whether it contains data this system is not allowed to process. Assemble context — add the customer record, the relevant policy passages, the template.

Context assembly deserves the most thought. Anthropic’s context-engineering guidance frames the goal as the smallest set of high-signal tokens that makes the desired outcome likely: more context is not better if most of it is irrelevant, because recall degrades as the window fills. Retrieval that brings in the three relevant policy sections usually beats pasting the whole policy manual into every request. Retrieval pipeline design is covered in 3.5 and 3.6.

Processing: Claude plus deterministic code

Processing is where the pattern chosen in 1.3 lives: a single call, a fixed workflow of calls, or an agent choosing tools in a loop. Whatever the pattern, the same rule holds — let Claude do the reading, judgement and writing, and keep calculations, lookups, business rules and permission checks in ordinary code or in tools that code controls. A quote, a refund limit or an eligibility threshold should come back from a system of record, not be generated.

Grounding belongs here too. Claude’s guidance on reducing hallucinations lists techniques that are really design choices: give the model explicit permission to say it does not know, restrict it to the supplied documents, have it extract direct quotes before analysing a long document, and require a citation for each claim so answers can be audited. None of them eliminates errors, which is why the output stage still checks.

One claim, end to end

Intake service
Claude
Policy system
Adjuster
Step 1: Intake service : Clean email, split photos, redact
Step 2: Intake service to Claude: Claim text + policy extract
Step 3: Claude to Policy system: Tool: check_cover(policy, peril)
Step 4: Policy system to Claude: Covered, excess £250
Step 5: Claude to Intake service: Fields + draft summary (JSON)
Step 6: Intake service : Validate schema and totals
Step 7: Intake service to Adjuster: Draft in queue for review
Step 8: Adjuster to Intake service: Approve, or edit with reason
Each stage adds a guarantee the model alone cannot give: code checks policy cover, the schema checks shape, and the adjuster checks judgement. (Your service executes the tool call Claude requests; it is drawn direct for clarity.)

Output: structure, validate, gate, deliver

If the output goes to a person, prose may be fine. If it goes to another system, it needs a contract. Claude’s structured outputs feature constrains the response to a JSON schema you supply — through output_config.format for the response, or strict: true on a tool definition — so the downstream parser always receives valid, correctly typed fields. The documentation is clear about the edges: a refusal or hitting the token limit can still produce something unusable, and structured outputs cannot be combined with citations. So the output stage still validates business rules: totals add up, dates are plausible, the chosen category exists.

Output concernDesign choiceWhy
Another system consumes itSchema-constrained JSON, then rule checksParsers need a contract; the schema cannot check business logic
A person must be able to verify itCitations or quoted sources per claimReviewers check evidence faster than they re-read sources
Being wrong is costlyHuman approval gate before releaseJudgement and accountability stay with a named person
The user is waitingStreaming to the interfacePerceived latency drops even when total time does not
Nobody is waitingBatch processingHalf the price when the result can wait

How should results be delivered?

Who is waiting for the result?
  • A customer, live
    Real time, streamedtight latency budget
  • An employee, within minutes
    Queued, asyncworker picks up, notifies
  • No one until tomorrow
    Message Batches50% discount, up to 24 h
Delivery mode follows the business process, not the model. The same prompt can run interactively for agents and in batch overnight.

The Message Batches API is the lever most often missed. Anthropic documents a 50% discount on standard prices, with most batches finishing in under an hour and a 24-hour limit. Nightly re-classification of a catalogue, bulk summarisation of the day’s calls, or running an evaluation set are natural fits; a live chat is not.

Feedback loops: how the system gets better

A system without a feedback loop is frozen on launch day while its inputs keep changing. Good designs have loops at three speeds. The inner loop runs inside one request: validation fails, the error goes back to Claude, it retries once; or an evaluator step checks a draft against criteria. The operational loop runs daily: people correct outputs, reviewers flag problems, low customer ratings trigger a look at the transcript. The improvement loop runs per release: failures from production become evaluation cases, the prompt or design changes, and a regression suite proves nothing else broke before rollout.

Open loop versus closed loop

Open loop

  • Prompt tuned once before launch
  • Human edits overwrite the draft and vanish
  • Quality known only from complaints
  • Prompt changes shipped on a hunch

Closed loop

  • Edits and ratings stored with the original output
  • Production failures added to the eval set
  • Every change runs the regression suite first
  • Metrics tracked against the success criteria
The closed-loop design costs a little more to build and is the only one that can show — or even notice — that it is getting better or worse.

Anthropic’s guidance on agent evaluation describes this as layers, none sufficient alone: automated evals for fast, repeatable checks; production monitoring for real behaviour; A/B tests for real outcomes; user feedback for problems nobody anticipated; and manual transcript review to keep the graders honest. It recommends starting with 20 to 50 realistic tasks drawn from manual testing and user-reported failures — the feedback loop and the eval set are the same asset. Metrics, datasets and A/B testing are taught in Domain 4; observability in 3.4 and 4.6.

Traps the wrong answers are built from

Tempting but wrongDo this instead
Passing raw, unchecked input straight to the modelClean, validate and reject bad input before the call; never ask Claude to invent missing facts.
Loading every document into every request “to be safe”Retrieve the few high-signal passages the task needs.
Parsing free text from Claude into a downstream systemConstrain the output to a schema, then validate business rules in code.
Letting the model compute prices, limits or eligibilityGet those from systems of record through tools or code.
Launching with no way to capture correctionsLog outputs with human edits and ratings, and feed failures into the eval set and regression suite.

You should now be able to

  • Lay out an end-to-end design across input, processing, output and feedback for a business process.
  • Decide what belongs to Claude and what belongs to deterministic code or systems of record.
  • Choose output contracts, validation and human gates to match the consumer and the risk.
  • Match delivery mode — streamed, queued or batched — to who is waiting for the result.
  • Design feedback loops at request, operational and release speed that turn production failures into tests.

Practice questions

Original questions written for this lesson, in the exam’s style. Answer first, then open the reasoning — every option is explained, including why the wrong ones are tempting.

  1. Question 1

    A bank’s trade-finance team uses Claude to extract fields from letters of credit and write them straight into a booking system. About 2% of bookings fail because dates arrive in mixed formats and some amounts include currency words.

    Which change most directly fixes the failure?

    1. AMove to a larger Claude model so the extraction is more accurate.
    2. BConstrain output to a typed schema and validate values in code before booking.
    3. CAdd “always use ISO dates” in capitals at the top of the system prompt.
    4. DSend every extracted letter of credit to a human for full re-keying.
    Show answer and reasoning
    1. AIncorrect. The fields are being found; they arrive in the wrong shape. A bigger model does not give the booking system a contract.
    2. BCorrect. A schema guarantees the shape and types the booking system expects, and code checks the business rules the schema cannot express.
    3. CIncorrect. It may help, but instructions alone are probabilistic and give no guarantee to a downstream system.
    4. DIncorrect. That removes most of the value; a targeted review of records that fail validation is enough.
  2. Question 2

    A hospital network’s Claude assistant drafts replies to patient portal messages for nurses to approve. Six months after launch, nurses say drafts feel “worse”, but the team cannot say what changed or when.

    What should the architecture have included? (Select 2.)

    1. ALogging each draft with the nurse’s final version and any rejection reason.
    2. BA larger context window so more of each patient’s history fits in.
    3. CA regression eval set, grown from flagged drafts and run before every change.
    4. DRemoving the nurse approval step to collect more unfiltered outputs.
    5. ESwitching model every quarter to the newest release.
    Show answer and reasoning
    1. ACorrect. Paired draft-and-decision logs make quality measurable over time and show exactly which kinds of message are degrading.
    2. BIncorrect. It changes the input but does nothing to reveal whether or why quality is changing.
    3. CCorrect. A regression suite fed by production failures catches silent quality loss before release and proves fixes work.
    4. DIncorrect. Removing the human gate raises clinical risk and destroys the very signal the team needs.
    5. EIncorrect. Unmeasured model changes are a likely cause of silent drift, not a cure for it.
  3. Question 3

    A public-sector agency wants Claude to summarise the 30,000 consultation responses it receives after each policy proposal. Analysts read the summaries the following week.

    Which delivery design best fits?

    1. AReal-time streaming calls so analysts see summaries appear as they are generated.
    2. BAn agent that decides for itself which responses to summarise and when.
    3. CSubmit responses through the Message Batches API and load results for analysts.
    4. DProcess responses one by one on a web server as each one arrives.
    Show answer and reasoning
    1. AIncorrect. Streaming improves perceived speed for someone waiting live; nobody is waiting here, so it pays full price for no benefit.
    2. BIncorrect. The work is fixed and fully known in advance, so autonomy adds unpredictability without value.
    3. CCorrect. The results are not needed immediately, so batch processing gives the documented 50% discount with ample time to finish.
    4. DIncorrect. It works, but pays interactive prices and adds per-request plumbing for work that is naturally batched.
  4. Question 4

    In an end-to-end Claude design, which responsibility belongs in deterministic code or a system of record rather than in the model?

    1. ADeciding which of fourteen teams should own an incoming complaint.
    2. BSummarising a clinician’s notes into a discharge letter draft.
    3. CDrafting a polite explanation of a declined card payment.
    4. DCalculating the refund due under a fixed tariff after a flight delay.
    Show answer and reasoning
    1. AIncorrect. Routing unstructured text by meaning is a core Claude strength; code then acts on the decision.
    2. BIncorrect. Summarisation from supplied notes is a language task well suited to Claude, with a human signing off.
    3. CIncorrect. Writing the explanation is a language task; the decline decision itself comes from the payment system.
    4. DCorrect. A fixed formula is deterministic; code gives the exact, auditable figure, and Claude can explain it.

Sources

Drafted with AI assistance and checked against the sources above; expert review is in progress. Spotted an error? Tell us and it gets fixed, dated and listed on how this is written.