Finding Duplicate Functions
obra/superpowers-lab
A skill your agent uses when auditing a codebase for semantic duplication - functions that do the same thing but have different names or implementations.
Two-mode skill: (1) find semantic duplicates — functions doing the same thing under different names, invisible to copy-paste detectors; (2) deepen shallow modules — thin wrappers and pass-through…
$ npx skills add romiluz13/cc10x --skill codebase-hygiene -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install romiluz13/cc10x codebase-hygiene --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/romiluz13/cc10x.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/cc10x/skills/codebase-hygiene .claude/skills/codebase-hygiene && rm -rf skills-srcUse ~/.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/
Install the "codebase-hygiene" agent skill from https://github.com/romiluz13/cc10x/tree/main/plugins/cc10x/skills/codebase-hygiene into .claude/skills/codebase-hygiene/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "codebase-hygiene", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/romiluz13/cc10x/tree/main/plugins/cc10x/skills/codebase-hygieneType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add romiluz13/cc10x --skill codebase-hygiene -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install romiluz13/cc10x codebase-hygiene --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/romiluz13/cc10x.git skills-src && mkdir -p .agents/skills && cp -r skills-src/plugins/cc10x/skills/codebase-hygiene .agents/skills/codebase-hygiene && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "codebase-hygiene" agent skill from https://github.com/romiluz13/cc10x/tree/main/plugins/cc10x/skills/codebase-hygiene into .agents/skills/codebase-hygiene/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "codebase-hygiene", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add romiluz13/cc10x --skill codebase-hygiene -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install romiluz13/cc10x codebase-hygiene --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/romiluz13/cc10x.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/plugins/cc10x/skills/codebase-hygiene .cursor/skills/codebase-hygiene && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "codebase-hygiene" agent skill from https://github.com/romiluz13/cc10x/tree/main/plugins/cc10x/skills/codebase-hygiene into .cursor/skills/codebase-hygiene/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "codebase-hygiene", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/romiluz13/cc10x.git --path plugins/cc10x/skills/codebase-hygiene--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add romiluz13/cc10x --skill codebase-hygiene -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install romiluz13/cc10x codebase-hygiene --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/romiluz13/cc10x.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/plugins/cc10x/skills/codebase-hygiene .gemini/skills/codebase-hygiene && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "codebase-hygiene" agent skill from https://github.com/romiluz13/cc10x/tree/main/plugins/cc10x/skills/codebase-hygiene into .gemini/skills/codebase-hygiene/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "codebase-hygiene", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install romiluz13/cc10x codebase-hygieneInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add romiluz13/cc10x --skill codebase-hygiene -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/romiluz13/cc10x.git skills-src && mkdir -p .github/skills && cp -r skills-src/plugins/cc10x/skills/codebase-hygiene .github/skills/codebase-hygiene && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "codebase-hygiene" agent skill from https://github.com/romiluz13/cc10x/tree/main/plugins/cc10x/skills/codebase-hygiene into .github/skills/codebase-hygiene/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "codebase-hygiene", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add romiluz13/cc10x --skill codebase-hygiene -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install romiluz13/cc10x codebase-hygiene --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/romiluz13/cc10x.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/plugins/cc10x/skills/codebase-hygiene .opencode/skills/codebase-hygiene && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "codebase-hygiene" agent skill from https://github.com/romiluz13/cc10x/tree/main/plugins/cc10x/skills/codebase-hygiene into .opencode/skills/codebase-hygiene/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "codebase-hygiene", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
codebase-hygieneTwo-mode skill: (1) find semantic duplicates — functions doing the same thing under different names, invisible to copy-paste detectors; (2) deepen shallow modules — thin wrappers and pass-through…
Codebase Hygiene is an agent skill from romiluz13/cc10x. Two-mode skill: (1) find semantic duplicates — functions doing the same thing under different names, invisible to copy-paste detectors; (2) deepen shallow modules — thin wrappers and pass-through layers that spread complexity. Advisory and read-only; changes route through BUILD with full gates.
Its SKILL.md is about 1.5k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
The repository describes itself as: The Loop Engine for Claude Code — engineer the loop, not the prompt. 1 router · 9 agents · 16 skills · 4 workflows. Fail-closed gates, test honesty, anti-anchored review. The licence is MIT.
6 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit 891acf0. It shows what the files ask for, not the result of running them.
Pre-approves these tools, so the agent can use them without asking each time:
ReadGrepGlobBashFrom allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
gitFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Codebase Hygiene loads about 1.5k tokens when it runs. Until then it costs about 78 tokens; SKILL.md has 741 words of instructions outside code blocks.
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.
The automated check noted patterns worth knowing about, such as sudo or a known installer.
allowed-tools: Read, Grep, Glob, BashAutomated 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.
The full file from romiluz13/cc10x at commit 891acf0, republished under its MIT licence (© romiluz13). 741 words, ~1,511 tokens.
.claude/skills/codebase-hygiene/SKILL.md (or your agent's skills folder).Advisory and read-heavy. Diagnoses and proposes; does not refactor. Any actual change goes through BUILD with full gates.
Semantic duplicates: functions serving the same purpose but implemented independently under different names. Copy-paste detectors catch syntactic duplicates; this finds "same intent, different implementation."
git log --oneline for hot spots and weight recently-changed code — deepening pays off in proportion to future change.name | file:line | signature.file:line evidence. Route through code-reviewer finding contract.| Zone | Why it duplicates |
|---|---|
utils/, helpers/, lib/ | Catch-all dumping grounds |
| Validation code | "Is this a valid email/id/url" rewritten per feature |
| Error formatting | Every module invents its own Error → string |
| Path manipulation | Join/normalize/relativize reimplemented |
| String formatting | Truncate, slugify, titlecase, pad re-rolled |
| Date formatting | Parse/format/diff scattered |
| API response shaping | Envelope/pagination/error-body copied per endpoint |
Never delete a duplicate until all three hold:
Existing code works; the problem is shape, not features. LLM-grown codebases accrete shallow modules — thin wrappers, pass-through layers, near-duplicate helpers. Each looks harmless; together they spread complexity across every caller.
Deep module: hides a lot of behavior behind a small interface. Shallow module: interface is almost as complex as its implementation — callers learn a thing without getting much.
For each candidate: If I deleted this module and inlined its code at every call site, where does the complexity go?
This verdict agrees with cc10x:codebase-design (canonical) and cc10x:architecture. Depth is leverage at the interface — not a lines-ratio.
| Smell | Usually |
|---|---|
Thin wrapper (doX(a){ return lib.doX(a) }) | Shallow |
| Pass-through layer (service maps 1:1 to repo) | Shallow |
| Near-duplicate helper (same intent, different name) | Shallow — consolidate first |
| Config/leverage module (small interface, branching/retry/state inside) | Deep — keep |
name | file:line | signature)Badge each candidate: Strong (unambiguous), Worth-exploring (real cost/risk), Speculative (hunch, low confidence).
For each: before/after sketch (current shallow interface vs proposed deeper one) with deletion test result. Then stop and ask which to pursue. Do not design interfaces for candidates the user hasn't chosen.
When designing the deeper interface, a port (an injected external dependency seam) needs two concrete adapters — e.g. a production transport and a test stand-in. An ordinary caller or a test exercising a public interface is NOT an adapter; the two-adapter rule is about ports, not every seam.
For a non-port seam (the common case for module deepening): the test must be able to reach the interface. If only production code crosses the seam and no test can reach it → the seam is a guess. Put the interface where a test can reach it, or don't introduce it. This aligns with cc10x:codebase-design — "one adapter means a hypothetical seam" applies to ports; internal seams need reachability, not a second adapter.
This skill ends at: chosen candidate + deeper-interface proposal + named seam. It does NOT edit code. The refactor routes through planner → BUILD workflow (builder → reviewer → verifier → doc-sync → memory). The deepening is verified: survivor interface has tests at its seam, every caller is repointed, suite + typecheck pass after merge.
Proposing is read-only; changing is gated.
© romiluz13, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in plugins/cc10x/skills/codebase-hygiene of romiluz13/cc10x.
Open the folder on GitHubat commit 891acf0
Codebase Hygiene 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.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Codebase Hygiene this skillromiluz13/cc10x | 164 | — | ~1.5k | Automated safety check: Notes | MIT | |
| Finding Duplicate Functionsobra/superpowers-lab | 429 | 2 repos | ~1.2k | Automated safety check: Pass | MIT | |
| Semantic Liststhedaviddias/Front-End-Checklist | 74k | — | ~504 | Automated safety check: Pass | MIT | |
| Duplicate JSthedaviddias/Front-End-Checklist | 74k | — | ~423 | Automated safety check: Pass | MIT | |
| Azure Functionsdavila7/claude-code-templates | 32k | 1 repos | ~344 | Automated safety check: Pass | MIT | |
| Semantic Versioningsickn33/agentic-awesome-skills | 47k | 1 repos | ~2.6k | Automated safety check: Pass | MIT |
obra/superpowers-lab
A skill your agent uses when auditing a codebase for semantic duplication - functions that do the same thing but have different names or implementations.
thedaviddias/Front-End-Checklist
A skill your agent uses when reviewing rendered HTML, interactive components, or design-system patterns related to Use semantic list elements.
thedaviddias/Front-End-Checklist
A skill your agent uses when auditing slow page loads, heavy assets, or rendering delays related to Remove duplicate JavaScript libraries.
davila7/claude-code-templates
Expert patterns for Azure Functions development including isolated worker model, Durable Functions orchestration, cold start optimization, and production patterns.
sickn33/agentic-awesome-skills
Automate versioning and changelog generation using semantic versioning principles.
sickn33/agentic-awesome-skills
Long-running, serverless Node.js HTTP functions deployed onto your Neon branch, with DATABASEURL injected automatically and compute that runs next to your data.
romiluz13/cc10x
A skill your agent uses when a BUILD phase completes, a commit is staged, or a PR is about to be created, and the diff has not yet been reflected in documentation.
romiluz13/cc10x
Answers questions about cc10x itself — what it is, how to install and configure it, how the router, workflows, memory, and hooks operate, and how to troubleshoot.
romiluz13/cc10x
THE ONLY ENTRY POINT FOR CC10X. An agent skill from romiluz13/cc10x.
romiluz13/cc10x
Canonical deep-module vocabulary (module, interface, depth, seam, adapter, leverage, locality) for designing a module's shape — a lot of behaviour behind a small interface at a clean seam, testable…
romiluz13/cc10x
A skill your agent uses when you need a one-off MCP server capability during research or debugging without permanently mounting it as a context-polluting integration.
romiluz13/cc10x
A skill your agent uses when a git merge or rebase reports conflicts and the operation is in progress.
Two-mode skill: (1) find semantic duplicates — functions doing the same thing under different names, invisible to copy-paste detectors; (2) deepen shallow modules — thin wrappers and pass-through…. Codebase Hygiene is an agent skill from romiluz13/cc10x. Two-mode skill: (1) find semantic duplicates — functions doing the same thing under different names, invisible to copy-paste detectors; (2) deepen shallow modules — thin wrappers and pass-through layers that spread complexity.
Run `npx skills add romiluz13/cc10x --skill codebase-hygiene -a claude-code`. Or copy the skill folder (plugins/cc10x/skills/codebase-hygiene in romiluz13/cc10x) into .claude/skills/codebase-hygiene in your project. Claude Code loads it when a task matches its description.
Run `npx skills add romiluz13/cc10x --skill codebase-hygiene -a codex`. Or copy the skill folder (plugins/cc10x/skills/codebase-hygiene in romiluz13/cc10x) into .agents/skills/codebase-hygiene in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add romiluz13/cc10x --skill codebase-hygiene -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/codebase-hygiene, .gemini/skills/codebase-hygiene, .github/skills/codebase-hygiene and .opencode/skills/codebase-hygiene in your project.
Going by SKILL.md and its folder, Codebase Hygiene needs the command-line tools its instructions call (git). Its frontmatter pre-approves these tools: Read, Grep, Glob, Bash.
SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found notes only (pre-approves every shell command (allowed-tools: bash)), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.
Codebase Hygiene is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.5k tokens (SKILL.md is roughly 6k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Codebase Hygiene: Finding Duplicate Functions (obra/superpowers-lab, 429 stars), Semantic Lists (thedaviddias/Front-End-Checklist, 74k stars), Duplicate JS (thedaviddias/Front-End-Checklist, 74k stars) and Azure Functions (davila7/claude-code-templates, 32k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
romiluz13 (a GitHub user) maintains it in romiluz13/cc10x, which has 164 GitHub stars. The repository holds 22 skills in this directory. The repository was last updated on September 30, 2026.
Source: romiluz13/cc10x on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.