Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIDeepSeekDeepSeekMuseMuse+22 more

    Module Decomposition Planner — Split, Don't Break Callers

    1

    Generate safe, data-driven plans to split god modules and monoliths without breaking existing callers.

    $12

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned
    Module Decomposition Planner — Split, Don't Break Callers

    Module Decomposition Planner — Split, Don't Break Callers

    Example session with this skill installed

    I need to split the services/user-management module. It has become a god module. Plan a decomposition that won't break the existing API for other teams.

    • Read your context and instructions
    • Compiled the module decomposition planner

    I have analyzed the services/user-management module using git ls-files and agent-context. I have identified three distinct seams and a re-export strategy to preserve the existing API.

    Module Decomposition Plan: user-management

    ComponentFilesExportsConsumer CountSeam
    Auth Logicauth.ts, session.tslogin, verify14 modulesuser-auth
    Profile Mgmtprofile.ts, avatar.tsupdateProfile3 modulesuser-profile
    Internal Helpersutils.ts, db-map.tsNone (Internal)0 (External)user-core

    Proposed Seams

    1. user-auth: Focuses on credential validation and session handling. This is the most heavily used seam.
    2. user-profile: Handles metadata and social features. Low coupling with the rest of the system.
    3. user-core: Contains private database mapping logic that should not be exported.

    Compatibility Strategy

    To avoid breaking the 14 dependent modules, we will use a

    Re-export strategy. The original services/user-management/index.ts will remain as a barrel file, importing and re-exporting symbols from the new locations. This allows teams to migrate their imports at their own pace.

    Migration Order

    1. Safety Net: Verify existing test coverage for login and updateProfile in the current module.
    2. Extract user-profile: Move profile files to services/user-profile/. Add re-exports to the old path.
    3. Extract user-auth: Move auth files to services/user-auth/. Add re-exports to the old path.
    4. Cleanup: Refactor user-core internal utilities to remove redundant exports.

    Next steps

    • Review the user-auth seam to ensure it meets the security layering rules in docs/architecture.md.
    • Run the provided git grep commands to verify no dynamic imports are missed.
    • Approve the plan to begin manual file migration.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Monolithic modules and "god files" create technical debt that slows down every PR. Moving symbols blindly breaks imports across the entire repository. This skill provides a data-driven approach to modularization, turning architectural intuition into a verifiable execution plan.

    What it does

    • Inventory analysis catalogs every exported and internal symbol with its declaring file.
    • Consumer mapping counts how many files depend on specific exports to identify load-bearing symbols.
    • Seam identification clusters files into coherent sub-modules based on domain vocabulary and actual usage patterns.
    • Compatibility planning designs re-export strategies to ensure the split doesn't break existing callers.
    • Step-by-step sequencing generates an independently verifiable order of operations for merging changes safely.

    How it works

    1. Repository discovery identifies the stack, workspace layout, and existing architectural constraints.
    2. Surface inspection uses git and optional ai-agent-context CLI to map the module's public API and internal dependencies.
    3. Design synthesis clusters files into new seams and validates them against repository layering rules.
    4. Strategy generation produces a detailed report covering inventory, consumer counts, and a phased migration order.

    Frameworks & tools

    Works with any language via git and standard file inspection. Enhanced analysis is available if ai-agent-context is present in the environment.

    Why this beats prompting it yourself

    Standard prompts often guess at boundaries and ignore the blast radius of moving exported symbols. This skill enforces a strict analysis phase using git grep and dependency mapping, ensuring your plan is based on hard evidence rather than LLM hallucinations about code structure.

    Use cases

    • Extracting a specific subsystem, like a scheduler, from a bloated billing module.
    • Planning the migration of shared utilities into a dedicated workspace package.
    • Decomposing a god module while maintaining backwards compatibility for all current importers.
    • Validating a proposed architectural split against existing repository layering rules.

    Known limitations

    The skill performs planning only and never edits, moves, or renames files. It requires a manual design decision for final seams, as it treats grouping suggestions as hints rather than facts.

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Agents & Orchestration.

    Planning only. Does not edit code or move files. Grouping suggestions are heuristics and require human design verification. CLI fallback reduces analysis depth for transitive impacts.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Trust & safety

    Security scan

    Security scan passed 28 days ago

    Software
    ai-agent-contextNode.jsagent-contextGit

    Permissions

    Terminal / Shell
    Read Files
    Write Files
    Network Access
    Listed28 days ago

    What's inside

    Frequently Asked Questions

    The planner analyzes symbol usage via git and dependency mapping to identify 'seams' where code can be separated. It then generates a phased migration strategy, including re-export patterns, to ensure your refactor doesn't cause breaking changes for existing consumers.

    This skill is language-agnostic as it relies on git and file-system inspection. While it works out of the box for any repository, it provides enhanced architectural insights when used alongside the `ai-agent-context` CLI.

    The skill is designed for any AI agent with filesystem access and git capabilities. It functions as a specialized planning layer that provides your agent with the 'architectural eyes' needed to map complex dependencies before suggesting code changes.

    For safety, this skill focuses strictly on discovery and planning; it will not modify your source code. You receive a verifiable execution plan that you or your agent can then use to perform the actual file moves and refactors.

    You receive the modular decomposition skill logic, integration documentation, and access to all future updates. The purchase includes the specialized analysis patterns required to turn raw repository data into a structured modularization roadmap.

    New in Agents & Orchestration