Skills

Tech Debt Audit

Thorough, file-cited technical debt audit across 9 dimensions using AST-grep...

Install

npx skills add code-yeongyu/oh-my-openagent --skill tech-debt-audit -g -a claude-code -y
Category
Engineering
Updated
3d ago
License
See repository
Context cost
Mediumabout 2,236 tokens
Runs scripts
No, instructions only

What it does

Thorough, file-cited technical debt audit across 9 dimensions using AST-grep (tree-sitter), grep, LSP, and language-native tooling. Produces TECH_DEBT_AUDIT.md with severity, effort estimates, and prioritized fixes. Use when asked for codebase health check, tech debt audit, architecture review, code quality assessment, or cleanup planning. Triggers: 'tech debt', 'technical debt', 'debt audit', 'code health', 'technical debt audit', 'codebase health check', 'find tech debt', 'debt analysis', 'audit code quality'.

Tech Debt Audit Protocol

Model-agnostic technical debt audit for oh-my-openagent (OMO). Uses OMO's built-in tools (grep, glob, bash with sg, read, lsp_diagnostics, task). Produces a grounded, citable TECH_DEBT_AUDIT.md artifact.

Output

Write results to TECH_DEBT_AUDIT.md in the repo root with:

  1. Executive Summary, 3-5 sentences: overall health, worst dimension, quick wins count
  2. Mental Model, the repo's architecture in 1 paragraph (what it does, stack, module boundaries)
  3. Findings Table, columns: ID, Category, File:Line, Severity (Critical/High/Medium/Low), Effort (Hours), Description, Recommendation
  4. Top 5 Priorities, ranked by impact/effort ratio
  5. Quick Wins Checklist, items under 30 minutes each
  6. "Looks Bad But Is Fine", patterns that look like debt but are intentional
  7. Open Questions, things the maintainer should clarify

Phase 0: Orient

Standard (always run)

  1. glob("**/*.ts") / glob("**/*.py") / etc, map the language stack
  2. glob("**/package.json") + read(), dependencies and build tooling
  3. bash("git log --oneline -200"), churn: find highest-change files
  4. glob("**/*") + basic math, find largest files (>300 LOC are candidates)
  5. Cross-reference high-churn + large = debt hot zones
  6. Write the mental model paragraph in your own working context

Phase 1: Audit Across 9 Dimensions

Use OMO tools for each dimension. Run parallel tool calls within each dimension. Every finding MUST cite file:line:col.

1. Architectural Decay

Standard (always run)

  • bash("sg -p \"import { $$$ } from '$SRC'\" -l ts ."), map module graph, look for circular patterns
  • bash("sg -p \"class $NAME { $$$ }\" -l ts ."), check for god classes
  • grep("TODO|FIXME|HACK|XXX|WORKAROUND|TEMP"), tagged debt markers
  • grep("async|await") on sync-looking files, misplaced async boundaries
  • bash("wc -l <file>") on each large file found in Phase 0
Read the whole SKILL.md on GitHub

More in Engineering