A software company keeps 11 services in one monorepository worked on by six teams. A single root instruction file for Claude Code holds every team's rules. In one month, sessions in the mobile team's display code twice applied the payments team's rule that currency values be stored in minor units, and the payments team reports that other teams' edits keep rewording its section. The company requires that each team's rules apply when Claude Code works in that team's code, and that each team approve every change to its own rules. What should the architect recommend?
- ASplit the root instructions into one headed section per team and add a line telling Claude Code to apply only the section for the code it is in
- BKeep shared conventions in the root instructions and move each team's rules into an instruction file in its own directory, with that team as required reviewer Correct
- CHave each team's engineers keep their team's rules in personal user-level memory, so that only members of that team ever load those rules
- DSplit the monorepository into one repository per team, so that each new repository carries its own root instruction file and its own reviewers
Why A is wrong: This is tempting because it tidies the file and states the intent clearly. It is wrong because every team's rules still load into every session, so applying the right section depends on the model obeying an instruction, and the single shared file still lets any team reword another team's section without that team's approval.
Why B is correct: This is correct because Claude Code loads a subdirectory's instruction file when it works on files in that part of the tree, so the payments rules reach payments code and not mobile display code. Making the owning team the required reviewer for its own file meets the approval requirement through the repository's normal code review.
Why C is wrong: This is tempting because it stops the rules leaking between teams. It is wrong because personal memory follows the person rather than the code: an engineer helping in another team's service gets none of its rules, headless runs get none at all, and nobody reviews changes to rules held on individual machines.
Why D is wrong: This is tempting because it gives each team a clean, owned instruction file. It is wrong because it is a large structural migration, affecting builds, dependencies and history, to solve a configuration-scoping problem that directory-level instructions in the existing repository already solve.