Agent skill

Cleanup Specialist

by ahaodev in ahaodev/shadmin

Safe cleanup of Shadmin's Go backend, React frontend, Go CLI, and docs — remove dead code, consolidate duplication, and improve maintainability without changing behavior or adding features.

MITAuto-check passedDevelopment

Install Cleanup Specialist

skills CLI
$ npx skills add ahaodev/shadmin --skill cleanup-specialist -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install ahaodev/shadmin cleanup-specialist --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/ahaodev/shadmin.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agent/skills/cleanup-specialist .claude/skills/cleanup-specialist && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
cleanup-specialist
GitHub stars
174
Token cost
~1.3k tokens
SKILL.md length
544 words
Files
1
Skills in repo
3
Repo updated
First seen
Licence
MIT

At a glance

Safe cleanup of Shadmin's Go backend, React frontend, Go CLI, and docs — remove dead code, consolidate duplication, and improve maintainability without changing behavior or adding features.

  • Works in 5 steps: Inventory — list the dead code /… → Plan — state the exact files and… → Change — apply one cleanup at a time, in… → …
  • Asked to simplify
  • SKILL.md covers Scope, Surfaces and scope, Cleanup responsibilities and Rules, plus 2 more sections
  • Calls go, pnpm and make

What it does

Cleanup Specialist is an agent skill from ahaodev/shadmin. Safe cleanup of Shadmin's Go backend, React frontend, Go CLI, and docs — remove dead code, consolidate duplication, and improve maintainability without changing behavior or adding features. Use when asked to simplify, deduplicate, remove dead code, tidy up, refactor for maintainability, or align naming and conventions.

Its SKILL.md is about 1.3k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Code simplification. It works with React, TypeScript, shadcn/ui and Vite. The repository describes itself as: An Enterprise-Grade Full-Stack RBAC Permission Management System Built with Go + React. The licence is MIT.

When your agent uses it

  • Asked to simplify
  • Remove dead code
  • Refactor for maintainability
  • Align naming and conventions

Example prompts

  • “/cleanup-specialist”

Workflow steps

5 steps, taken from the first numbered list in SKILL.md.

  1. Inventory — list the dead code / duplication you found and where
  2. Plan — state the exact files and intended edits before changing anything
  3. Change — apply one cleanup at a time, in scope
  4. Verify — run the gates above; if behavior could be affected, compare before/after
  5. Report — list files changed, what was removed/merged, verification results, and residual risks

What it can do on your machine

Read from SKILL.md and the folder at commit b3547b2. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • go
    • pnpm
    • make

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use pnpm, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Cleanup Specialist loads about 1.3k tokens when it runs. Until then it costs about 85 tokens; SKILL.md has 544 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~85
When it runs · the whole SKILL.md, loaded when a task matches
~1.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from ahaodev/shadmin at commit b3547b2, republished under its MIT licence (© ahaodev). 544 words, ~1,295 tokens.

Download SKILL.mdSave it as .claude/skills/cleanup-specialist/SKILL.md (or your agent's skills folder).
name
cleanup-specialist
description
Safe cleanup of Shadmin's Go backend, React frontend, Go CLI, and docs — remove dead code, consolidate duplication, and improve maintainability without changing behavior or adding features. Use when asked to simplify, deduplicate, remove dead code, tidy up, refactor for maintainability, or align naming and conventions.

Shadmin Cleanup Specialist

Safe cleanup of Shadmin (Go/Gin/Ent backend, React 19 + TypeScript frontend, thin Go CLI). Simplify safely: remove dead code, consolidate duplication, and improve maintainability without changing behavior. Do not add features.

Scope

When a specific file or directory is mentioned:

  • Focus only on cleaning up the specified file(s) or directory
  • Read outside the target only to confirm usages before deleting or merging
  • Don't make changes outside the specified scope

When no specific target is provided:

  • Sweep the repo for cleanup opportunities
  • Prioritize the most impactful first: dead code, duplicated logic, then docs

Surfaces and scope

SurfacePaths
Backend (Go)main.go, cmd/, bootstrap/, api/, domain/, repository/, usecase/, ent/, internal/, pkg/
Frontend (React 19 + TS)frontend/src/
CLI (Go)cli/
Docsdocs/, README.md, README.zh.md, AGENTS.md, .agent/*.md

Never edit (generated or owned by tooling):

  • Generated code: ent/*.go (except ent/schema/), frontend/src/routeTree.gen.ts, docs/docs.go, docs/swagger.*, frontend/dist/
  • shadcn primitives: frontend/src/components/ui/

Frozen contracts — cleanup must not change:

  • API routes/paths. Casbin API resource IDs are deterministic (METHOD:/api/v1/path) and persisted in the apiresource table; renaming a route or path breaks role bindings.
  • Permission strings (system:<resource>:<action>) and Casbin middleware checks.
  • Response shape: domain.Response{Code, Msg, Data} with code 0 = success, 1 = error; domain.PagedResult[T] fields.
  • Layer separation (route → controller → usecase → repository). Similar-looking code across layers is architecture, not duplication.
  • Public CLI output contract (JSON by default, --pretty).

Cleanup responsibilities

Go backend:

  • Remove unused functions, variables, imports, unreachable branches, commented-out code, and leftover debug prints
  • Consolidate duplicated domain↔ent converters, pagination (domain.QueryParams.Paginate()), filter parsing, and HTTP status/error mapping
  • Simplify over-nested logic; keep context.WithTimeout + defer cancel() and fmt.Errorf("...: %w", err) wrapping intact
  • Align naming with conventions: lower_snake files, PascalCase exports, short receivers

React frontend:

  • Remove unused files, exports, and dependencies (use pnpm knip as a signal, then verify)
  • Consolidate repeated TanStack Query keys, useTableUrlState wiring, dialog state handling, and Zod schemas
  • Normalize API access: everything goes through services/ and returns response.data.data; no inline API calls
  • Replace duplicated permission checks with the existing usePermission() hook and PERMISSIONS constants
  • Keep imports on the @/ alias; component files PascalCase .tsx, utilities/hooks kebab-case .ts

CLI:

  • Remove dead flags/helpers, keep JSON-default + --pretty output behavior, config stays under cli/

Documentation:

  • Delete stale/redundant sections and boilerplate comments
  • Consolidate duplicated content across README.md, README.zh.md, AGENTS.md and docs/getting-started/*.{en,zh}.md — keep each fact in one place and cross-reference
  • Fix broken links and outdated commands/field names
Show full SKILL.md (166 more words)Show less

Rules

  • Prefer the smallest diff that removes the mess; no drive-by refactors
  • No new dependencies (backend or frontend)
  • No hardcoded menus in React — menus come from backend /api/v1/resources
  • Don't touch unrelated files; don't reformat files you didn't otherwise change
  • One improvement at a time, and re-verify after each removal

Verification (required)

Run the gates for every surface you touched and report exact results:

bash
# Backend
gofmt -s -l .            # should list nothing
go vet ./...
go test ./...

# Frontend (if frontend/ changed)
cd frontend && pnpm lint && pnpm format:check
# pnpm knip              # when hunting unused exports/deps

# CLI (if cli/ changed)
cd cli && make test

# Only if you edited ent/schema/
go generate ./ent

If a gate can't run (e.g., node_modules missing or pnpm unavailable), say so explicitly — never claim a check passed when it was skipped.

Workflow

  1. Inventory — list the dead code / duplication you found and where
  2. Plan — state the exact files and intended edits before changing anything
  3. Change — apply one cleanup at a time, in scope
  4. Verify — run the gates above; if behavior could be affected, compare before/after
  5. Report — list files changed, what was removed/merged, verification results, and residual risks

Focus on cleaning up existing code, not adding features. Work on both code (.go, .ts, .tsx) and documentation (.md) files.

© ahaodev, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agent/skills/cleanup-specialist of ahaodev/shadmin.

Open the folder on GitHubat commit b3547b2

Compare with similar skills

Cleanup Specialist next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Cleanup Specialist compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Cleanup Specialist this skillahaodev/shadmin174—~1.3kAutomated safety check: PassMIT
Web Artifacts Builderanthropics/skills180k41 repos~769Automated safety check: PassApache-2.0
Code Refactor Reviewkcsujeet/ilamy-calendar3512 repos~1.6kAutomated safety check: PassMIT
Morphous CatalogAmeyanagi/morphos102—~2.1kAutomated safety check: PassApache-2.0
Release New Versionkcsujeet/ilamy-calendar351—~5.8kAutomated safety check: PassMIT
Finish Extensions Featuresenchabot-opensource/monorepo114—~554Automated safety check: PassGPL-3.0

Similar skills

  • Web Artifacts Builder

    anthropics/skills

    Official

    Builds multi-component claude.ai HTML artifacts as a small React, TypeScript and Tailwind project, then bundles it into one shareable HTML file.

    180k GitHub starsUsed in 41 repos~769 tokens
    Frontend & DesignAuto-check passed
  • Code Refactor Review

    kcsujeet/ilamy-calendar

    Reviews code changes for reuse, composition, codebase consistency, and slop.

    351 GitHub starsUsed in 2 repos~1.6k tokens
    DevelopmentAuto-check passed
  • Morphous Catalog

    Ameyanagi/morphos

    Create or refresh Morphous website design-system/theme bundles from animal, insect, plant, landscape, mineral, weather, or other nature motifs.

    102 GitHub stars~2.1k tokensUpdated 1 mo ago
    Frontend & DesignAuto-check passed
  • Release New Version

    kcsujeet/ilamy-calendar

    Cut a new release of @ilamy/calendar — analyze commits since the last tag, suggest a semver bump, draft a CHANGELOG entry in the project's existing style, run the CI gate, commit, tag, push to…

    351 GitHub stars~5.8k tokensUpdated today
    DevelopmentAuto-check passed
  • Finish Extensions Feature

    senchabot-opensource/monorepo

    A skill your agent uses when completing a new feature or making a user-facing change in the apps/extensions workspace to ensure no required files or configurations are forgotten.

    114 GitHub stars~554 tokensUpdated 2 days ago
    DevelopmentAuto-check passed
  • Redesign My Landingpage

    instructa/agent-skills

    Build, critique, and iterate high-converting marketing or product landing pages using React + Vite + TypeScript + Tailwind and shadcn/ui components, with all icons sourced from Iconify.

    139 GitHub stars~1.8k tokensUpdated 10 days ago
    Frontend & DesignAuto-check passed

More from ahaodev/shadmin

  • Shadmin Dev

    ahaodev/shadmin

    Apply Shadmin feature-development standards (backend Go/Gin/Ent + frontend React/TS).

    174 GitHub stars~2.8k tokensUpdated today
    Auto-check passed
  • Shadmin CLI

    ahaodev/shadmin

    A skill your agent uses when the user asks to query Shadmin admin platform resources (users, roles, menus, registered API resources) from a terminal — for example "list shadmin users", "show shadmin…

    174 GitHub stars~1.1k tokensUpdated today
    Auto-check: notes

Categories

Questions about Cleanup Specialist

What does Cleanup Specialist do?

Safe cleanup of Shadmin's Go backend, React frontend, Go CLI, and docs — remove dead code, consolidate duplication, and improve maintainability without changing behavior or adding features. Cleanup Specialist is an agent skill from ahaodev/shadmin. Safe cleanup of Shadmin's Go backend, React frontend, Go CLI, and docs — remove dead code, consolidate duplication, and improve maintainability without changing behavior or adding features.

When should I use Cleanup Specialist?

Cleanup Specialist fits situations like: asked to simplify; remove dead code; refactor for maintainability; align naming and conventions.

How do I install Cleanup Specialist in Claude Code?

Run `npx skills add ahaodev/shadmin --skill cleanup-specialist -a claude-code`. Or copy the skill folder (.agent/skills/cleanup-specialist in ahaodev/shadmin) into .claude/skills/cleanup-specialist in your project. Claude Code loads it when a task matches its description.

How do I install Cleanup Specialist in Codex?

Run `npx skills add ahaodev/shadmin --skill cleanup-specialist -a codex`. Or copy the skill folder (.agent/skills/cleanup-specialist in ahaodev/shadmin) into .agents/skills/cleanup-specialist in your project. Codex loads it when a task matches its description.

Can I use Cleanup Specialist in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add ahaodev/shadmin --skill cleanup-specialist -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/cleanup-specialist, .gemini/skills/cleanup-specialist, .github/skills/cleanup-specialist and .opencode/skills/cleanup-specialist in your project.

What does Cleanup Specialist need to run?

Going by SKILL.md and its folder, Cleanup Specialist needs the command-line tools its instructions call (go, pnpm and make).

Does Cleanup Specialist access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Cleanup Specialist safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Cleanup Specialist use?

Cleanup Specialist is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Cleanup Specialist use?

About 1.3k tokens (SKILL.md is roughly 5.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Cleanup Specialist?

Skills that share tags, products or a category with Cleanup Specialist: Web Artifacts Builder (anthropics/skills, 180k stars), Code Refactor Review (kcsujeet/ilamy-calendar, 351 stars), Morphous Catalog (Ameyanagi/morphos, 102 stars) and Release New Version (kcsujeet/ilamy-calendar, 351 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Cleanup Specialist?

ahaodev (a GitHub user) maintains it in ahaodev/shadmin, which has 174 GitHub stars. The repository holds 3 skills in this directory. The repository was last updated on October 8, 2026.

Source: ahaodev/shadmin on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.