Pre-Winter Sale Special Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: force70

Anthropic Claude Certified Architect – Foundations CCAR-F Question # 34 Topic 4 Discussion

Anthropic Claude Certified Architect – Foundations CCAR-F Question # 34 Topic 4 Discussion

CCAR-F Exam Topic 4 Question 34 Discussion:
Question #: 34
Topic #: 4

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?


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.


Get Premium CCAR-F Questions

Contribute your Thoughts:


Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.