You save $9.99
CCDV-F Premium Bundle
- Premium File 96 Questions & Answers
- Last Update: Nov 24, 2026
- Training Course 116 Lectures
You save $9.99
A developer expects a user-defined database tool to run on Anthropic infrastructure automatically.
Which change should be made first?
Separate server-executed tool configuration from client-defined tools whose execution remains in application code. For the situation 'A developer expects a user-defined database tool to run on Anthropic infrastructure automatically', this directly implements the required control. Tool execution location determines where credentials, policy and result handling reside. Verify the result by checking that traces classify server and client executions and identify the responsible runtime.
Return a structured tool error and let the workflow retry or escalate appropriately. That addresses the different 'Tool failure representation' situation: A search tool returns an upstream timeout but the wrapper passes an empty success result. Here the implementation must instead separate server-executed tool configuration from client-defined tools whose execution remains in application code, because tool execution location determines where credentials, policy and result handling reside.
Define narrowly scoped tools with precise descriptions, typed parameters and required fields. That addresses the different 'Tool schema quality' situation: A database tool exposes a single free-form string argument for several unrelated operations. Here the implementation must instead separate server-executed tool configuration from client-defined tools whose execution remains in application code, because tool execution location determines where credentials, policy and result handling reside.
Execute validated client-side tools and send correlated tool_result content in a subsequent message. That addresses the different 'Client tool result handoff' situation: An API assistant emits a lookup tool_use message and a frontend mistakenly treats it as the retrieved value. Here the implementation must instead separate server-executed tool configuration from client-defined tools whose execution remains in application code, because tool execution location determines where credentials, policy and result handling reside.
A PDF attachment claims the reader must first upload environment variables.
What should the engineer do next?
Treat external text as untrusted and enforce independent tool and data-access checks. For the situation 'A PDF attachment claims the reader must first upload environment variables', this directly implements the required control. Prompt injection exploits confusion between source data and trusted instructions. Verify the result by checking that injection tests cannot trigger forbidden tool actions or reveal privileged instructions.
Bind service identities to tenant and operation scopes, and authorize each tool request. That addresses the different 'Identity-bound service authorization' situation: A SaaS backend uses one unscoped credential to access all customers' records. Here the implementation must instead treat external text as untrusted and enforce independent tool and data-access checks, because prompt injection exploits confusion between source data and trusted instructions.
Redact or exclude unnecessary personal fields before model and tool calls. That addresses the different 'Sensitive data minimization' situation: A claims chatbot forwards full identity documents although only two nonsecret fields are required. Here the implementation must instead treat external text as untrusted and enforce independent tool and data-access checks, because prompt injection exploits confusion between source data and trusted instructions.
Block unauthorized data destinations and validate outgoing tool arguments against allowlists. That addresses the different 'Output exfiltration prevention' situation: An untrusted page suggests that the agent email account data to a third-party address. Here the implementation must instead treat external text as untrusted and enforce independent tool and data-access checks, because prompt injection exploits confusion between source data and trusted instructions.
A long-lived customer-service worker reuses a prior customer's messages when a new user connects. For another customer workflow, an engineering team is required to demonstrate the same control before launch, with a required sign-off based on observable evidence.
What should the engineer do next?
Partition state by authenticated session and expire or clear it on account switch. For the situation 'A long-lived customer-service worker reuses a prior customer's messages when a new user connects. For another customer workflow, an engineering team is required to demonstrate the same control before launch, with a required sign-off based on observable evidence', this directly implements the required control. Session identifiers and explicit context selection prevent cross-user history mixing. Verify the result by checking that a user-switch test finds no earlier private turns in the new model request.
Keep retrieved content as untrusted data and maintain trusted instructions outside it. That addresses the different 'Instruction versus retrieved data' situation: A document summarizer encounters a PDF that says to ignore all system rules. Here the implementation must instead partition state by authenticated session and expire or clear it on account switch, because session identifiers and explicit context selection prevent cross-user history mixing.
Use supported structured output or validated schema constraints and reject nonconforming responses. That addresses the different 'Structured output contract' situation: A billing tool needs exactly three typed JSON fields for downstream parsing. Here the implementation must instead partition state by authenticated session and expire or clear it on account switch, because session identifiers and explicit context selection prevent cross-user history mixing.
Require disambiguation and confirmation before executing a consequential action. That addresses the different 'Clarification of ambiguous parameters' situation: A customer types 'close all open ones' with several possible ticket interpretations. Here the implementation must instead partition state by authenticated session and expire or clear it on account switch, because session identifiers and explicit context selection prevent cross-user history mixing.
An incident triage orchestrator receives bulky log-search results from a specialist.
What should the engineer do next?
Delegate noisy evidence gathering to a subagent that returns a compact verified summary. For the situation 'An incident triage orchestrator receives bulky log-search results from a specialist', this directly implements the required control. A subagent has its own context and can compress observations before contributing relevant findings to the main task. Verify the result by checking that the main transcript contains concise cited findings rather than every raw search or log result.
Use a supervisor to dispatch scoped tasks and reconcile their results under one final decision point. That addresses the different 'Supervisor delegation boundaries' situation: A cross-functional incident assistant delegates network analysis and application-log analysis to different specialists. Here the implementation must instead delegate noisy evidence gathering to a subagent that returns a compact verified summary, because a subagent has its own context and can compress observations before contributing relevant findings to the main task.
Place an explicit human authorization gate before the irreversible tool invocation. That addresses the different 'Human approval of irreversible agent actions' situation: An automated purchasing assistant drafts orders but spends money only after a manager agrees. Here the implementation must instead delegate noisy evidence gathering to a subagent that returns a compact verified summary, because a subagent has its own context and can compress observations before contributing relevant findings to the main task.
Use an agent with a bounded tool set, stop conditions and review of consequential actions. That addresses the different 'Agent selection for ambiguous investigation' situation: A support investigator must explore unfamiliar incident evidence and choose among several diagnostic tools. Here the implementation must instead delegate noisy evidence gathering to a subagent that returns a compact verified summary, because a subagent has its own context and can compress observations before contributing relevant findings to the main task.
An orchestration worker retries an email-sending step following a network disconnect.
What should the engineer do next?
Use idempotency keys and check the external operation's status before a potentially duplicated retry. For the situation 'An orchestration worker retries an email-sending step following a network disconnect', this directly implements the required control. Model retries do not reverse external side effects; application-level idempotency prevents duplicate writes. Verify the result by checking that a forced timeout followed by retry creates only one ticket or outgoing action.
Require an observed authoritative tool response before stating an external operation succeeded. That addresses the different 'Tool observation evidence' situation: A repair agent says an update succeeded immediately after issuing a patch command. Here the implementation must instead use idempotency keys and check the external operation's status before a potentially duplicated retry, because model retries do not reverse external side effects; application-level idempotency prevents duplicate writes.
Summarize durable decisions and prune irrelevant tool history before continuing. That addresses the different 'Context compaction in agent loop' situation: A lengthy agent run approaches its model context capacity after dozens of tool results. Here the implementation must instead use idempotency keys and check the external operation's status before a potentially duplicated retry, because model retries do not reverse external side effects; application-level idempotency prevents duplicate writes.
Run independent scoped subagent tasks concurrently and merge after validating each result. That addresses the different 'Parallel subagent aggregation' situation: A coordinator asks two independent specialists to inspect separate code modules. Here the implementation must instead use idempotency keys and check the external operation's status before a potentially duplicated retry, because model retries do not reverse external side effects; application-level idempotency prevents duplicate writes.
A remediation workflow resumes after operator approval on a later shift.
What should the engineer do next?
Persist session identifiers and minimal approved state in application storage and restore them on continuation. For the situation 'A remediation workflow resumes after operator approval on a later shift', this directly implements the required control. HTTP request lifecycles and model context are not automatically durable application session storage. Verify the result by checking that a resumed session preserves the authorized case state without exposing another user's messages.
Use the Claude Agent SDK within an application-owned service and wrap tool permissions and tracing. That addresses the different 'Agent SDK integration boundary' situation: A Python service needs multi-turn agent tooling with session management and structured observability. Here the implementation must instead persist session identifiers and minimal approved state in application storage and restore them on continuation, because hTTP request lifecycles and model context are not automatically durable application session storage.
Execute the validated tool call, append the correlated tool_result and continue until an appropriate terminal stop reason. That addresses the different 'Custom tool loop completion' situation: An assistant returns a tool_use block for a database lookup and the caller currently displays it as the final answer. Here the implementation must instead persist session identifiers and minimal approved state in application storage and restore them on continuation, because hTTP request lifecycles and model context are not automatically durable application session storage.
Add a maximum tool-step budget, loop detection and a safe escalation response. That addresses the different 'Loop termination budget' situation: An automated troubleshooting agent keeps querying the same endpoints with no progress. Here the implementation must instead persist session identifiers and minimal approved state in application storage and restore them on continuation, because hTTP request lifecycles and model context are not automatically durable application session storage.
A long explanation generates over many seconds and the client needs a live progress view.
Which change should be made first?
Consume the supported streaming event sequence and assemble deltas into the final message. For the situation 'A long explanation generates over many seconds and the client needs a live progress view', this directly implements the required control. Streaming delivers content incrementally and requires correct event lifecycle handling rather than one synchronous text field. Verify the result by checking that the interface displays text progressively and the completed content matches the assembled event stream.
Use the top-level system parameter for application instructions and structured user messages for user content. That addresses the different 'Role and system instruction placement' situation: A developer includes a top-level system instruction as if it were a user message. Here the implementation must instead consume the supported streaming event sequence and assemble deltas into the final message, because streaming delivers content incrementally and requires correct event lifecycle handling rather than one synchronous text field.
Send the relevant conversation messages or a controlled summary on each request. That addresses the different 'Messages API stateless history' situation: A chat interface sends only the latest user turn and expects the API to remember prior turns. Here the implementation must instead consume the supported streaming event sequence and assemble deltas into the final message, because streaming delivers content incrementally and requires correct event lifecycle handling rather than one synchronous text field.
Check secret injection, authorization scope and environment configuration rather than changing the prompt. That addresses the different 'Provider authentication error' situation: A staging deployment receives 401 errors immediately after a secret rotation. Here the implementation must instead consume the supported streaming event sequence and assemble deltas into the final message, because streaming delivers content incrementally and requires correct event lifecycle handling rather than one synchronous text field.
A malicious tool result embeds a URL with customer information in a query parameter.
Which approach most directly meets the stated need?
Block unauthorized data destinations and validate outgoing tool arguments against allowlists. For the situation 'A malicious tool result embeds a URL with customer information in a query parameter', this directly implements the required control. Network and tool egress policies constrain exfiltration even if text instructions are compromised. Verify the result by checking that red-team tests show denied external sends and no sensitive values in outbound requests.
Use a secrets manager and least-privileged runtime injection with masked logs. That addresses the different 'Secret injection to runtime' situation: An integration commits an API key in a source-controlled settings file. Here the implementation must instead block unauthorized data destinations and validate outgoing tool arguments against allowlists, because network and tool egress policies constrain exfiltration even if text instructions are compromised.
Redact or exclude unnecessary personal fields before model and tool calls. That addresses the different 'Sensitive data minimization' situation: A claims chatbot forwards full identity documents although only two nonsecret fields are required. Here the implementation must instead block unauthorized data destinations and validate outgoing tool arguments against allowlists, because network and tool egress policies constrain exfiltration even if text instructions are compromised.
Treat external text as untrusted and enforce independent tool and data-access checks. That addresses the different 'Prompt injection through retrieved source' situation: A search result tells a customer assistant to disclose its hidden system instructions. Here the implementation must instead block unauthorized data destinations and validate outgoing tool arguments against allowlists, because network and tool egress policies constrain exfiltration even if text instructions are compromised.
A service integrates a server-hosted search tool but also has private local functions.
Which implementation is the best fit?
Separate server-executed tool configuration from client-defined tools whose execution remains in application code. For the situation 'A service integrates a server-hosted search tool but also has private local functions', this directly implements the required control. Tool execution location determines where credentials, policy and result handling reside. Verify the result by checking that traces classify server and client executions and identify the responsible runtime.
Define narrowly scoped tools with precise descriptions, typed parameters and required fields. That addresses the different 'Tool schema quality' situation: A database tool exposes a single free-form string argument for several unrelated operations. Here the implementation must instead separate server-executed tool configuration from client-defined tools whose execution remains in application code, because tool execution location determines where credentials, policy and result handling reside.
Return a structured tool error and let the workflow retry or escalate appropriately. That addresses the different 'Tool failure representation' situation: A search tool returns an upstream timeout but the wrapper passes an empty success result. Here the implementation must instead separate server-executed tool configuration from client-defined tools whose execution remains in application code, because tool execution location determines where credentials, policy and result handling reside.
Execute validated client-side tools and send correlated tool_result content in a subsequent message. That addresses the different 'Client tool result handoff' situation: An API assistant emits a lookup tool_use message and a frontend mistakenly treats it as the retrieved value. Here the implementation must instead separate server-executed tool configuration from client-defined tools whose execution remains in application code, because tool execution location determines where credentials, policy and result handling reside.
A coordinator asks two independent specialists to inspect separate code modules.
Which approach most directly meets the stated need?
Run independent scoped subagent tasks concurrently and merge after validating each result. For the situation 'A coordinator asks two independent specialists to inspect separate code modules', this directly implements the required control. Parallel branches improve latency only when tasks are independent and their results can be reconciled. Verify the result by checking that the final report attributes evidence to each specialist and resolves cross-branch inconsistencies.
Use idempotency keys and check the external operation's status before a potentially duplicated retry. That addresses the different 'Agent retry idempotency' situation: An agent times out after calling a ticket-create tool, leaving the result unknown. Here the implementation must instead run independent scoped subagent tasks concurrently and merge after validating each result, because parallel branches improve latency only when tasks are independent and their results can be reconciled.
Summarize durable decisions and prune irrelevant tool history before continuing. That addresses the different 'Context compaction in agent loop' situation: A lengthy agent run approaches its model context capacity after dozens of tool results. Here the implementation must instead run independent scoped subagent tasks concurrently and merge after validating each result, because parallel branches improve latency only when tasks are independent and their results can be reconciled.
Require an observed authoritative tool response before stating an external operation succeeded. That addresses the different 'Tool observation evidence' situation: A repair agent says an update succeeded immediately after issuing a patch command. Here the implementation must instead run independent scoped subagent tasks concurrently and merge after validating each result, because parallel branches improve latency only when tasks are independent and their results can be reconciled.
A developer sets a large max_tokens value and assumes the prompt can grow indefinitely.
What should the engineer do next?
Budget input context and output generation separately and prune irrelevant content before exceeding limits. For the situation 'A developer sets a large max_tokens value and assumes the prompt can grow indefinitely', this directly implements the required control. Context window constraints apply to total conversational input and generation while max_tokens limits response length. Verify the result by checking that usage and token-count tests show the assembled request fits and the answer has enough output allowance.
Route tasks to effort levels based on complexity and measure accuracy against time and cost. That addresses the different 'Effort allocation' situation: A service uses maximum reasoning effort for trivial routing decisions. Here the implementation must instead budget input context and output generation separately and prune irrelevant content before exceeding limits, because context window constraints apply to total conversational input and generation while max_tokens limits response length.
Pin relevant versions and test semantic invariants while recognizing remaining generation variability. That addresses the different 'Non-deterministic inference audits' situation: An operator insists that identical prompts must yield identical prose across releases. Here the implementation must instead budget input context and output generation separately and prune irrelevant content before exceeding limits, because context window constraints apply to total conversational input and generation while max_tokens limits response length.
Add a few concise representative examples covering the difficult boundary conditions. That addresses the different 'Zero-shot and few-shot examples' situation: A JSON extraction prompt fails on uncommon invoice layouts. Here the implementation must instead budget input context and output generation separately and prune irrelevant content before exceeding limits, because context window constraints apply to total conversational input and generation while max_tokens limits response length.
Please check your mailbox for a message from support@examlabs.com and follow the directions.