Domain 5 · 16.8% of the CCDV-F exam
Model Selection and Optimization
Choose how a call is generated, how it reaches the API, which family serves it, and what the tokens cost: fundamentals, the REST client, Opus versus Sonnet versus Haiku, and caching.
Task statements
- 5.1 · 5.2%
LLM Fundamentals
Claude generates one next token at a time inside a finite context window. Sampling makes that choice vary. Thinking, effort, fast mode, and examples change how many tokens that process spends and what shape the text takes.
- 5.2 · 6.1%
Technical Fundamentals
The Claude API is HTTP. Official SDKs wrap that REST surface with types, retries, and streaming helpers. Token streaming is server-sent events on that HTTP response. A WebSocket is a different, two-way connection, and it is not how the Messages API delivers tokens.
- 5.3 · 2.7%
Model Selection and Tradeoffs
Haiku, Sonnet, and Opus are a speed, quality, and price ladder. Effort and fast mode move a call along that ladder without a new name. A new model id is a behavior change: pin the snapshot you evaluated, and rerun the eval before you serve it.
- 5.4 · 2.8%
Cost and Token Management
The bill is the usage object times the price card. Output and uncached input dominate. Prompt caching stores a shared prefix at a cache checkpoint so later calls read it at a fraction of the input price. The checkpoint only hits when that prefix, including thinking and effort, stays the same.
Build exercises
Label one call's controls
5.1 · Beginner · 30 minutes
- How a window, an output cap, and thinking share a request.
- Where effort ends and adaptive thinking begins.
- When an example belongs in the prompt.
Trace one turn across the transports
5.2 · Intermediate · 35 minutes
- Which hop is REST, which is SSE, and which may be a WebSocket.
- Where the transcript and the API key live.
- When the next POST starts.
Pick a rung and a pin
5.3 · Intermediate · 40 minutes
- How volume and a failing set point at different families.
- What you re-test when the id changes.
- Where effort and fast mode sit relative to a rename.
Price a prefix and a hit
5.4 · Intermediate · 35 minutes
- How to turn usage buckets into a cost.
- Where a checkpoint sits.
- Which edit forces a new write.