Code Simplification

Makes working code easier to read and change without altering what it does, and proves the behaviour stayed the same. Use when someone says "simplify this", "clean up this function", "this file is a mess", "reduce the complexity", "refactor for readability", "tidy my diff before the PR", or when a linter reports high cyclomatic complexity or deep nesting. Covers pinning current behaviour with characterization tests, measuring complexity, choosing a named refactoring, applying it in small verified steps, and reporting suspected bugs found on the way instead of fixing them silently.

213 stars 34 forksSoftware Development

Install

skills CLI (Claude Code, Cursor, Codex and more)
npx skills add TerminalSkills/skills --skill code-simplification
Manual install
git clone --depth 1 https://github.com/TerminalSkills/skills.git /tmp/skills
mkdir -p ~/.claude/skills
cp -r /tmp/skills/skills/code-simplification ~/.claude/skills/code-simplification

Personal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.

From the SKILL.md

# Code Simplification

## Overview

Simplifying means rewriting how code is expressed while every caller, test and user sees the same results: the same return values and types, the same errors, the same side effects in the same order. The work is a loop: pin down what the code does today, find what makes it hard to follow, apply one named refactoring, re-check, repeat.

"Simpler" means a reader has less to keep in their head: fewer branches per function, shallower nesting, fewer parameters, no names that only pass a value along, no code that never runs. Line count is not the measure. The deliverable is a set of small changes plus a report with numbers before and after and a list of everything that looked like a bug and was deliberately left as it was.

## Instructions

### 1. Settle the scope and the safety net

Look these up in the repository first (package scripts, Makefile, `pyproject.toml`, CI workflow, `CLAUDE.md` or `AGENTS.md`):

- the test, type-check and lint commands, and the lint configuration already in force
- every caller of the code in question (language server references or a text search), and whether the name is part of a public surface: `exports` in `package.json`, `__all__`, an HTTP route, a CLI flag
- the files in the current diff, when the request is "tidy what I just wrote"

Ask the user only what the repository cannot answer:
Read the full skill on GitHub

Details

Skill name
code-simplification
Path
skills/code-simplification/SKILL.md
License
Apache-2.0
Repo updated
8 November 2026

FAQ

What does the Code Simplification skill do?

Makes working code easier to read and change without altering what it does, and proves the behaviour stayed the same. Use when someone says "simplify this", "clean up this function", "this file is a mess", "reduce the complexity", "refactor for readability", "tidy my diff before the PR", or when a linter reports high cyclomatic complexity or deep nesting. Covers pinning current behaviour with characterization tests, measuring complexity, choosing a named refactoring, applying it in small verified steps, and reporting suspected bugs found on the way instead of fixing them silently.

How do I install the Code Simplification skill?

skills CLI (Claude Code, Cursor, Codex and more): npx skills add TerminalSkills/skills --skill code-simplification. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.

Is Code Simplification popular?

It lives in TerminalSkills/skills, which has 213 GitHub stars and 34 forks.

Related skills

3dsmax Rendering

213

TerminalSkills/skills

Scripts and configures production rendering in Autodesk 3ds Max with the V-Ray and Corona renderers: output size and files, render elements, denoising, light mix, batch and command-line rendering, and network rendering. Use when a user asks to set up a production render, render several cameras in one batch, render from the command line or on a render farm, add render passes for compositing, or cut render time for archviz and product shots.

Other34

3dsmax Scripting

213

TerminalSkills/skills

Covers scripting Autodesk 3ds Max, the 3D modeling and rendering application, with MAXScript and Python (pymxs): scene manipulation, object creation, material assignment, camera and light setup, batch operations, and file I/O. Use when tasks involve automating repetitive 3ds Max workflows, batch processing scenes, running scripts headless with 3dsmaxbatch, creating custom tools, or scripting scene setup for archviz, product visualization, or VFX.

Productivity & Notes34

3proxy

213

TerminalSkills/skills

3proxy is a small open-source proxy server that runs HTTP/HTTPS, SOCKS4/5, SNI and TCP/UDP port-mapping proxies from one config file. Use when a user asks to set up an HTTP or SOCKS5 proxy, add proxy users and passwords, write 3proxy access rules, chain or rotate upstream (parent) proxies, limit bandwidth, connections or monthly traffic per user, run 3proxy in Docker, or fix a 3proxy.cfg that will not start.

DevOps & Cloud34

Codegraph

213

TerminalSkills/skills

CodeGraph indexes a source tree into a local SQLite knowledge graph of symbols, calls and imports, and serves it to coding agents over MCP and a CLI. Use it when an agent burns tool calls on grep and file reads to understand a codebase, or when you need callers, callees, blast radius or affected tests for a symbol. Covers install, `codegraph init`, query/explore/impact/affected commands, MCP registration, exclusions and troubleshooting. Triggers: "index my repo for the agent", "who calls this function", "what breaks if I change this", "codegraph".

Software Development34

Code Server

213

TerminalSkills/skills

code-server runs VS Code on a remote machine and serves it to any web browser, so you can code from a laptop, tablet or thin client while the files, terminal and compute stay on a server. Use this skill to install code-server from a release archive or package, configure ~/.config/code-server/config.yaml with password auth, keep it on localhost behind an SSH tunnel or a TLS reverse proxy, install extensions from Open VSX and run it as a service. Trigger phrases: "VS Code in the browser", "remote dev server", "install code-server", "code from my iPad".

Software Development34

Coderabbit

213

TerminalSkills/skills

CodeRabbit reviews pull requests with AI on GitHub, GitLab, Azure DevOps and Bitbucket, and reviews local changes from a CLI before they are pushed. Use when a user asks to set up automated PR reviews, write or validate a .coderabbit.yaml, add path-specific review instructions, control a review with @coderabbitai commands, or run coderabbit review from the terminal or a coding agent.

Software Development34

Browse the most popular Claude skills, all software development skills, or write your own with the skills generator.