Skip to content

Commit 71485b8

Browse files
author
catlog22
committed
fix(workflow): resolve analyze-with-file and lite-plan phase conflict
Add workflow boundary markers to analyze-with-file Post-Completion Options so that when "生成任务" triggers lite-plan via Skill(), the model follows lite-plan's Phase 1-5 exclusively instead of returning to analyze Phase 4 synthesis. Root cause: Skill() expands inline (shared context), causing phase number collision between the two workflows.
1 parent 2fc792a commit 71485b8

2 files changed

Lines changed: 9 additions & 4 deletions

File tree

.claude/commands/workflow/analyze-with-file.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -542,7 +542,11 @@ CONSTRAINTS: ${perspective.constraints}
542542
- **Trade-offs Made**: Key trade-offs and why certain paths were chosen over others
543543
- Add session statistics: rounds, duration, sources, artifacts, **decision count**
544544

545-
3. **Post-Completion Options**
545+
3. **Post-Completion Options** (⚠️ TERMINAL — analyze-with-file ends after user selection)
546+
547+
> **WORKFLOW BOUNDARY**: After user selects any option below, the analyze-with-file workflow is **COMPLETE**.
548+
> If "生成任务" is selected, workflow-lite-plan takes over exclusively — do NOT return to any analyze-with-file phase.
549+
> The "Phase" numbers in workflow-lite-plan (Phase 1-5) are SEPARATE from analyze-with-file phases.
546550
547551
```javascript
548552
const hasActionableRecs = conclusions.recommendations?.some(r => r.priority === 'high' || r.priority === 'medium')
@@ -562,7 +566,7 @@ CONSTRAINTS: ${perspective.constraints}
562566
})
563567
```
564568
565-
**Handle "生成任务"**:
569+
**Handle "生成任务"** (⚠️ TERMINAL — analyze-with-file ends here, lite-plan takes over exclusively):
566570
```javascript
567571
if (nextStep.includes("生成任务")) {
568572
// 1. Build task description from high/medium priority recommendations
@@ -585,8 +589,9 @@ CONSTRAINTS: ${perspective.constraints}
585589
if (findings.length) contextLines.push(`**Key Findings**:\n${findings.map(f => `- ${f}`).join('\n')}`)
586590
}
587591

588-
// 3. Call lite-plan with enriched task description (no special flags)
592+
// 3. Hand off to lite-plan — analyze-with-file COMPLETE, do NOT return to any analyze phase
589593
Skill(skill="workflow-lite-plan", args=`"${taskDescription}\n\n${contextLines.join('\n')}"`)
594+
return // ⛔ analyze-with-file terminates here
590595
}
591596
```
592597

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "claude-code-workflow",
3-
"version": "7.2.0",
3+
"version": "7.2.1",
44
"description": "JSON-driven multi-agent development framework with intelligent CLI orchestration (Gemini/Qwen/Codex), context-first architecture, and automated workflow execution",
55
"type": "module",
66
"main": "ccw/dist/index.js",

0 commit comments

Comments
 (0)