Technical Debt Patterns
Expert guide to detecting, categorizing, and prioritizing technical debt in Rails applications. Use when: (1) Auditing codebase health, (2) Planning refactoring sprints, (3) Estimating feature impact, (4) Identifying code smells, (5) Tracking deprecations. Trigger keywords: technical debt, code smell, complexity, cyclomatic, deprecation, legacy, refactor, audit, health check, god class
npx skills add majiayu000/claude-skill-registry --skill technical-debt-patterns --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# Technical Debt Patterns Expert patterns for detecting, categorizing, and prioritizing technical debt in Rails applications. ## Decision Tree: Debt Category Identification ``` What type of issue is this? │ ├─ Code structure problem? │ ├─ Method too long (>20 lines) → Code Smell: Long Method │ ├─ Class too large (>150 lines) → Code Smell: Large Class │ ├─ Excessive parameter passing → Code Smell: Data Clump │ └─ Method uses another object's data → Code Smell: Feature Envy │ ├─ Complexity issue? │ ├─ Flog score >60 → Complexity: High │ ├─ Cyclomatic complexity >10 → Complexity: High │ ├─ Deep nesting (>3 levels) → Complexity: Nesting │ └─ Too many conditionals → Complexity: Conditional │ ├─ Security concern? │ ├─ SQL injection risk → Security: SQL Injection │ ├─ XSS vulnerability → Security: XSS │ ├─ Mass assignment issue → Security: Mass Assignment │ └─ Outdated gem with CVE → Security: Dependency │ ├─ Outdated code? │ ├─ Rails deprecation warning → Deprecation: Rails │ ├─ Ruby version warning → Deprecation: Ruby │ └─ Deprecated gem API → Deprecation: Gem │ ├─ Performance problem? │ ├─ N+1 query pattern → Performance: N+1 │ ├─ Missing database index → Performance: Index │ ├─ Memory
- Decision Tree: Debt Category Identification
- NEVER Do These (Critical Anti-Patterns)
- Code Smell Detection Patterns
- Long Method (>20 lines)
- Large Class (>150 lines)
- Feature Envy
- Data Clump
- Complexity Metrics
- Flog Score Thresholds
- Cyclomatic Complexity
- Severity Scoring Framework
- Quick Reference Tables
- Detection Tools
- Effort Estimation
Find methods longer than 20 lines
awk '
len = NR - start
if (len > 20) print FILENAME ":" name " (" len " lines)"
start = 0
Find classes larger than 150 lines
for file in app/models/*.rb app/services/*.rb; do
if [ "$lines" -gt 150 ]; then
echo "$file: $lines lines"
fiWhat does the Technical Debt Patterns skill do?
Expert guide to detecting, categorizing, and prioritizing technical debt in Rails applications. Use when: (1) Auditing codebase health, (2) Planning refactoring sprints, (3) Estimating feature impact, (4) Identifying code smells, (5) Tracking deprecations. Trigger keywords: technical debt, code smell, complexity, cyclomatic, deprecation, legacy, refactor, audit, health check, god class
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill technical-debt-patterns --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
