CCAR-F scenarios › Code Generation with Claude Code · Question 20 of 60
Scenario 2 · Code Generation with Claude Code
Your engineering team relies on Claude Code to generate, refactor, debug, and document code. You're responsible for fitting it into the team's workflow: custom slash commands and skills, a sensible CLAUDE.md setup, and knowing when a task calls for plan mode and when direct execution is enough.
Context Management & Reliability
You're adding comprehensive tests to a legacy service in phases. In phase one, a subagent mapped the module structure and identified the high-risk billing paths. In phase two you spawn new subagents to write tests for each area, but they repeat the structural exploration and sometimes target low-impact code. What change best fixes this?
Show answer and explanation
Answer: C — Summarize the key findings from phase one, including module map, high-risk paths, and priorities, and inject that summary into each phase-two subagent's initial prompt.
Subagents don't inherit context automatically, so summarizing one phase's key findings and injecting the summary into the next phase's subagents gives them what they need without repeating exploration (task 5.4). No setting gives subagents another agent's transcript by default (a). That's the isolated-context misconception, and a raw transcript would be verbose anyway. Merging everything into one long subagent (b) brings back context exhaustion and degradation. Writing tests from function names only (d) gives up the understanding needed for meaningful tests.
More from this scenario
- A new engineer joins and finds that Claude Code ignores the team's error-handling and…
- Your monorepo has a shared standards folder with files for API design, PCI handling…
- The root CLAUDE.md has a long section on database migration conventions. Migration files…
- Your team's /map-dependencies skill reads dozens of files and produces several thousand…
- Two hours into exploring an unfamiliar payments codebase, Claude Code's answers start to…