feat(workflow): add workflow:replan command with session-level replanning support

## Changes

### New Command: workflow:replan
- Created `.claude/commands/workflow/replan.md` with comprehensive session-level replanning
- Supports dual modes: session-wide and task-specific replanning
- Interactive boundary clarification using guided questioning
- Updates multiple artifacts: IMPL_PLAN.md, TODO_LIST.md, task JSONs, session metadata
- Comprehensive backup management with restore capability

### Key Features
1. **Interactive Clarification**: Guided questions to define modification scope
   - Modification scope (tasks only, plan update, task restructure, comprehensive)
   - Affected modules detection
   - Task change types (add, remove, merge, split, update)
   - Dependency relationship updates

2. **Session-Aware Operations**:
   - Auto-detects active sessions from `.workflow/active/`
   - Updates all session artifacts consistently
   - Maintains backup history in `.process/backup/replan-{timestamp}/`

3. **Comprehensive Artifact Updates**:
   - IMPL_PLAN.md section modifications
   - TODO_LIST.md task list updates
   - Task JSON files (requirements, implementation, dependencies)
   - Session metadata tracking

4. **Impact Analysis**: Automatically determines affected files and operations

### Deprecation
- Added deprecation notice to `/task:replan` in both command and reference files
- Updated `COMMAND_REFERENCE.md` to:
  - Add workflow:replan to Core Workflow section
  - Mark task:replan as deprecated with migration guidance

### Migration Path
- Old: `/task:replan IMPL-1 "changes"`
- New: `/workflow:replan IMPL-1 "changes"`

### Files Modified
- `.claude/commands/task/replan.md`: Added deprecation notice
- `.claude/commands/workflow/replan.md`: New command implementation
- `.claude/skills/command-guide/reference/commands/task/replan.md`: Deprecation notice
- `.claude/skills/command-guide/reference/commands/workflow/replan.md`: Reference documentation
- `COMMAND_REFERENCE.md`: Updated command listings

This change enhances workflow replanning capabilities by providing interactive,
session-aware modifications that maintain consistency across all workflow artifacts.
This commit is contained in:
Claude
2025-11-20 03:11:28 +00:00
parent 292dc113e3
commit d96a8a06a0
5 changed files with 1808 additions and 1 deletions

View File

@@ -39,6 +39,7 @@ These commands orchestrate complex, multi-phase development processes, from plan
|---|---|
| `/workflow:plan` | Orchestrate 5-phase planning workflow with quality gate, executing commands and passing context between phases. |
| `/workflow:lite-plan` | ⚡ **NEW** Lightweight interactive planning and execution workflow with in-memory planning, smart code exploration, three-dimensional multi-select confirmation (task approval + execution method + code review), and parallel task execution support. |
| `/workflow:replan` | ⚡ **NEW** Interactive workflow replanning with session-level artifact updates and boundary clarification through guided questioning. Supports both session-wide and task-specific modifications. |
| `/workflow:execute` | Coordinate agents for existing workflow tasks with automatic discovery. |
| `/workflow:resume` | Intelligent workflow session resumption with automatic progress analysis. |
| `/workflow:review` | Optional specialized review (security, architecture, docs) for completed implementation. |
@@ -122,7 +123,7 @@ Commands for managing individual tasks within a workflow session.
| `/task:create` | Create implementation tasks with automatic context awareness. |
| `/task:breakdown` | Intelligent task decomposition with context-aware subtask generation. |
| `/task:execute` | Execute tasks with appropriate agents and context-aware orchestration. |
| `/task:replan` | Replan individual tasks with detailed user input and change tracking. |
| `/task:replan` | ⚠️ **DEPRECATED** Use `/workflow:replan` instead. Legacy command for task replanning (maintained for backward compatibility). |
## Memory and Versioning Commands