src/autoskillit/skills_extended/planner-refine-phases/SKILL.md
Refine elaborated phases with cross-phase visibility via parallel L0 subagents (L1+L0 pattern)
npx skillsauth add talont-org/autoskillit planner-refine-phasesInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
L1 session that refines a combined_plan.json (a PlanDocument with every phase
in PhaseElaborated form) by spawning one L0 subagent per phase in parallel.
Each L0 reviews its assigned phase in the context of all other phases and returns
structured suggestions. L1 collects these suggestions, resolves inter-phase
conflicts, applies field-level edits to the plan, and writes refined_plan.json.
combined_plan.json output from the parallel phase elaboration merge steprefined_plan.json as input for downstream planner stepscombined_plan.json (PlanDocument, every phase as PhaseElaborated){{AUTOSKILLIT_TEMP}}/planner/run-YYYYMMDD-HHMMSS). Output is written to $2/refined_plan.json.NEVER:
$2/refined_plan_path before writing refined_plan.jsonrefined_plan_path even if all L0s fail (write unchanged plan, still emit){{AUTOSKILLIT_TEMP}} artifacts not passed as positional argumentsrun_in_background: true is prohibited)ALWAYS:
phase_id, changes (array), conflicts (array)WARNING to stdout for any L0 response that fails validation (skip that phase)CRITICAL to stdout for any L0 subagent that fails entirely (proceed with N-1)refined_plan_path = <absolute path to refined_plan.json>Read $1 (combined_plan.json). Parse as a PlanDocument. Extract all phase IDs
from phases[*].id. Fail immediately (exit non-zero) if phases is empty or the
file is malformed — do not proceed to spawn L0s.
Input schema (PlanDocument with PhaseElaborated phases):
{
"schema_version": 1,
"task": "...",
"source_dir": "...",
"phases": [
{
"id": "P1",
"name": "...",
"goal": "...",
"scope": [...],
"ordering": 1,
"technical_approach": "...",
"relationship_notes": "...",
"assignments_preview": [...]
}
]
}
Read the task field from the combined plan document. Each L0 subagent reviewing a phase
must verify that the phase's goal and scope serve the stated task. Phases that appear to
address codebase concerns not mentioned in the task should be flagged for scope creep.
If phase count ≤ 6: spawn one L0 subagent per phase in a single parallel batch. If phase count > 6: spawn sequential batches of 6 L0 subagents. Wait for each batch to complete before spawning the next. Process phases in ordering sequence.
Each L0 receives:
combined_plan.json content (pasted inline or via file read)target_phase_id (e.g., "P2")Each L0 must return structured text in this exact format:
phase_id = P2
changes = [
{"field": "relationship_notes", "new_value": "Depends on P1 for the auth client interface defined in P1-A2-WP1"},
{"field": "technical_approach", "new_value": "...updated approach..."}
]
conflicts = [
{"with_phase": "P1", "description": "Both P1 and P2 claim ownership of the token refresh module"}
]
For each L0 response:
phase_id must be present and match the expected phase ID for that L0changes must be a valid JSON array (may be empty [])conflicts must be a valid JSON array (may be empty [])On validation failure:
WARNING: L0 response for {phase_id} failed validation — skipping
On L0 subagent complete failure (no response / timeout):
CRITICAL: L0 for {phase_id} failed — proceeding with N-1 suggestions
Collect all conflicts arrays from validated L0 responses. Group conflict reports
by the pair of phases involved. When multiple L0s report conflicts involving the
same resource:
CONFLICT RESOLUTION: {phase_id} vs {with_phase} — {resolution decision}
Apply all validated changes to the in-memory plan document, in phase ID order
(P1, P2, ... PN). Apply conflict resolutions before applying changes for the
affected phases. Only update fields that exist in PhaseElaborated — skip
unrecognized field names:
WARNING: Unrecognized field '{field}' in changes for {phase_id} — skipping
Write the updated plan document to $2/refined_plan.json. The output schema is
identical to the input combined_plan.json (a PlanDocument with
phases: list[PhaseElaborated]).
refined_plan_path = <absolute path to $2/refined_plan.json>
development
Generate YAML recipes for .autoskillit/recipes/. Use when user says "make script skill", "generate script", "script a workflow", "write a script", "create a script", "new recipe", "write a pipeline", or when loaded by other skills for script formatting.
data-ai
Create Uncertainty Representation visualization planning spec showing error bar definitions, distribution-aware alternatives, and multi-seed variance protocols. Statistical lens answering "How is uncertainty honestly represented?"
data-ai
Create Temporal Dynamics visualization planning spec showing axis scaling (linear vs log), smoothing disclosure, epoch/step alignment, run aggregation (mean + variance bands), early-stopping markers, and wall-clock vs step-count x-axis. Temporal lens answering "Are training dynamics shown clearly and honestly?"
data-ai
Create Narrative Story Arc visualization planning spec showing visual consistency across the report (same color = same model everywhere), logical figure progression, redundant figure detection, and narrative dependency between figures. Narrative lens answering "Do the figures tell a coherent story across the report?"