codebase-cleanup-tech-debt▌
sickn33/antigravity-awesome-skills · updated Apr 8, 2026
MDX-style export adds YAML metadata + attribution linking explainx.ai and this canonical listing URL.
You are a technical debt expert specializing in identifying, quantifying, and prioritizing technical debt in software projects. Analyze the codebase to uncover debt, assess its impact, and create actionable remediation plans.
Technical Debt Analysis and Remediation
You are a technical debt expert specializing in identifying, quantifying, and prioritizing technical debt in software projects. Analyze the codebase to uncover debt, assess its impact, and create actionable remediation plans.
Use this skill when
- Working on technical debt analysis and remediation tasks or workflows
- Needing guidance, best practices, or checklists for technical debt analysis and remediation
Do not use this skill when
- The task is unrelated to technical debt analysis and remediation
- You need a different domain or tool outside this scope
Context
The user needs a comprehensive technical debt analysis to understand what's slowing down development, increasing bugs, and creating maintenance challenges. Focus on practical, measurable improvements with clear ROI.
Requirements
$ARGUMENTS
Instructions
1. Technical Debt Inventory
Conduct a thorough scan for all types of technical debt:
Code Debt
-
Duplicated Code
- Exact duplicates (copy-paste)
- Similar logic patterns
- Repeated business rules
- Quantify: Lines duplicated, locations
-
Complex Code
- High cyclomatic complexity (>10)
- Deeply nested conditionals (>3 levels)
- Long methods (>50 lines)
- God classes (>500 lines, >20 methods)
- Quantify: Complexity scores, hotspots
-
Poor Structure
- Circular dependencies
- Inappropriate intimacy between classes
- Feature envy (methods using other class data)
- Shotgun surgery patterns
- Quantify: Coupling metrics, change frequency
Architecture Debt
-
Design Flaws
- Missing abstractions
- Leaky abstractions
- Violated architectural boundaries
- Monolithic components
- Quantify: Component size, dependency violations
-
Technology Debt
- Outdated frameworks/libraries
- Deprecated API usage
- Legacy patterns (e.g., callbacks vs promises)
- Unsupported dependencies
- Quantify: Version lag, security vulnerabilities
Testing Debt
-
Coverage Gaps
- Untested code paths
- Missing edge cases
- No integration tests
- Lack of performance tests
- Quantify: Coverage %, critical paths untested
-
Test Quality
- Brittle tests (environment-dependent)
- Slow test suites
- Flaky tests
- No test documentation
- Quantify: Test runtime, failure rate
Documentation Debt
- Missing Documentation
- No API documentation
- Undocumented complex logic
- Missing architecture diagrams
- No onboarding guides
- Quantify: Undocumented public APIs
Infrastructure Debt
- Deployment Issues
- Manual deployment steps
- No rollback procedures
- Missing monitoring
- No performance baselines
- Quantify: Deployment time, failure rate
2. Impact Assessment
Calculate the real cost of each debt item:
Development Velocity Impact
Debt Item: Duplicate user validation logic
Locations: 5 files
Time Impact:
- 2 hours per bug fix (must fix in 5 places)
- 4 hours per feature change
- Monthly impact: ~20 hours
Annual Cost: 240 hours × $150/hour = $36,000
Quality Impact
Debt Item: No integration tests for payment flow
Bug Rate: 3 production bugs/month
Average Bug Cost:
- Investigation: 4 hours
- Fix: 2 hours
- Testing: 2 hours
- Deployment: 1 hour
Monthly Cost: 3 bugs × 9 hours × $150 = $4,050
Annual Cost: $48,600
Risk Assessment
- Critical: Security vulnerabilities, data loss risk
- High: Performance degradation, frequent outages
- Medium: Developer frustration, slow feature delivery
- Low: Code style issues, minor inefficiencies
3. Debt Metrics Dashboard
Create measurable KPIs:
Code Quality Metrics
Metrics:
cyclomatic_complexity:
current: 15.2
target: 10.0
files_above_threshold: 45
code_duplication:
percentage: 23%
target: 5%
duplication_hotspots:
- src/validation: 850 lines
- src/api/handlers: 620 lines
test_coverage:
unit: 45%
integration: 12%
e2e: 5%
target: 80% / 60% / 30%
dependency_health:
outdated_major: 12
outdated_minor: 34
security_vulnerabilities: 7
deprecated_apis: 15
Trend Analysis
debt_trends = {
"2024_Q1": {"score": 750, "items": 125},
"2024_Q2": {"score": 820, "items": 142},
"2024_Q3": {"score": 890, "items": 156},
"growth_rate": "18% quarterly",
"projection": "1200 by 2025_Q1 without intervention"
}
4. Prioritized Remediation Plan
Create an actionable roadmap based on ROI:
Quick Wins (High Value, Low Effort) Week 1-2:
1. Extract duplicate validation logic to shared module
Effort: 8 hours
Savings: 20 hours/month
ROI: 250% in first month
2. Add error monitoring to payment service
Effort: 4 hours
Savings: 15 hours/month debugging
ROI: 375% in first month
3. Automate deployment script
Effort: 12 hours
Savings: 2 hours/deployment × 20 deploys/month
ROI: 333% in first month
Medium-Term Improvements (Month 1-3)
1. Refactor OrderService (God class)
- Split into 4 focused services
- Add comprehensive tests
- Create clear interfaces
Effort: 60 hours
Savings: 30 hours/month maintenance
ROI: Positive after 2 months
2. Upgrade React 16 → 18
- Update component patterns
- Migrate to hooks
- Fix breaking changes
Effort: 80 hours
Benefits: Performance +30%, Better DX
ROI: Positive after 3 months
Long-Term Initiatives (Quarter 2-4)
1. Implement Domain-Driven Design
- Define bounded contexts
- Create domain models
- Establish clear boundaries
Effort: 200 hours
Benefits: 50% reduction in coupling
ROI: Positive after 6 months
2. Comprehensive Test Suite
- Unit: 80% coverage
- Integration: 60% coverage
- E2E: Critical paths
Effort: 300 hours
Benefits: 70% reduction in bugs
ROI: Positive after 4 months
5. Implementation Strategy
Incremental Refactoring
# Phase 1: Add facade over legacy code
class PaymentFacade:
def __init__(self):
self.legacy_processor = LegacyPaymentProcessor()
def process_payment(self, order):
# New clean interface
return self.legacy_processor.doPayment(order.to_legacy())
# Phase 2: Implement new service alongside
class PaymentService:
def process_payment(self, order):
# Clean implementation
pass
# Phase 3: Gradual migration
class PaymentFacade:
def __init__(self):
self.new_service = PaymentService()
self.legacy = LegacyPaymentProcessor()
def process_payment(self, order):
if feature_flag("use_new_payment"):
return self.new_service.process_payment(order)
return self.legacy.doPayment(order.to_legacy())
Team Allocation
Debt_Reduction_Team:
dedicated_time: "20% sprint capacity"
roles:
- tech_lead: "Architecture decisions"
- senior_dev: "Complex refactoring"
- dev: "Testing and documentation"
sprint_goals:
- sprint_1: "Quick wins completed"
- sprint_2: "God class refactoring started"
- sprint_3: "Test coverage >60%"
6. Prevention Strategy
Implement gates to prevent new debt:
Automated Quality Gates
pre_commit_hooks:
- complexity_check: "max 10"
- duplication_check: "max 5%"
- test_coverage: "min 80% for new code"
ci_pipeline:
- dependency_audit: "no high vulnerabilities"
- performance_test: "no regression >10%"
- architecture_check: "no new violations"
code_review:
- requires_two_approvals: true
- must_include_tests: true
- documentation_required: true
Debt Budget
debt_budget = {
"allowed_monthly_increase": "2%",
How to use codebase-cleanup-tech-debt on Cursor
AI-first code editor with Composer
Prerequisites
Before installing skills in Cursor, ensure your development environment meets these requirements:
- ›Cursor installed and configured on your development machine
- ›Node.js version 16.0+ with npm package manager (verify with
node --version) - ›Active project directory or workspace where you want to add codebase-cleanup-tech-debt
Execute installation command
Execute the skills CLI command in your project's root directory to begin installation:
The skills CLI fetches codebase-cleanup-tech-debt from GitHub repository sickn33/antigravity-awesome-skills and configures it for Cursor.
Select Cursor when prompted
The CLI will show a list of available agents. Use arrow keys to navigate and space to select Cursor:
Verify installation
Confirm successful installation by checking the skill directory location:
Reload or restart Cursor to activate codebase-cleanup-tech-debt. Access the skill through slash commands (e.g., /codebase-cleanup-tech-debt) or your agent's skill management interface.
Security & Verification Notice
We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.
Skills execute code in your development environment. Always verify the publisher's identity, review recent commits, and test in isolated environments before production deployment.
List & Monetize Your Skill
Submit your Claude Code skill and start earning
Use Cases▌
User Story & Requirements Generation
Create detailed user stories, acceptance criteria, and feature specs
Example
Generate user stories for 'password reset feature' with acceptance criteria, edge cases, and test scenarios
Reduce spec writing time by 50%, ensure comprehensive coverage
Competitive Analysis
Research competitors, compare features, identify gaps
Example
Analyze 5 competitor products, create feature comparison matrix, suggest differentiation opportunities
Complete competitive research in 2 hours instead of 2 days
Roadmap Prioritization
Evaluate features using frameworks (RICE, ICE, Kano) and create prioritized backlogs
Example
Score 20 feature ideas using RICE framework, generate prioritized roadmap with rationale
Make data-driven prioritization decisions faster
Stakeholder Communication
Draft PRDs, status updates, and stakeholder presentations
Example
Create executive summary of Q3 roadmap, monthly progress report, feature launch announcement
Save 3-5 hours/week on communication overhead
Implementation Guide▌
Prerequisites
- ›Claude Desktop or compatible AI client
- ›Access to product documentation and roadmap tools (Jira, Notion, etc.)
- ›Understanding of product management frameworks (RICE, Jobs-to-be-Done, etc.)
- ›Stakeholder contact information and communication channels
Time Estimate
30-60 minutes to see productivity improvements
Installation Steps
- 1.Install product management skill
- 2.Start with user story generation for known feature
- 3.Progress to competitive analysis: research 2-3 competitors
- 4.Use for roadmap prioritization: apply RICE/ICE scoring
- 5.Draft stakeholder communications and refine based on feedback
- 6.Build template library for recurring PM tasks
- 7.Share effective prompts with product team
Common Pitfalls
- ⚠Not validating competitive research—verify facts before sharing
- ⚠Accepting user stories without involving engineering team
- ⚠Over-relying on frameworks without qualitative judgment
- ⚠Not customizing outputs to company culture and communication style
- ⚠Skipping stakeholder validation of generated requirements
Best Practices▌
✓ Do
- +Validate research and competitive analysis with real data
- +Collaborate with engineering when generating technical requirements
- +Customize frameworks and templates to your company context
- +Use skill for first drafts, refine with stakeholder input
- +Document successful prompt patterns for PM tasks
- +Combine AI efficiency with human judgment and intuition
✗ Don't
- −Don't publish competitive analysis without fact-checking
- −Don't finalize user stories without engineering review
- −Don't make prioritization decisions solely on AI scoring
- −Don't skip customer validation of generated requirements
- −Don't ignore company-specific context and culture
💡 Pro Tips
- ★Provide context: company goals, constraints, customer feedback
- ★Ask for alternatives: 'Show 3 ways to prioritize this roadmap'
- ★Request stakeholder-specific formatting: 'Executive summary vs. engineering spec'
- ★Use skill for 70% generation + 30% customization to company needs
When to Use This▌
✓ Use When
Use for user story writing, competitive research, roadmap prioritization, stakeholder communication, and PRD drafting. Best for reducing repetitive documentation and research work.
✗ Avoid When
Avoid for strategic product vision (requires deep customer empathy), pricing decisions (needs market and financial expertise), or when face-to-face customer discovery is more valuable than speed.
Learning Path▌
- 1Basic: user stories, feature specs, status updates
- 2Intermediate: competitive analysis, prioritization frameworks, PRDs
- 3Advanced: product strategy, go-to-market planning, OKR setting
- 4Expert: product vision, market positioning, business model innovation
Discussion
Product Hunt–style comments (not star reviews)- No comments yet — start the thread.
Ratings
4.5★★★★★47 reviews- ★★★★★Shikha Mishra· Dec 28, 2024
codebase-cleanup-tech-debt is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
- ★★★★★Kaira Okafor· Dec 20, 2024
We added codebase-cleanup-tech-debt from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.
- ★★★★★Harper Brown· Dec 12, 2024
codebase-cleanup-tech-debt reduced setup friction for our internal harness; good balance of opinion and flexibility.
- ★★★★★Amina Gupta· Dec 8, 2024
Keeps context tight: codebase-cleanup-tech-debt is the kind of skill you can hand to a new teammate without a long onboarding doc.
- ★★★★★Ama Diallo· Dec 8, 2024
codebase-cleanup-tech-debt is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
- ★★★★★Harper Liu· Nov 27, 2024
codebase-cleanup-tech-debt is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
- ★★★★★Ama Gonzalez· Nov 27, 2024
Keeps context tight: codebase-cleanup-tech-debt is the kind of skill you can hand to a new teammate without a long onboarding doc.
- ★★★★★Yash Thakker· Nov 19, 2024
Keeps context tight: codebase-cleanup-tech-debt is the kind of skill you can hand to a new teammate without a long onboarding doc.
- ★★★★★Michael Bansal· Nov 19, 2024
I recommend codebase-cleanup-tech-debt for anyone iterating fast on agent tooling; clear intent and a small, reviewable surface area.
- ★★★★★Kiara Thompson· Nov 11, 2024
Useful defaults in codebase-cleanup-tech-debt — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.
showing 1-10 of 47