refactoring-expert

Refactors code using Martin Fowler's catalog and functional programming practices.

Updated Jan 21, 2026
One-click install
npx skills add https://github.com/HsnSaboor/open-engineer --skill refactoring-expert-hsnsaboor
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: refactoring-expert
Source: https://github.com/HsnSaboor/open-engineer/tree/main/src/skills/bundled/samhvw8-refactoring-expert
Command: npx skills add https://github.com/HsnSaboor/open-engineer --skill refactoring-expert-hsnsaboor

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill addresses the challenge of maintaining high code quality, reducing technical debt, and modernizing legacy systems through systematic and safe refactoring practices.

Core Features & Use Cases

  • Systematic Refactoring: Applies Martin Fowler's catalog and functional programming patterns for incremental code improvement.
  • Debt Reduction: Identifies and eliminates code smells, complexity, and duplication.
  • Quality Enforcement: Ensures behavior preservation through robust testing and automated tooling.
  • Use Case: Refactor a complex, hard-to-maintain legacy module into a more modular, SOLID-compliant, and testable structure using characterization tests and incremental transformations.

Quick Start

Use the refactoring-expert skill to refactor the 'user-authentication' module to improve its SOLID compliance.

Frequently Asked Questions about refactoring-expert

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

FAQPage Schema
How do I refactor legacy code to reduce technical debt without changing behavior?

Refactoring legacy code safely requires establishing safety nets via characterization tests to lock down current behavior, then applying incremental transformations from Martin Fowler's catalog to systematically reduce technical debt and complexity.

What is the best way to detect and eliminate code smells in a complex module?

Detecting code smells involves identifying symptoms of poor design like duplication and complexity, which you eliminate by applying functional programming patterns and SOLID principles through systematic, incremental refactoring transformations.

How do I improve SOLID compliance in a hard-to-maintain codebase?

Improving SOLID compliance involves systematically refactoring the codebase by applying Martin Fowler's catalog transformations to restructure dependencies, reduce coupling, and enforce single responsibility through incremental, test-validated updates.

Do I need automated tooling and characterization tests to modernize legacy systems?

Characterization tests and automated tooling are required for legacy modernization to validate behavior preservation, establish safety nets, and verify that incremental refactoring transformations maintain functional integrity.

When should I apply functional programming best practices during a code refactoring?

Functional programming best practices should be applied during refactoring when reducing code complexity, eliminating duplication, and addressing code smells to achieve a more modular, SOLID-compliant, and testable structure.