improve-codebase-architecture

Analyze module coupling and depth to identify architecture deepening opportunities.

3|1|Updated Mar 23, 2026
One-click install
npx skills add https://github.com/malinskibeniamin/skills --skill improve-codebase-architecture-malinskibeniamin
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: improve-codebase-architecture
Source: https://github.com/malinskibeniamin/skills/tree/main/improve-codebase-architecture
Command: npx skills add https://github.com/malinskibeniamin/skills --skill improve-codebase-architecture-malinskibeniamin

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill helps identify architectural friction and opportunities to deepen modules by applying domain vocabulary and ADR guidance, enabling targeted refactors, reduced coupling, and improved testability.

Core Features & Use Cases

  • Explore codebases to locate shallow modules where the interface nearly matches the implementation.
  • Propose concrete deepening opportunities with ADR-aligned rationale and suggested seams/adapters.
  • Generate an HTML architecture report (HTML-REPORT.md) to communicate findings and recommended actions.

Quick Start

Run the Explore workflow to identify shallow modules and surface deepening opportunities with ADR-backed guidance.

Frequently Asked Questions about improve-codebase-architecture

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

FAQPage Schema
How do I find modules with high coupling that need architecture refactoring?

Architecture deepening is the process of increasing module depth to hide implementation details behind simpler interfaces. You need it when planning refactors or architecture reviews to reduce system coupling, improve testability, and align structural changes with existing ADR guidance.

How do I use ADRs and CONTEXT.md to plan a codebase refactor?

To identify deepening opportunities in a codebase, analyze module depth, coupling, and interface-to-implementation ratios. This process surfaces shallow modules and provides ADR-backed guidance on exactly where to place seams and adapters to improve maintainability.

Where should I place seams and adapters to improve codebase testability?

Place seams and adapters at shallow module boundaries where interface nearly matches implementation. Targeting these high-coupling areas with ADR-aligned rationale separates concerns, reduces dependencies, and directly improves overall system testability and maintainability.

What is architecture deepening and when do I need it for my codebase?

Architecture deepening increases module depth by hiding complex implementation details behind simpler, narrower interfaces. You need it during refactor planning or architecture reviews when high coupling and shallow modules reduce testability and maintainability across your system.

Can I generate an architecture review report for shallow modules during a refactor?

Yes, you can generate an HTML architecture report to communicate findings from shallow module analysis. This report outputs structured recommendations and ADR-backed rationale, detailing where to place seams and adapters to reduce coupling during refactoring.

What are the limitations of using module depth analysis for reducing codebase coupling?

Module depth analysis primarily targets structural coupling and shallow interfaces rather than runtime dependencies or performance bottlenecks. It should not be used as the sole method for refactoring when the core architectural friction stems from data flow or infrastructure scaling issues.