Turn Claude Code from a coding assistant into a fully automated development workflow engine.
A production-tested, language-agnostic configuration framework for Claude Code. One bash setup.sh gives you automated code review, quality gates, prompt optimization, database analysis, CI/CD integration, and more.
This is NOT a library or package — it's a configuration framework. It provides battle-tested templates for Claude Code's 5 automation layers:
┌─────────────────────────────────────────────────────────────────┐
│ Claude Code Power Framework │
├──────────────┬──────────────┬──────────────┬───────────────────┤
│ Layer 1 │ Layer 2 │ Layer 3 │ Layer 4 + 5 │
│ Memory │ Automation │ Agents │ CI/CD + MCP │
│ │ │ │ │
│ CLAUDE.md │ 5 Hooks │ 4 Agents │ GitHub Actions │
│ Path Rules │ │ Agent Teams │ MCP Servers │
│ │ │ │ │
│ "What to │ "When to │ "Who does │ "Where it │
│ know" │ act" │ what" │ extends to" │
└──────────────┴──────────────┴──────────────┴───────────────────┘
git clone https://github.com/SkyNotSilent/claude-code-power-framework.git
cd claude-code-power-framework
# Go to your project directory
cd /path/to/your/project
# Run setup from the framework directory
bash /path/to/claude-code-power-framework/setup.shThe interactive script will:
- Detect your project type (Node.js, Python, Go, Rust)
- Ask which layers you want to install
- Copy and customize templates with your project name and paths
Copy files from examples/ directly into your project:
# For a TypeScript monorepo
cp -r examples/nextjs-nestjs-monorepo/.claude your-project/
cp examples/nextjs-nestjs-monorepo/CLAUDE.md your-project/
# For a Python FastAPI project
cp -r examples/python-fastapi/.claude your-project/
cp examples/python-fastapi/CLAUDE.md your-project/
# For minimal setup (just CLAUDE.md + .env protection)
cp -r examples/minimal/.claude your-project/
cp examples/minimal/CLAUDE.md your-project/CLAUDE.md is loaded at every session start. It tells Claude your project's tech stack, key files, coding standards, and automation rules.
Path Rules (.claude/rules/*.md) are loaded only when editing matching files — keeping context lean.
| Rule File | Loaded When Editing |
|---|---|
backend.md |
apps/api/**/*.ts |
frontend.md |
apps/web/**/*.tsx |
database.md |
**/*.prisma |
5 lifecycle hooks in .claude/settings.json:
| Hook | Purpose | Blocks? |
|---|---|---|
SessionStart |
Project status banner | No |
PreToolUse |
.env file protection | Yes |
PostToolUse |
Auto-compile check after edits | No |
Stop |
Uncommitted changes reminder | Yes |
TaskCompleted |
Compilation gate | Yes |
4 sub-agents with different models and tool access:
| Agent | Model | Speed | Purpose |
|---|---|---|---|
quality-gate |
haiku | ~5s | Fast compile + security check |
code-reviewer |
sonnet | ~30s | Deep 3-tier code review |
prompt-optimizer |
sonnet | ~20s | AI prompt quality (read-only) |
db-analyzer |
sonnet | ~30s | Schema + query analysis |
Key design decisions:
- haiku for speed — quality-gate runs on every edit, must be fast
- Least privilege — prompt-optimizer has no Bash access
- Background mode — all agents run without blocking your conversation
Two workflows using anthropics/claude-code-action@v1:
- PR Auto-Review — Reviews every PR + responds to
@claudecomments - Daily Report — Scheduled project summary as a GitHub Issue
Connect Claude to external tools via Model Context Protocol:
{
"mcpServers": {
"database": {
"command": "npx",
"args": ["-y", "@bytebase/dbhub", "--dsn", "${DATABASE_URL}"]
}
}
}| Example | Stack | Layers | Use Case |
|---|---|---|---|
nextjs-nestjs-monorepo |
TS + NestJS + Next.js + Prisma | All 5 | Full-stack TypeScript monorepo |
python-fastapi |
Python + FastAPI + SQLAlchemy | 1-3 | Python REST API |
minimal |
Any | 1-2 | Lowest barrier to entry |
claude-code-power-framework/
├── templates/ # Template files with {{PLACEHOLDER}} markers
│ ├── CLAUDE.md
│ ├── .claude/
│ │ ├── settings.json # 5 hooks
│ │ ├── rules/ # 3 path-scoped rules
│ │ └── agents/ # 4 sub-agents
│ ├── .mcp.json
│ └── .github/workflows/ # 2 CI workflows
├── examples/ # Ready-to-use configurations
│ ├── nextjs-nestjs-monorepo/ # Full TypeScript example
│ ├── python-fastapi/ # Python example
│ └── minimal/ # Minimal setup
├── docs/ # Detailed documentation
│ ├── architecture.md # 5-layer architecture overview
│ ├── hooks-reference.md # Hook events + types
│ ├── agents-guide.md # Agent creation + configuration
│ ├── rules-guide.md # Path rule syntax + best practices
│ ├── ci-workflows.md # GitHub Actions setup
│ ├── mcp-setup.md # MCP server configuration
│ └── troubleshooting.md # Common issues + fixes
├── setup.sh # Interactive installer
├── README.md # This file
└── README.zh-CN.md # Chinese documentation
| Document | Content |
|---|---|
| Architecture | 5-layer design, how layers interact |
| Hooks Reference | All 6 hook events, 4 hook types, examples |
| Agents Guide | Frontmatter schema, model selection, tool restrictions |
| Rules Guide | Path syntax, best practices, common patterns |
| CI Workflows | GitHub Actions setup, cost considerations |
| MCP Setup | Database access, recommended servers |
| Troubleshooting | Windows issues, common errors, fixes |
Contributions welcome! Please:
- Fork the repository
- Create a feature branch (
feat/your-feature) - Submit a pull request
Ideas for contributions:
- New example configurations (Django, Go, Rust, Java Spring)
- Additional agent templates
- setup.sh improvements
- Documentation translations
Built with Claude Code. Tested in production.