Question 100
An autonomous triage job must stop before it exceeds its approved tool-call and cost budget. What is the appropriate next design choice?
- Store durable task state outside the model
- Assign action limits in the agent harness
- Use a model-directed agent loop
- Keep model context limited to relevant evidence
Explanation
Correct Answer
B:Host-controlled counters and deadlines bound execution regardless of what Claude decides next; a crucial qualification is that prompt instructions alone cannot enforce a hard external quota.
Incorrect Answers
A:The application persists task IDs, stage progress, completed actions, and retry metadata in controlled storage; here, the controlling capability is that host-controlled counters and deadlines bound execution regardless of what Claude decides next, but conversation context alone is not a transactional checkpoint or a durable job record.
C:Claude selects an action after observing each result, with the application enforcing iteration and permission limits; by comparison, the intended solution relies on this: host-controlled counters and deadlines bound execution regardless of what Claude decides next; the autonomy adds variability and demands hard budgets, logs, and a stopping policy.
D:A curated evidence window preserves useful facts while discarding noisy intermediate transcripts; the needed capability is different—host-controlled counters and deadlines bound execution regardless of what Claude decides next—and pruning must preserve commitments and results required for downstream steps.
Question 101
A maintenance agent should produce a proposed deployment plan before any configuration change occurs. Which development approach should be selected?
- Use Anthropic-hosted managed execution where supported
- Gate a write tool behind a transaction boundary
- Separate planning from execution
- Serialize dependent tool calls
Explanation
Correct Answer
C:The application can review and authorize the plan before handing it to a restricted executor; its operational boundary is that treating a plan as permission to execute is a serious privilege error.
Incorrect Answers
A:Managed runtime can reduce infrastructure ownership for supported agent operations; the requirement instead turns on this behavior: the application can review and authorize the plan before handing it to a restricted executor; hosted deployment still requires review of data paths, available tools, and platform limitations.
B:The application coordinates the write with transactional or compensating logic outside the model; this cannot substitute for the behavior that the application can review and authorize the plan before handing it to a restricted executor, because language-model intent is not a database rollback guarantee.
D:Sequential execution preserves the data dependency and passes the created ID to the following action; this addresses a separate concern, not the fact that the application can review and authorize the plan before handing it to a restricted executor; running the payment call early risks missing or stale identifiers.
Question 102
A model-generated record repeatedly fails JSON validation and may contaminate a financial data pipeline. Which option best fits the described workflow?
- Escalate a persistent authorization denial
- Use a retry budget for transient calls
- Reproduce with a raw valid API request
- Quarantine malformed output for review
Explanation
Correct Answer
D:Failed artifacts are retained securely for diagnostics and excluded from the production write path; the important constraint is that automatically coercing unknown fields risks corrupting downstream ledgers.
Incorrect Answers
A:Operators investigate credentials and permissions through the proper access workflow; by comparison, the intended solution relies on this: failed artifacts are retained securely for diagnostics and excluded from the production write path; retries or prompt pressure must not be used to bypass access controls.
B:A bounded attempt count and deadline balance recovery against cost and responsiveness; the needed capability is different—failed artifacts are retained securely for diagnostics and excluded from the production write path—and endless retries can exhaust quotas and mask permanent faults.
C:An isolated direct call distinguishes transport and wrapper behavior from a more complex integration path, whereas the requirement calls for another behavior: failed artifacts are retained securely for diagnostics and excluded from the production write path; a successful API response does not automatically validate downstream application logic.
Question 103
An assistant requests the status of unrelated warehouses whose responses are not interdependent. Which change would satisfy the constraint?
- Serialize conflicting writes to shared state
- Read the returned tool_use ID and name
- Reconcile all returned tool results before synthesis
- Dispatch independent read-only calls in parallel
Explanation
Correct Answer
D:Concurrent safe execution shortens latency while preserving per-call identifiers; in production, read operations still need rate limits and isolation under load.
Incorrect Answers
A:Coordination or transactions prevent lost updates and inconsistent final state; this addresses a separate concern, not the fact that concurrent safe execution shortens latency while preserving per-call identifiers; independent model-generated reasoning does not provide concurrency control.
B:Each client tool request includes metadata that ties subsequent execution and results to that call; here, the controlling capability is that concurrent safe execution shortens latency while preserving per-call identifiers, but guessing an operation from nearby text can dispatch the wrong function.
C:The harness maps all available results to their calls before requesting a comparative answer; the missing capability is more specific: concurrent safe execution shortens latency while preserving per-call identifiers; ignoring a pending result can produce an unsupported recommendation.
Question 104
A user's network fails halfway through a response and the server must decide whether to cancel or preserve state. Which production safeguard is most relevant?
- Use a queue for disconnected long-running workloads
- Apply UI rendering backpressure
- Handle a disconnect during generation
- Parse SSE frames at event boundaries
Explanation
Correct Answer
C:Stream lifecycle logic records interruption and avoids falsely marking partial output complete, subject to this requirement: the final message-stop signal has not been observed after a broken connection.
Incorrect Answers
A:Durable queued work survives client disconnection and exposes later status; this cannot substitute for the behavior that stream lifecycle logic records interruption and avoids falsely marking partial output complete, because keeping an open WebSocket alone does not make background jobs persistent.
B:Batching display updates preserves order while reducing unnecessary layout work; in contrast, stream lifecycle logic records interruption and avoids falsely marking partial output complete, while excessive rendering frequency can cause jank even when API streaming is fast.
D:A buffered parser reconstructs complete event frames before decoding their data; here, the controlling capability is that stream lifecycle logic records interruption and avoids falsely marking partial output complete, but treating every TCP chunk as one whole JSON object will fail unpredictably.
Question 105
The application needs to send the customer's changing question while preserving its own policy independently. How should this requirement be met?
- Use a user content block for the actual request
- Use the Messages API system field for app-wide behavior
- Keep user instructions subordinate to security policy
- Use an explicit tool definition for callable business actions
Explanation
Correct Answer
A:A user message carries the current request as task data subordinate to the system rules; the important constraint is that treating customer input as a new system instruction would invert the intended trust hierarchy.
Incorrect Answers
B:Server code supplies a governing system instruction separately from the user-message array; the requirement instead turns on this behavior: a user message carries the current request as task data subordinate to the system rules; placing it inside user-supplied text exposes the rule to unintended editing and trust confusion.
C:The application enforces identity and authorization checks despite the request's wording; this cannot substitute for the behavior that a user message carries the current request as task data subordinate to the system rules, because requests from end users do not grant new backend privileges.
D:Tool schemas advertise an available operation and define its structured inputs; in contrast, a user message carries the current request as task data subordinate to the system rules, while a prose instruction mentioning a function does not register it with the API.
Question 106
An asynchronous bulk job finishes with some requests successful and others errored. Which capability is necessary for this outcome?
- Correlate batch results by custom identifiers
- Handle partial failures inside a batch
- Submit independent offline jobs to Message Batches
- Handle ping events without treating them as content
Explanation
Correct Answer
B:Per-item result handling records and retries appropriate failures without duplicating successful work; in production, a batch-level completion event does not imply every included request succeeded.
Incorrect Answers
A:Stable request IDs let the application map each result to the correct original record; the missing capability is more specific: per-item result handling records and retries appropriate failures without duplicating successful work; relying on result ordering can mix customer records or output destinations.
C:Batch submission processes asynchronous independent requests efficiently and can reduce input/output processing cost; the needed capability is different—per-item result handling records and retries appropriate failures without duplicating successful work—and it does not provide a synchronous final message for a user awaiting an immediate reply.
D:Ping events maintain connectivity but do not represent assistant text to display, whereas the requirement calls for another behavior: per-item result handling records and retries appropriate failures without duplicating successful work; showing keepalives as answer content would corrupt the rendered response.
Question 107
A monorepo needs different test conventions for its backend and frontend packages. Which approach targets the deciding condition?
- Place narrow guidance close to the relevant code
- Start a new session for an unrelated objective
- Use CLAUDE.md for repository instructions
- Keep secrets outside coding-agent memory files
Explanation
Correct Answer
A:Scoped project guidance can communicate local conventions without overloading every task with unrelated instructions; the implementation must still recognize that conflicting guidance across scopes should be reviewed for effective precedence.
Incorrect Answers
B:A clean context prevents old task details from biasing the new investigation; the missing capability is more specific: scoped project guidance can communicate local conventions without overloading every task with unrelated instructions; shared persistent project guidance may still apply independently of session history.
C:A project instruction file provides contextual guidance when Claude Code works in that repository; by comparison, the intended solution relies on this: scoped project guidance can communicate local conventions without overloading every task with unrelated instructions; it is explanatory context rather than a security boundary enforcing tool privileges.
D:Credentials remain in protected stores or environment controls rather than committed textual guidance; the needed capability is different—scoped project guidance can communicate local conventions without overloading every task with unrelated instructions—and a shared file can be copied, logged, and inherited by unintended readers.
Question 108
A coding assistant must execute untrusted test snippets while preserving confidential project files. Which choice should be used here?
- Use a hook for mandatory pre-execution validation
- Use a sandbox for model-requested code execution
- Use structured tool schemas for business actions
- Add a human gate for high-stakes changes
Explanation
Correct Answer
B:Process and network isolation contain potential side effects of generated programs, subject to this requirement: a model's internal safety judgment is not an OS permission boundary.
Incorrect Answers
A:A lifecycle hook evaluates the proposed action outside the model and can block it deterministically; in contrast, process and network isolation contain potential side effects of generated programs, while natural-language checklists are weaker than enforced execution controls.
C:Typed schemas and dispatcher checks convert an intention into a constrained operation; here, the controlling capability is that process and network isolation contain potential side effects of generated programs, but general Skill text cannot replace a server-enforced action interface.
D:Approval controls and audit records separate planning from privileged commitment; the missing capability is more specific: process and network isolation contain potential side effects of generated programs; a system prompt telling the model to act cautiously does not itself block execution.
Question 109
A legal compliance question presents competing interpretations that exceed the agent's approved authority. What is the correct engineering decision?
- Build a task plan with measurable completion criteria
- Use checkpointed milestones
- Use a compact task summary for handoff
- Use a fallback to a human decision-maker
Explanation
Correct Answer
D:Escalation transfers the ambiguous decision with relevant evidence and uncertainties; the implementation must still recognize that generating a confident answer is not an acceptable replacement for the required human approval.
Incorrect Answers
A:A plan with explicit deliverables and stop checks makes progress and completion observable; this cannot substitute for the behavior that escalation transfers the ambiguous decision with relevant evidence and uncertainties, because planning quality does not replace runtime controls on tools and duration.
B:Milestone artifacts preserve progress and support a safe resume after transient interruptions; in contrast, escalation transfers the ambiguous decision with relevant evidence and uncertainties, while checkpoints must be consistent with any external actions already committed.
C:A narrow summary communicates findings, evidence, and unresolved questions within a smaller token budget; this addresses a separate concern, not the fact that escalation transfers the ambiguous decision with relevant evidence and uncertainties; it must not silently claim unverified findings are authoritative.
Question 110
An answer is being composed with several facts verified but one critical prerequisite still uncertain. What should the team do at this decision point?
- Track source timestamps or versions
- Keep unresolved questions explicit
- Attach source IDs to retrieved excerpts
- Keep pointers to source documents
Explanation
Correct Answer
B:Recording open issues prevents compaction from converting uncertainty into an invented guarantee, subject to this requirement: suppressing gaps for a cleaner paragraph undermines factual reliability.
Incorrect Answers
A:Version metadata allows the agent to prefer current evidence and flag historical material; in contrast, recording open issues prevents compaction from converting uncertainty into an invented guarantee, while timestamp alone does not establish which source is authoritative.
C:Citation metadata lets downstream logic connect statements to original retrieved material; here, the controlling capability is that recording open issues prevents compaction from converting uncertainty into an invented guarantee, but without accurate source mapping, fabricated references can look convincing.
D:References and identifiers enable later retrieval without copying the entire source into every prompt; the missing capability is more specific: recording open issues prevents compaction from converting uncertainty into an invented guarantee; pointers alone do not make an inaccessible document available at inference time.