Agent Skill
2/7/2026

plugin-task-plan

Create implementation tasks from deliverables using skill delegation

C
cuioss
1GitHub Stars
1Views
npx skills add cuioss/plan-marshall

SKILL.md

Nameplugin-task-plan
DescriptionCreate implementation tasks from deliverables using skill delegation

name: plugin-task-plan description: Create implementation tasks from deliverables using skill delegation user-invocable: false

Plugin Task Plan Skill

Role: Domain planning skill for plugin development tasks. Transforms solution outline deliverables into optimized, executable tasks that delegate to existing skills for implementation.

Key Pattern: Skill delegation with optimization - reads deliverables with metadata from solution_outline.md, applies aggregation/split analysis, creates tasks with delegation blocks and dependencies.

Contract Compliance

MANDATORY: All tasks MUST follow the structure defined in the central contracts:

ContractLocationPurpose
Task Contractplan-marshall:manage-tasks/standards/task-contract.mdTask structure and optimization workflow

Non-compliant tasks will be rejected by validation.

CRITICAL: The steps field MUST contain file paths from the deliverable's Affected files section:

# CORRECT - file paths from deliverable
steps:
  - marketplace/bundles/plan-marshall/agents/phase-1-init-agent.md
  - marketplace/bundles/plan-marshall/agents/phase-3-outline-agent.md

# WRONG - descriptive text (violates contract)
steps[2]{number,target,status}:
1,Convert phase-1-init-agent outputs,pending
2,Convert phase-3-outline-agent outputs,pending

The steps field lists FILES TO MODIFY, not progress tracking entries.

Operation: plan

Input:

ParameterTypeRequiredDescription
plan_idstringYesPlan identifier
deliverable_numbernumberNoSingle deliverable number (omit to process all deliverables)

Process:

Step 1: Load All Deliverables

Read the solution document to get all deliverables with metadata:

python3 .plan/execute-script.py plan-marshall:manage-solution-outline:manage-solution-outline \
  list-deliverables \
  --plan-id {plan_id}

For each deliverable, extract:

  • metadata.change_type, metadata.execution_mode, metadata.domain
  • metadata.suggested_skill, metadata.suggested_workflow
  • metadata.context_skills, metadata.depends
  • affected_files, verification

Step 2: Build Dependency Graph

Parse depends field for each deliverable:

  • Identify independent deliverables (depends: none)
  • Identify dependency chains
  • Detect cycles (INVALID - reject)

Step 3: Analyze for Aggregation

For each pair of deliverables, check if they can be aggregated:

  • Same change_type?
  • Same suggested_skill?
  • Same execution_mode (must be automated)?
  • Combined file count < 10?
  • NO dependency between them? (CRITICAL - cannot aggregate if one depends on other)

Step 4: Analyze for Splits

For each deliverable, check for split requirements:

  • execution_mode: mixed → MUST split
  • Different concerns within → SHOULD split
  • File count > 15 → CONSIDER splitting

Step 4b: Log Optimization Decisions (REQUIRED)

After analyzing each deliverable or deliverable pair, log the decision:

# If aggregating deliverables
python3 .plan/execute-script.py plan-marshall:manage-logging:manage-log \
  work --plan-id {plan_id} --level INFO --message "[OPTIMIZATION] (pm-plugin-development:plugin-task-plan) Aggregating D{N}+D{M}: same skill ({skill}), no inter-dependency"

# If keeping deliverable separate
python3 .plan/execute-script.py plan-marshall:manage-logging:manage-log \
  work --plan-id {plan_id} --level INFO --message "[OPTIMIZATION] (pm-plugin-development:plugin-task-plan) Keeping D{N} separate: {reason}"

# If splitting deliverable
python3 .plan/execute-script.py plan-marshall:manage-logging:manage-log \
  work --plan-id {plan_id} --level INFO --message "[OPTIMIZATION] (pm-plugin-development:plugin-task-plan) Splitting D{N}: execution_mode=mixed"

This logging is REQUIRED for audit trail and debugging.

Step 5: Create Optimized Tasks

For aggregated deliverables or single deliverables, create tasks using heredoc.

CRITICAL: The steps field MUST contain file paths copied from the deliverable's Affected files section.

python3 .plan/execute-script.py plan-marshall:manage-tasks:manage-tasks add \
  --plan-id {plan_id} <<'EOF'
title: {Action Verb} {Target}: {Scope}
deliverable: {n}
domain: plan-marshall-plugin-dev
phase: 5-execute
description: |
  {combined description from deliverables}

steps:
  - marketplace/bundles/{bundle}/agents/{file1}.md
  - marketplace/bundles/{bundle}/agents/{file2}.md
  - marketplace/bundles/{bundle}/commands/{file3}.md

depends_on: {TASK-N | none}

delegation:
  skill: {suggested_skill from deliverable metadata}
  workflow: {suggested_workflow from deliverable metadata}
  context_skills: {context_skills from deliverable metadata - MUST include even if empty []}

verification:
  commands:
    - {verification.command from deliverable}
  criteria: {verification.criteria from deliverable}
EOF

Field mapping from deliverable to task:

Deliverable FieldTask FieldRequired
Affected files: liststeps: list (copy file paths directly)Yes
metadata.suggested_skilldelegation.skillYes
metadata.suggested_workflowdelegation.workflowYes
metadata.context_skillsdelegation.context_skillsYes (even if empty [])
metadata.dependsUsed to compute depends_onYes
Verification.Commandverification.commandsYes
Verification.Criteriaverification.criteriaYes

CRITICAL: The context_skills field MUST always be included in the delegation block, even when empty. Tasks without this field violate the task-contract and will fail validation.

Example with real paths:

python3 .plan/execute-script.py plan-marshall:manage-tasks:manage-tasks add \
  --plan-id migrate-json-to-toon <<'EOF'
title: Migrate plan-marshall Agents to TOON Format
deliverable: 2
domain: plan-marshall-plugin-dev
phase: 5-execute
description: |
  Convert all JSON output blocks to TOON format in plan-marshall agents.

steps:
  - marketplace/bundles/plan-marshall/agents/phase-1-init-agent.md
  - marketplace/bundles/plan-marshall/agents/phase-3-outline-agent.md
  - marketplace/bundles/plan-marshall/agents/phase-4-plan-agent.md
  - marketplace/bundles/plan-marshall/agents/phase-5-execute-agent.md

depends_on: TASK-1

delegation:
  skill: pm-plugin-development:plugin-maintain
  workflow: update-component
  context_skills: []

verification:
  commands:
    - grep -r '```json' marketplace/bundles/plan-marshall/agents/
  criteria: Returns no matches (exit code 1)
EOF

Step 6: Record Issues as Lessons

On ambiguous deliverable or planning issues:

python3 .plan/execute-script.py plan-marshall:manage-lessons:manage-lesson add \
  --component "pm-plugin-development:plugin-task-plan" \
  --category improvement \
  --title "{issue summary}" \
  --detail "{context and resolution approach}"

Valid categories: bug, improvement, anti-pattern

Step 7: Return Results

Output:

status: success
plan_id: {plan_id}

optimization_summary:
  deliverables_processed: {N}
  tasks_created: {M}
  aggregations: {count of deliverable groups}
  splits: {count of split deliverables}

tasks_created[M]{number,title,deliverables,depends_on}:
1,Create skill: java-logging-patterns,[1],none
2,Update plugin-maintain,[2 3],TASK-1
3,Refactor bundle structure,[4],none

lessons_recorded: {count}

Delegation Mapping

When creating tasks, map from deliverable metadata to stdin TOON fields:

Deliverable MetadataTOON Field
domaindomain:
suggested_skilldelegation: skill:
suggested_workflowdelegation: workflow:
context_skillsdelegation: context_skills: (merged from all aggregated deliverables)
affected_filessteps: (one per file)
verification.commandverification: commands: (may consolidate)
verification.criteriaverification: criteria:

Plugin-Specific Skill Mapping

Change TypeComponent TypeSkillWorkflow
createskillpm-plugin-development:plugin-createcreate-skill
createcommandpm-plugin-development:plugin-createcreate-command
createagentpm-plugin-development:plugin-createcreate-agent
createbundlepm-plugin-development:plugin-createcreate-bundle
modifyanypm-plugin-development:plugin-maintainupdate-component
refactoranypm-plugin-development:plugin-maintainrefactor-structure
migrateformatpm-plugin-development:plugin-maintainupdate-component
deleteanypm-plugin-development:plugin-maintainremove-component

Task Generation Patterns

These patterns show how to create tasks for different operation types. Note that steps always contains FILE PATHS.

Create Component Task

Deliverable: "Create new {skill|command|agent} for {purpose}"

The steps field lists files that WILL BE CREATED:

title: Create skill: java-logging-patterns
steps:
  - marketplace/bundles/pm-dev-java/skills/java-logging-patterns/SKILL.md
delegation:
  skill: pm-plugin-development:plugin-create
  workflow: create-skill

Modify Component Task

Deliverable: "Update {component} to {change description}"

The steps field lists existing files to MODIFY:

title: Update plugin-maintain Skill
steps:
  - marketplace/bundles/pm-plugin-development/skills/plugin-maintain/SKILL.md
delegation:
  skill: pm-plugin-development:plugin-maintain
  workflow: update-component

Migrate Task (Multiple Files)

Deliverable: "Migrate {components} to {new format}"

The steps field lists ALL files to migrate (copied from Affected files):

title: Migrate plan-marshall Agents to TOON Format
steps:
  - marketplace/bundles/plan-marshall/agents/phase-1-init-agent.md
  - marketplace/bundles/plan-marshall/agents/phase-3-outline-agent.md
  - marketplace/bundles/plan-marshall/agents/phase-4-plan-agent.md
  - marketplace/bundles/plan-marshall/agents/phase-5-execute-agent.md
delegation:
  skill: pm-plugin-development:plugin-maintain
  workflow: update-component

Script Task (Special Case)

Scripts are created within skills. The steps lists the script file AND its test:

title: Create script: manage-references
steps:
  - marketplace/bundles/plan-marshall/skills/manage-references/scripts/manage-references.py
  - test/plan-marshall/manage-references/test_manage_references.py
delegation:
  skill: pm-plugin-development:plugin-create
  workflow: create-skill

Parameter Extraction

When analyzing deliverables, extract these parameters:

For Create Operations

ParameterSource
bundleExplicit in deliverable OR inferred from context
nameExplicit in deliverable OR derived from purpose
descriptionExtracted from deliverable body
typeComponent-specific (agent type, skill type, etc.)

For Modify Operations

ParameterSource
component_pathExplicit path OR resolve from component name
improvementsDescription from deliverable body

Multi-Task Deliverables

Some deliverables require multiple tasks in sequence:

Skill with Scripts

TASK-1: Create skill structure
  - Delegate to: plugin-create → create-skill

TASK-2: Create script(s)
  - Create Python script in skill/scripts/
  - Add test file
  - Update SKILL.md

Command with New Skill

TASK-1: Create supporting skill
  - Delegate to: plugin-create → create-skill

TASK-2: Create command
  - Delegate to: plugin-create → create-command
  - Reference skill from TASK-1

Task Dependencies

When creating multiple tasks:

DependencyOrdering
Scripts within skillCreate skill first, then scripts
Command referencing skillCreate skill first
Agent referencing skillCreate skill first
Refactor before createComplete refactor first

Error Handling

Ambiguous Deliverable

If deliverable doesn't specify:

  • Target bundle → Ask for clarification
  • Component type → Infer from keywords or ask
  • Operation type → Default to create unless "update/modify/fix" present

Missing Information

If deliverable lacks required parameters:

  • Generate task with available info
  • Note missing parameters in task description
  • Record lesson for future reference

Integration

Caller: pm-plugin-development:plugin-task-plan-agent

Script Notations (use EXACTLY as shown):

  • plan-marshall:manage-solution-outline:manage-solution-outline - Read solution and list deliverables (list-deliverables, read)
  • plan-marshall:manage-tasks:manage-tasks - Create tasks (add --plan-id X <<'EOF' ... EOF)
  • plan-marshall:manage-lessons:manage-lesson - Record lessons on issues (add)
  • plan-marshall:manage-logging:manage-log - Log progress (work)

Skills Delegated To:

  • pm-plugin-development:plugin-create - Component creation (handles validation and verification internally)
  • pm-plugin-development:plugin-maintain - Component updates and refactoring (handles verification internally)

Contract Reference:

Skills Info
Original Name:plugin-task-planAuthor:cuioss