Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Comprehensive codebase health analysis. Use when reviewing code quality, identifying technical debt, checking dependencies, or assessing project structure.
.claude/skills/majiayu000-project-health-auditor/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-01 | ✗→✓ | ▲ Improved | 76% | 0% |
| case-07 | ✗→✓ | ▲ Improved | 26% | 0% |
| case-09 | ✗→✓ | ▲ Improved | 52% | 0% |
| case-10 | ✗→✓ | ▲ Improved | 55% | 0% |
| case-11 | ✗→✓ | ▲ Improved | 41% | 0% |
> Inspired by claude-code-plugins-plus
Analyze codebase health across multiple dimensions: code quality, dependencies, security, testing, documentation, and architecture.
bash# Count lines per file (identify large files) find src -name "*.ts" -o -name "*.js" | xargs wc -l | sort -n # Find long functions (over 50 lines) # Check for deeply nested code # Identify duplicate code patterns
| Smell | Indicator | Action | |-------|-----------|--------| | Long files | >500 lines | Split into modules | | Long functions | >50 lines | Extract methods | | Deep nesting | >4 levels | Flatten logic | | Many parameters | >5 params | Use objects | | Duplicate code | Similar blocks | Extract shared | | Dead code | Unused exports | Remove | | Magic numbers | Hardcoded values | Use constants |
markdown## Code Quality Audit - [ ] No files over 500 lines - [ ] No functions over 50 lines - [ ] No nesting deeper than 4 levels - [ ] No functions with >5 parameters - [ ] No obvious code duplication - [ ] No dead/unused code - [ ] Consistent naming conventions - [ ] Proper error handling
bash# Check outdated packages (npm) npm outdated # Check for vulnerabilities npm audit # Analyze bundle size npx webpack-bundle-analyzer # Check unused dependencies npx depcheck
| Metric | Healthy | Warning | Critical | |--------|---------|---------|----------| | Outdated (major) | 0 | 1-3 | >3 | | Outdated (minor) | <5 | 5-10 | >10 | | Vulnerabilities | 0 | Low/Med | High/Crit | | Unused deps | 0 | 1-3 | >3 | | Bundle size | <500KB | 500KB-1MB | >1MB |
markdown## Dependencies Audit - [ ] No critical vulnerabilities - [ ] No high vulnerabilities - [ ] <3 major version updates pending - [ ] No unused dependencies - [ ] Lock file in sync - [ ] Bundle size reasonable
bash# Check for secrets in code grep -r "password\|secret\|api_key\|token" --include="*.ts" --include="*.js" # Check for hardcoded credentials grep -r "Bearer \|Basic " --include="*.ts" # Check .env is gitignored cat .gitignore | grep ".env"
| Check | Concern | Solution | |-------|---------|----------| | Secrets in code | Credential exposure | Use env vars | | .env committed | Secret leak | Add to .gitignore | | SQL strings | SQL injection | Use parameterized queries | | User input in HTML | XSS | Sanitize/escape | | Outdated deps | Known vulns | Update regularly | | No rate limiting | DoS | Add rate limits | | No input validation | Injection | Validate all inputs |
markdown## Security Audit - [ ] No hardcoded secrets - [ ] .env files gitignored - [ ] Dependencies scanned for vulns - [ ] Input validation in place - [ ] Output encoding for XSS - [ ] SQL injection prevention - [ ] Authentication implemented - [ ] Authorization checks exist
bash# Run tests with coverage (npm/jest) npm test -- --coverage # Run tests with coverage (pytest) pytest --cov=src --cov-report=html
| Metric | Good | Acceptable | Poor | |--------|------|------------|------| | Line coverage | >80% | 60-80% | <60% | | Branch coverage | >70% | 50-70% | <50% | | Function coverage | >80% | 60-80% | <60% |
markdown## Testing Audit - [ ] Unit tests exist - [ ] Integration tests exist - [ ] Line coverage >60% - [ ] Critical paths tested - [ ] Edge cases covered - [ ] Tests run in CI - [ ] Test execution <5 min - [ ] No flaky tests
bash# Check for README ls README.md # Check for API docs ls docs/ || ls documentation/ # Check for inline docs (JSDoc, docstrings) grep -r "@param\|@returns\|Args:\|Returns:" src/
| Doc Type | Purpose | Required | |----------|---------|----------| | README.md | Project overview | Always | | CONTRIBUTING.md | Contribution guide | Open source | | API docs | Endpoint reference | APIs | | Code comments | Complex logic | As needed | | Architecture docs | System design | Large projects | | CHANGELOG.md | Version history | Libraries |
markdown## Documentation Audit - [ ] README exists and current - [ ] Installation instructions - [ ] Usage examples - [ ] API documentation - [ ] Contributing guide - [ ] License specified - [ ] Complex code documented
| Aspect | Check | Concern | |--------|-------|---------| | Coupling | Import chains | Tight coupling | | Cohesion | Module size | God modules | | Layers | Directory structure | Layer violations | | Dependencies | Package.json | Circular deps | | Config | Hardcoded values | Environment issues |
markdown## Architecture Smells - Circular dependencies - God classes/modules - Feature envy (cross-module reaching) - Shotgun surgery (changes touch many files) - Inappropriate intimacy (modules know too much)
markdown## Architecture Audit - [ ] Clear module boundaries - [ ] No circular dependencies - [ ] Proper layer separation - [ ] Configuration externalized - [ ] Environment-specific settings - [ ] Scalability considered - [ ] Single responsibility
markdown# Project Health Report **Project:** [Name] **Date:** [Date] **Auditor:** Claude ## Summary | Category | Score | Status | |----------|-------|--------| | Code Quality | X/10 | 🟢/🟡/🔴 | | Dependencies | X/10 | 🟢/🟡/🔴 | | Security | X/10 | 🟢/🟡/🔴 | | Testing | X/10 | 🟢/🟡/🔴 | | Documentation | X/10 | 🟢/🟡/🔴 | | Architecture | X/10 | 🟢/🟡/🔴 | | **Overall** | **X/10** | **Status** | ## Critical Issues (Fix Immediately) 1. [Issue description] 2. [Issue description] ## High Priority (Fix Soon) 1. [Issue description] 2. [Issue description] ## Recommendations 1. [Recommendation] 2. [Recommendation] ## Technical Debt - [Debt item with estimated effort] - [Debt item with estimated effort]
bash# Full audit script echo "=== Code Stats ===" && cloc src/ echo "=== Dependencies ===" && npm outdated echo "=== Security ===" && npm audit echo "=== Test Coverage ===" && npm test -- --coverage echo "=== TODO/FIXME ===" && grep -r "TODO\|FIXME" src/
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-04 | pass→pass | 7,854 | 8,043 | +2% | 1 | 1 | 0% | 1,278 | 3,187 | +149% | 0 | 0 | — |
case-05 | pass→pass | 16,383 | 15,775 | -4% | 1 | 1 | 0% | 3,509 | 5,113 | +46% | 0 | 0 | — |
case-01 | fail→pass | 18,329 | 28,244 | +54% | 1 | 1 | 0% | 2,075 | 3,642 | +76% | 0 | 0 | — |
case-02 | fail→fail | 21,348 | 20,935 | -2% | 1 | 1 | 0% | 2,354 | 5,238 | +123% | 0 | 0 | — |
case-03 | fail→fail | 22,955 | 27,534 | +20% | 1 | 1 | 0% | 3,720 | 6,229 | +67% | 0 | 0 | — |
case-06 | pass→fail | 10,088 | 6,985 | -31% | 1 | 1 | 0% | 1,831 | 2,971 | +62% | 0 | 0 | — |
case-07 | fail→pass | 12,446 | 4,685 | -62% | 1 | 1 | 0% | 2,042 | 2,576 | +26% | 0 | 0 | — |
case-08 | pass→pass | 13,940 | 9,431 | -32% | 1 | 1 | 0% | 2,148 | 3,365 | +57% | 0 | 0 | — |
case-09 | fail→pass | 10,822 | 5,012 | -54% | 1 | 1 | 0% | 1,778 | 2,708 | +52% | 0 | 0 | — |
case-10 | fail→pass | 11,066 | 4,924 | -56% | 1 | 1 | 0% | 1,654 | 2,565 | +55% | 0 | 0 | — |
case-11 | fail→pass | 11,117 | 4,222 | -62% | 1 | 1 | 0% | 1,774 | 2,494 | +41% | 0 | 0 | — |
case-12 | pass→pass | 9,561 | 7,230 | -24% | 1 | 1 | 0% | 1,601 | 2,974 | +86% | 0 | 0 | — |
case-13 | pass→pass | 10,438 | 6,191 | -41% | 1 | 1 | 0% | 1,681 | 2,820 | +68% | 0 | 0 | — |
case-14 | pass→pass | 14,944 | 10,136 | -32% | 1 | 1 | 0% | 2,445 | 3,358 | +37% | 0 | 0 | — |
case-15 | fail→pass | 12,642 | 4,564 | -64% | 1 | 1 | 0% | 1,986 | 2,537 | +28% | 0 | 0 | — |
case-16 | pass→pass | 3,322 | 3,327 | +0% | 1 | 1 | 0% | 509 | 2,346 | +361% | 0 | 0 | — |
case-17 | pass→pass | 9,105 | 7,030 | -23% | 1 | 1 | 0% | 1,414 | 3,001 | +112% | 0 | 0 | — |
case-18 | pass→pass | 7,884 | 2,314 | -71% | 1 | 1 | 0% | 1,150 | 2,199 | +91% | 0 | 0 | — |
case-19 | fail→pass | 10,689 | 2,970 | -72% | 1 | 1 | 0% | 1,642 | 2,302 | +40% | 0 | 0 | — |
case-20 | pass→pass | 10,316 | 3,207 | -69% | 1 | 1 | 0% | 1,458 | 2,263 | +55% | 0 | 0 | — |
case-21 | pass→pass | 8,533 | 4,322 | -49% | 1 | 1 | 0% | 1,475 | 2,571 | +74% | 0 | 0 | — |
case-22 | fail→fail | 8,070 | 2,118 | -74% | 1 | 1 | 0% | 1,169 | 2,143 | +83% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted. The headline lift of +27 percentage points is the difference between those two pass rates over the 22 comparable cases. 1 case got worse with the skill loaded, and it is included in that figure.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.