一键导入
executing-plans
// Executes implementation plans with smart task grouping. Groups related tasks to share context, parallelizes across independent subsystems.
// Executes implementation plans with smart task grouping. Groups related tasks to share context, parallelizes across independent subsystems.
Selects and applies professional journalistic story structures (WSJ Formula, Inverted Pyramid, Hourglass, Tick-Tock, etc.) based on the content being written. Use when writing articles, blog posts, features, essays, long-form content, news stories, trend pieces, investigative reports, profiles, or any narrative prose longer than a few paragraphs. Also use when the user asks for help structuring a piece, choosing a story framework, organizing a draft, outlining an article, or wants to know which article format fits their content. Trigger on requests like "help me structure this," "what format should I use," "write a feature about," "draft a blog post on," or any mention of story structure, article architecture, or narrative frameworks. Complements the writer skill (which handles tone and anti-AI rhetoric) by providing the structural blueprint.
Writing style and tone guide for human-sounding content. Use when writing documentation, READMEs, commit messages, PR descriptions, blog posts, LinkedIn posts, social media content, or any user-facing content.
Guides clean, scalable system architecture during the build phase. Use when designing modules, defining boundaries, structuring projects, managing dependencies, or preventing tight coupling and brittleness as systems grow.
Enforces precise, minimal design for dashboards and admin interfaces. Use when building SaaS UIs, data-heavy interfaces, or any product needing Jony Ive-level craft.
Prevents silent failures and context loss in error handling. Use when writing try-catch blocks, designing error propagation, reviewing catch blocks, or implementing Result patterns.
Guides database architecture decisions for PostgreSQL, DuckDB, Parquet, PGVector, and Neo4j. Use when designing schemas, choosing storage strategies, optimizing queries, tuning maintenance, configuring vector search, modeling graph data, or diagnosing performance issues across OLTP, OLAP, similarity search, and graph workloads.
| name | executing-plans |
| description | Executes implementation plans with smart task grouping. Groups related tasks to share context, parallelizes across independent subsystems. |
You are an orchestrator. Spawn and coordinate sub-agents to do the actual implementation. Group related tasks by subsystem (e.g., one agent for API routes, another for tests) rather than spawning per-task. Each agent re-investigates the codebase, so fewer agents with broader scope = faster execution.
Create a branch for the work unless trivial. Consider git worktrees for isolated environments.
Clarify ambiguity upfront: If the plan has unclear requirements or meaningful tradeoffs, use AskUserQuestion before starting. Present options with descriptions explaining the tradeoffs. Use multiSelect: true for independent features that can be combined; use single-select for mutually exclusive choices. Don't guess when the user can clarify in 10 seconds.
Track progress with tasks: Use TaskCreate to create tasks for each major work item from the plan. Update status with TaskUpdate as work progresses (in_progress when starting, completed when done). This makes execution visible to the user and persists across context compactions.
Group related tasks to share agent context. One agent per subsystem, groups run in parallel.
Why grouping matters:
Without: Task 1 (auth/login) → Agent 1 [explores auth/]
Task 2 (auth/logout) → Agent 2 [explores auth/ again]
With: Tasks 1-2 (auth/*) → Agent 1 [explores once, executes both]
| Signal | Group together |
|---|---|
| Same directory prefix | src/auth/* tasks |
| Same domain/feature | Auth tasks, billing tasks |
| Plan sections | Tasks under same ## heading |
Limits: 3-4 tasks max per group. Split if larger.
Parallel: Groups touch different subsystems
Group A: src/auth/* ─┬─ parallel
Group B: src/billing/* ─┘
Sequential: Groups have dependencies
Group A: Create shared types → Group B: Use those types
Dispatch sub-agents to complete task groups. Monitor progress and handle issues.
Model selection: Choose the right model for sub-agents based on task complexity:
| Model | Use for | Examples |
|---|---|---|
opus | Complex coding, multi-file features, architectural work | New endpoints + route components, refactors spanning multiple subsystems |
sonnet | Moderate coding, straightforward features, writing | Simple CRUD endpoints, config changes, content updates |
haiku | Token-intensive non-coding work, simple mechanical tasks | Reading logs, generating commit messages, reading diffs for review summaries |
Default to opus for coding tasks unless the work is clearly straightforward. haiku is not suitable for writing code — it's for lightweight tasks where expensive tokens would be wasted on simple reads and summaries.
Agent tool:
description: "Auth tasks: login, logout"
model: opus # or sonnet for simpler coding tasks
prompt: |
Execute these tasks from [plan-file] IN ORDER:
- Task 1: Add login endpoint
- Task 2: Add logout endpoint
Use skills: <relevant skills>
Commit after each task. Report: files changed, test results
Architectural fit: Changes should integrate cleanly with existing patterns. If a change feels like it's fighting the architecture, that's a signal to refactor first rather than bolt something on. Don't reinvent wheels when battle-tested libraries exist, but don't reach for a dependency for trivial things either (no lodash just for _.map). The goal is zero tech debt, not "ship now, fix later."
Auto-recovery:
All four checks must pass before marking complete:
Automated tests: Run the full test suite. All tests must pass.
Manual verification: Automated tests aren't sufficient. Actually exercise the changes:
DX quality: During manual testing, watch for friction:
Fix DX issues inline or document for follow-up. Don't ship friction.
Code review (mandatory): After tests pass and manual verification is done, dispatch the ce:code-reviewer agent via Task tool to review the full diff against the base branch. This step is not optional.
Load relevant domain skills into the agent based on what was implemented. Evaluate which apply and include them in the agent prompt:
Skill(ce:architecting-systems) - system design, module boundariesSkill(ce:managing-databases) - database workSkill(ce:handling-errors) - error handlingSkill(ce:writing-tests) - test qualitySkill(ce:optimizing-performance) - performance workHandle the review verdict:
Plan execution is not done until review findings are addressed.
After verification passes, commit only the changes related to this plan:
git status to see all changesgit add -A or git add . - only stage files you modified as part of this planAfter committing:
./plans/done/ if applicable