This example provides a tool-agnostic starter layout for implementing the Progressive Disclosure pattern in a real repository.
Keep a small, universal rules file that applies to every task, and load specialized rules only when the work context requires them (security, API design, testing, CI/CD, etc.).
.ai/
├── CLAUDE.md # Universal rules + routing hints (<60 lines)
├── rules/
│ ├── security/ # secrets, auth, dependencies
│ ├── development/ # api-design, database, testing
│ ├── operations/ # deployment, monitoring, cicd
│ └── architecture/ # patterns, performance
└── prompts/ # reusable task templates
- Keep
.ai/CLAUDE.mdminimal and explicit about when to load specialized rules. - Add small, focused rule files under
.ai/rules/(aim for <100 lines each). - Optionally combine with Event Automation to auto-load the relevant rules before edits, writes, or test runs.