Summer Sale 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: exams65

ExamsBrite Dumps

Claude Certified Architect – Foundations Question and Answers

Claude Certified Architect – Foundations

Last Update Aug 28, 2026
Total Questions : 152

We are offering FREE CCAR-F Anthropic exam questions. All you do is to just go and sign up. Give your details, prepare CCAR-F free exam questions and then go for complete pool of Claude Certified Architect – Foundations test questions that will help you more.

CCAR-F pdf

CCAR-F PDF

$36.75  $104.99
CCAR-F Engine

CCAR-F Testing Engine

$43.75  $124.99
CCAR-F PDF + Engine

CCAR-F PDF + Testing Engine

$57.75  $164.99
Questions 1

You have configured the system so that all four subagents have access to the complete set of 18 tools. During testing, agents frequently call tools outside their specialization—the synthesis agent attempts web searches, and the report generator tries to analyze documents. What is the primary cause of this poor tool-selection behavior?

Options:

A.  

The agents’ role descriptions in their system prompts conflict with having access to tools outside those roles.

B.  

The tool definitions consume too much context-window space, leaving insufficient room for task content.

C.  

The coordinator cannot track which capabilities each subagent has, leading to misrouted tasks.

D.  

Choosing from 18 tools instead of four or five relevant tools increases decision complexity beyond reliable selection thresholds.

Discussion 0
Questions 2

Your pipeline runs:

PROMPT= " You are a code reviewer. "

PROMPT= " $PROMPT Analyze the provided diff "

PROMPT= " $PROMPT for bugs, security issues, "

PROMPT= " $PROMPT and style violations. "

claude -p \

--dangerously-skip-permissions \

--system-prompt " $PROMPT " < diff.txt

The reviews complete and return feedback, but Claude comments only on the piped diff—it never reads surrounding files in the checked-out repository to understand broader context, even when the diff modifies a function called by many other modules. Which change to the invocation will cause Claude to read related repository files while still applying your custom review instructions?

Options:

A.  

Keep --system-prompt and add --allowedTools " Read, Glob, Grep " because non-interactive -p mode otherwise disables filesystem tools.

B.  

Replace --system-prompt with --append-system-prompt so the review instructions are added to Claude Code’s default prompt instead of overwriting its built-in file-reading and code-navigation guidance.

C.  

Remove --system-prompt entirely and place the review instructions in a root-level CLAUDE.md because --system-prompt is incompatible with tool use under -p.

D.  

Stop piping the diff through standard input and embed it in the prompt string so Claude Code treats the invocation as an agentic session rather than a stream-processing operation.

Discussion 0
Questions 3

You are building a multi-agent research system using the Claude Agent SDK. A coordinator agent delegates to specialized subagents: one searches the web, one analyzes documents, one synthesizes findings, and one generates reports. The system researches topics and produces comprehensive, cited reports.

The document-analysis agent has a single analyze_document tool that takes a document and a free-text instruction parameter. During evaluation, requests such as “extract the key financial metrics” often return narrative summaries, while “summarize the methodology” sometimes returns raw data tables. The synthesis agent reports that 35% of analysis results require new requests with clarified instructions.

What is the most effective way to improve reliability?

Options:

A.  

Enhance the tool description with detailed examples showing how different instruction phrasings should map to different output formats.

B.  

Split the generic tool into purpose-specific tools—extract_data_points, summarize_content, and verify_claim_against_source—each with defined input and output contracts.

C.  

Keep the single tool but add an analysis_type enum parameter requiring explicit selection between extraction, summarization, and verification modes.

D.  

Have the coordinator pre-classify each analysis request before passing instructions to the document-analysis agent.

Discussion 0
Questions 4

In production, you observe that simple fact-checking queries—for example, “What year was the Paris Climate Agreement signed?”—traverse all four subagents sequentially, consuming more than 40 seconds and significant tokens per query. Complex comparative research benefits from the full pipeline. Your query distribution is diverse and evolving as users discover new applications. What is the most effective approach to optimize for varying query complexity?

Options:

A.  

Create a fast path for factual questions that bypasses subagents entirely, routing all other queries through the complete pipeline to ensure research thoroughness.

B.  

Train a query-complexity classifier on labeled historical data to predict optimal subagent combinations, retraining it periodically as query patterns evolve.

C.  

Have the coordinator analyze each query and dynamically decide which subagents to invoke based on its assessment of the query requirements.

D.  

Implement pattern-based routing that categorizes queries by structure—single-fact, comparative, or analytical—and maps each category to a predefined subagent combination.

Discussion 0
Questions 5

You built an LLM-powered code-review tool that analyzes pull requests and returns structured findings. Each finding is a JSON object containing file_path, line_number, issue_category—such as security or style—and description. Developers can dismiss findings they consider unhelpful, and currently 35% of findings are dismissed. You want to analyze these dismissals to understand what the system is getting wrong and improve the prompts accordingly. What change to the output structure would best support this analysis?

Options:

A.  

Add a model_confidence field from 0.0 to 1.0 and filter findings below a threshold calibrated against historical dismissal rates.

B.  

Add a detected_pattern field recording the specific code construct that triggered the finding, such as single-letter loop variable.

C.  

Expand the description field with more detailed explanations of why each issue matters and how it should be fixed.

D.  

Remove the issue_category field and track dismissal rates only at the individual-finding level.

Discussion 0
Questions 6

You are integrating Claude Code into your Continuous Integration/Continuous Deployment (CI/CD) pipeline. The system runs automated code reviews, generates test cases, and provides feedback on pull requests. You need to design prompts that provide actionable feedback and minimize false positives.

The automated review consistently flags patterns your team uses intentionally—force-unwrapping optionals in test files, using large coordinator classes that follow your established architecture, and importing internally maintained modules marked as deprecated in the public SDK. Developers dismiss approximately 30% of all findings as project-specific false positives.

Which approach prevents the model from generating these findings in the first place by supplying the project’s conventions as persistent context during every review?

Options:

A.  

Document the team’s accepted patterns and intentional conventions in the project’s CLAUDE.md file so the model receives this context during every review.

B.  

Configure the review to analyze only the changed lines in the diff without the surrounding file context, reducing the amount of code the model evaluates.

C.  

Build post-processing keyword filters that suppress findings containing terms such as “force unwrap,” “large class,” or “deprecated import” before results reach developers.

D.  

Have developers add inline suppression comments at flagged lines and preprocess diffs to exclude suppressed lines before sending code to the model.

Discussion 0
Questions 7

You are building a structured data extraction system using Claude. The system extracts information from unstructured documents, validates the output using JSON schemas, and maintains high accuracy. It must handle edge cases gracefully and integrate with downstream systems.

Your extraction uses tool use with a JSON schema in which property_type is defined as an enum: house, apartment, condo, or townhouse. After deployment, 8% of extractions fail schema validation. Investigation reveals that listings mention many uncommon property types—“studio,” “loft,” “duplex,” “mobile home,” “tiny house,” and “converted warehouse”—and new types continue appearing regularly.

What is the most effective long-term solution?

Options:

A.  

Change property_type from an enum to a free-form string and implement a normalization step in post-processing.

B.  

Add few-shot examples demonstrating how to map unexpected property types to the closest existing enum value.

C.  

Continuously expand the enum to include newly observed property types and add monitoring for additional edge cases.

D.  

Add an other value to the enum with a separate property_type_detail string field for specifics when other is selected.

Discussion 0
Questions 8

After deploying the automated review, you notice high precision but low recall—real bugs are slipping through undetected. Investigation reveals that your review prompt instructs Claude to “only report high-confidence issues you are certain about” and “err on the side of not commenting.” Developers appreciate the low noise, but a race condition that caused a production outage was visible in a reviewed pull request and went unreported. You need to substantially improve bug detection while keeping false-positive rates manageable. What is the most effective approach?

Options:

A.  

Add detailed few-shot examples demonstrating bug categories Claude should flag—race conditions, null dereferences, and error-handling gaps—while retaining the high-confidence filtering instruction.

B.  

Remove the conservative instructions and have Claude report every potential issue, then apply a programmatic filter that deduplicates findings and suppresses historically noisy categories.

C.  

Split the review into a finding stage whose objective is comprehensive coverage—reporting every potential issue with confidence and severity metadata—and a separate stage that verifies and thresholds those findings.

D.  

Expand the context to include related tests, recent Git history, and the module’s dependency graph so Claude has richer evidence for judging severity.

Discussion 0
Questions 9

You are building a multi-agent research system using the Claude Agent SDK. A coordinator agent delegates to specialized subagents: one searches the web, one analyzes documents, one synthesizes findings, and one generates reports. The system researches topics and produces comprehensive, cited reports.

In production, you observe that simple fact-checking queries, such as “In what year was the Paris Climate Agreement signed?”, traverse all four subagents sequentially, consuming more than 40 seconds and significant tokens per query. Complex comparative research benefits from the complete pipeline. Your query distribution is diverse and continues to evolve as users discover new applications.

What is the most effective approach to optimize for varying query complexity?

Options:

A.  

Create a fast path for factual questions that bypasses subagents entirely, routing every other query through the complete pipeline.

B.  

Train a query-complexity classifier using labeled historical data to predict the optimal subagent combination, retraining it periodically.

C.  

Implement pattern-based routing that classifies queries as single-fact, comparative, or analytical and maps each category to a predefined subagent combination.

D.  

Have the coordinator analyze each query and dynamically determine which subagents are required.

Discussion 0
Questions 10

Production monitoring shows that the research phase takes longer than expected. Analysis reveals that the coordinator invokes the web-search subagent, waits for its response, and then invokes the document-analysis subagent. These tasks are independent; neither requires the other’s output. How should you modify the system to run these subagents concurrently?

Options:

A.  

Structure the coordinator to emit both Agent tool calls—for web search and document analysis—in a single response message instead of separate conversation turns.

B.  

Switch both subagents from a Sonnet-tier model to a Haiku-tier model to reduce their individual execution times.

C.  

Add instructions explaining the performance benefits of parallel execution and request that the coordinator invoke both subagents simultaneously.

D.  

Create an asynchronous orchestration layer that launches parallel threads, each running a separate coordinator-subagent pair, and then aggregates the results.

Discussion 0
Questions 11

You are integrating Claude Code into your Continuous Integration/Continuous Deployment (CI/CD) pipeline. The system runs automated code reviews, generates test cases, and provides feedback on pull requests. You need to design prompts that provide actionable feedback and minimize false positives.

Your automated reviewer uses a single prompt covering security issues, API design, and business-logic correctness. Your evaluation suite shows strong recall for API-design findings at 82% but poor recall for business-logic edge cases in quiz scoring at 34%. When you add few-shot examples of logic bugs to the prompt, logic recall improves to 41%, but API-design recall drops to 68%.

How should you address this trade-off to improve detection across both categories?

Options:

A.  

Split the review into separate focused prompts—one for security and API design and another for business logic—each with dedicated examples, and then consolidate the findings before posting.

B.  

Replace the few-shot examples with a detailed checklist of specific logic edge cases to verify, such as division by zero in score calculations and boundary conditions in grading thresholds.

C.  

Upgrade to a more capable model tier because its stronger reasoning will handle both concern types in one prompt and eliminate the recall trade-off.

D.  

Provide the full repository as context instead of only the changed files and surrounding code, giving the model deeper visibility into business-logic patterns.

Discussion 0
Questions 12

The coordinator agent has AgentDefinition objects configured for all four specialized subagents, each with appropriate descriptions, prompts, and tool restrictions. During testing, you notice that the coordinator correctly reasons about when to delegate—it generates messages such as, “I’ll ask the web-search agent to find sources on this topic”—but no subagent execution occurs. The coordinator then proceeds as if the delegation happened and continues with incomplete information. Logs show no errors. What is the most likely cause?

Options:

A.  

The AgentDefinition objects are configured correctly, but the coordinator’s system prompt does not explicitly list the available subagent types.

B.  

The coordinator’s allowedTools configuration does not include " Agent " —called " Task " in older SDK releases—so it cannot invoke the tool required to spawn subagents.

C.  

Subagent context isolation prevents task descriptions from reaching subagents unless explicit context forwarding is configured in ClaudeAgentOptions.

D.  

The coordinator’s max_tokens setting is too low, causing the subagent invocation to be truncated before the agent-type parameter is specified.

Discussion 0
Questions 13

You are building a multi-agent research system using the Claude Agent SDK. A coordinator agent delegates to specialized subagents: one searches the web, one analyzes documents, one synthesizes findings, and one generates reports. The system researches topics and produces comprehensive, cited reports.

A user expands the research system beyond its original web-search agent by adding specialized data sources. A financial API agent returns structured JSON containing revenue, margins, and growth rates. A news-monitoring agent returns prose summaries of recent developments. A patent-analysis agent returns structured lists of technology areas. The synthesis agent combines these results into executive briefings. Currently, it converts everything into bullet points, causing financial comparisons to lose tabular clarity and news summaries to lose their narrative flow.

What change would most improve briefing quality?

Options:

A.  

Standardize all subagent outputs as prose summaries with inline citations.

B.  

Add a format-conversion layer that transforms every subagent output into a common intermediate representation.

C.  

Update the synthesis agent to render each content type appropriately—for example, financial data as tables, news as prose, and patent areas as structured lists.

D.  

Standardize all subagent outputs as JSON containing claim , evidence , source , and confidence fields.

Discussion 0
Questions 14

You are building a structured data extraction system using Claude. The system extracts information from unstructured documents, validates the output using JavaScript Object Notation (JSON) schemas, and maintains high accuracy. It must handle edge cases gracefully and integrate with downstream systems.

Your extraction system implements automatic retries when validation fails. On each retry, the specific validation error is appended to the prompt. This retry-with-error-feedback approach resolves most failures within 2–3 attempts.

For which failure pattern would additional retries be LEAST effective?

Options:

A.  

The model extracts keywords as a nested object organized by category when the schema requires a flat array of strings.

B.  

The model extracts “et al.” for co-authors when the full list exists only in an external document not in the input.

C.  

The model extracts citation counts as locale-formatted strings (“1,234”) when the schema requires integers.

D.  

The model extracts dates as ISO 8601 datetime strings (“2023-03-15T00:00:00Z”) when the schema requires only the date portion (YYYY-MM-DD).

Discussion 0
Questions 15

Your pipeline includes a release-notes generation step that classifies and summarizes approximately 200 commits at the end of each weekly release cycle. Each commit is currently sent as a separate Messages API call using a Sonnet-tier Claude model. The release notes are not needed until the following morning, so results have approximately 12 hours of acceptable latency. Your team needs to reduce per-token API cost for this step while keeping the same model and prompts, with no change to the model tier or output quality. Which approach satisfies all these constraints?

Options:

A.  

Concatenate all 200 commit messages into a single Messages API request and have the model return all summaries in one response, because fewer requests always reduce total token cost.

B.  

Issue the 200 Messages API requests in parallel using concurrent connections, because concurrency lowers the per-token price charged by the API.

C.  

Submit the 200 requests to the Message Batches API with unique custom_id values and retrieve the results after the batch finishes, which applies a 50% discount to all input and output tokens.

D.  

Switch the summarization calls from the Sonnet-tier model to a Haiku-tier model to take advantage of Haiku’s lower per-token rates.

Discussion 0
Questions 16

Your pipeline reviews approximately 200 database-migration scripts daily using the Message Batches API. Each request includes a shared 8,000-token system prompt containing migration-review guidelines and schema documentation, followed by an individual migration script. You added cache_control breakpoints to the shared system prompt in every request, but monitoring shows cache-hit rates of only 32%, with misses concentrated among requests processed later in the batch window. Which change addresses the root cause without adding sequential-processing latency?

Options:

A.  

Split the 200 requests into ten sequential batches of 20, submitting each batch only after the previous batch completes.

B.  

Add cache-prewarming requests with max_tokens: 0 at the beginning of every batch.

C.  

Move the cache_control breakpoint from the shared system prompt to each migration script so similar code patterns can be reused.

D.  

Configure the cache breakpoints to use the extended one-hour TTL instead of the default five-minute TTL.

Discussion 0
Questions 17

You are using Claude Code to accelerate software development. Your team uses it for code generation, refactoring, debugging, and documentation. You need to integrate it into your development workflow with custom slash commands, CLAUDE.md configurations, and understand when to use plan mode vs direct execution.

A security audit requires updating your authentication library from v2 to v3. The migration guide documents breaking changes: authenticate() now returns a Promise instead of accepting a callback, the User type has restructured fields, and three deprecated methods were removed. Grep shows the library is imported in 45 files across several modules.

What’s the most effective approach?

Options:

A.  

Create a custom slash command encapsulating the migration transformations, then execute it against each file without prior codebase exploration.

B.  

Update the dependency version, run the test suite, and use Claude Code to fix each failure as it appears.

C.  

Enter plan mode to explore library usage across modules, map affected code paths, then create a migration strategy before implementing.

D.  

Paste the migration guide’s breaking changes into your prompt and use direct execution to update all usages across the 45 files.

Discussion 0
Questions 18

You are building developer productivity tools using the Claude Agent SDK. The agent helps engineers explore unfamiliar codebases, understand legacy systems, generate boilerplate code, and automate repetitive tasks. It uses the built-in tools (Read, Write, Bash, Grep, Glob) and integrates with Model Context Protocol (MCP) servers.

An engineer used the agent yesterday to analyze a legacy authentication module, identifying two distinct refactoring approaches: extracting a microservice versus refactoring in-place. Today, they want to explore both approaches in depth—having the agent propose specific code changes for each—before deciding which to implement.

What’s the most effective way to structure this exploration?

Options:

A.  

Use fork_session to create two branches from yesterday’s analysis, exploring one approach in each fork.

B.  

Resume yesterday’s session and explore both approaches sequentially within the same conversation thread.

C.  

Resume yesterday’s session to explore the first approach, then start a new session for the second, manually recreating the original context.

D.  

Start two fresh sessions, manually providing a summary of yesterday’s analysis findings to establish context.

Discussion 0
Questions 19

You are integrating Claude Code into your Continuous Integration/Continuous Deployment (CI/CD) pipeline. The system runs automated code reviews, generates test cases, and provides feedback on pull requests. You need to design prompts that provide actionable feedback and minimize false positives.

Your test generation produces unit tests for new code, but reviews show that 55% are low-value: trivial assertions that only verify functions do not throw exceptions, tests duplicating existing coverage, or tests ignoring your team’s fixture conventions.

How do you reduce the rate of low-value tests being generated in the first place?

Options:

A.  

Implement two-phase generation in which a second Claude call scores each test against quality criteria, filtering out low-scoring tests before presenting results to developers.

B.  

Add post-generation coverage analysis that automatically filters out any generated test that does not increase line coverage beyond existing tests.

C.  

Restrict test generation to directories where historical quality metrics show higher acceptance rates, disabling it for areas where generated tests consistently require substantial editing.

D.  

Document testing standards in CLAUDE.md, including valuable-test criteria, available fixtures and their intended use cases, and examples distinguishing meaningful behavioral tests from trivial assertions.

Discussion 0
Questions 20

A customer sends: “This is frustrating. I’ve explained my issue twice and nothing is being resolved. I want to talk to a real person NOW.” The agent has not yet called any tools to investigate the customer’s account. What should the agent do?

Options:

A.  

Briefly explain what the agent can help with and offer to resolve the issue quickly, escalating only if the customer repeats the request.

B.  

First call get_customer and lookup_order to gather account context, and then escalate to a human agent.

C.  

Immediately call escalate_to_human with the conversation history.

D.  

Acknowledge the frustration and ask one targeted question to understand the specific issue before escalating.

Discussion 0
Questions 21

Your test-generation process produces unit tests for new code, but reviews show that 55% are low-value: trivial assertions that verify only that functions do not throw exceptions, tests that duplicate existing coverage, or tests that ignore your team’s fixture conventions. How should you reduce the rate of low-value tests being generated in the first place?

Options:

A.  

Restrict test generation to directories where historical quality metrics show higher acceptance rates, disabling it in areas where generated tests consistently require substantial editing.

B.  

Implement two-phase generation in which a second Claude call scores every test against quality criteria and filters out low-scoring tests before presenting them to developers.

C.  

Document your testing standards in CLAUDE.md, including valuable-test criteria, available fixtures and their intended uses, and examples distinguishing meaningful behavioural tests from trivial assertions.

D.  

Add post-generation coverage analysis that automatically filters out every generated test that does not increase line coverage beyond the existing test suite.

Discussion 0
Questions 22

You are building a customer support resolution agent using the Claude Agent SDK. The agent handles high-ambiguity requests like returns, billing disputes, and account issues. It has access to your backend systems through custom Model Context Protocol (MCP) tools ( get_customer , lookup_order , process_refund , escalate_to_human ). Your target is 80%+ first-contact resolution while knowing when to escalate.

Your process_refund tool returns two types of errors: technical errors (“503 Service Unavailable”, “Connection timeout”) that are transient (~5% of calls), and business errors (“Order exceeds 30-day return window”, “Item already refunded”) that are permanent (~12% of calls). Monitoring shows the agent wastes 3–4 turns retrying business errors that can never succeed. Currently, both error types return only a plain text message to Claude.

What’s the most effective way to reduce wasted retries while improving customer-facing response quality?

Options:

A.  

Implement automatic retry logic at the tool layer for technical errors only, passing business errors to Claude without retries.

B.  

Add few-shot examples showing how to distinguish retriable from non-retriable errors by parsing error message text.

C.  

Add a check_refund_eligibility tool that must be called before process_refund to prevent business rule violations.

D.  

Return structured error responses with " retriable " : false for business errors and a customer-friendly explanation for Claude to use.

Discussion 0
Questions 23

You are building developer productivity tools using the Claude Agent SDK. The agent helps engineers explore unfamiliar codebases, understand legacy systems, generate boilerplate code, and automate repetitive tasks. It uses the built-in tools (Read, Write, Bash, Grep, Glob) and integrates with Model Context Protocol (MCP) servers.

An engineer submits two requests:

    Request A: “Rename the getUserData function to fetchUserProfile everywhere it’s used.”

    Request B: “Improve error handling throughout the data processing module—add try/catch blocks, meaningful error messages, and ensure failures don’t silently corrupt data.”

For which request does specifying an explicit multi-phase workflow (such as analyze → propose → implement with review) most improve outcome quality?

Options:

A.  

Neither request benefits significantly

B.  

Request A, the function rename task

C.  

Both requests benefit equally

D.  

Request B, the error handling task

Discussion 0
Questions 24

You are integrating Claude Code into your Continuous Integration/Continuous Deployment (CI/CD) pipeline. The system runs automated code reviews, generates test cases, and provides feedback on pull requests. You need to design prompts that provide actionable feedback and minimize false positives.

Your automated review calls the Claude API for each pull request, using tool_use with a report_findings tool that returns a JSON array of finding objects. Each object contains file_path, line_number, severity, category, and description. During testing on a large pull request touching more than 30 files, the response reaches the max_tokens limit and is truncated in the middle of the JSON, causing your pipeline’s parser to fail.

What is the most effective way to handle this?

Options:

A.  

Split the review into multiple API calls that each analyze a subset of the changed files, and then merge the resulting findings arrays.

B.  

Increase max_tokens to the model’s maximum and instruct Claude to keep each finding description under 50 words.

C.  

Switch from tool_use to prompting Claude to return findings as a Markdown list.

D.  

Add retry logic that detects truncated JSON and resends the request with instructions to report only critical and high-severity findings.

Discussion 0
Questions 25

You are building a structured data extraction system using Claude. The system extracts information from unstructured documents, validates the output using JavaScript Object Notation (JSON) schemas, and maintains high accuracy. It must handle edge cases gracefully and integrate with downstream systems.

Your system has been running for 3 weeks and human reviewers have corrected 847 extractions. Analysis reveals a recurring pattern: when recipes use informal measurements like “a handful” or “a splash,” the model either invents specific amounts or leaves fields empty—accounting for 23% of all corrections.

How should you use this feedback to improve extraction accuracy?

Options:

A.  

Fine-tune the model on the 847 corrected extractions.

B.  

Add few-shot examples to your prompt demonstrating correct handling of informal measurements—extracting them verbatim rather than converting or omitting them.

C.  

Implement a post-processing layer that uses pattern matching to detect informal measurement phrases in source text and automatically populate values when the extraction is empty.

D.  

Update your JSON schema to add a “measurement_type” enum field (precise/informal).

Discussion 0
Questions 26

The web-search agent has gathered several relevant sources for a research topic. The document-analysis agent now needs to examine those sources. How does information typically flow between these two specialized subagents?

Options:

A.  

The coordinator receives the web-search agent’s output and includes the relevant sources and findings in the prompt used to invoke the document-analysis agent.

B.  

The web-search agent directly invokes the document-analysis agent and passes the discovered sources as parameters.

C.  

The agents communicate through an event-driven message queue, with the document-analysis agent subscribing to web-search completion events.

D.  

Both agents automatically access a shared memory store in which the web-search agent writes its findings.

Discussion 0
Questions 27

You are building a structured data extraction system using Claude. The system extracts information from unstructured documents, validates the output using JSON schemas, and maintains high accuracy. It must handle edge cases gracefully and integrate with downstream systems.

Your extraction system uses tool use with a JSON schema containing 12 fields and detailed descriptions, totaling approximately 2,500 tokens for the complete tool definition. Processing documents under 150,000 tokens yields 98% accuracy. For documents between 175,000 and 190,000 tokens, accuracy drops to 71%, with information from the final third consistently missed. The model’s context window is 200,000 tokens.

What is the most likely cause?

Options:

A.  

Schemas exceeding eight to ten fields increase decision complexity during parameter generation, reducing extraction accuracy independently of document length.

B.  

The model distributes attention proportionally across the input length, causing fields mentioned only once near the document’s end to receive insufficient processing focus.

C.  

Very long documents exceed the model’s effective attention span regardless of context limits, causing accuracy degradation for content farther from the prompt instructions.

D.  

Tool definitions consume input-context tokens. Combined with system prompts and document content, the total approaches the context limit, degrading end-of-document processing.

Discussion 0
Questions 28

You are building developer productivity tools using the Claude Agent SDK. The agent helps engineers explore unfamiliar codebases, understand legacy systems, generate boilerplate code, and automate repetitive tasks. It uses the built-in tools (Read, Write, Bash, Grep, Glob) and integrates with Model Context Protocol (MCP) servers.

Your code review assistant needs to analyze pull requests and provide feedback on three aspects: code style compliance, potential security issues, and documentation completeness. Each aspect requires reading files, running analysis tools, and generating a report section. The review process follows the same three-step workflow for every PR.

Which task decomposition pattern is most appropriate for this workflow?

Options:

A.  

Single comprehensive prompt—include all three instructions in one prompt and let the model handle all three aspects simultaneously.

B.  

Orchestrator-workers—have a central LLM analyze each PR to dynamically determine which checks are needed, then delegate to specialized worker LLMs for each identified subtask.

C.  

Prompt chaining—break the review into sequential steps where each aspect (style, security, documentation) is analyzed separately, with outputs combined in a final synthesis step.

D.  

Routing—classify each PR by type (feature, bugfix, refactor) first, then route to different review prompts optimized for that category.

Discussion 0
Questions 29

You are building a customer support resolution agent using the Claude Agent SDK. The agent handles high-ambiguity requests like returns, billing disputes, and account issues. It has access to your backend systems through custom Model Context Protocol (MCP) tools ( get_customer , lookup_order , process_refund , escalate_to_human ). Your target is 80%+ first-contact resolution while knowing when to escalate.

A customer raises three separate issues during one session: a refund inquiry (turns 1–15), a subscription question (turns 16–30), and a payment method update (turns 31–45). At turn 48, the customer asks “What happened with my refund?” The conversation is approaching context limits.

What strategy best maintains the agent’s ability to address all issues throughout the session?

Options:

A.  

Summarize earlier turns into a narrative description, preserving full message history only for the active issue.

B.  

Implement sliding window context that retains the most recent 30 turns.

C.  

Rely on MCP tools to re-fetch relevant information on demand when the customer references earlier issues.

D.  

Extract and persist structured issue data (order IDs, amounts, statuses) into a separate context layer.

Discussion 0
Questions 30

The automated review consistently flags patterns your team uses intentionally—force-unwrapping optionals in test files, using large coordinator classes that follow your established architecture, and importing internally maintained modules marked as deprecated in the public SDK. Developers are dismissing approximately 30% of all findings as project-specific false positives. Which approach prevents the model from generating these findings in the first place by supplying the project’s conventions as persistent context during every review?

Options:

A.  

Build post-processing keyword filters that suppress findings containing terms such as “force unwrap,” “large class,” or “deprecated import” before results reach developers.

B.  

Configure the review to analyze only the changed lines in the diff without surrounding file context, reducing the amount of code the model evaluates during each review.

C.  

Have developers add inline suppression comments at flagged lines and preprocess diffs to exclude suppressed lines before sending code to the model.

D.  

Document the team’s accepted patterns and intentional conventions in the project’s CLAUDE.md file so the model receives this context during every review.

Discussion 0
Questions 31

You are using Claude Code to accelerate software development. Your team uses it for code generation, refactoring, debugging, and documentation. You need to integrate it into your development workflow with custom slash commands, CLAUDE.md configurations, and understand when to use plan mode vs direct execution.

Your team has connected a custom MCP server that provides DevOps workflow templates. The server exposes several MCP prompts (such as deploy_checklist and incident_response ) in addition to tools.

How do these MCP prompts become accessible within Claude Code?

Options:

A.  

They are automatically prepended to every conversation as additional system-level context, influencing Claude’s behavior throughout the session.

B.  

They are added to Claude Code’s tool registry alongside the server’s tools, invoked automatically by the model when relevant to the task.

C.  

They are surfaced as @ -mentionable resources alongside files, fetched and attached to your message when referenced.

D.  

They appear as slash commands (e.g., /mcp__servername__deploy_checklist ) that you can invoke, with arguments passed after the command name.

Discussion 0
Questions 32

Your code-review prompts include both implementation changes and the corresponding test file, but the review comments fail to identify untested code paths. The model correctly flags functions that have no tests at all, but it fails to recognize when conditional branches or error-handling paths within tested functions lack coverage. What is the most effective way to improve branch-level gap detection without overcomplicating the pipeline?

Options:

A.  

Interleave the implementation and tests in the prompt, presenting each function immediately before its test cases.

B.  

Add explicit instructions requiring Claude to enumerate every conditional branch and exception path, then verify that each path has a corresponding test assertion.

C.  

Implement a two-pass pipeline in which one model call extracts all conditional branches and another cross-references them against test assertions.

D.  

Include few-shot examples showing code with an uncovered branch and the corresponding review comment identifying the missing test case.

Discussion 0
Questions 33

You are integrating Claude Code into your Continuous Integration/Continuous Deployment (CI/CD) pipeline. The system runs automated code reviews, generates test cases, and provides feedback on pull requests. You need to design prompts that provide actionable feedback and minimize false positives.

Your automated code review is missing genuine bugs in pull requests. Investigation reveals that your review prompt includes the instruction: “Only flag critical issues that would definitely cause production failures. Ignore minor concerns and anything you are uncertain about.” Developers confirm that some missed bugs are genuine logic errors that the model investigated but chose not to report. The team requires the review output to remain structured, with each finding tagged with metadata, and actionable.

Which prompt change both removes the cause of the suppressed findings and preserves structured, tagged output for downstream filtering?

Options:

A.  

Add a second review pass that rereads the diff using the same prompt, looking for anything the first pass may have missed.

B.  

Instruct the model to report all findings with confidence and severity tags, deferring filtering to a downstream step.

C.  

Remove all severity-related instructions from the prompt and let the model use its default judgment about what to report.

D.  

Enable extended thinking and instruct the model to reason step by step about every code change before producing its review.

Discussion 0
Questions 34

You are building a multi-agent research system using the Claude Agent SDK. A coordinator agent delegates to specialized subagents: one searches the web, one analyzes documents, one synthesizes findings, and one generates reports. The system researches topics and produces comprehensive, cited reports.

The synthesis agent receives summarized findings from the web-search and document-analysis agents, then passes a consolidated summary to the report generator. During testing, you discover that the generated reports make factual claims without proper citations. The report generator cannot attribute statements to their original sources because that metadata was lost during the summarization steps.

What is the most effective approach to ensure proper source attribution in the final reports?

Options:

A.  

Have each agent output structured data separating content summaries from source metadata such as URLs, document names, and page numbers.

B.  

Skip summarization and pass the complete raw outputs from web search and document analysis directly to the report generator.

C.  

Instruct the synthesis agent to embed source references inline within its summary text using a consistent citation format.

D.  

Have the report generator query the web-search agent to relocate sources for claims in the final report.

Discussion 0
Questions 35

You are building developer-productivity tools using the Claude Agent SDK. The agent helps engineers explore unfamiliar codebases, understand legacy systems, generate boilerplate code, and automate repetitive tasks. It uses the built-in tools—Read, Write, Bash, Grep, and Glob—and integrates with Model Context Protocol (MCP) servers.

You are building a security-scanning workflow.

When engineers need to locate every occurrence of a dangerous function such as eval() across a large codebase, which tool should the agent use for content searching?

Options:

A.  

Use Glob with a pattern such as **/eval* to locate files, and then read each matching file.

B.  

Use Grep to search for the regular-expression pattern eval\( across all files in the codebase.

C.  

Read the project’s main entry file and follow import statements to trace where eval() might be used.

D.  

Use Bash to run ls -R | grep eval and search the recursively listed filenames.

Discussion 0
Questions 36

You are building a multi-agent research system using the Claude Agent SDK. A coordinator agent delegates to specialized subagents: one searches the web, one analyzes documents, one synthesizes findings, and one generates reports. The system researches topics and produces comprehensive, cited reports.

The synthesis agent completes its initial pass but flags that three key research questions remain unanswered because the web-search and document-analysis agents did not find relevant information on those specific subtopics. The coordinator currently proceeds directly to report generation, producing reports with incomplete coverage.

What change would most effectively improve research completeness?

Options:

A.  

Increase the initial breadth of queries sent to web search and document analysis to reduce the probability of missing relevant information.

B.  

Have the coordinator evaluate the synthesis output for gaps, then re-delegate to web search and document analysis with targeted queries before invoking synthesis again.

C.  

Have the report-generation agent note which research questions could not be answered, so users understand the limitations of the final output.

D.  

Give the synthesis agent direct access to web-search tools so it can autonomously fill knowledge gaps without returning control to the coordinator.

Discussion 0
Questions 37

You are building a structured data extraction system using Claude. The system extracts information from unstructured documents, validates the output using JavaScript Object Notation (JSON) schemas, and maintains high accuracy. It must handle edge cases gracefully and integrate with downstream systems.

Your system extracts event metadata (date, location, organizer, attendee_count) from news articles using a JSON schema with all nullable fields. During evaluation, you observe the model frequently generates plausible but incorrect values for fields not mentioned in the article—for example, outputting “500” for attendee_count when the source contains no attendance information.

What’s the most effective way to reduce these false extractions?

Options:

A.  

Upgrade to a more capable model tier with improved instruction-following to reduce hallucination tendencies.

B.  

Make all schema fields required (non-nullable) with strict validation rules to ensure the model only outputs verifiable data.

C.  

Add prompt instructions to return null for any field where information is not directly stated in the source.

D.  

Add a post-processing step using a second LLM call to verify each extracted value exists in the source document.

Discussion 0
Questions 38

During testing, when a customer says, “I need a refund for my recent purchase,” the agent immediately invokes process_refund but populates the required order_id parameter with a plausible-looking fabricated value instead of first calling lookup_order. The refund fails because the invented order identifier does not exist. Which change directly addresses the root cause of the fabricated order_id?

Options:

A.  

Update the process_refund tool description to state explicitly that order_id must come from a successful lookup_order result and must never be assumed, inferred, or invented.

B.  

Change tool_choice from auto to any so Claude must call a tool on every turn.

C.  

Add server-side validation that checks whether order_id exists before attempting the refund and returns an error when it does not.

D.  

Preprocess customer messages to extract any mentioned order identifiers and inject them into the conversation before sending the request to Claude.

Discussion 0
Questions 39

You are building a structured data extraction system using Claude. The system extracts information from unstructured documents, validates the output using JavaScript Object Notation (JSON) schemas, and maintains high accuracy. It must handle edge cases gracefully and integrate with downstream systems.

The system needs to extract candidate information (name, contact details, skills, work experience, education) from uploaded resumes. The extracted data must strictly conform to a predefined JSON schema, as missing required fields or incorrect data types will cause downstream validation failures.

What is the most reliable approach to ensure Claude’s output consistently matches the schema?

Options:

A.  

Parse Claude’s text response with regex patterns to extract JSON objects, using retry logic for malformed responses.

B.  

Include detailed JSON formatting instructions and a template example in the system prompt, asking Claude to output only valid JSON.

C.  

Make two separate API calls—first extracting information as text, then asking Claude to format that text as JSON.

D.  

Define a tool with an input schema matching your required JSON structure and extract the data from Claude’s tool_use response.

Discussion 0
Questions 40

You are building a multi-agent research system using the Claude Agent SDK. A coordinator agent delegates to specialized subagents: one searches the web, one analyzes documents, one synthesizes findings, and one generates reports. The system researches topics and produces comprehensive, cited reports.

Production reviews reveal inconsistent handling of uncertainty in final reports. Sometimes conflicting subagent findings are synthesized into a single confident statement, losing important nuance, while other reports use excessive qualifications and become unhelpful. The web-search agent returns, “Industry analysts estimate a $50 billion market size, although methodologies vary.” The document-analysis agent returns, “A peer-reviewed study estimates $35 billion, with a ±$7 billion 95% confidence interval.” The coordinator either selects one estimate arbitrarily or produces a vague $35–$50 billion range.

What systematic approach best addresses this?

Options:

A.  

Implement a confidence-calibration layer that normalizes subagent uncertainty expressions to probability scores between 0.0 and 1.0, and then calculate a confidence-weighted average.

B.  

Configure subagents to report only findings meeting a high-confidence threshold, filtering uncertain information before it reaches the coordinator.

C.  

Add a verification subagent that passes claims to synthesis only when they are corroborated by at least two independent sources.

D.  

Instruct the synthesis agent to distinguish well-established findings from contested findings explicitly, preserving each source’s original uncertainty, methodology, and supporting evidence.

Discussion 0
Questions 41

You are building developer-productivity tools using the Claude Agent SDK. The agent helps engineers explore unfamiliar codebases, understand legacy systems, generate boilerplate code, and automate repetitive tasks. It uses the built-in tools—Read, Write, Bash, Grep, and Glob—and integrates with Model Context Protocol (MCP) servers.

After adding an MCP server with specialized code-refactoring tools—extract_function, rename_variable, and inline_function—you notice that the agent still uses basic text manipulation through Write and Bash sed commands for refactoring tasks. The MCP server is connected and healthy. Examining the configuration, you find that each MCP tool has a minimal description such as, “extract_function: Extracts a function from code.”

What is the most effective way to improve adoption of the MCP refactoring tools?

Options:

A.  

Implement a request classifier that detects refactoring intent and automatically routes those requests to the MCP server before the agent processes them.

B.  

Accept this as expected behavior because simpler tools such as sed are more predictable than specialized refactoring tools.

C.  

Enhance the MCP tool descriptions to explain when each tool is preferable to text manipulation and clarify expected inputs and outputs.

D.  

Remove the Write tool from the agent’s configuration for refactoring sessions so it must use the MCP tools for code modifications.

Discussion 0
Questions 42

After deploying automated code review, developers report that approximately 35% of flagged findings are false positives falling into consistent patterns: style suggestions contradicting team conventions, security warnings for patterns that are safe in your deployment context, and performance suggestions that would degrade your specific use case. You want to reduce false positives while maintaining the ability to catch genuine issues. Which approach best enables the model to generalize its judgment to novel code patterns it has not seen before?

Options:

A.  

Implement post-processing that uses keyword matching to filter out findings containing terms such as “convention,” “context-dependent,” or “trade-off.”

B.  

Include few-shot examples in your prompt showing annotated code snippets that distinguish acceptable patterns from genuine issues in each category.

C.  

Create a comprehensive written specification of all patterns that should not be flagged, and then include the full documentation in the system prompt.

D.  

Add instructions to your system prompt to “be conservative,” “only flag definite issues,” and “consider that some patterns may be intentional.”

Discussion 0
Questions 43

Your automated code review is missing genuine bugs in pull requests. Investigation reveals that the review prompt includes this instruction: “Only flag critical issues that would definitely cause production failures. Ignore minor concerns and anything you are uncertain about.” Developers confirm that some missed findings are genuine logic errors that the model investigated but chose not to report. The team requires the review output to remain structured, with every finding tagged with metadata, and actionable. Which prompt change both removes the cause of the suppressed findings and preserves structured, tagged output for downstream filtering?

Options:

A.  

Enable extended thinking and instruct the model to reason step by step about every code change before producing its review.

B.  

Instruct the model to report all findings with confidence and severity tags, deferring filtering to a downstream step.

C.  

Remove all severity-related instructions and allow the model to use its default judgment about which findings to report.

D.  

Add a second review pass that rereads the diff using the same prompt and looks for anything the first pass may have missed.

Discussion 0
Questions 44

You are building developer productivity tools using the Claude Agent SDK. The agent helps engineers explore unfamiliar codebases, understand legacy systems, generate boilerplate code, and automate repetitive tasks. It uses the built-in tools (Read, Write, Bash, Grep, Glob) and integrates with Model Context Protocol (MCP) servers.

An engineer used Claude Code yesterday to investigate authentication flows in a legacy monolith, building up significant context over a 2-hour session. Today she wants to continue that specific investigation. She’s worked on three other codebases since then and knows the session was named “auth-deep-dive”.

How should she resume?

Options:

A.  

Use --session-id with the UUID from yesterday’s session transcript file

B.  

Use --continue to pick up where the most recent conversation left off

C.  

Start fresh and re-read the same files

D.  

Use --resume auth-deep-dive to load that specific session by name

Discussion 0
Questions 45

You are building a structured data extraction system using Claude. The system extracts information from unstructured documents, validates the output using JSON schemas, and maintains high accuracy. It must handle edge cases gracefully and integrate with downstream systems.

Your extraction pipeline occasionally receives responses that cannot be parsed as valid JSON, causing downstream processing failures. The current implementation prompts Claude to return JSON in the response text and then parses it.

What is the most reliable approach to ensure Claude returns valid, schema-compliant structured data?

Options:

A.  

Add explicit formatting instructions to the prompt with JSON examples, emphasizing that Claude must return only valid JSON with no surrounding text.

B.  

Use regular expressions to locate and extract JSON from the response text, handling cases where Claude includes explanatory text around the JSON block.

C.  

Define a tool with a JSON schema specifying the expected structure, using tool use to constrain Claude’s output to schema-compliant JSON.

D.  

Implement a retry loop that catches JSON parsing errors and re-prompts Claude with the error details, asking it to correct the malformed output.

Discussion 0