bigquery-mcp
CLAUDE.md2 starsChanged 17 months agoMITView on GitHub
This document provides guidelines for Claude when working on the BigQuery MCP project. Before considering work complete: - [ ] Tests pass - [ ] Code is clean and follows style guidelines - [ ] Documentation is updated - [ ] No sensitive data in commits - [ ] TASKS.md is updated - [ ] Appropriate commits made
In this repositoryOne other file it gives its agents.
- .cursor/rules/default.mdcCursor rule
The file
Show its rules and text
We split this CLAUDE.md into the rules it gives an agent
31 rules. About 0 are common, 30 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈30
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Very specific: line 9
Completing Tasks: When you complete a task, mark it as done by changing [ ] to [x]
- Distinctive: line 11
Remove completed tasks from TASKS.md
- Distinctive: line 12
Update CHANGELOG.md with the version changes
- Distinctive: line 13
Ask about incrementing the version number
- Distinctive: line 20
When in doubt, ask whether changes warrant a new version
- Distinctive: line 25
Use inline comments sparingly, only where logic is non-obvious
- Distinctive: line 26
Keep comments concise and to the point
- Distinctive: line 27
No decorative comment blocks or ASCII art
- Distinctive: line 32
Keep files focused and under 300 lines where possible
- Distinctive: line 33
Use descriptive variable names, but concise where appropriate
- Distinctive: line 34
Follow PEP 8 style guidelines
- Distinctive: line 40
No emoji or decorative elements
- Distinctive: line 50
Commit after completing each meaningful unit of work
- Distinctive: line 56
Ensure understanding of the specific task
- Distinctive: line 57
Check for any blocking dependencies
- Distinctive: line 60
Write tests alongside implementation
- Distinctive: line 62
Keep security in mind (no credentials in code)
- Distinctive: line 67
Update documentation if needed
- Distinctive: line 75
Use fixtures for test data, never real company data
- Distinctive: line 79
No company-specific information in tests
- Distinctive: line 80
Use generic examples (e.g., "analytics_dataset" not "business_banking_demo")
- Distinctive: line 85
Keep examples generic and professional
- Distinctive: line 86
Update when adding new features
- Distinctive: line 87
Ensure all code examples are tested
- Distinctive: line 91
Use clear, user-focused language
- Distinctive: line 96
Never commit credentials or sensitive data
- Distinctive: line 97
All SQL operations must be read-only
- Distinctive: line 99
Use parameterized queries where applicable
- Distinctive: line 104
Before considering work complete:
- Distinctive: line 137
When unsure about a decision, ask for clarification
- Distinctive: line 139
Keep the user experience simple and intuitive
≈ “Common” is an estimate: at least 1 in 5 of the 12,729 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Claude Development Guidelines
This document provides guidelines for Claude when working on the BigQuery MCP project.
Task Management
Working with TASKS.md
- Completing Tasks: When you complete a task, mark it as done by changing
[ ]to[x] - Version Batches: Once all tasks for a version are complete:
- Remove completed tasks from TASKS.md
- Update CHANGELOG.md with the version changes
- Ask about incrementing the version number
Version Management
- Pre-1.0 versions use 0.x.y format
- Minor version (0.x.0) for new features/significant changes
- Patch version (0.x.y) for bug fixes and minor improvements
- When in doubt, ask whether changes warrant a new version
Code Style
Comments
- Use inline comments sparingly, only where logic is non-obvious
- Keep comments concise and to the point
- No decorative comment blocks or ASCII art
- Docstrings for all public functions/classes
Code Organization
- Functions should do one thing well
- Keep files focused and under 300 lines where possible
- Use descriptive variable names, but concise where appropriate
- Follow PEP 8 style guidelines
Git Commits
Commit Messages
- Single line, imperative mood: "Add list_projects tool"
- No emoji or decorative elements
- Be specific but concise
- Examples:
- "Add BigQuery client initialization"
- "Fix SQL validation for nested queries"
- "Update dependencies to latest versions"
Commit Frequency
- Logical, atomic commits
- One feature/fix per commit where possible
- Commit after completing each meaningful unit of work
Development Workflow
- Before Making Changes:
- Review current TASKS.md
- Ensure understanding of the specific task
- Check for any blocking dependencies
- While Developing:
- Write tests alongside implementation
- Run tests frequently
- Keep security in mind (no credentials in code)
- After Changes:
- Update TASKS.md
- Make appropriate git commit(s)
- Update documentation if needed
- Note any new tasks discovered
Testing
Test Organization
tests/unit/- Fast tests with mocked dependenciestests/integration/- Tests requiring BigQuery connection- Use fixtures for test data, never real company data
Test Data
- Anonymize any data from sandbox environments
- No company-specific information in tests
- Use generic examples (e.g., "analytics_dataset" not "business_banking_demo")
Documentation
README Updates
- Keep examples generic and professional
- Update when adding new features
- Ensure all code examples are tested
Changelog
- Group changes by type: Added, Changed, Fixed, Removed
- Use clear, user-focused language
- Date entries when releasing versions
Security Reminders
- Never commit credentials or sensitive data
- All SQL operations must be read-only
- Validate all user inputs
- Use parameterized queries where applicable
- Keep dependencies updated
Quality Checklist
Before considering work complete:
- Tests pass
- Code is clean and follows style guidelines
- Documentation is updated
- No sensitive data in commits
- TASKS.md is updated
- Appropriate commits made
Common Patterns
Error Handling
try:
result = perform_operation()
except SpecificError as e:
logger.error(f"Operation failed: {e}")
return {"status": "error", "error": str(e)}Tool Response Format
return {
"status": "success", # or "error"
"data": result_data,
"metadata": {
"row_count": len(results),
"execution_time_ms": elapsed_time
}
}Notes
- When unsure about a decision, ask for clarification
- Prioritize security and reliability over features
- Keep the user experience simple and intuitive
- Remember this is a read-only tool for data exploration
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

