code-refinement
Automatically reviews staged code to ensure adherence to clean code principles and linting standards.
Install
mkdir -p .claude/skills/code-refinement && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/13060" && unzip -o skill.zip -d .claude/skills/code-refinement && rm skill.zipInstalls to .claude/skills/code-refinement
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Review staged files for code quality (KISS, DRY, YAGNI, Clean Code) and fix linting issues.Key capabilities
- →Review staged files for code quality.
- →Fix linting issues.
- →Check for opportunities to use established framework utilities.
- →Verify project's UI framework components are used.
- →Run the project's linting command.
- →Review tests and code coverage.
How it works
The skill reviews staged files against quality principles, checks for framework utility usage, runs linters, and assesses test coverage to ensure high-quality code.
Inputs & outputs
When to use code-refinement
- →Check code before committing
- →Refactor redundant functions
- →Fix linting errors
About this skill
Code Refinement
Review the staged files to ensure the changes adhere to the KISS, DRY, and YAGNI principles. Confirm that Clean Code standards are met (including clear, consistent naming and comments where needed).
Check for opportunities to use established framework utilities, composables, or library functions instead of hand-rolled logic. If the staged code reimplements behavior that the project's framework or core libraries already provide, flag it and suggest the existing alternative.
Verify that the project's UI framework components and utility classes are used where appropriate instead of custom CSS or HTML elements. Flag any custom styling that duplicates what the framework already provides.
Run the project's linting command and fix all reported errors and warnings. Discover the command from package scripts, a Makefile, CI config, or pre-commit config; if the project has no linter, note that and move on. Avoid using lint-suppression comments (e.g., eslint-disable, noqa, @ts-ignore) to make the lint pass unless absolutely necessary, and only with a clear justification in the code.
Review tests and code coverage: check whether existing tests adequately cover the new or modified code, add tests for any gaps you find, and update any existing tests that must change to handle the new behavior correctly. When finished, ensure everything is ready for a high-quality code review.
When not to use it
- →When lint-suppression comments are used without clear justification.
- →When the project has no linter and no code quality review is needed.
- →When custom styling duplicates framework provisions.
Limitations
- →It avoids using lint-suppression comments unless absolutely necessary.
- →It flags custom styling that duplicates framework provisions.
- →It notes if the project has no linter and moves on.
How it compares
This skill provides a structured and automated approach to code refinement, including linting, adherence to quality principles, and test coverage checks, ensuring a higher quality code review than manual inspection.
Compared to similar skills
code-refinement side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| code-refinement (this skill) | 0 | 5mo | No flags | Intermediate |
| qlty-check | 5 | 7mo | Review | Beginner |
| solid | 5 | 6mo | No flags | Advanced |
| code-refactor | 3 | 7mo | Review | Intermediate |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
qlty-check
parcadei
Code quality checks, formatting, and metrics via qlty CLI
solid
ramziddin
Use this skill when writing code, implementing features, refactoring, planning architecture, designing systems, reviewing code, or debugging. This skill transforms junior-level code into senior-engineer quality software through SOLID principles, TDD, clean code practices, and professional software design.
code-refactor
luongnv89
Systematic code refactoring based on Martin Fowler's methodology. Use when users ask to refactor code, improve code structure, reduce technical debt, clean up legacy code, eliminate code smells, or improve code maintainability. This skill guides through a phased approach with research, planning, and safe incremental implementation.
improvement
tddworks
Guide for making improvements to existing ClaudeBar functionality using TDD. Use this skill when: (1) Enhancing existing features (not adding new ones) (2) Improving UX, performance, or code quality (3) User asks "improve X", "make Y better", or "enhance Z" (4) Small enhancements that don't require full architecture design For NEW features, use implement-feature skill instead.
tdd-workflows-tdd-refactor
sickn33
Use when working with tdd workflows tdd refactor
moai-workflow-ddd
modu-ai
Domain-Driven Development workflow specialist using ANALYZE-PRESERVE-IMPROVE cycle for behavior-preserving code transformation