|
| 1 | +# CLAUDE.md |
| 2 | + |
| 3 | +Guidance for Claude Code when working in this repository. |
| 4 | + |
| 5 | +## Repository Context |
| 6 | + |
| 7 | +Documentation repository for Carpenter-Singh Lab at the Broad Institute. Maintains lab standards for data science workflows using Cookiecutter Data Science (CCDS) principles. |
| 8 | + |
| 9 | +## Key Tasks When Working Here |
| 10 | + |
| 11 | +### 1. Documentation Improvements |
| 12 | + |
| 13 | +- Check for consistency in command examples across documents |
| 14 | +- Ensure all code blocks are properly formatted and executable |
| 15 | +- Verify that file paths and project names use consistent placeholder syntax (e.g., `{PROJECT_NAME}`) |
| 16 | +- Look for outdated dependencies or version numbers that may need updating |
| 17 | + |
| 18 | +### 2. Common Updates |
| 19 | + |
| 20 | +When asked to update documentation: |
| 21 | + |
| 22 | +- Follow the Documentation Guidelines below |
| 23 | +- Focus on executable commands over explanations |
| 24 | + |
| 25 | +### 3. Adding New Sections |
| 26 | + |
| 27 | +When adding new documentation: |
| 28 | + |
| 29 | +- Follow the existing markdown structure and heading hierarchy |
| 30 | +- Place new content in the appropriate file (workflows.md for process-related content) |
| 31 | +- Use real-world examples from the referenced repositories when possible |
| 32 | + |
| 33 | +### 4. Quality Checks |
| 34 | + |
| 35 | +Before finalizing any changes: |
| 36 | + |
| 37 | +- Ensure all bash commands use proper escaping and line continuations |
| 38 | +- Verify that Python/YAML/TOML code blocks have correct syntax |
| 39 | +- Check that any new commands follow the established patterns in the document |
| 40 | + |
| 41 | +## Repository Structure |
| 42 | + |
| 43 | +```text |
| 44 | +carpenter-singh-lab-standards/ |
| 45 | +├── README.md # Main entry point, links to other docs |
| 46 | +├── workflows.md # Comprehensive CCDS workflow guide |
| 47 | +└── CLAUDE.md # This file |
| 48 | +``` |
| 49 | + |
| 50 | +## When Making Changes |
| 51 | + |
| 52 | +- workflows.md is the authoritative source for lab procedures |
| 53 | +- New documentation must complement, not duplicate, existing content |
| 54 | +- Make processes clear and executable, not flexible |
| 55 | + |
| 56 | +## Documentation Guidelines |
| 57 | + |
| 58 | +When updating documentation in this repository, follow these principles: |
| 59 | + |
| 60 | +### Target Audience |
| 61 | + |
| 62 | +- **Expert data scientists** who are new to the lab |
| 63 | +- They will be instructed to read documentation thoroughly |
| 64 | +- They want to understand THE way this lab operates, not explore options |
| 65 | +- Assume technical competence - skip basic explanations |
| 66 | + |
| 67 | +### Writing Style |
| 68 | + |
| 69 | +- **Prescriptive over descriptive**: "Do X" not "You might consider X" |
| 70 | +- **Dense over verbose**: One clear statement beats three explanatory paragraphs |
| 71 | +- **Executable over abstract**: Every process needs exact, working commands |
| 72 | +- **Real over generic**: Use actual filenames from real projects, not placeholders |
| 73 | + |
| 74 | +### Content Organization |
| 75 | + |
| 76 | +- **Role-based sections**: Clearly separate what analysts vs maintainers need |
| 77 | +- **Most-used first**: Daily workflow before one-time setup |
| 78 | +- **Progressive disclosure**: Core workflow in main text, edge cases in appendix |
| 79 | +- **Decision trees**: "If X → do Y" for any branching logic |
| 80 | + |
| 81 | +### Critical Elements to Include |
| 82 | + |
| 83 | +- **Coordination requirements**: Bold warnings when team sync is needed |
| 84 | +- **Order dependencies**: Explicit when sequence matters (e.g., hook installation) |
| 85 | +- **Known gotchas**: Document issues with specific workarounds |
| 86 | +- **The "why" sparingly**: Only when it affects implementation choices |
| 87 | + |
| 88 | +### What to Avoid |
| 89 | + |
| 90 | +- Beginner explanations ("Git is a version control system...") |
| 91 | +- Multiple options without clear guidance |
| 92 | +- Philosophical discussions about methodology |
| 93 | +- Untested command sequences |
| 94 | + |
| 95 | +Remember: Documentation should be the authoritative reference that turns an expert data scientist into an expert lab member. |
0 commit comments