/agentic-awesome-skills:untangle-codebase [optional area or concern to focus on]from agentic-awesome-skills
Performs a codebase-wide structural refactor by identifying hidden links, duplicated logic, and poor colocation. Use for explicit restructuring requests, not single defects.
Ships in agentic-awesome-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description, though model invocation is off: only you can start it.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Use for an explicitly requested codebase-wide structural refactor. For a single defect, use systematic debugging; for a bounded cleanup, prefer code-refactoring-refactor-clean.
Work only within the user-authorized repository and scope. Preserve unrelated work and establish baseline behavior with existing checks. Refactoring writes files; never publish, deploy, push, or delete user data without authorization. Optional comment/test removal requires the selection requested below. Do not remove tests merely to make failures disappear. Use subagents only when available and authorized; otherwise perform the review passes yourself. Do not upload private source to external services without permission.
Start a thorough refactor of this codebase and complete it to the end.
Treat this as a goal.
Why do this at all?
1. Ask
Besides untangling the codebase, there are two other things you may do:
| Addition | What it does |
|---|---|
| Comments | Remove comments that only restate the code. |
| Tests | Remove tests that wouldn't catch a real bug, and fix the ones that fail without one. |
List these (with their exact descriptions) for the user and ask which ones to do. Then do only those.
2. List every problem
Don't change anything yet.
Go through the codebase asking one thing: should these pieces change together? Write down every place the code gets the answer wrong, as in the decision log example. There are only three ways to get it wrong.
Hidden links: pieces that must change together, where the code doesn't show it.
Needless links: pieces tied together that change for different reasons.
Surplus: pieces with no reason of their own to change.
Also write down every special case: code that exists for one situation instead of following from how the system works. Each one is a requirement the design never accounted for, so use them to work out what the system needs to be.
if for one value3. Redesign from first principles
Work out the fixes as if the system had known today's requirements from the start. Look for the one fix behind several problems, which often looks nothing like them. Don't fix special cases one by one.
Ask the same thing of every fix, even one that looks better in the code: pieces that change together end up together, pieces that don't aren't tied, and everything depends on what changes less.
Write each fix above the problems it solves, as in the decision log example.
4. Fix everything on the list
Remove the special cases the redesign makes unnecessary, and keep the ones the system still needs. Don't go looking for bugs separately. A structural fix may fix some along the way, which is fine.
If the user chose Comments:
// sort first so the binary search works, only change when it does, so they have no reason of their own to change. Remove them, even if they're phrased as a why.// the proxy drops websockets, so we poll, change when that does, and the code can't show it. Keep them.// wait 100ms because the cache isn't ready yet, only change when the problem behind the workaround does. They go when the redesign removes that problem.If the user chose Tests, do this last, because tests are your regression safety net. A test should fail on a regression, and only then:
5. Check, and repeat until done
Have subagents search for special cases, hidden links, needless links and surplus. Do not stop until there is nothing worth fixing left.
You're done when:
Tips
The list of problems:
- `ui/LogoutDialog.tsx:30` waits 100ms after closing and hopes the message input can take focus by then.
- `ui/Toolbar.tsx:40` and `ui/Menu.tsx:22` call the same actions, each with its own check for when they're disabled.
- `checkout/submit.ts:9` depends directly on `payments/stripe.ts`.
- `shortcuts/keymap.ts:18` has a switch with one case per action, separate from the menu's list.
- `ui/CommandPalette.tsx:55` keeps its own list of actions, and it's missing the newer ones.
- `ui/SettingsDialog.tsx:61` sets a global `skipRefocus` flag to stop the logout dialog it opens from sending focus to the message input.
- `history/undo.ts:30` has a special case for every action that can be undone.
- `refunds/refund.ts:22` wraps every Stripe call in `if (order.provider === "paypal")`.
- Every action handler has to call `track()` by hand, and some don't.
- `ui/Toolbar.test.tsx` and `ui/Menu.test.tsx` test the same actions separately.
Then with the fixes:
- Make the general `Dialog` give focus back to whatever had it before it opened, so the wait and the flag can both go.
- `ui/LogoutDialog.tsx:30` waits 100ms after closing and hopes the message input can take focus by then.
- `ui/SettingsDialog.tsx:61` sets a global `skipRefocus` flag to stop the logout dialog it opens from sending focus to the message input.
- Define a `PaymentProvider` interface that Stripe and PayPal both implement, so checkout and refunds no longer know which one they're using.
- `checkout/submit.ts:9` depends directly on `payments/stripe.ts`.
- `refunds/refund.ts:22` wraps every Stripe call in `if (order.provider === "paypal")`.
- Make every user action a command with a name, a handler and an undo, so the toolbar, menu, shortcuts, palette and undo history all run from one list.
- `ui/Toolbar.tsx:40` and `ui/Menu.tsx:22` call the same actions, each with its own check for when they're disabled.
- `shortcuts/keymap.ts:18` has a switch with one case per action, separate from the menu's list.
- `ui/CommandPalette.tsx:55` keeps its own list of actions, and it's missing the newer ones.
- `history/undo.ts:30` has a special case for every action that can be undone.
- Every action handler has to call `track()` by hand, and some don't.
- `ui/Toolbar.test.tsx` and `ui/Menu.test.tsx` test the same actions separately.
Illustrative request: "Untangle our checkout module while preserving public behavior; keep comments and tests." Produce a decision log of coupling problems, implement scoped structural changes, and report baseline and final regression checks. This is an example, not an executed benchmark.
Adapted from caldoai/skills, pinned upstream commit f3cf47774975a7d9fca45730babf4ff7ad765ada. MIT copyright notice is retained in LICENSE. Local adaptations add AAS metadata, explicit scope, safety boundaries, examples and limitations.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub sickn33/agentic-awesome-skills --plugin agentic-awesome-skills3,104 skills in this plugin
/007Security audit, hardening, threat modeling (STRIDE/PASTA), Red/Blue Team, OWASP checks, code review, incident response, and infrastructure security for any project./00-andruia-consultantUsar al iniciar o mejorar un proyecto de IA: diagnostica código y restricciones, propone skills existentes y redacta tareas y un plan de implementación en español./10-andruia-skill-smithUsar para crear o mejorar una skill de Andru.ia: define entradas y resultados, redacta SKILL.md con ejemplos y límites, valida la estructura y prepara una PR.3 plugins in 2 repositories ship this exact skill · first indexed Nov 5, 2026
Other plugins' skills for the same job