AgentSkillsCN

feature-plan

从待办事项清单中启动功能实施,采用自适应智能体调度机制。当用户希望开始处理待办事项、启动实施工作,或明确提及某项特定功能 ID 以开展实施时,可使用此技能。

SKILL.md
--- frontmatter
name: feature-plan
description: Start implementing a feature from the backlog with adaptive agent dispatch. Use when user wants to begin work on a backlog item, start implementation, or mentions a specific feature ID to work on.
user-invocable: true

Implement Feature Command

You are executing the IMPLEMENT FEATURE workflow - a comprehensive feature kickoff process that ensures proper planning before any implementation begins.

First Step (Do This Now)

Read the file at path: docs/features/DASHBOARD.md

This file contains the backlog. If it doesn't exist, check if docs/features/ directory exists - if not, the project hasn't been set up for feature tracking yet.

Note: To start a feature, create docs/features/[id]/plan.md. The PostToolUse hook automatically updates DASHBOARD.md - do NOT edit DASHBOARD.md directly.

Contents


Feature Target

$ARGUMENTS

If no specific feature ID was provided above, you will help the user select from the backlog.


File Organization

Features are stored in directories with status determined by file presence:

code
docs/features/
├── DASHBOARD.md              # Auto-generated, read-only for Claude
├── my-feature/
│   ├── idea.md               # Problem statement + metadata (backlog)
│   ├── plan.md               # Implementation plan (in-progress)
│   └── shipped.md            # Completion notes (completed)
└── another-feature/
    └── idea.md

Status Detection by File Presence

Files PresentStatus
idea.md onlybacklog
idea.md + plan.mdin-progress
idea.md + plan.md + shipped.mdcompleted

Key Principles:

  • /feature-capture creates idea.md only (backlog status)
  • /feature-plan adds plan.md (changes to in-progress)
  • /feature-ship adds shipped.md (changes to completed)
  • DASHBOARD.md is auto-regenerated by hooks - never edit directly

Workflow Overview

This command orchestrates a 6-phase workflow:

PhaseNamePurpose
1Feature SelectionChoose from backlog or validate provided ID
2Requirements AnalysisDeep dive with project-manager agent
3System DesignArchitecture planning (adaptive based on feature type)
4Implementation PlanCreate detailed plan document
5Write plan.mdWrite plan.md to transition to in-progress
6Kickoff SummaryCreate todos and provide clear next steps

Phase Details

Phase 1: Feature Selection

See: selection.md

  • Read DASHBOARD.md and find/select feature from Backlog section
  • Read the feature's idea.md for full details
  • Verify feature is in backlog status (no plan.md exists yet)
  • Handle already-in-progress features with user options
  • Set statusline immediately after selection by running:
    bash
    python3 ${CLAUDE_PLUGIN_ROOT}/skills/shared/lib/statusline.py set <feature-id>
    

Phase 2: Requirements Deep Dive

See: requirements.md

  • Read idea.md for problem statement and context
  • Optional: Run code-archaeologist for legacy code
  • Run project-manager agent for requirements analysis
  • Effort-based scaling (Small/Medium/Large)

Phase 3: System Design (Adaptive)

See: design.md

  • Classify feature type (Backend/Frontend/Full-Stack/Infrastructure)
  • Dispatch appropriate specialized agents
  • Save design documents to feature directory
Feature TypeAgents Used
Backend-Onlyapi-designer
Frontend-Onlyux-optimizer + frontend-architect
Full-Stackapi-designer + frontend-architect + integration-designer
UI-Heavyux-optimizer → then full-stack agents
Infrastructuresystem-designer

Phases 4-6: Implementation & Kickoff

See: implementation.md

  • Create plan.md with implementation steps
  • After writing plan.md, regenerate the dashboard by running:
    bash
    python3 ${CLAUDE_PLUGIN_ROOT}/skills/shared/lib/run_dashboard.py <project_root>
    
  • Stage changes with git
  • Display kickoff summary with next steps

plan.md Format

Write plan.md with YAML frontmatter followed by content:

markdown
---
started: YYYY-MM-DD
---

# Implementation Plan: [Feature Name]

## Overview
Brief summary of what will be implemented...

## Implementation Steps
- [ ] Step 1: Description
- [ ] Step 2: Description
- [ ] Step 3: Description

## Technical Decisions
Key architectural choices made during design...

## Testing Strategy
How this feature will be tested...

## Risks & Mitigations
Any identified risks and how they'll be addressed...

Completing a Feature

When the feature is done, use the /feature-ship command:

code
/feature-ship [feature-id]

This runs quality gates before marking the feature complete:

  1. Security Review - Scans for vulnerabilities (OWASP Top 10, CVEs)
  2. QA Validation - Verifies test coverage and acceptance criteria
  3. Final Verification - Runs tests, type checks, and build
  4. Status Update - Creates shipped.md (triggers hook to update DASHBOARD.md)

Error Handling

ErrorResolution
DASHBOARD.md not foundCreate it with generate-dashboard.sh
Feature not foundList available items, ask to select
Agent errorsRetry with more context or continue without that design phase
Directory missingCreate docs/features/ if needed
Already in progressAsk if user wants to continue existing work

Philosophy: "Never Code Without a Plan"

By completing these 6 phases, you ensure:

  • Requirements are clearly understood
  • Architecture is properly designed
  • Implementation is broken into manageable steps
  • Documentation will stay current
  • Testing is considered upfront
  • Risks are identified and mitigated

Let's get started!