discipline-refactor

Reorganize any repository by discipline/domain with module-based structure. Code in src/<pkg>/modules/, documents in <folder>/modules/. Orchestrates Explore, Plan, and general-purpose subagents. Works standalone.

5 stars

Best use case

discipline-refactor is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Reorganize any repository by discipline/domain with module-based structure. Code in src/<pkg>/modules/, documents in <folder>/modules/. Orchestrates Explore, Plan, and general-purpose subagents. Works standalone.

Teams using discipline-refactor should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/discipline-refactor/SKILL.md --create-dirs "https://raw.githubusercontent.com/vamseeachanta/workspace-hub/main/.agents/skills/_internal/meta/discipline-refactor/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/discipline-refactor/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How discipline-refactor Compares

Feature / Agentdiscipline-refactorStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Reorganize any repository by discipline/domain with module-based structure. Code in src/<pkg>/modules/, documents in <folder>/modules/. Orchestrates Explore, Plan, and general-purpose subagents. Works standalone.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# Discipline Refactor

## Sub-Skills

- [Core Principles](core-principles/SKILL.md)
- [Target Repository Structure](target-repository-structure/SKILL.md)
- [Orchestration Architecture](orchestration-architecture/SKILL.md)
- [Phase 1: Analysis](phase-1-analysis/SKILL.md)
- [Phase 2: Planning](phase-2-planning/SKILL.md)
- [Phase 3: Execution](phase-3-execution/SKILL.md)
- [Phase 4: Validation](phase-4-validation/SKILL.md)
- [Standard Folders → Module Structure (+1)](standard-folders-module-structure/SKILL.md)
- [How to Identify Disciplines](how-to-identify-disciplines/SKILL.md)
- [Python Package (+1)](python-package/SKILL.md)
- [Rollback](rollback/SKILL.md)
- [Verification Checklist](verification-checklist/SKILL.md)

Related Skills

module-based-refactor

5
from vamseeachanta/workspace-hub

Reorganize a repository from flat structure to a module-based 5-layer architecture (src/tests/specs/docs/examples) while preserving git history. Use when restructuring a codebase into modules, migrating import paths, cleaning up hidden folders, consolidating duplicate directories, removing root-level artifacts, or archiving completed plan files. Capabilities: parallel agent spawn strategy, hidden-folder consolidation patterns, benchmark fixture separation, 4-phase atomic commit workflow.

discipline-refactor-verification-checklist

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Verification Checklist.

discipline-refactor-target-repository-structure

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Target Repository Structure.

discipline-refactor-standard-folders-module-structure

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Standard Folders → Module Structure (+1).

discipline-refactor-rollback

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Rollback.

discipline-refactor-phase-4-validation

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Phase 4: Validation.

discipline-refactor-phase-3-execution

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Phase 3: Execution.

discipline-refactor-phase-2-planning

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Phase 2: Planning.

discipline-refactor-phase-1-analysis

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Phase 1: Analysis.

discipline-refactor-orchestration-architecture

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Orchestration Architecture.

discipline-refactor-how-to-identify-disciplines

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: How to Identify Disciplines.

discipline-refactor-core-principles

5
from vamseeachanta/workspace-hub

Sub-skill of discipline-refactor: Core Principles.