Atomic plan format and toolchain contract shared by planning and execution agents. Use when generating, validating, or executing atomic plans with Phase 0, baseline capture, and final QA loops.
Shared rules for atomic plan formatting, Phase 0 requirements, baseline capture, and final QA loops.
Use this skill when:
### Phase N — <Title>- [ ] [P#-T#] (or [x] for completed)validate_orchestration_artifacts MCP tool with artifact_type: "plan" and artifact_path: <plan-path> before they can be reported as approved.When orchestration selects short path, a minimal plan is still mandatory and must include these blocks:
evidence-and-timestamp-conventionsTimestamp:, Command:, EXIT_CODE:, Output Summary:Output Summary: (baseline percent and, when applicable, targeted module/new-code percent).Timestamp:, Command:, EXIT_CODE:, Output Summary:Output Summary:.SKIPPED is invalid unless the task text itself explicitly authorizes a skip condition.For short-path planning handoffs, orchestrators MUST include:
DIRECTIVE: MINIMAL-AUDIT PLAN REQUIREDRequired planner outputs for this directive:
${feature-folder}/issue.md as sole requirements source,${feature-folder}/issue.md to contain an explicit ## Acceptance Criteria section and MUST treat only that section as the minor-audit AC source,spec.md/user-story.md/research.md,plan-path and final preflight signal.After preflight all-clear on the minimal-audit plan:
Branching after Phase 0:
manual bootstrap → save state and stop for manual resume,Phase 0 must include tasks to read policy files in the order defined in policy-compliance-order.
Phase 0 must also capture baseline toolchain results for the languages touched. Baseline artifact conventions (location + required fields) are defined in evidence-and-timestamp-conventions.
For short-path/minimal-audit plans, Phase 0 evidence is incomplete unless both artifacts exist:
phase0-instructions-read.md with at least: Timestamp:, Policy Order:, and explicit list of files read.Timestamp:, Command:, EXIT_CODE:, Output Summary: for each baseline check executed.Output Summary: is mandatory for each command-step artifact and must concisely summarize the essential result signal (for example: pass/fail status, key counts, coverage headline, or primary diagnostic).
For any language in scope where repository policy requires coverage validation:
UNVERIFIED).Run the full toolchain loop for each applicable language in order:
For languages with mandatory coverage policy, step 4 must use coverage-enabled test commands and persist numeric coverage evidence.
If any step fails or changes files, restart the loop from step 1 until a clean pass completes.
For command-bearing tasks in approved plans (especially Phase 2 final-QC tasks):
EXIT_CODE: SKIPPED MUST NOT be used as a passing outcome,Any regression test task expected to fail must be tagged with [expect-fail] and include an auditable evidence artifact per evidence-and-timestamp-conventions.
When validating or handing off plans for execution:
DIRECTIVE: PREFLIGHT VALIDATION ONLY.PREFLIGHT: ALL CLEARPREFLIGHT: REVISIONS REQUIREDBefore a plan can be treated as approved:
validate_orchestration_artifacts MCP tool with artifact_type: "plan" and artifact_path: <plan-path>,When a caller provides an explicit target plan file path (for example ${plan-path} or ${file}):
plan.<timestamp>.md) during the same planning cycle.If the provided path does not exist, it may be created once, then reused for all subsequent revisions in that cycle.
When a plan is generated or validated from a feature folder, resolve selected mode in this order:
issue.md metadata block:
- Work Mode: minor-audit- Work Mode: full-feature- Work Mode: full-bug- Work Mode: full resolves to full-featureissue.mdfull-feature when marker is missing or malformedminor-audit plans MUST include baseline evidence tasks, targeted verification evidence tasks, and end-state evidence tasks.minor-audit plans MUST require ${feature-folder}/issue.md to contain an explicit ## Acceptance Criteria section; do not infer acceptance criteria from other issue.md sections.minor-audit plans MUST NOT treat missing spec.md or user-story.md as automatic blockers.minor-audit execution/validation/audit MUST fail closed when spec.md or user-story.md exists unexpectedly in the active folder, when the explicit ## Acceptance Criteria section is missing from issue.md, when required Phase 0 artifacts are missing, or when checklist state contradicts evidence on disk.full-feature plans MUST enforce full-document expectations (spec.md + user-story.md) and full QA loop obligations.full-bug plans MUST enforce spec-driven expectations (spec.md required, user-story.md optional/absent by default) and full QA loop obligations.