MO

modular-large-file-refactor

Splits oversized files into manageable modules while maintaining existing functionality.

Install

mkdir -p .claude/skills/modular-large-file-refactor && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/10237" && unzip -o skill.zip -d .claude/skills/modular-large-file-refactor && rm skill.zip

Installs to .claude/skills/modular-large-file-refactor

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

Refactor oversized source files into smaller, coherent modules while reducing complexity and preserving behavior. Use when Claude needs to split a large component, hook, service, command handler, or Rust module; untangle mixed responsibilities; extract helpers or submodules; or reorganize code into a clearer modular design without changing the public contract.
362 chars✓ has a “when” triggerlonger than Claude Code's old 250-char listing cap (fine on current versions)
Advanced

Key capabilities

  • →Split large files
  • →Extract modules
  • →Reduce complexity
  • →Preserve behavior

How it works

Identifies responsibilities and extracts logic into focused modules while maintaining public APIs.

Inputs & outputs

You give it
Large source file
You get back
Smaller, coherent modules

When to use modular-large-file-refactor

  • →Refactor a 1000-line file
  • →Extract helpers into new modules
  • →Improve modularity of services

About modular-large-file-refactor

Analyzes large files to identify distinct responsibilities. Guides the extraction of logic into focused modules, improving readability and maintainability without breaking public APIs.

Refactor oversized source files into smaller, coherent modules while reducing complexity and preserving behavior. Use when Claude needs to split a large component, hook, service, command handler, or Rust module; untangle mixed responsibilities; extract helpers or submodules; or reorganize code into

When not to use it

  • →Splitting for line count only

Prerequisites

scripts/find_large_files.sh

Limitations

  • →Do not create utility dumping grounds

How it compares

Optimizes for cognitive load and ownership boundaries rather than arbitrary line counts.

Compared to similar skills

modular-large-file-refactor side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
modular-large-file-refactor (this skill)07moReviewAdvanced
software-architecture33310moNo flagsIntermediate
oracle176moReviewIntermediate
clojure-write166moNo flagsIntermediate

Try saying

Example prompts that trigger this skill in your AI assistant.

Search skills

Search the agent skills registry