EPIC: Plan Correction System — CorrectionService, CLI Compliance & Dry-Run (v3.3.0) #6197

Closed
opened 2026-04-09 17:39:10 +00:00 by HAL9000 · 1 comment
Owner

Background

The plan correction system (agents plan correct) is a core v3.3.0 deliverable that allows users to fix plans mid-execution. Multiple UAT findings show the correction system is incomplete: --mode=revert doesn't re-enter Strategize, --mode=append doesn't persist to the decision tree, CorrectionService doesn't persist to the database, and the dry-run output is missing required fields.

Demonstrable Capability

When this Epic is complete, agents plan correct will:

  • Correctly re-enter Strategize phase when --mode=revert is used
  • Persist correction guidance to the decision tree when --mode=append is used
  • Store correction attempts in the correction_attempts SQLite table
  • Show spec-compliant dry-run output with warnings, estimated_recompute_time_seconds, and hint
  • Display spec-compliant rich output panels (Correction, Affected Subtree, Sandbox Rollback, Recompute)
  • Increment plan.attempt counter on each correction

Acceptance Criteria

  • agents plan correct --mode=revert re-enters Strategize phase after correction
  • agents plan correct --mode=append persists guidance to decision tree and plan lifecycle
  • CorrectionService persists to correction_attempts SQLite table
  • agents plan correct --dry-run shows warnings, estimated_recompute_time_seconds, and hint
  • agents plan correct rich output shows all 4 spec-required panels
  • plan.attempt counter incremented on each correction
  • All nox stages pass
  • Coverage ≥ 97%

Metadata

  • Branch Naming Convention: feat/v3.3.0/plan-correction
  • Milestone: v3.3.0

Child Issues

  • #6155agents plan correct --mode=revert sets phase_transition_target but CLI never reads it
  • #6149agents plan correct --mode=append spawns synthetic in-memory child plan but never persists
  • #6132agents plan correct --dry-run output missing spec-required fields
  • #6092CorrectionService never persists to correction_attempts SQLite table
  • #5319 — plan correct does not increment plan.attempt counter
  • #5317 — plan correct --mode=append does not actually spawn a child plan
  • #5312 — plan correct rich output missing spec-required panels

Definition of Done

  • All child issues are closed
  • Integration between child issues verified
  • All nox stages pass
  • Coverage >= 97%

Automated by CleverAgents Bot
Supervisor: Epic Planning | Agent: epic-planner

## Background The plan correction system (`agents plan correct`) is a core v3.3.0 deliverable that allows users to fix plans mid-execution. Multiple UAT findings show the correction system is incomplete: `--mode=revert` doesn't re-enter Strategize, `--mode=append` doesn't persist to the decision tree, `CorrectionService` doesn't persist to the database, and the dry-run output is missing required fields. ## Demonstrable Capability When this Epic is complete, `agents plan correct` will: - Correctly re-enter Strategize phase when `--mode=revert` is used - Persist correction guidance to the decision tree when `--mode=append` is used - Store correction attempts in the `correction_attempts` SQLite table - Show spec-compliant dry-run output with `warnings`, `estimated_recompute_time_seconds`, and hint - Display spec-compliant rich output panels (Correction, Affected Subtree, Sandbox Rollback, Recompute) - Increment `plan.attempt` counter on each correction ## Acceptance Criteria - [ ] `agents plan correct --mode=revert` re-enters Strategize phase after correction - [ ] `agents plan correct --mode=append` persists guidance to decision tree and plan lifecycle - [ ] `CorrectionService` persists to `correction_attempts` SQLite table - [ ] `agents plan correct --dry-run` shows `warnings`, `estimated_recompute_time_seconds`, and hint - [ ] `agents plan correct` rich output shows all 4 spec-required panels - [ ] `plan.attempt` counter incremented on each correction - [ ] All nox stages pass - [ ] Coverage ≥ 97% ## Metadata - **Branch Naming Convention**: `feat/v3.3.0/plan-correction` - **Milestone**: v3.3.0 ## Child Issues <!-- Updated by automation after child issues are created --> - [ ] #6155 — `agents plan correct --mode=revert` sets `phase_transition_target` but CLI never reads it - [ ] #6149 — `agents plan correct --mode=append` spawns synthetic in-memory child plan but never persists - [ ] #6132 — `agents plan correct --dry-run` output missing spec-required fields - [ ] #6092 — `CorrectionService` never persists to `correction_attempts` SQLite table - [ ] #5319 — plan correct does not increment plan.attempt counter - [ ] #5317 — plan correct --mode=append does not actually spawn a child plan - [ ] #5312 — plan correct rich output missing spec-required panels ## Definition of Done - [ ] All child issues are closed - [ ] Integration between child issues verified - [ ] All nox stages pass - [ ] Coverage >= 97% --- **Automated by CleverAgents Bot** Supervisor: Epic Planning | Agent: epic-planner
Author
Owner

Closing as Duplicate: Epic #4959 (EPIC: Correction Engine — Revert & Append Modes with plan.attempt Tracking) already covers this scope.

The orphaned issues that were intended for this epic have been linked to Epic #4959 instead:

Closing this duplicate epic to avoid confusion.


Automated by CleverAgents Bot
Supervisor: Epic Planning | Agent: epic-planner

**Closing as Duplicate**: Epic #4959 (EPIC: Correction Engine — Revert & Append Modes with plan.attempt Tracking) already covers this scope. The orphaned issues that were intended for this epic have been linked to Epic #4959 instead: - #6155 → linked to #4959 - #6149 → linked to #4959 - #6132 → linked to #4959 - #6092 → linked to #4959 Closing this duplicate epic to avoid confusion. --- **Automated by CleverAgents Bot** Supervisor: Epic Planning | Agent: epic-planner
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
cleveragents/cleveragents-core#6197
No description provided.