code-quality

Validates code quality after modifications through a 7-phase workflow covering SOLID, DRY, linters, and architecture rules.

1|Updated Jul 29, 2026
One-click install
npx skills add https://github.com/fusengine/kimi-code --skill code-quality-fusengine
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: code-quality
Source: https://github.com/fusengine/kimi-code/tree/main/plugins/ai-pilot/skills/code-quality
Command: npx skills add https://github.com/fusengine/kimi-code --skill code-quality-fusengine

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires jscpd, and includes references (resource) components.

What problem does it solve? After fixing a bug or refactoring code, developers need a systematic way to confirm the change did not introduce linter errors, SOLID violations, duplicated logic, or architecture regressions. This Skill provides a canonical 7-phase validation workflow that checks code quality after modifications across multiple languages. ## Core Features & Use Cases - 7-Phase Validation Workflow: Explores architecture, researches documentation, analyzes impact via Grep usages, detects duplication with jscpd, runs linters, applies precision corrections, and re-verifies until clean. - DRY Detection with jscpd: Measures duplication against per-language thresholds (e.g., 3% for TypeScript, 10% for Java) and guides extraction of shared logic. - SOLID and Architecture Enforcement: Detects violations such as interfaces in component files, business logic in components, and files exceeding 100 LoC, with fix examples for TypeScript, Python, Go, PHP, Java, and Rust. - Use Case: After fixing TypeScript errors in an auth module, run this workflow to confirm tsc and ESLint pass, duplication dropped below threshold, and all files comply with the project's architecture rules. ## Quick Start Validate the code quality of the changes I just made in the auth module, checking linter errors, duplication, and SOLID compliance.

Frequently Asked Questions about code-quality

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I validate code quality after making changes?▼

Run the 7-phase workflow: explore the codebase architecture, research relevant documentation, analyze impact of each change via Grep usages, detect duplication with jscpd, run language-specific linters, apply corrections, then re-verify until linters, tests, and duplication are all clean.

How do I detect code duplication with jscpd?▼

Run npx jscpd ./src --threshold 5 --reporters console,json to scan for copy-pasted code across 150+ languages. Thresholds vary by language: 3% for TypeScript and Python, 5% for Go and PHP, 10% for Java and C/C++. Duplication above 10% requires mandatory refactoring.

What linter commands should I run for TypeScript and Python?▼

For TypeScript run npx eslint . --fix, npx prettier --write ., and npx tsc --noEmit. For Python run ruff check . --fix, black ., mypy ., and isort . to cover linting, formatting, and type checking.

Should I run code quality checks before or after functional verification?▼

Run functional verification first to confirm the original problem was actually solved, then run code-quality validation. Code quality checks confirm the fix is clean but do not verify the fix works.

When should a file be split for being too large?▼

Split a file when its total line count reaches 200 or more. Files under 100 lines of actual code (excluding comments and blanks) are fine, and files between 100 LoC and 200 total lines are acceptable if well-documented.

What architecture violations does this validation catch?▼

It catches interfaces defined inside component files, business logic placed in components instead of hooks, monolithic components that should be sectioned, local state used for global data instead of stores, and files exceeding size limits.