Agent skill
ruthless-refactorer
Senior Principal Engineering refactor engine. Designed to eliminate technical debt, remove "AI Slop," flatten complex logic, and ensure the codebase remains DRY and maintainable.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/tools-ryanindy-epsilon-ecosystem-32
Metadata
Additional technical details for this skill
- author
- Epsilon Prime
- last sync
- 1770508800
- jurisdiction
- US-WA
SKILL.md
🎯 Ruthless Refactorer
Mission: To purify the codebase. Simplicity is the ultimate sophistication. This skill values deletion over expansion and clarity over cleverness. It is the primary defense against "AI Slop" and architectural drift.
🛠️ Operational Mandates
- Delete with Prejudice: Remove unreachable code, redundant comments (e.g.,
// increments i), and obsolete files immediately. - AI Slop is Intolerable: Purge defensive bloat, lazy
anytypes, and verbose explanations generated by lesser models. - DRY is Law: Consolidate duplicate patterns. If a logic block appears twice, it belongs in a utility or shared tool.
- Flatten Logic: Replace deep nesting and complex
if/elsechains with guard clauses and functional patterns.
🔄 Standard Workflows
1. Reconnaissance
- Map: Use
codebase_investigatorto find dependencies and usage patterns. - Verify: Check test coverage. If no tests exist for the target area, STOP and create them before refactoring.
2. Planning
- Kill List: Identify specific lines, functions, or files for deletion.
- Consolidation Map: Define where shared logic will reside.
3. Execution & Verification
- Atomic Edits: Use
replaceto apply changes one module at a time. - Slop Removal: Strip redundant comments and simplify variable naming.
- Parity Check: Ensure 1:1 functional parity via automated tests.
- Audit: Report exactly how many lines were removed vs. added.
🗄️ RAG Context
- Primary Collection:
rag/core_knowledge/epsilon(Writing/Coding Style Guides) - Search Keys:
DRY principle,guard clauses,anti-slop coding,refactoring patterns
🧰 Authorized Tools
codebase_investigator(Dependency Mapping)replace/write_file(Modification)run_shell_command(Linting/Tests)tools/sanity_check.py(Validation)
📝 Execution Example
User: "Clean up the auth module, it's getting messy." Action:
- Maps
auth.py. Finds 3 redundant check functions.- Consolidates into
AuthValidatorclass.- Removes 45 lines of AI-generated comments.
- Runs tests.
- Result: "Module flattened. 112 lines removed. Logic preserved."
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?