Agent skill · AI & Agents

finding-duplicate-functions

Use when auditing a codebase for semantic duplication - functions that do the same thing but have different names or implementations. Especially useful for LLM-generated codebases where new functions are often created rather than reusing existing ones.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill finding-duplicate-functions --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 5 KB
Bundled scripts: none
Path: skills/analysis/finding-duplicate-functions/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Finding Duplicate-Intent Functions ## Overview LLM-generated codebases accumulate semantic duplicates: functions that serve the same purpose but were implemented independently. Classical copy-paste detectors (jscpd) find syntactic duplicates but miss "same intent, different implementation." This skill uses a two-phase approach: classical extraction followed by LLM-powered intent clustering. ## When to Use - Codebase has grown organically with multiple contributors (human or LLM) - You suspect utility functions have been reimplemented multiple times - Before major refactoring to identify consolidation opportunities - After jscpd has been run and syntactic duplicates are already handled ## Quick Reference | Phase | Tool | Model | Output | |-------|------|-------|--------| | 1. Extract | `scripts/extract-functions.sh` | - | `catalog.json` | | 2. Categorize | `scripts/categorize-prompt.md` | haiku | `categorized.json` | | 3. Split | `scripts/prepare-category-analysis.sh` | - | `categories/*.json` | | 4. Detect | `scripts/find-duplicates-prompt.md` | opus | `duplicates/*.json` | | 5. Report | `scripts/generate-report.sh` | - | `report.md` | ## Process ```dot digraph duplicate_detectio

What's inside
Steps it walks through
  1. Overview
  2. When to Use
  3. Quick Reference
  4. Process
  5. Phase 1: Extract Function Catalog
  6. Phase 2: Categorize by Domain
  7. Phase 3: Split into Categories
  8. Phase 4: Find Duplicates (Per Category)
  9. Phase 5: Generate Report
  10. Phase 6: Human Review
  11. High-Risk Duplicate Zones
  12. Common Mistakes
  13. How to use this skill
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the finding-duplicate-functions skill do?

Use when auditing a codebase for semantic duplication - functions that do the same thing but have different names or implementations. Especially useful for LLM-generated codebases where new functions are often created rather than reusing existing ones.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill finding-duplicate-functions --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going