generate-plan

Generates structured implementation plans from ideas, specs, or freeform descriptions via a planner subagent.

Updated May 19, 2026
One-click install
npx skills add https://github.com/davidsunglee/pi-flow --skill generate-plan-davidsunglee
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: generate-plan
Source: https://github.com/davidsunglee/pi-flow/tree/main/packages/pi-flow-core/skills/generate-plan
Command: npx skills add https://github.com/davidsunglee/pi-flow --skill generate-plan-davidsunglee

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Turning a rough idea, spec, or design doc into an executable implementation plan requires deep codebase analysis and iterative review, which is slow and error-prone when done manually. ## Core Features & Use Cases - Multi-source input handling: Accepts an idea ID, a file path (spec, RFC, design doc), or freeform text, with path-based handoff so large artifacts never pollute the orchestrator's context. - Planner subagent dispatch: Resolves model tiers, fills a prompt template, and dispatches the planner agent to analyze the codebase and write a dated plan file to docs/plans/. - Iterative refinement loop: Hands the plan to the refine-plan skill for review-edit cycles, commit gating, and an executable-plan parseability check before offering execution. - Use Case: Given a spec at docs/specs/reduce-context.md, generate a validated, reviewed implementation plan in docs/plans/ and optionally proceed straight to execute-plan. ## Quick Start Generate an implementation plan from the spec at docs/specs/reduce-context.md and refine it until it is approved.

Frequently Asked Questions about generate-plan

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate an implementation plan from a spec file?▼

Pass the spec file path as input; the skill extracts provenance from the file preamble, dispatches the planner subagent to read the artifact from disk, and writes a dated plan to docs/plans/. The plan then goes through the refine-plan review-edit loop before being offered for execution.

How do I turn a captured idea into an implementation plan?▼

Provide the idea ID (e.g., IDEA-7ef7d441); the skill reads the idea body with the built-in idea tool and inlines it into the planner prompt, since the planner subagent lacks the idea tool. The resulting plan is refined and validated like any other input source.

Does generate-plan work with large specs or design docs?▼

Yes. File inputs are passed by path rather than inlined, so large specs, RFCs, and design docs never pollute the orchestrator's context window. The planner reads the full artifact from disk itself.

What happens if the generated plan is not approved?▼

When refine-plan returns not_approved_within_budget, the skill reports the status, commit state, plan path, and review paths, then stops without offering execution. You inspect the saved plan and review files manually and can invoke execute-plan yourself if desired.

Why does generate-plan fail with an artifact handoff error?▼

The planner must emit a PLAN_ARTIFACT marker matching the expected output path, and the file must exist, be non-empty, and be freshly written. If validation fails, the skill surfaces the failure JSON and stops before refinement.