
Agent Md Refactor
Restructures bloated agent instruction files into a minimal root plus categorized, linked documents.
- skills.sh installs
- 4.3K
- GitHub stars
- 2.7K
- last updated
- Aug 21, 2026
What it does
- Runs a five-phase process: find contradictions, extract essentials, group the rest, create the file hierarchy, and flag redundant instructions
- Includes root and linked-file templates, plus a before-and-after example of a bloated CLAUDE.md split into progressive disclosure
- Enforces a root file under 50 lines and a 3 to 8 file limit for topic groups, with each linked file self-contained
- Designed for projects whose AGENTS.md or CLAUDE.md has grown long and needs its instructions reorganized
Install
$ npx -y skills add softaworks/agent-toolkit --skill agent-md-refactor -yInstalls into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.
Files
Agent MD Refactor
Refactor bloated agent instruction files (AGENTS.md, CLAUDE.md, COPILOT.md, etc.) to follow progressive disclosure principles - keeping essentials at root and organizing the rest into linked, categorized files.
Triggers
Use this skill when:
- "refactor my AGENTS.md" / "refactor my CLAUDE.md"
- "split my agent instructions"
- "organize my CLAUDE.md file"
- "my AGENTS.md is too long"
- "progressive disclosure for my instructions"
- "clean up my agent config"
Quick Reference
| Phase | Action | Output |
|---|---|---|
| 1. Analyze | Find contradictions | List of conflicts to resolve |
| 2. Extract | Identify essentials | Core instructions for root file |
| 3. Categorize | Group remaining instructions | Logical categories |
| 4. Structure | Create file hierarchy | Root + linked files |
| 5. Prune | Flag for deletion | Redundant/vague instructions |
Process
Phase 1: Find Contradictions
Identify any instructions that conflict with each other.
Details
- Repository
- github.com/softaworks/agent-toolkit
- Categories
- Memory & Context, Agent Workflow & Planning
More from softaworks/agent-toolkit
All 40- Crafting Effective Readmes4.3K
- Session Handoff4.3K
- React Dev4.2K
- Commit Work4.2K
- Marp Slide4.2K
- React Useeffect4.2K
- Professional Communication4.1K
- Codex4.1K
- Command Creator4.1K
- Dependency Updater4.1K
- Meme Factory4.1K
- Reducing Entropy4.1K
- Ship Learn Next4K
- Gemini4K
- Openapi To Typescript4K
- Feedback Mastery4K
- Difficult Workplace Conversations4K
- Daily Meeting Update4K
- Game Changing Features4K
- Plugin Forge4K
- Naming Analyzer4K
- Lesson Learned3K
- Gepetto1.6K
- Requirements Clarity1K
Similar to Agent Md Refactor
More Memory & Context
agents-mdgetsentry/skills7.8K installsConcise AGENTS.md and CLAUDE.md setup that inspects the repo and keeps agent instructions reference-backed.
claude-md-progressive-disclosurerdaymade/claude-code-skills1K installsRestructure a CLAUDE.md or AGENTS.md with progressive disclosure, moving low-frequency detail while preserving all information.
initmcollina/skills1.5K installsGuided creation and pruning of AGENTS.md files, keeping only non-discoverable repository rules and gotchas.
claude-md-improveranthropics/claude-plugins-official15K installsAudit and improve CLAUDE.md files by scoring them against quality criteria, then propose targeted updates after approval.
agents-md-generatormadteacher/mad-agents-skills390 installsGenerates and repairs minimal AGENTS.md files for repository roots and confirmed nested modules via progressive disclosure.
improve-claude-mdhumanlayer/skills2.8K installsA structured guide for improving CLAUDE.md files with conditional <important if> blocks that keep agent instructions relevant.