Guidelines
akash-network/node
Behavioral guidelines to reduce common LLM coding mistakes. An agent skill from akash-network/node.
Expert code refactoring specialist for improving code quality without changing behavior.
$ npx skills add curiositech/some_claude_skills --skill refactoring-surgeon -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install curiositech/some_claude_skills refactoring-surgeon --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/curiositech/some_claude_skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/refactoring-surgeon .claude/skills/refactoring-surgeon && 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 "refactoring-surgeon" agent skill from https://github.com/curiositech/some_claude_skills/tree/main/.claude/skills/refactoring-surgeon into .claude/skills/refactoring-surgeon/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-surgeon", 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/curiositech/some_claude_skills/tree/main/.claude/skills/refactoring-surgeonType 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 curiositech/some_claude_skills --skill refactoring-surgeon -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install curiositech/some_claude_skills refactoring-surgeon --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/curiositech/some_claude_skills.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.claude/skills/refactoring-surgeon .agents/skills/refactoring-surgeon && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "refactoring-surgeon" agent skill from https://github.com/curiositech/some_claude_skills/tree/main/.claude/skills/refactoring-surgeon into .agents/skills/refactoring-surgeon/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-surgeon", 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 curiositech/some_claude_skills --skill refactoring-surgeon -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install curiositech/some_claude_skills refactoring-surgeon --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/curiositech/some_claude_skills.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.claude/skills/refactoring-surgeon .cursor/skills/refactoring-surgeon && 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 "refactoring-surgeon" agent skill from https://github.com/curiositech/some_claude_skills/tree/main/.claude/skills/refactoring-surgeon into .cursor/skills/refactoring-surgeon/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-surgeon", 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/curiositech/some_claude_skills.git --path .claude/skills/refactoring-surgeon--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 curiositech/some_claude_skills --skill refactoring-surgeon -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install curiositech/some_claude_skills refactoring-surgeon --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/curiositech/some_claude_skills.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.claude/skills/refactoring-surgeon .gemini/skills/refactoring-surgeon && 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 "refactoring-surgeon" agent skill from https://github.com/curiositech/some_claude_skills/tree/main/.claude/skills/refactoring-surgeon into .gemini/skills/refactoring-surgeon/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-surgeon", 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 curiositech/some_claude_skills refactoring-surgeonInstalls 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 curiositech/some_claude_skills --skill refactoring-surgeon -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/curiositech/some_claude_skills.git skills-src && mkdir -p .github/skills && cp -r skills-src/.claude/skills/refactoring-surgeon .github/skills/refactoring-surgeon && 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 "refactoring-surgeon" agent skill from https://github.com/curiositech/some_claude_skills/tree/main/.claude/skills/refactoring-surgeon into .github/skills/refactoring-surgeon/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-surgeon", 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 curiositech/some_claude_skills --skill refactoring-surgeon -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install curiositech/some_claude_skills refactoring-surgeon --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/curiositech/some_claude_skills.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.claude/skills/refactoring-surgeon .opencode/skills/refactoring-surgeon && 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 "refactoring-surgeon" agent skill from https://github.com/curiositech/some_claude_skills/tree/main/.claude/skills/refactoring-surgeon into .opencode/skills/refactoring-surgeon/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-surgeon", 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.
refactoring-surgeonExpert code refactoring specialist for improving code quality without changing behavior.
Refactoring Surgeon is an agent skill from curiositech/some_claude_skills. Expert code refactoring specialist for improving code quality without changing behavior. Activate on: refactor, code smell, technical debt, legacy code, cleanup, simplify, extract method, extract class, DRY, SOLID principles. NOT for: new feature development (use feature skills), bug fixing (use debugging skills), performance optimization (use performance skills).
Its SKILL.md is about 1.6k tokens, which your agent loads only when the skill is triggered. The skill folder holds 10 other files, including scripts and reference files (for example `.claude-plugin/plugin.json`, `CHANGELOG.md` and `references/extract-method.ts`).
It sits in Development, covering Refactoring. The repository describes itself as: Claude skills that make my life easier. The licence is MIT.
10 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit 6713fc7. 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:
ReadWriteEditBash(npm test:*npm run lint:*git:*)From allowed-tools in the SKILL.md frontmatter.
Ships 1 file in scripts/ (TypeScript and Shell), which the agent can run.
From the folder's file list and the shell code blocks in SKILL.md.
Links to these hosts (documentation or services it may open):
refactoring.gururefactoring.comoreilly.comFrom 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.
Refactoring Surgeon loads about 1.6k tokens when it runs, and up to ~10k if it reads all its reference files. Until then it costs about 97 tokens; SKILL.md has 495 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 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); the scripts in this folder are not scanned.
The full file from curiositech/some_claude_skills at commit 6713fc7, republished under its MIT licence (© curiositech). 495 words, ~1,605 tokens.
.claude/skills/refactoring-surgeon/SKILL.md (or your agent's skills folder). This skill also uses 7 other files; get the full folder from GitHub.Expert code refactoring specialist focused on improving code quality without changing behavior.
| Category | Techniques |
|---|---|
| Extraction | Extract Method, Extract Class, Extract Interface |
| Movement | Move Method, Move Field, Inline Method |
| Simplification | Replace Conditional with Polymorphism, Decompose Conditional |
| Organization | Introduce Parameter Object, Replace Magic Numbers |
| Legacy Migration | Strangler Fig, Branch by Abstraction, Parallel Change |
┌─────────────────────┐ ┌─────────────────────┐ ┌─────────────────────┐
│ Long Method │ │ Large Class │ │ Long Parameter │
│ > 20 lines? │ │ > 200 lines? │ │ List │
│ → Extract Method │ │ → Extract Class │ │ → Parameter Object │
└─────────────────────┘ └─────────────────────┘ └─────────────────────┘┌─────────────────────┐ ┌─────────────────────┐ ┌─────────────────────┐
│ Switch Statements │ │ Refused Bequest │ │ Parallel │
│ Type-checking? │ │ Unused inheritance?│ │ Hierarchies │
│ → Polymorphism │ │ → Delegation │ │ → Move Method │
└─────────────────────┘ └─────────────────────┘ └─────────────────────┘┌─────────────────────┐ ┌─────────────────────┐
│ Divergent Change │ │ Shotgun Surgery │
│ One class, many │ │ One change, many │
│ reasons to change? │ │ classes affected? │
│ → Extract Class │ │ → Move/Inline │
└─────────────────────┘ └─────────────────────┘Complete refactoring examples in ./references/:
| File | Pattern | Use Case |
|---|---|---|
extract-method.ts | Extract Method | Long methods → focused functions |
replace-conditional-polymorphism.ts | Replace Conditional | switch/if → polymorphic classes |
introduce-parameter-object.ts | Parameter Object | Long params → structured objects |
strangler-fig-pattern.ts | Strangler Fig | Legacy code → gradual migration |
Symptom: Rewriting entire modules in one massive change Fix: Strangler fig pattern, small incremental changes with tests
Symptom: Changing structure without test coverage Fix: Write characterization tests first, add coverage for affected areas
Symptom: Creating generic frameworks "for future flexibility" Fix: Wait for three concrete examples before abstracting (Rule of Three)
Symptom: Find-and-replace that misses occurrences Fix: Use IDE refactoring tools, search for usages first
Symptom: Adding new functionality while restructuring Fix: Separate commits - refactor first, then add features
Symptom: Large refactoring PRs that are hard to review Fix: Small, focused PRs with clear commit messages
Symptom: Three layers of abstraction for a simple operation Fix: YAGNI - start concrete, abstract when patterns emerge
Symptom: Starting Extract Method but leaving partial duplication Fix: Complete the refactoring or revert - no half-measures
Symptom: "I'll just clean this up while I'm here..." Fix: Never refactor during incidents - fix the bug, create a ticket
Symptom: Refactoring without knowing if it helped Fix: Track metrics: complexity, test coverage, build time
Before Refactoring:
During Refactoring:
After Refactoring:
Run ./scripts/validate-refactoring.sh to check:
© curiositech, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 7 other files (scripts, references) in .claude/skills/refactoring-surgeon of curiositech/some_claude_skills.
Open the folder on GitHubat commit 6713fc7
Refactoring Surgeon 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 |
|---|---|---|---|---|---|---|
| Refactoring Surgeon this skillcuriositech/some_claude_skills | 243 | — | ~1.6k | Automated safety check: Pass | MIT | |
| Guidelinesakash-network/node | 1.1k | 20 repos | ~577 | Automated safety check: Pass | MIT | |
| Component Refactoringlangflow-ai/langflow | 155k | — | ~3.5k | Automated safety check: Pass | MIT | |
| Migrate Core Code to Submodulestinyhumansai/openhuman | 42k | — | ~2.6k | Automated safety check: Pass | GPL-3.0 | |
| ast-grep Structural Searchcode-yeongyu/oh-my-openagent | 70k | — | ~3.3k | Automated safety check: Pass | MIT | |
| Systematic Code Refactoringluongnv89/claude-howto | 42k | — | ~3k | Automated safety check: Pass | MIT |
akash-network/node
Behavioral guidelines to reduce common LLM coding mistakes. An agent skill from akash-network/node.
langflow-ai/langflow
Refactor high-complexity React components in Langflow frontend.
tinyhumansai/openhuman
Plans and carries out moving non-host-specific code and its tests from the OpenHuman core into vendored tiny submodule libraries, then releases the submodule and re-pins the host.
code-yeongyu/oh-my-openagent
Searches and rewrites code by syntax-tree shape across 25 languages with ast-grep, for codemods, structural queries and YAML lint rules, using a Python wrapper script.
luongnv89/claude-howto
Guides refactoring in phases based on Martin Fowler's method: research, test coverage check, planning and small tested steps, with your approval at each phase.
skills-directory/skill-codex
A skill your agent uses when the user asks to run Codex CLI (codex exec, codex resume) or references OpenAI Codex for code analysis, refactoring, or automated editing
curiositech/some_claude_skills
Detect crisis signals in user content using NLP, mental health sentiment analysis, and safe intervention protocols.
curiositech/some_claude_skills
End-to-end form handling with react-hook-form, Zod schemas, validation patterns, error messaging, field arrays, and multi-step wizards.
curiositech/some_claude_skills
Build production CI/CD pipelines with GitHub Actions. An agent skill from curiositech/some_claude_skills.
curiositech/some_claude_skills
Expert in background job processing with Bull/BullMQ (Redis), Celery, and cloud queues.
curiositech/some_claude_skills
Strategic analyst that maps competitive landscapes, identifies white space opportunities, and provides positioning recommendations.
curiositech/some_claude_skills
Build production computer vision pipelines for object detection, tracking, and video analysis.
Categories
Expert code refactoring specialist for improving code quality without changing behavior. Refactoring Surgeon is an agent skill from curiositech/some_claude_skills. Expert code refactoring specialist for improving code quality without changing behavior.
Refactoring Surgeon fits situations like: tasks that involve Refactoring.
Run `npx skills add curiositech/some_claude_skills --skill refactoring-surgeon -a claude-code`. Or copy the skill folder (.claude/skills/refactoring-surgeon in curiositech/some_claude_skills) into .claude/skills/refactoring-surgeon in your project. Claude Code loads it when a task matches its description.
Run `npx skills add curiositech/some_claude_skills --skill refactoring-surgeon -a codex`. Or copy the skill folder (.claude/skills/refactoring-surgeon in curiositech/some_claude_skills) into .agents/skills/refactoring-surgeon 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 curiositech/some_claude_skills --skill refactoring-surgeon -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/refactoring-surgeon, .gemini/skills/refactoring-surgeon, .github/skills/refactoring-surgeon and .opencode/skills/refactoring-surgeon in your project.
Going by SKILL.md and its folder, Refactoring Surgeon needs TypeScript and a shell for the scripts in its folder. Our summary lists: Node.js; A Bash shell. Its frontmatter pre-approves these tools: Read, Write, Edit, Bash(npm test:*,npm run lint:*,git:*).
SKILL.md names 3 domains. As links in the text: refactoring.guru, refactoring.com and oreilly.com. This is read from the text; nothing was executed.
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. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.
Refactoring Surgeon 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.6k tokens (SKILL.md is roughly 6.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 8.3k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Refactoring Surgeon: Guidelines (akash-network/node, 1.1k stars), Component Refactoring (langflow-ai/langflow, 155k stars), Migrate Core Code to Submodules (tinyhumansai/openhuman, 42k stars) and ast-grep Structural Search (code-yeongyu/oh-my-openagent, 70k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
curiositech (a GitHub organization) maintains it in curiositech/some_claude_skills, which has 243 GitHub stars. The repository holds 95 skills in this directory. The repository was last updated on September 6, 2026.
Source: curiositech/some_claude_skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.