Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 44 additions & 7 deletions .aiox-core/development/tasks/dev-develop-story.md
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ const {
- All tasks complete
- All tests pass
- Execute story-dod-checklist
- Set status: "Ready for Review"
- Set status: "InReview" (see Status Transitions section)
- **Generate decision log**:
```javascript
const logPath = await completeDecisionLogging(storyId, 'completed');
Expand Down Expand Up @@ -416,7 +416,7 @@ const {
- All tests pass
- Execute story-dod-checklist
- Present completion summary to user
- Set status: "Ready for Review"
- Set status: "InReview" (see Status Transitions section)

**User Prompts**: 5-10 (balanced for control and speed)

Expand Down Expand Up @@ -467,7 +467,7 @@ const {
- All tests pass
- Execute story-dod-checklist
- Present execution summary vs. plan
- Set status: "Ready for Review"
- Set status: "InReview" (see Status Transitions section)

**User Prompts**: All upfront (questionnaire phase), then 0 during execution

Expand Down Expand Up @@ -501,7 +501,7 @@ const {
- Completion Notes List
- File List
- Change Log (add entry on completion)
- Status (set to "Ready for Review" when complete)
- Status (set to "InReview" when complete — see Status Transitions section)

**DO NOT modify**: Story, Acceptance Criteria, Dev Notes, Testing sections

Expand All @@ -514,7 +514,7 @@ const {
- Missing configuration
- Failing regression tests

### Ready for Review Criteria (All Modes)
### InReview Criteria (All Modes)

- Code matches all requirements
- All validations pass
Expand All @@ -530,7 +530,7 @@ const {
5. File List is complete
6. **Execute CodeRabbit Self-Healing Loop** (see below)
7. Execute `.aiox-core/product/checklists/story-dod-checklist.md`
8. Set story status: "Ready for Review"
8. Set story status: "InReview" (see Status Transitions section)
9. HALT (do not proceed further)

---
Expand Down Expand Up @@ -915,10 +915,47 @@ Found 5 technical decisions needed.
- **Educational Value**: Interactive mode explanations help developers learn framework patterns
- **Scope Drift Prevention**: Pre-flight mode eliminates mid-development ambiguity

## Status Transitions (MANDATORY — All Modes)

**Reference:** `.claude/rules/story-lifecycle.md` — @dev owns Ready → InProgress and InProgress → InReview transitions.

**These steps MUST be executed at the specified points, regardless of execution mode.**

### On Development Start (before first task):

0. **Pre-check (blocking):**
- If current Status is `**InProgress**`, skip to first uncompleted task (resume scenario — no status change needed).
- If current Status is not `**Ready**` and not `**InProgress**`, HALT and log: "Cannot start development: expected Ready or InProgress, found {current status}."
- If Change Log section is missing, HALT and request user to restore template structure.
1. **Update story Status field:** change `**Ready**` to `**InProgress**` (skip if already InProgress)
2. **Add Change Log entry:**
```text
| {today's date} | {next version} | Development started ({mode} mode) — Status: Ready → InProgress | @dev |
```
3. **Log:** "🚀 Story status updated: Ready → InProgress"

### On Development Complete (after DOD checklist, before HALT):

0. **Pre-check (blocking):**
- If current Status is not `**InProgress**`, HALT and log: "Cannot mark for review: expected InProgress, found {current status}."
- If Change Log section is missing, HALT and request user to restore template structure.
1. **Update story Status field:** change `**InProgress**` to `**InReview**`
2. **Add Change Log entry:**
```text
| {today's date} | {next version} | Development complete — Status: InProgress → InReview | @dev |
```
3. **Log:** "✅ Story status updated: InProgress → InReview"

### Rationale

Status transitions defined in `story-lifecycle.md` are advisory (contextual rules). These steps make them imperative (procedural), ensuring agents always execute the transitions as part of the workflow rather than relying on contextual rule awareness.

Comment on lines +949 to +952

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

Resolve remaining “Ready for Review” instructions to avoid contradictory status flow.

This new mandatory flow ends at InReview, but other sections still instruct Ready for Review (for example, the completion checklist and self-healing purpose text). That conflict can cause incorrect final status updates and wrong handoff behavior.

Suggested follow-up patch
-### Ready for Review Criteria (All Modes)
+### InReview Criteria (All Modes)

-8. Set story status: "Ready for Review"
+8. Set story status: "InReview"

-**Purpose**: Catch and auto-fix code quality issues before marking story as "Ready for Review"
+**Purpose**: Catch and auto-fix code quality issues before marking story as "InReview"

-✅ Story ready for review
+✅ Story moved to InReview
As per coding guidelines: "Verify task follows AIOS task format with clear elicitation points."

Also applies to: 957-957

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.aios-core/development/tasks/dev-develop-story.md around lines 948 - 951,
The document introduces a mandatory status flow ending at "InReview" but other
sections still reference "Ready for Review", causing conflicting status
transitions; search for all occurrences of the literal "Ready for Review"
(including in the completion checklist and the "self-healing purpose" text) and
replace or reword them to align with the new mandatory state "InReview" (or add
clear mapping notes if "Ready for Review" must remain as a legacy term), update
any task completion checks or handoff instructions that trigger status updates
to set "InReview" instead of "Ready for Review", and verify the updated task
follows AIOS task format with explicit elicitation points mentioned in the doc.

---

## Handoff
next_agent: @qa
next_command: *review {story-id}
condition: Story status is Ready for Review
condition: Story status is InReview (updated in Status Transitions above)
alternatives:
- agent: @qa, command: *gate {story-id}, condition: Quick gate decision needed
- agent: @dev, command: *apply-qa-fixes, condition: Self-identified issues during dev
56 changes: 52 additions & 4 deletions .aiox-core/development/tasks/qa-gate.md
Original file line number Diff line number Diff line change
Expand Up @@ -420,11 +420,59 @@ Gate: CONCERNS → qa.qaLocation/gates/{epic}.{story}-{slug}.yml
- Always update story with gate reference
- Clear, actionable findings

## Post-Gate Status Update (MANDATORY)

**Reference:** `.claude/rules/story-lifecycle.md` — Status transitions are @qa responsibility during QA gate.

**This step MUST be executed before presenting results to user.**

### IF verdict is PASS or CONCERNS:

0. **Pre-check (blocking):**
- If current Status is not `**InReview**`, HALT and log: "Cannot apply PASS/CONCERNS transition: expected InReview, found {current status}."
- If Change Log section is missing, HALT and request user to restore template structure.
1. **Update story Status field** in the story file: change `**InReview**` to `**Done**`
2. **Add Change Log entry:**
```text
| {today's date} | {next version} | QA Gate {PASS|CONCERNS} — Status: InReview → Done | @qa |
```
3. **Log:** "✅ Story status updated: InReview → Done"

### IF verdict is FAIL:

0. **Pre-check (blocking):**
- If current Status is not `**InReview**`, HALT and log: "Cannot apply FAIL transition: expected InReview, found {current status}."
- If Change Log section is missing, HALT and request user to restore template structure.
1. **Update story Status field** in the story file: change `**InReview**` to `**InProgress**`
2. **Add Change Log entry:**
```text
| {today's date} | {next version} | QA Gate FAIL — Status: InReview → InProgress — {reason} | @qa |
```
3. **Log:** "❌ Story returned to InProgress — fixes required"

### IF verdict is WAIVED:

0. **Pre-check (blocking):**
- If current Status is not `**InReview**`, HALT and log: "Cannot apply WAIVED transition: expected InReview, found {current status}."
- If Change Log section is missing, HALT and request user to restore template structure.
1. **Update story Status field** in the story file: change `**InReview**` to `**Done**`
2. **Add Change Log entry:**
```text
| {today's date} | {next version} | QA Gate WAIVED — Status: InReview → Done — {waiver reason} | @qa |
```
3. **Log:** "⚠️ Story status updated: InReview → Done (waived)"

### Rationale

Status transitions defined in `story-lifecycle.md` are advisory (contextual rules). This step makes them imperative (procedural), ensuring agents always execute the transition as part of the workflow rather than relying on contextual rule awareness.

---

## Handoff
next_agent: @devops
next_command: *push
condition: QA gate verdict is PASS
condition: QA gate verdict is PASS or CONCERNS (status updated to Done)
alternatives:
- agent: @dev, command: *apply-qa-fixes, condition: QA gate verdict is FAIL or CONCERNS
- agent: @po, command: *close-story {story-id}, condition: QA gate verdict is WAIVED

- agent: @po, command: *review-concerns {story-id}, condition: QA gate verdict is CONCERNS (status updated to Done, has non-blocking issues)
- agent: @dev, command: *apply-qa-fixes, condition: QA gate verdict is FAIL (status updated to InProgress)
- agent: @po, command: *close-story {story-id}, condition: QA gate verdict is WAIVED (status updated to Done)
39 changes: 37 additions & 2 deletions .aiox-core/development/tasks/validate-next-story.md
Original file line number Diff line number Diff line change
Expand Up @@ -463,10 +463,45 @@ Provide a structured validation report including:
- **Implementation Readiness Score**: 1-10 scale
- **Confidence Level**: High/Medium/Low for successful implementation

### 12. Post-Validation Status Update (MANDATORY)

**Reference:** `.claude/rules/story-lifecycle.md` — Draft → Ready transition is @po responsibility.

**This step MUST be executed before presenting results to user.**

#### IF verdict is GO (score >= 7):

0. **Pre-check (blocking):**
- If current Status is not `**Draft**`, HALT and log: "Cannot apply GO transition: expected Draft, found {current status}."
- If Change Log section is missing, HALT and request user to restore template structure.
1. **Update story Status field** in the story file: change `**Draft**` to `**Ready**`
2. **Add Change Log entry:**
```text
| {today's date} | {next version} | Validated GO ({score}/10) — Status: Draft → Ready | @po |
```
3. **Log:** "✅ Story status updated: Draft → Ready"

#### IF verdict is NO-GO (score < 7):

0. **Pre-check (blocking):**
- If current Status is not `**Draft**`, HALT and log: "Cannot apply NO-GO outcome: expected Draft, found {current status}."
- If Change Log section is missing, HALT and request user to restore template structure.
1. **Keep** story Status as `**Draft**`
2. **Add Change Log entry:**
```text
| {today's date} | {next version} | Validation NO-GO — {reason summary} | @po |
```
3. **Log:** "❌ Story remains Draft — fixes required before re-validation"

#### Rationale

Status transitions defined in `story-lifecycle.md` are advisory (contextual rules). This step makes them imperative (procedural), ensuring agents always execute the transition as part of the workflow rather than relying on contextual rule awareness.

---

## Handoff
next_agent: @dev
next_command: *develop {story-id}
condition: Story status is Approved (GO decision)
condition: Story status is Ready (GO decision, status updated in Step 12)
alternatives:
- agent: @sm, command: *draft, condition: Story rejected (NO-GO), needs rework