/ancplua-skills:tech-debtfrom ancplua-skills
Evidence-grounded technical-debt audit. Hunts accretion — code that was added (shimmed, wrapped, re-validated, try/catch-padded) when it should have been deleted — plus NativeAOT/source-generator hazards. Trigger with "tech debt", "technical debt audit", "what should we refactor", "code health", or when the user asks about code quality, refactoring priorities, or maintenance backlog.
Ships in ancplua-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Debt here is code that was added when it should have been deleted. The remedy column is deletion, not a nicer abstraction. Every finding is grounded in the actual code, never in a heuristic. If you can only describe a finding in prose, you have not read it yet — go read it.
Hunt these. Each row is: what it looks like, how to find it, and the fix (which is removal).
| Signature | Detection | Fix |
|---|---|---|
| Wrapper/adapter/shim that only forwards | class \w*(Adapter|Wrapper|Shim|Compat|Proxy|Manager) whose methods just delegate | Inline the callee, delete the layer |
| Parallel old/new both reachable | \w+(V2|Old|New|Legacy|_v\d) with both live | Pick one, migrate callers, delete the other |
| Back-compat left in place | [Obsolete], #pragma warning disable, TODO: remove, kept for compat | If nothing depends on it, delete now. If something does, that dependency is the finding |
| Validation of validation | Second null/range check on a value already guarded upstream; ThrowIfNull then if (x is null) again downstream | One guard at the boundary, delete the rest |
| Try/catch bloat | catch (Exception), catch→log→rethrow, try wrapping >1 operation | Early guard return; let it throw where you cannot handle it |
| Magic literal | Same numeric/string literal ≥2× | One named const. If it is config, one source |
| Premature abstraction | Interface/base with exactly one impl and one caller | Collapse to the concrete type |
| God unit | File/class > ~400 LOC or method > ~40 lines mixing concerns | Split by concern, not by line count |
Thresholds (400 / 40 / ≥2×) are defaults — tune to the repo.
Debt that a generic audit misses and that breaks your hard constraints:
GetMethod / GetProperties / Activator.CreateInstance / Type.GetType(" / dynamic / Expression.Compile. Each is a trim/AOT hazard (IL2xxx / IL3050). Fix is a source generator or a compile-time constant map, not a suppression.*.Generators / *.SourceGenerators / analyzer project not targeting netstandard2.0, or reaching for net10-only APIs. Breaks analyzer load in the compiler host.[RequiresUnreferencedCode], [RequiresDynamicCode], [UnconditionalSuppressMessage(... "IL2\d{3}")], <IlcTrim*>. A suppression added to silence rather than to prove safe is debt.Each finding is:
path:lineNo prose-only findings. Level is seziert, not überflogen — if the snippet is not shown, the finding does not ship.
Required section. Do not flag intentional structure — a false positive costs a whole session:
catch that maps to a domain error at an API edge — that is the handler, keep it.For each thing that looks like a signature hit but is intentional, name it and say why it stays.
Score each finding:
Priority = (Impact + Risk) x (6 - Effort)
Produce a chat todo list. Not a document, not a memory. It is worked through in order and can be paused when something unexpected comes up. Each item carries its path:line and priority score.
Order the items so the encompassing fix comes before its parts. Never work a subset before the item that contains it.
If the scope is too large for one pass, split it into scoped, cohesive sessions. Prefer three sessions of ~20 items over one list of 50. Each session can then be delegated or run on its own.
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub ancplua/ancplua-skills --plugin ancplua-skills43 skills in this plugin
/agent-log-scanScan agent transcripts and turn antipatterns into config and routine changes, not just an allowlist like fewer-permission-prompts. Use when asked to scan agent logs or session history, "why do my agents keep failing", "what happened across my sessions", to find retry loops, permission thrash, API dead-ends or limit interrupts, or raise autonomy./analyzer-purityKeep Roslyn analyzers, source generators and code fixes pure, loadable and cache-friendly inside every compiler host. Use when creating, changing, reviewing or packaging a netstandard2.0 project with IsRoslynComponent, EnforceExtendedAnalyzerRules or Microsoft.CodeAnalysis references, or when an RS1xxx/RS2xxx diagnostic, a sluggish IDE or a generator that reruns on every keystroke points at one./