BrainyBeeBrainyBee
ExploreBlogStart Studying
HomeClaude Certified Architect - Foundations (CCAR-F)Reference: CLAUDE.md, rules and memory
Grounded reference578 words

Reference: CLAUDE.md, rules and memory

Claude Certified Architect - Foundations (CCAR-F) › Domain 3: Claude Code Configuration & Workflows

CLAUDE.md, rules and memory, from the Claude Code documentation

Domain 3 examines where configuration lives and who receives it. The exam guide names three levels. The documentation describes four, plus a second memory system the guide does not mention at all.

Guide and documentation, side by side

The exam guide keys user-level, project-level and directory-level CLAUDE.md. That is what you are graded on. The documentation adds a managed-policy scope above them and a CLAUDE.local.md beside them, and it is worth knowing both — the guide sets the exam, the documentation sets reality.

Every CLAUDE.md location

Listed in load order, broadest first, so a project instruction lands in context after a user instruction.

ScopeLocationShared with
Managed policymacOS /Library/Application Support/ClaudeCode/CLAUDE.md · Linux/WSL /etc/claude-code/CLAUDE.md · Windows: under Program Files/ClaudeCode/Everyone on the machine
User~/.claude/CLAUDE.mdJust you, every project
Project./CLAUDE.md or ./.claude/CLAUDE.mdThe team, via source control
Local./CLAUDE.local.mdJust you, this project — gitignore it

Files are concatenated, not overridden. Across a directory tree, content is ordered from the filesystem root down to your working directory, so the file closest to where you launched Claude is read last. Within a directory, CLAUDE.local.md is appended after CLAUDE.md.

Subdirectory files are discovered but load on demand, when Claude reads a file in that directory — not at launch.

The limits worth memorising

Documented limits

Target size
under 200 lines per CLAUDE.md
Hard skip
a file over 4 MiB is not loaded
@import depth
four hops maximum
Auto-memory index
first 200 lines or 25KB of MEMORY.md

Imports

@path/to/import pulls another file in. Relative paths resolve against the file containing the import, not the working directory. Imported files can import further files, to a maximum depth of four hops.

Import parsing skips code spans and fenced blocks, so a path wrapped in backticks stays literal text while the same path outside them imports the file. That is the documented way to mention a path in a CLAUDE.md without pulling it in.

Imports do not save context

Splitting a large CLAUDE.md into @path imports improves organisation and changes nothing about context cost, because imported files load at launch alongside the file that references them. To actually reduce what loads, scope rules by path instead.

Path-scoped rules

.claude/rules/ holds topic files. A rule with no paths frontmatter loads at launch with the same priority as .claude/CLAUDE.md. A rule with paths loads only when Claude reads a matching file.

code
--- paths: - "src/api/**/*.ts" ---

Brace expansion works — src/**/*.{ts,tsx} — and a rule's whole paths list shares a budget of 1,000 expanded patterns. User-level rules live in ~/.claude/rules/ and load before project rules, giving project rules the higher priority.

/memory and /context

These are two different commands

The published objective names /memory for verifying what is loaded, and that is what the exam keys. The documentation is more precise: /memory LISTS your memory file locations and opens them for editing, while /context is what reports which files actually loaded into this session. If you are diagnosing behaviour that differs between two people, /context answers it directly.

/init generates a starting CLAUDE.md from the codebase, and suggests improvements rather than overwriting if one already exists.

What survives /compact

A project-root CLAUDE.md is re-read from disk after compaction and re-injected. Nested CLAUDE.md files and path-scoped rules reload as Claude reads files they apply to. An instruction that disappears after /compact was given only in conversation — which is the argument for writing it down.

Skills and commands, as documented

Two facts worth holding beside the guide's account.

Custom commands have been merged into skills. A file at .claude/commands/deploy.md and a skill at .claude/skills/deploy/SKILL.md both create /deploy and work the same way. Existing command files keep working; skills add a directory for supporting files, frontmatter, and automatic invocation.

argument-hint does not do what the guide says. The documentation describes it as a hint shown during autocomplete to indicate expected arguments — not a prompt raised when a skill is invoked without any. The exam grades the guide's version.

FrontmatterDocumented behaviour
context: forkRuns the skill in a forked subagent context
allowed-toolsGrants go through the normal permission flow
argument-hintHint shown during autocomplete
disable-model-invocationStops Claude invoking the skill on its own

The CLI flags this exam names

FlagDocumented behaviour
-p / --printPrint response without interactive mode
--output-formatPrint mode only. Values: text, json, stream-json
--json-schemaValidated JSON matching a schema. Print mode only
--resume / -rResume a session by ID or name, or pick interactively
--continue / -cLoad the most recent conversation in this directory

Sources

  • How Claude remembers your project — https://code.claude.com/docs/en/memory (retrieved 2026-08-30)
  • Extend Claude with skills — https://code.claude.com/docs/en/skills (retrieved 2026-08-30)
  • CLI reference — https://code.claude.com/docs/en/cli-reference (retrieved 2026-08-30)
All Claude Certified Architect - Foundations (CCAR-F) Study Resources

Related Notes

  • Domain 3: Claude Code Configuration & Workflows150 words
  • Domain 3 Project — configure Claude Code for a team, then put it in CI882 words
  • CCAR-F: how the exam is dealt194 words
  • Scenario 1: Customer Support Resolution Agent225 words
  • Scenario 2: Code Generation with Claude Code185 words
  • Scenario 3: Multi-Agent Research System199 words
  • Scenario 4: Developer Productivity with Claude197 words
  • Scenario 5: Claude Code for Continuous Integration168 words
  • Scenario 6: Structured Data Extraction185 words
  • Domain 1: Agentic Architecture & Orchestration169 words
  • Domain 1 Project — build a support agent, then make it a team1,199 words
  • Reference: the tool-use round trip505 words

Ready to study Claude Certified Architect - Foundations (CCAR-F)?

Practice tests, flashcards, and all study notes — free, no sign-up.

Start Studying

Ready to study Claude Certified Architect - Foundations (CCAR-F)?

Practice tests, flashcards, and all study notes — free, no sign-up needed.

Start Studying — Free
Claude Certified Architect - Foundations (CCAR-F) ResourcesExplore All HivesBlogHome

© 2026 BrainyBee. Free AI-powered exam prep.