AgentSkillsCN

plan-creator

为新功能制定架构方案——适用于任意执行器(循环执行或集群执行)。可接受来自头脑风暴阶段的功能描述或设计文件。若需处理 Bug,则使用 /bug-plan-creator;若要提升代码质量,则使用 /code-quality-plan-creator。

SKILL.md
--- frontmatter
name: plan-creator
allowed-tools: Task, Read
argument-hint: <feature-description or design-file-path>
description: Create architectural plans for new features - works with any executor (loop or swarm). Accepts a feature description or a design file from /brainstorming. For bugs use /bug-plan-creator, for code quality use /code-quality-plan-creator.
context: fork
agent: plan-creator-default
model: opus

Architectural Plan Creator

Create comprehensive architectural plans for new features in existing codebases (brownfield development). Plans specify HOW to implement, not just WHAT.

Use the right tool:

  • New features/enhancements/plan-creator (this command)
  • Bug fixes/bug-plan-creator
  • Code quality improvements/code-quality-plan-creator

Arguments

Takes a feature description OR a design file path:

  • "Add OAuth2 authentication with Google login"
  • "Add user profile page with avatar upload"
  • docs/designs/2025-01-15-oauth-design.md

Tip: For complex features, use the brainstorming skill first to create a design document, then pass the design file path here.

Instructions

Step 1: Process Input

The user invoked this skill with arguments: $ARGUMENTS

Determine the input type:

Design file detection — If the argument matches a file path ending in .md inside docs/designs/:

  1. Use the Read tool to load the design file contents
  2. Proceed to Step 2 with the design file contents as context

Text description — Otherwise:

  1. Treat the arguments as a task description
  2. Grammar and spell check before passing to agent

Step 2: Launch Agent

Launch background agent with the appropriate prompt:

If design file was provided:

code
Create architectural plan from design document:

<full design file contents>

REQUIRED Task tool parameters:

code
subagent_type: "plan-creator-default"
run_in_background: true
prompt: "Create architectural plan from design document:\n\n<full design file contents>"

If text description was provided:

code
Create architectural plan: <corrected task description>

REQUIRED Task tool parameters:

code
subagent_type: "plan-creator-default"
run_in_background: true
prompt: "Create architectural plan: <corrected task description>"

Output a status message like "Creating plan..." and end your turn. The system wakes you when the agent finishes.

Step 3: Commit the Plan

After the plan file is created, commit it to the repository:

bash
git add docs/plans/{plan-file}.md
git commit -m "docs(plan): add {task-slug} implementation plan"

Step 4: Report Result

code
## Architectural Plan Created

**Plan**: docs/plans/{task-slug}-{hash5}-plan.md

Next Steps:
1. Review the plan
2. Execute (loop or swarm are interchangeable):
   - `/plan-loop <plan-path>` or `/plan-swarm <plan-path>`

Error Handling

ScenarioAction
Agent failsReport error, stop
Plan not readyReport issues, suggest fixes

Example Usage

bash
/plan-creator Add OAuth2 authentication with Google login
/plan-creator Add user profile page with avatar upload
/plan-creator Refactor the auth module to use dependency injection
/plan-creator docs/designs/2025-01-15-oauth-design.md
/plan-creator docs/designs/2025-03-22-notifications-design.md