fix: update execution-plan.md status on stage completion#69
fix: update execution-plan.md status on stage completion#69inariku wants to merge 4 commits intoawslabs:mainfrom
Conversation
|
Hey @raj-jain-aws 👋 Same ask as #68 — would appreciate a merge commit instead of squash so the contribution shows up. Thanks! |
|
Hi @inariku. You are already a contributor. We squash commits that show contribution, this PR shows your participation (no commits). |
|
@inariku Can you confirm if this issue is still a problem, if so I will approve |
|
@inariku Please resolve the conflicts |
Each stage's completion instructions update aidlc-state.md but not execution-plan.md, leaving the execution plan with stale status values. Add instructions to update the corresponding stage status to COMPLETED in execution-plan.md at every stage completion point. Affected files (12): - inception: workflow-planning, reverse-engineering, requirements-analysis, user-stories, application-design, units-generation - construction: functional-design, nfr-requirements, nfr-design, infrastructure-design, code-generation, build-and-test Closes awslabs#23
…aid flowchart and checklist Testing revealed that the AI only updated the checklist section but not the Mermaid diagram. Add explicit '(both Mermaid flowchart and checklist)' to all update instructions, and add a note in the execution-plan.md template in workflow-planning.md.
Testing showed that AI agents skip the execution-plan.md update despite instructions in individual stage files. This is an attention problem - the AI focuses on aidlc-state.md and audit.md updates but misses the execution-plan.md instruction. Changes: - Add MANDATORY execution-plan tracking as a Key Principle in core-workflow.md (loaded first, highest attention) - Make workflow-planning.md approval step a numbered sub-list for better visibility
The execution-plan.md contains three representations of stage status: Mermaid flowchart, text alternative (required by content-validation.md), and checklist. Previous instructions only mentioned flowchart and checklist, leaving the text alternative stale. Update all 15 occurrences to specify 'Mermaid flowchart, text alternative, and checklist'.
11404fc to
6f9c14a
Compare
|
@harmjeff Yes, the issue is still present — upstream main has no instructions to update |
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 13 out of 13 changed files in this pull request and generated 13 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| - **Transparent Planning**: Always show execution plan before starting | ||
| - **User Control**: User can request stage inclusion/exclusion | ||
| - **Progress Tracking**: Update aidlc-state.md with executed and skipped stages | ||
| - **Execution Plan Tracking**: When completing ANY stage, update that stage's status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist). This is MANDATORY for every stage completion. |
There was a problem hiding this comment.
The new mandatory principle requires updating the execution plan to COMPLETED on “ANY stage completion”, but several CONSTRUCTION stages are explicitly per-unit (see common/process-overview.md). If agents follow this literally, they may mark a stage COMPLETED in execution-plan.md after finishing the first unit, even though other units remain. Consider tightening the wording to clarify that execution-plan.md should only be updated to COMPLETED when the stage is complete for the overall workflow (e.g., last unit completed), or update the execution-plan format to track per-unit progress.
| - **Execution Plan Tracking**: When completing ANY stage, update that stage's status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist). This is MANDATORY for every stage completion. | |
| - **Execution Plan Tracking**: When a stage is FULLY COMPLETE for the overall workflow (e.g., all units finished for per-unit CONSTRUCTION stages), update that stage's status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist). This is MANDATORY for every overall stage completion; do NOT mark a stage COMPLETED in the execution plan based only on the first or partial unit being finished. |
| **Note**: Replace STATUS placeholders with actual phase status (COMPLETED/SKIP/EXECUTE) and apply appropriate styling. When updating a stage status to COMPLETED, update it in the Mermaid flowchart, text alternative, and checklist. | ||
|
|
There was a problem hiding this comment.
This note (and the new stage-completion instructions) refer to updating a “text alternative” in execution-plan.md, but the execution-plan template defined in Step 7 currently includes only the Mermaid flowchart and the checklist sections (no dedicated text-alternative section). To make this requirement actionable, consider adding an explicit text-alternative section to the template (and clarifying what it should contain) or removing/renaming the reference here to match the actual template structure.
| **Note**: Replace STATUS placeholders with actual phase status (COMPLETED/SKIP/EXECUTE) and apply appropriate styling. When updating a stage status to COMPLETED, update it in the Mermaid flowchart, text alternative, and checklist. | |
| **Note**: Replace STATUS placeholders with actual phase status (COMPLETED/SKIP/EXECUTE) and apply appropriate styling. When updating a stage status to COMPLETED, update it in the Mermaid flowchart, the Text Alternative section below, and the checklist. | |
| ## Text Alternative for Workflow Diagram | |
| Provide a concise text description of the workflow for accessibility (for example, for screen readers). At minimum, list each phase and the status of its stages in reading order. | |
| - **Inception Phase**: | |
| - Workspace Detection – [STATUS] | |
| - Reverse Engineering – [STATUS] | |
| - Requirements Analysis – [STATUS] | |
| - User Stories – [STATUS] | |
| - Workflow Planning – [STATUS] | |
| - Application Design – [STATUS] | |
| - Units Planning – [STATUS] | |
| - Units Generation – [STATUS] | |
| - **Construction Phase**: | |
| - Functional Design – [STATUS] | |
| - NFR Requirements – [STATUS] | |
| - NFR Design – [STATUS] | |
| - Infrastructure Design – [STATUS] | |
| - Code Generation – [STATUS] | |
| - Build and Test – [STATUS] | |
| - **Operations Phase**: | |
| - Operations – [STATUS] |
|
|
||
| - **If approved**: Proceed to next stage in execution plan | ||
| - **If approved**: | ||
| 1. Update Workflow Planning status from IN PROGRESS to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) |
There was a problem hiding this comment.
In the execution-plan template’s checklist, the INCEPTION item is currently “Execution Plan (IN PROGRESS)” rather than “Workflow Planning (IN PROGRESS)”, so the instruction here to update Workflow Planning in the checklist is ambiguous/non-actionable. Either update the execution-plan checklist template to include a “Workflow Planning” entry (and align naming with the flowchart WP node), or adjust this instruction to match the checklist item name that actually exists.
| 1. Update Workflow Planning status from IN PROGRESS to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) | |
| 1. Update the INCEPTION checklist item "Execution Plan" status from IN PROGRESS to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) |
| - [ ] Update Code Generation Part 1 (Planning) status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) | ||
| - [ ] Update the "Current Status" section |
There was a problem hiding this comment.
This stage is “Code Generation” in execution-plan.md (the template shows a single node: “Code Generation (Planning + Generation)”), so asking to mark “Code Generation Part 1 (Planning)” as COMPLETED in execution-plan.md doesn’t match any stage/status in that file. Also, marking the stage COMPLETED at the end of planning would be premature (generation hasn’t happened yet). Suggest removing this execution-plan update from Part 1, or updating the execution-plan format to explicitly track Part 1 vs Part 2 if that’s the intent.
| - [ ] Update Code Generation Part 1 (Planning) status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) | |
| - [ ] Update the "Current Status" section | |
| - [ ] Keep `aidlc-docs/inception/plans/execution-plan.md` using a single "Code Generation (Planning + Generation)" stage; do not mark Code Generation as COMPLETED until Part 2 (Generation) is finished | |
| - [ ] Update the "Current Status" section in `aidlc-state.md` to reflect that planning is complete and generation is ready to start |
| - Log approval in audit.md with timestamp | ||
| - Record the user's approval response with timestamp | ||
| - Mark Code Generation stage as complete for this unit in aidlc-state.md | ||
| - Update Code Generation status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) |
There was a problem hiding this comment.
Code Generation is defined as an ALWAYS, per-unit stage (common/process-overview.md). Updating the single “Code Generation” status in execution-plan.md to COMPLETED at the end of each unit risks marking the overall stage done while other units remain. Consider gating this update so it only flips to COMPLETED once the final unit’s code generation is approved, or revise execution-plan.md to track per-unit progress explicitly.
| - Update Code Generation status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) | |
| - Only when **all units' Code Generation** is approved, update the global Code Generation status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist). Otherwise, leave the global status as IN PROGRESS and track per-unit completion in `aidlc-state.md`. |
| - Log approval in audit.md with timestamp | ||
| - Record the user's approval response with timestamp | ||
| - Mark Infrastructure Design stage complete in aidlc-state.md | ||
| - Update Infrastructure Design status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) |
There was a problem hiding this comment.
Infrastructure Design is a per-unit stage (common/process-overview.md). Updating the single “Infrastructure Design” status in execution-plan.md to COMPLETED at the end of one unit could incorrectly show the overall stage as done while other units remain. Consider only marking COMPLETED in execution-plan.md once all units have finished Infrastructure Design, or update the execution plan to track per-unit completion.
| - Update Infrastructure Design status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) | |
| - Update Infrastructure Design status in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist) **only when Infrastructure Design is complete for all units**; otherwise, ensure any per-unit tracking in the execution plan is updated for the current unit |
| @@ -298,6 +298,7 @@ If the analysis in step 9 reveals ANY ambiguous answers, you MUST: | |||
|
|
|||
| ## Step 23: Update Progress | |||
| - Mark User Stories stage complete in `aidlc-state.md` | |||
There was a problem hiding this comment.
The workflow’s directory structure places the canonical state file at aidlc-docs/aidlc-state.md (core-workflow.md “Directory Structure”). This step still references aidlc-state.md without the aidlc-docs/ prefix, which can lead agents to write/update the wrong file. Consider updating this reference to aidlc-docs/aidlc-state.md for consistency with other stages.
| - Mark User Stories stage complete in `aidlc-state.md` | |
| - Mark User Stories stage complete in `aidlc-docs/aidlc-state.md` |
| @@ -98,6 +98,7 @@ If the analysis in step 7 reveals ANY ambiguous answers, you MUST: | |||
|
|
|||
| ## Step 11: Update Progress | |||
| - Mark Units Planning complete in aidlc-state.md | |||
There was a problem hiding this comment.
This step still says “Mark Units Planning complete in aidlc-state.md” (no aidlc-docs/ prefix), while the canonical path in the workflow is aidlc-docs/aidlc-state.md (core-workflow.md “Directory Structure”). Since this step is being touched, consider updating the state-file reference here to the canonical path to avoid creating/updating the wrong file.
| - Mark Units Planning complete in aidlc-state.md | |
| - Mark Units Planning complete in aidlc-docs/aidlc-state.md |
| ``` | ||
|
|
||
| Update Reverse Engineering status to COMPLETED in `aidlc-docs/inception/plans/execution-plan.md` (Mermaid flowchart, text alternative, and checklist). | ||
|
|
||
| ## Step 12: Present Completion Message to User |
There was a problem hiding this comment.
For consistency with the surrounding “Update State Tracking” step (which is a bulleted checklist), consider making this new execution-plan update instruction a bullet in the same list (rather than a standalone sentence between code fences/headings). That makes it less likely to be missed during stage completion.
| - Wait for explicit user approval before proceeding | ||
| - Record approval response with timestamp | ||
| - Update Requirements Analysis stage complete in aidlc-state.md No newline at end of file | ||
| - Update Requirements Analysis stage complete in aidlc-state.md |
There was a problem hiding this comment.
This completion checklist still references “aidlc-state.md” without the canonical aidlc-docs/ prefix, even though earlier in this file Step 8 updates aidlc-docs/aidlc-state.md and the core workflow’s directory structure puts the file under aidlc-docs/. Consider updating this line to aidlc-docs/aidlc-state.md to avoid ambiguity about which file should be edited.
| - Update Requirements Analysis stage complete in aidlc-state.md | |
| - Update Requirements Analysis stage complete in `aidlc-docs/aidlc-state.md` |
Problem
When stages complete,
aidlc-state.mdis updated correctly, butexecution-plan.mdis never updated. This leaves the execution plan with stale status values (e.g.,IN PROGRESSorEXECUTE) even after stages have finished.Solution
aidlc-docs/inception/plans/execution-plan.mdat every stage completion point across all rule-details files(Mermaid flowchart, text alternative, and checklist)to ensure all three representations are updatedcore-workflow.mdto ensure AI agents prioritize this updateChanges
core-workflow.md(1 file):Execution Plan Trackingas a MANDATORY Key PrincipleInception phase (7 files):
workflow-planning.md— update on user approval (numbered sub-list for visibility) + note in execution-plan templatereverse-engineering.md— Step 10: Update State Trackingrequirements-analysis.md— approval handlinguser-stories.md— Step 23: Update Progressapplication-design.md— Step 15: Update Progressunits-generation.md— Step 11 (Units Planning) and Step 19 (Units Generation)Construction phase (6 files):
functional-design.md— approval handlingnfr-requirements.md— approval handlingnfr-design.md— approval handlinginfrastructure-design.md— approval handlingcode-generation.md— Code Planning (Step 9) and Code Generation completionbuild-and-test.md— Step 8: Update State TrackingTest Evidence
Tested by running a full AI-DLC workflow (simple TODO CLI app in Python) with the modified rules in Kiro CLI.
Test Setup
.kiro/steering/and.kiro/aws-aidlc-rule-details/Using AI-DLC, create a simple TODO list CLI app in PythonResults —
execution-plan.mdstatus updatesIN PROGRESS→COMPLETEDEXECUTE→COMPLETEDEXECUTE→COMPLETEDBefore (Workflow Planning created, before approve)
After (Code Generation completed)
Key Findings
core-workflow.mdwas essential for making the AI consistently perform the updates. Without it (tested in earlier iterations), the AI skipped theexecution-plan.mdupdates despite instructions in individual stage files.Closes #23
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.