mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-03-25 19:48:33 +08:00
feat: standardize request_user_input schema across all codex skills and add config reminder
- Update all 68 .codex/skills files to use correct request_user_input schema (header, id, question, options with label/description) - Remove deprecated multiSelect, type, value, prompt fields - Add mandatory confirmation gates to planning-only skills - Add Codex config.toml reminder to ccw install CLI - Add Codex configuration section to README.md and README_CN.md Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -6,7 +6,7 @@ argument-hint: "[-y|--yes] [-c|--continue] [-m progressive|direct|auto] \"requir
|
||||
|
||||
## Auto Mode
|
||||
|
||||
When `--yes` or `-y`: Auto-confirm strategy selection, use recommended mode, skip interactive rounds.
|
||||
When `--yes` or `-y`: Auto-confirm strategy selection, use recommended mode, skip interactive refinement rounds. **This skill is planning-only — it NEVER executes code or modifies source files. Output is the roadmap + issues for user review.**
|
||||
|
||||
# Roadmap-with-file Skill
|
||||
|
||||
@@ -143,9 +143,9 @@ Strategic requirement roadmap with **iterative decomposition**. Creates a single
|
||||
│ ├─ Update roadmap.md with each round │
|
||||
│ └─ Repeat until approved (max 5 rounds) │
|
||||
│ │
|
||||
│ Phase 4: Handoff │
|
||||
│ Phase 4: Handoff (PLANNING ENDS HERE) │
|
||||
│ ├─ Final roadmap.md with Issue ID references │
|
||||
│ ├─ Options: csv-wave-pipeline | view issues | done │
|
||||
│ ├─ Options: view issues | done (show next-step commands) │
|
||||
│ └─ Issues ready in .workflow/issues/issues.jsonl │
|
||||
│ │
|
||||
└─────────────────────────────────────────────────────────────────────────┘
|
||||
@@ -403,20 +403,19 @@ Bash(`mkdir -p ${sessionFolder}`)
|
||||
} else if (AUTO_YES) {
|
||||
selectedMode = recommendedMode
|
||||
} else {
|
||||
const answer = ASK_USER([
|
||||
{
|
||||
const answer = request_user_input({
|
||||
questions: [{
|
||||
header: "Strategy",
|
||||
id: "strategy",
|
||||
type: "choice",
|
||||
prompt: `Decomposition strategy:\nUncertainty: ${uncertaintyLevel}\nRecommended: ${recommendedMode}`,
|
||||
question: `Decomposition strategy:\nUncertainty: ${uncertaintyLevel}\nRecommended: ${recommendedMode}`,
|
||||
options: [
|
||||
{ value: "progressive", label: recommendedMode === 'progressive' ? "Progressive (Recommended)" : "Progressive" },
|
||||
{ value: "direct", label: recommendedMode === 'direct' ? "Direct (Recommended)" : "Direct" }
|
||||
],
|
||||
default: recommendedMode
|
||||
}
|
||||
]) // BLOCKS (wait for user response)
|
||||
{ label: recommendedMode === 'progressive' ? "Progressive (Recommended)" : "Progressive" },
|
||||
{ label: recommendedMode === 'direct' ? "Direct (Recommended)" : "Direct" }
|
||||
]
|
||||
}]
|
||||
}) // BLOCKS (wait for user response)
|
||||
|
||||
selectedMode = answer.strategy
|
||||
selectedMode = answer.answers.strategy.answers[0]
|
||||
}
|
||||
```
|
||||
|
||||
@@ -670,31 +669,36 @@ ${selectedMode === 'progressive' ? `**Progressive Mode**:
|
||||
while (!approved && round < 5) {
|
||||
round++
|
||||
|
||||
const feedback = ASK_USER([
|
||||
{
|
||||
const feedback = request_user_input({
|
||||
questions: [{
|
||||
header: "Validate",
|
||||
id: "feedback",
|
||||
type: "choice",
|
||||
prompt: `Roadmap validation (round ${round}):\n${issueIds.length} issues across ${waveCount} waves. Feedback?`,
|
||||
question: `Roadmap validation (round ${round}):\n${issueIds.length} issues across ${waveCount} waves. Feedback?`,
|
||||
options: [
|
||||
{ value: "approve", label: "Approve", description: "Proceed to handoff" },
|
||||
{ value: "scope", label: "Adjust Scope", description: "Modify issue scopes" },
|
||||
{ value: "convergence", label: "Modify Convergence", description: "Refine criteria/verification" },
|
||||
{ value: "replan", label: "Re-decompose", description: "Change strategy/layering" }
|
||||
{ label: "Approve", description: "Proceed to handoff" },
|
||||
{ label: "Adjust Scope", description: "Modify issue scopes" },
|
||||
{ label: "Modify Convergence", description: "Refine criteria/verification" },
|
||||
{ label: "Re-decompose", description: "Change strategy/layering" }
|
||||
]
|
||||
}
|
||||
]) // BLOCKS (wait for user response)
|
||||
}]
|
||||
}) // BLOCKS (wait for user response)
|
||||
|
||||
if (feedback.feedback === 'approve') {
|
||||
const feedbackChoice = feedback.answers.feedback.answers[0]
|
||||
if (feedbackChoice === 'Approve') {
|
||||
approved = true
|
||||
} else {
|
||||
// CONSTRAINT: All modifications below ONLY touch roadmap.md and issues.jsonl
|
||||
// NEVER modify source code or project files during interactive rounds
|
||||
switch (feedback.feedback) {
|
||||
case 'scope':
|
||||
switch (feedbackChoice) {
|
||||
case 'Adjust Scope':
|
||||
// Collect scope adjustments
|
||||
const scopeAdjustments = ASK_USER([
|
||||
{ id: "adjustments", type: "text", prompt: "Describe scope adjustments needed:" }
|
||||
]) // BLOCKS
|
||||
const scopeAdjustments = request_user_input({
|
||||
questions: [{
|
||||
header: "Scope",
|
||||
id: "adjustments",
|
||||
question: "Describe scope adjustments needed:"
|
||||
}]
|
||||
}) // BLOCKS
|
||||
|
||||
// Update ONLY roadmap.md Roadmap table + Convergence sections
|
||||
Edit({ path: `${sessionFolder}/roadmap.md`, /* scope changes */ })
|
||||
@@ -702,32 +706,36 @@ ${selectedMode === 'progressive' ? `**Progressive Mode**:
|
||||
|
||||
break
|
||||
|
||||
case 'convergence':
|
||||
case 'Modify Convergence':
|
||||
// Collect convergence refinements
|
||||
const convergenceRefinements = ASK_USER([
|
||||
{ id: "refinements", type: "text", prompt: "Describe convergence refinements needed:" }
|
||||
]) // BLOCKS
|
||||
const convergenceRefinements = request_user_input({
|
||||
questions: [{
|
||||
header: "Convergence",
|
||||
id: "refinements",
|
||||
question: "Describe convergence refinements needed:"
|
||||
}]
|
||||
}) // BLOCKS
|
||||
|
||||
// Update ONLY roadmap.md Convergence Criteria section
|
||||
Edit({ path: `${sessionFolder}/roadmap.md`, /* convergence changes */ })
|
||||
|
||||
break
|
||||
|
||||
case 'replan':
|
||||
case 'Re-decompose':
|
||||
// Return to Phase 2 with new strategy
|
||||
const newStrategy = ASK_USER([
|
||||
{
|
||||
const newStrategy = request_user_input({
|
||||
questions: [{
|
||||
header: "Strategy",
|
||||
id: "strategy",
|
||||
type: "choice",
|
||||
prompt: "Select new decomposition strategy:",
|
||||
question: "Select new decomposition strategy:",
|
||||
options: [
|
||||
{ value: "progressive", label: "Progressive" },
|
||||
{ value: "direct", label: "Direct" }
|
||||
{ label: "Progressive" },
|
||||
{ label: "Direct" }
|
||||
]
|
||||
}
|
||||
]) // BLOCKS
|
||||
}]
|
||||
}) // BLOCKS
|
||||
|
||||
selectedMode = newStrategy.strategy
|
||||
selectedMode = newStrategy.answers.strategy.answers[0]
|
||||
// Re-execute Phase 2 (updates roadmap.md + issues.jsonl only)
|
||||
break
|
||||
}
|
||||
@@ -793,47 +801,42 @@ ${selectedMode === 'progressive' ? `**Progressive Mode**:
|
||||
if (AUTO_YES) {
|
||||
nextStep = "done" // Default to done in auto mode
|
||||
} else {
|
||||
const answer = ASK_USER([
|
||||
{
|
||||
id: "next",
|
||||
type: "choice",
|
||||
prompt: `${issueIds.length} issues ready. Next step:`,
|
||||
const answer = request_user_input({
|
||||
questions: [{
|
||||
header: "Next Step",
|
||||
id: "next_step",
|
||||
question: `${issueIds.length} issues ready. Next step:`,
|
||||
options: [
|
||||
{ value: "csv-wave", label: "Execute with csv-wave-pipeline (Recommended)", description: `Run all ${issueIds.length} issues via wave-based batch execution` },
|
||||
{ value: "view", label: "View issues", description: "Display issue details" },
|
||||
{ value: "done", label: "Done", description: "Save and exit" }
|
||||
{ label: "View issues", description: "Display issue details" },
|
||||
{ label: "Done", description: "Planning complete — show next-step commands" }
|
||||
]
|
||||
}
|
||||
]) // BLOCKS (wait for user response)
|
||||
}]
|
||||
}) // BLOCKS (wait for user response)
|
||||
|
||||
nextStep = answer.next
|
||||
nextStep = answer.answers.next_step.answers[0]
|
||||
}
|
||||
```
|
||||
|
||||
3. **Execute Selection**
|
||||
```javascript
|
||||
switch (nextStep) {
|
||||
case 'csv-wave':
|
||||
// Launch csv-wave-pipeline for wave-based batch execution
|
||||
console.log(`\nTo execute, run:\n\n $csv-wave-pipeline "${requirement}"\n`)
|
||||
break
|
||||
|
||||
case 'view':
|
||||
// Display issues from issues.jsonl
|
||||
Bash(`ccw issue list --session ${sessionId}`)
|
||||
break
|
||||
// Fall through to show next-step commands
|
||||
// STOP — do not execute anything
|
||||
|
||||
case 'done':
|
||||
// Output paths and end
|
||||
// Output paths and end — this skill is planning-only
|
||||
console.log([
|
||||
`Roadmap saved: ${sessionFolder}/roadmap.md`,
|
||||
`Issues created: ${issueIds.length}`,
|
||||
'',
|
||||
'To execute later:',
|
||||
'Planning complete. To execute, run:',
|
||||
` $csv-wave-pipeline "${requirement}"`,
|
||||
` ccw issue list --session ${sessionId}`
|
||||
].join('\n'))
|
||||
break
|
||||
return // STOP — this skill is planning-only, NEVER proceed to execution
|
||||
}
|
||||
```
|
||||
|
||||
@@ -865,8 +868,9 @@ ${selectedMode === 'progressive' ? `**Progressive Mode**:
|
||||
3. **Iterate on Roadmap**: Use feedback rounds to refine, not recreate
|
||||
4. **Testable Convergence**: criteria = assertions, DoD = business language
|
||||
5. **Explicit Lifecycle**: Always close_agent after wait completes to free resources
|
||||
6. **DO NOT STOP**: Continuous workflow until handoff complete
|
||||
7. **Plan-Only Modifications**: Interactive feedback (Phase 3) MUST only update `roadmap.md` and `issues.jsonl`. NEVER modify source code, configuration files, or any project files during interactive rounds. Code changes happen only after handoff (Phase 4) via `$csv-wave-pipeline` or other execution skills
|
||||
6. **Planning-Only Skill**: This skill ONLY produces roadmap and issues. It NEVER executes code, creates source files, or runs implementation. All code changes happen via separate execution skills after user manually triggers them
|
||||
7. **Plan-Only Modifications**: Interactive feedback (Phase 3) MUST only update `roadmap.md` and `issues.jsonl`. NEVER modify source code, configuration files, or any project files during any phase. Code changes happen only after handoff when user manually runs `$csv-wave-pipeline` or other execution skills
|
||||
8. **MANDATORY CONFIRMATION GATE**: After Phase 2 decomposition completes, you MUST present the roadmap to the user and wait for confirmation (Phase 3) before proceeding to handoff. NEVER skip Phase 3 user validation
|
||||
|
||||
---
|
||||
|
||||
@@ -894,4 +898,4 @@ ${selectedMode === 'progressive' ? `**Progressive Mode**:
|
||||
|
||||
---
|
||||
|
||||
**Now execute roadmap-with-file for**: $ARGUMENTS
|
||||
**Now plan roadmap for**: $ARGUMENTS
|
||||
|
||||
Reference in New Issue
Block a user