ai-agent-setup
CLAUDE.md3 starsChanged 6 months agoMITView on GitHub
Maintainer: Hoang Nguyen (hoang.nguyen@angelhack.com) Tier: Standard See TIERS.md for tier options: Starter | Standard | Strict This project uses Claude AI as an intelligent development agent with structured workflows, specialized sub-agents, and mandatory coding standards. Follow this workflow for all feature development: All rules in .claude/rules/ are mandatory and must be followed: Invoke the right agent for each task type:
- Deletes or force-pushes
- Commits and pushes
In this repository13 other files it gives its agents.
- AGENTS.mdAGENTS.md
- code-reviewSkill
- nestjs-backendSkill
- nodejs-backendSkill
- react-frontendSkill
- react-native-mobileSkill
- tddSkill
- Code Review & QualitySkill
- Data Transformation & AnalysisSkill
- deploySkill
- Incremental ImplementationSkill
- security-reviewSkill
- Test-Driven DevelopmentSkill
The file
We split this CLAUDE.md into the rules it gives an agent
2 rules. About 0 are common, 1 is distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
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
- Distinctive: line 16
Follow this workflow for all feature development:
- Very specific: line 64
All rules in .claude/rules/ are mandatory and must be followed:
≈ “Common” is an estimate: at least 1 in 5 of the 26,980 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 AI Agent Configuration
Maintainer: Hoang Nguyen (hoang.nguyen@angelhack.com)
Tier: Standard
See TIERS.md for tier options: Starter | Standard | Strict
Overview
This project uses Claude AI as an intelligent development agent with structured workflows, specialized sub-agents, and mandatory coding standards.
Development Workflow
Follow this workflow for all feature development:
┌─────────────────────────────────────────────────────────────┐
│ │
│ /spec → /plan → /build → /test → /review → Ship│
│ │
│ Define Plan Build Verify Review Deploy │
│ │
└─────────────────────────────────────────────────────────────┘| Phase | Command | Purpose |
| Define | /spec | Create PRD with objectives, scope, boundaries |
| Plan | /plan | Decompose into vertical slices with acceptance criteria |
| Build | /build | Implement incrementally using TDD (RED-GREEN-REFACTOR) |
| Verify | /test | Write and verify tests; use Prove-It for bug fixes |
| Review | /review | Five-axis code review before merge |
| Ship | /deploy | Build, test, deploy with staged rollout |
Supporting Commands
| Command | Purpose |
/debug | Systematic error diagnosis and root cause analysis |
/simplify | Reduce complexity without changing behavior |
/fix-issue | Analyze and fix reported issues |
Core Principles
Code Quality
- Test-Driven Development — Write failing tests first, then implement
- Incremental Implementation — Small vertical slices, always buildable
- Five-Axis Review — Correctness, Readability, Architecture, Security, Performance
Philosophy
- Progress over perfection
- Fix root causes, not symptoms
- The simplest thing that could work
- Tests are proof, not afterthought
Mandatory Rules
All rules in .claude/rules/ are mandatory and must be followed:
Code Quality
| Rule | Description |
clean-code.md | Variables, functions, SOLID, async/await |
code-style.md | Formatting, naming conventions |
error-handling.md | AppError class, global handler patterns |
Architecture & Design
| Rule | Description |
tech-stack.md | Approved technologies (Next.js, React Native, PG, Redis, Prisma) |
system-design.md | CAP theorem, caching, scaling, queues |
project-structure.md | Layered architecture, folder organization |
api-conventions.md | REST standards, response envelopes |
Data & Naming
| Rule | Description |
naming-conventions.md | Cache keys, DB, queues, env vars |
database.md | Prisma patterns, transactions, N+1 prevention |
Operations
| Rule | Description |
security.md | CRITICAL — Never violate security rules |
monitoring.md | Prometheus, Grafana, logging, alerting |
testing.md | Coverage thresholds, test patterns |
git-workflow.md | Branching strategy, conventional commits |
Language Patterns
| Rule | Description |
typescript-patterns.md | Type safety, generics, utility types |
python-patterns.md | PEP8, type hints, async patterns |
sql-patterns.md | Query optimization, N+1, indexes |
Available Agents
Invoke the right agent for each task type:
Development Agents
| Agent | When to Invoke |
| 🖥️ Frontend Developer | Components, pages, routing, state, UI performance |
| 📱 Mobile Developer | React Native, Expo, navigation, native modules |
| 🔧 Backend Developer | APIs, services, DB queries, background jobs |
| 🏗️ Systems Architect | Architecture decisions, ADRs, system design |
Quality Agents
| Agent | When to Invoke |
| 👀 Code Reviewer | Five-axis PR review, code quality assessment |
| 🧪 Test Engineer | Test strategy, TDD, coverage, bug reproduction |
| 🔒 Security Auditor | Vulnerability assessment, threat modeling |
| ✅ QA Engineer | Test plans, E2E tests, bug reports |
Product Agents
| Agent | When to Invoke |
| 📋 Project Manager | User stories, sprint planning, status reports |
| 🎨 UI/UX Designer | Design system, wireframes, accessibility |
| ✍️ Copywriter/SEO | Page copy, meta tags, SEO optimization |
Build Resolver Agents
| Agent | When to Invoke |
| ⚛️ React Build Resolver | React/Next.js build errors, module issues |
| 📱 React Native Resolver | Metro bundler, iOS/Android build errors |
| 🟢 Node Build Resolver | npm errors, TypeScript, ESM/CJS issues |
| 🔷 Prisma Resolver | Migration errors, schema validation, queries |
Available Skills
Agent Skills (.agents/skills/)
Open standard skills compatible with 30+ AI agents:
| Skill | Description | Impact Levels |
nodejs-backend | Express, Prisma, Redis, BullMQ | CRITICAL/HIGH/MEDIUM |
nestjs-backend | NestJS, TypeORM, Guards, DI | CRITICAL/HIGH/MEDIUM |
react-frontend | Next.js/Vite, TailwindCSS, Zustand | CRITICAL/HIGH/MEDIUM |
react-native-mobile | Expo/RN CLI, NativeWind | CRITICAL/HIGH/MEDIUM |
code-review | Five-axis review framework | CRITICAL/MAJOR/MINOR |
tdd | RED-GREEN-REFACTOR workflow | CRITICAL/HIGH/MEDIUM |
Compile all skills: node scripts/compile-skills.js → generates AGENTS.md
Claude Skills (.claude/skills/)
Specialized skills for complex operations:
| Skill | Description |
incremental-implementation | Vertical slice development |
deploy | Full deployment pipeline |
security-review | Security audit checklist |
data-transform | CRITICAL — Data conversion, validation, cleaning with zero data loss |
Reference Checklists
Quick references in .claude/references/:
| Reference | Use For |
security-checklist.md | Pre-deploy security verification |
testing-patterns.md | Test structure and anti-patterns |
performance-checklist.md | Core Web Vitals, optimization |
accessibility-checklist.md | WCAG 2.1 AA compliance |
mobile-performance-checklist.md | React Native performance, 60 FPS |
mobile-release-checklist.md | App Store / Play Store submission |
external-skills.md | Third-party AI skills (GSAP, etc.) |
Recommended Tools
CodeGraph (Optional)
CodeGraph builds a semantic knowledge graph of codebases, enabling faster and cheaper code exploration.
Benefits:
| Metric | Improvement |
| Tokens processed | 57% fewer |
| Cost | 35% cheaper |
| Response time | 46% faster |
| Tool calls | 71% fewer |
Setup:
npx @colbymchenry/codegraph init -iMCP Tools provided:
| Tool | Purpose |
codegraph_search | Symbol lookup |
codegraph_context | Multi-symbol context in one call |
codegraph_trace | Call path tracing with bodies |
codegraph_callers | Find all callers of a symbol |
codegraph_callees | Find all callees of a symbol |
codegraph_impact | Change impact analysis |
codegraph_explore | Grouped source for related symbols |
When to use:
- Large codebases (>10k LOC)
- Architecture exploration ("How does X reach Y?")
- Impact analysis before refactoring
- Understanding call flows
Sensitive Commands Policy
CRITICAL: The following commands must NOT be executed automatically. Instead:
- Log the command that would run
- Suggest a safer alternative (if available)
- Continue workflow — DO NOT block, DO NOT wait for confirmation
| Command | Risk Level | Safe Alternative |
git push --force | 🔴 HIGH | git push --force-with-lease |
git reset --hard | 🔴 HIGH | git stash before reset |
rm -rf | 🔴 HIGH | mv to .trash/ folder |
DROP TABLE/DATABASE | 🔴 HIGH | Backup first, confirm DB name |
DELETE FROM (no WHERE) | 🔴 HIGH | Add WHERE clause or LIMIT |
TRUNCATE TABLE | 🟠 MEDIUM | Backup first |
git checkout -- . | 🟠 MEDIUM | git stash for recovery |
npm/pnpm publish | 🟠 MEDIUM | Confirm version and registry |
docker system prune | 🟠 MEDIUM | List items before prune |
| Deploy to production | 🟠 MEDIUM | Deploy to staging first |
Handling Flow
┌─────────────────────────────────────────────────────────────┐
│ Detect sensitive command │
│ ↓ │
│ Log: "⚠️ Sensitive: [command] — using safe alternative" │
│ ↓ │
│ Execute safe alternative (if available) │
│ ↓ │
│ Continue workflow — DO NOT BLOCK │
└─────────────────────────────────────────────────────────────┘Examples
# User requests: "push changes to remote"
# ❌ DON'T: git push --force origin main
# ✅ DO: git push --force-with-lease origin main
# User requests: "clean up old files"
# ❌ DON'T: rm -rf ./tmp/*
# ✅ DO: mkdir -p .trash && mv ./tmp/* .trash/
# User requests: "reset to clean state"
# ❌ DON'T: git reset --hard HEAD
# ✅ DO: git stash -u && git reset --hard HEADHooks System
Automated checks that run before/after tool operations:
| Hook | Type | Purpose |
security-scan | PreToolUse | Scan for secrets before write |
lint-check | PreToolUse | Run linter before commit |
auto-format | PostToolUse | Auto-format after edit |
typescript-check | PostToolUse | Type-check TS files |
console-log-warn | PostToolUse | Warn about console.log |
session-summary | Lifecycle | Summarize session on exit |
cost-tracker | Lifecycle | Track token usage |
See .claude/hooks/README.md for details on creating custom hooks.
MCP Server Configs
Pre-configured MCP servers for common services:
| Server | Purpose | Priority |
| Supabase | PostgreSQL, auth, storage | HIGH |
| Vercel | Deploy & preview | HIGH |
| Playwright | Browser automation | HIGH |
| GitHub | Enhanced git operations | HIGH |
| Sentry | Error tracking | MEDIUM |
| Memory | Persistent context | MEDIUM |
See .claude/mcp-configs/README.md for setup instructions.
Agent Behavior Guidelines
- Follow the workflow — Use
/spec→/plan→/build→/review - Apply mandatory rules — All rules in
.claude/rules/are non-negotiable - Test first — Write failing tests before implementing
- Incremental changes — Small commits, always buildable
- Explain before acting — Describe changes before making them
- Fix root causes — Don't patch symptoms
- Use the right agent — Invoke specialized agents for their domains
- Handle sensitive commands safely — Use alternatives, never block workflow
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.

