/features:organize-by-featurefrom features
Restructures a codebase from technical layers into feature folders using features-cli. Runs the full workflow: map, plan, extract, document, validate. Use when asked to refactor to a feature-based architecture.
Ships in features. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Turn a codebase organized by technical layer (components/, services/, utils/) into feature folders where each feature can be read on its own.
A feature is readable on its own when someone who opens its folder can tell, without reading other features:
owner in the README frontmatter, or inherited from a parent feature),__docs__/decisions/),features commandAll skills in this set use features-cli. Run features --help to check it is installed. If it isn't, use npx features-cli@latest in place of features in every command (for example npx features-cli@latest check ./src). Only use the commands and flags listed in the CLI reference.
Copy this checklist into your reply and keep it up to date:
- [ ] 1. Prepare: clean git tree, baseline build and tests pass
- [ ] 2. Plan: feature breakdown approved by the user
- [ ] 3. For each feature: extract, document, validate, commit
- [ ] 4. Final validation and hand-over
git status is clean. If it isn't, ask the user to commit or stash their changes first. Never stash or discard them yourself.Makefile, Cargo.toml, CI workflows, CONTRIBUTING.md). Run them and note the result. This is the baseline: the refactor must not make it worse. If tests already fail, tell the user and list the failing tests before going on../src, or each package of a monorepo). It is the PATH argument of every features command below.features scan PATH --json --skip-changes into a file) to see what already exists. Regenerate it after each feature.Use the plan-feature-breakdown skill. It writes a breakdown file and asks the user to approve it. Do not move any code before the user approves the plan.
Take the features in the order of the approved plan (fewest dependencies first). For each one:
README.md (title, description, owner) and its decision records.features check and the report on the scanned folder. Fix what the report flags for this feature.refactor(checkout): move checkout code into features/checkout. One feature per commit keeps the history readable and each step easy to revert.Stop and ask the user when a file clearly belongs to several features, when a move would change behavior, or when tests fail and the cause isn't the move.
CODEOWNERS file, or the user wants one, offer to run features codeowners PATH --project-dir .. It only rewrites the section between its markers.AGENTS.md or CLAUDE.md so future agent sessions use the feature map (see the root README of features-cli, section "Give your AI coding agent a map of the codebase").TODO, and the commits made. Suggest features serve PATH to browse the result.CODEOWNERS, existing docs or git history. When unsure, ask or write a visible TODO placeholder.What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub interaction-dynamics/features --plugin features7 skills in this plugin
/create-featureCreates a new feature in a codebase organized by feature, following the features-cli conventions - checks that no existing feature already covers it, picks the folder (top-level or sub-feature), writes its README (owner, title, description) and first spec, builds the code inside the folder without reaching into other features, records decisions and validates with features check. Use when the user asks to add, build, start or scaffold a new feature, module or capability ("add a referral program", "create a feature for invoices"). Not for changes inside an existing feature./document-featureWrites or fixes the README.md of a feature folder (frontmatter with owner and other metadata, title, one-line description), its decision records in __docs__/decisions and its specs in __docs__/specs, following the features-cli format, so the feature can be understood on its own. Use when the user asks to document a feature, add an owner or a description, record a design decision (ADR, MADR), write a spec, or after moving code into a feature folder./explore-featuresGenerates the features-cli JSON report of a codebase (features, paths, owners, descriptions, specs and decision records, imports between features) into a file and reads it to understand the project before working on it. Use at the start of a task in an unfamiliar codebase, when looking for where a feature lives or who owns it, before changing a feature (to read its description, specs and decisions), or when the other feature skills need the current feature map./extract-featureMoves the code of one feature into its own feature folder (features/<name>/) in small, safe steps, with git mv, updated imports and passing tests, without changing behavior. Use when the user asks to move, extract or group the code of a feature into a folder, or as the "move" step of the organize-by-feature workflow. Works with any language./plan-feature-breakdownAnalyzes a codebase and proposes how to split it into feature folders (feature names, target paths, files to move, shared code, owners and migration order), then writes the plan to a file for the user to approve. Uses features-cli to see the features that already exist. Use before reorganizing a codebase by feature, when the user asks which features a codebase has, or how to split a folder into features. Read-only: it never moves code./validate-featuresValidates the feature folders of a codebase with features-cli (features check, features scan) and a report script that flags features without description or owner, imports between sibling features, oversized features, duplicate names and code left outside any feature. Use after moving or documenting features, before committing a feature refactor, or when the user asks whether the codebase follows the feature-based architecture guidelines.Other plugins' skills for the same job