From 41cff287997eb82cdecd1e661c6853553c871fbe Mon Sep 17 00:00:00 2001 From: catlog22 Date: Sat, 7 Feb 2026 23:44:22 +0800 Subject: [PATCH] Refactor code structure for improved readability and maintainability --- .../workflows/_template-compare-matrix.html | 0 .../workflows/chinese-response.md | 0 .../cli-templates/fix-plan-template.json | 0 .../cli-templates/fix-progress-template.json | 0 .../style-skill-memory/skill-md-template.md | 0 .../planning-roles/data-architect.md | 0 .../planning-roles/product-manager.md | 0 .../planning-roles/product-owner.md | 0 .../planning-roles/scrum-master.md | 0 .../planning-roles/subject-matter-expert.md | 0 .../planning-roles/synthesis-role.md | 0 .../planning-roles/system-architect.md | 0 .../planning-roles/test-strategist.md | 0 .../planning-roles/ui-designer.md | 0 .../cli-templates/planning-roles/ux-expert.md | 0 .../analysis-analyze-code-patterns.txt | 0 .../prompts/analysis-analyze-performance.txt | 0 .../analysis-analyze-technical-document.txt | 0 .../analysis-assess-security-risks.txt | 0 .../analysis-diagnose-bug-root-cause.txt | 0 .../prompts/analysis-review-architecture.txt | 0 .../prompts/analysis-review-code-quality.txt | 0 .../analysis-review-quality-standards.txt | 0 .../prompts/analysis-trace-code-execution.txt | 0 .../development-debug-runtime-issues.txt | 0 .../prompts/development-generate-tests.txt | 0 .../development-implement-component-ui.txt | 0 .../prompts/development-implement-feature.txt | 0 .../prompts/development-refactor-codebase.txt | 0 .../prompts/documentation-api.txt | 0 .../documentation-folder-navigation.txt | 0 .../prompts/documentation-module-readme.txt | 0 .../documentation-project-architecture.txt | 0 .../documentation-project-examples.txt | 0 .../prompts/documentation-project-readme.txt | 0 .../prompts/documentation-swagger-api.txt | 0 .../memory-document-module-structure.txt | 0 .../prompts/planning-breakdown-task-steps.txt | 0 .../planning-design-component-spec.txt | 0 .../planning-evaluate-concept-feasibility.txt | 0 .../planning-plan-architecture-design.txt | 0 .../planning-plan-migration-strategy.txt | 0 .../cli-templates/prompts/rules-rule-api.txt | 0 .../prompts/rules-rule-components.txt | 0 .../prompts/rules-rule-config.txt | 0 .../cli-templates/prompts/rules-rule-core.txt | 0 .../prompts/rules-rule-patterns.txt | 0 .../prompts/rules-rule-testing.txt | 0 .../prompts/rules-tech-rules-agent-prompt.txt | 12 +- .../prompts/tech-tech-module-format.txt | 0 .../prompts/tech-tech-skill-index.txt | 0 .../prompts/test-suggestions-enhancement.txt | 0 .../prompts/test-test-concept-analysis.txt | 0 .../universal-universal-creative-style.txt | 0 .../universal-universal-rigorous-style.txt | 0 .../prompts/verification-codex-technical.txt | 0 .../prompts/verification-cross-validation.txt | 0 .../prompts/verification-gemini-strategic.txt | 0 .../workflow-analysis-results-structure.txt | 0 .../workflow-codex-feasibility-validation.txt | 2 +- .../workflow-gemini-solution-design.txt | 2 +- .../prompts/workflow-impl-plan-template.txt | 0 .../prompts/workflow-skill-aggregation.txt | 0 .../workflow-skill-conflict-patterns.txt | 0 .../prompts/workflow-skill-index.txt | 0 .../workflow-skill-lessons-learned.txt | 0 .../workflow-skill-sessions-timeline.txt | 0 .../prompts/workflow-task-json-agent-mode.txt | 0 .../prompts/workflow-task-json-cli-mode.txt | 0 .../protocols/analysis-protocol.md | 0 .../cli-templates/protocols/write-protocol.md | 0 .../schemas/conflict-resolution-schema.json | 0 .../schemas/debug-log-json-schema.json | 0 .../schemas/diagnosis-json-schema.json | 0 .../schemas/discovery-finding-schema.json | 0 .../schemas/discovery-state-schema.json | 0 .../schemas/explore-json-schema.json | 0 .../schemas/fix-plan-json-schema.json | 0 .../schemas/issues-jsonl-schema.json | 0 .../schemas/multi-cli-discussion-schema.json | 0 .../schemas/plan-json-schema.json | 0 .../schemas/plan-verify-agent-schema.json | 0 .../schemas/project-guidelines-schema.json | 0 .../schemas/project-tech-schema.json | 0 .../cli-templates/schemas/queue-schema.json | 0 .../schemas/registry-schema.json | 0 .../review-deep-dive-results-schema.json | 0 .../review-dimension-results-schema.json | 0 .../schemas/solution-schema.json | 0 .../schemas/verify-json-schema.json | 0 .../cli-templates/tech-stacks/go-dev.md | 0 .../cli-templates/tech-stacks/java-dev.md | 0 .../tech-stacks/javascript-dev.md | 0 .../cli-templates/tech-stacks/python-dev.md | 0 .../cli-templates/tech-stacks/react-dev.md | 0 .../tech-stacks/typescript-dev.md | 0 .../ui-design/systems/animation-tokens.json | 0 .../ui-design/systems/design-tokens.json | 0 .../ui-design/systems/layout-templates.json | 0 .../workflows/cli-tools-usage.md | 0 .../workflows/coding-philosophy.md | 0 {.claude => .ccw}/workflows/context-tools.md | 0 .../workflows/file-modification.md | 0 .../review-directory-specification.md | 0 {.claude => .ccw}/workflows/task-core.md | 0 .../workflows/test-quality-config.json | 0 {.claude => .ccw}/workflows/tool-strategy.md | 0 .../workflows/windows-platform.md | 0 .../workflows/workflow-architecture.md | 2 +- .claude/CLAUDE.md | 8 +- .claude/agents/action-planning-agent.md | 6 +- .claude/agents/cli-execution-agent.md | 8 +- .claude/agents/code-developer.md | 18 +- .claude/agents/conceptual-planning-agent.md | 8 +- .claude/agents/ui-design-agent.md | 6 +- .claude/commands/issue/discover-by-prompt.md | 2 +- .claude/commands/issue/discover.md | 6 +- .claude/commands/memory/docs-full-cli.md | 2 +- .claude/commands/memory/docs-related-cli.md | 2 +- .claude/commands/memory/style-skill-memory.md | 4 +- .../workflow/brainstorm/auto-parallel.md | 2 +- .../workflow/brainstorm/role-analysis.md | 20 +- .../workflow/collaborative-plan-with-file.md | 2 +- .claude/commands/workflow/init.md | 2 +- .claude/commands/workflow/lite-fix.md | 10 +- .claude/commands/workflow/lite-plan.md | 10 +- .claude/commands/workflow/multi-cli-plan.md | 2 +- .claude/commands/workflow/plan-verify.md | 4 +- .../commands/workflow/review-module-cycle.md | 10 +- .../commands/workflow/review-session-cycle.md | 12 +- .claude/commands/workflow/session/complete.md | 2 +- .../commands/workflow/test-cycle-execute.md | 2 +- .../workflow/tools/code-validation-gate.md | 2 +- .../workflow/tools/conflict-resolution.md | 4 +- .../commands/workflow/tools/context-gather.md | 2 +- .../workflow/tools/task-generate-tdd.md | 2 +- .../workflow/tools/test-concept-enhanced.md | 2 +- .../workflow/tools/test-task-generate.md | 2 +- .../issue-discover/phases/02-discover.md | 6 +- .../phases/03-discover-by-prompt.md | 2 +- .../review-cycle/phases/02-parallel-review.md | 14 +- .../phases/04-iterative-deep-dive.md | 8 +- .../skill-generator/templates/llm-action.md | 6 +- .../phases/02-task-generate-tdd.md | 2 +- .codex/agents/action-planning-agent.md | 6 +- .codex/agents/cli-execution-agent.md | 8 +- .codex/agents/code-developer.md | 18 +- .codex/agents/conceptual-planning-agent.md | 8 +- .codex/agents/ui-design-agent.md | 6 +- .../issue-discover/phases/02-discover.md | 6 +- .../phases/03-discover-by-prompt.md | 2 +- .codex/skills/issue-execute/SKILL.md | 2 +- .../review-cycle/phases/02-parallel-review.md | 14 +- .../phases/04-iterative-deep-dive.md | 8 +- .../phases/02-parallel-role-analysis.md | 20 +- .../phases/01-lite-plan.md | 1050 +++++------------ .../phases/02-lite-execute.md | 667 ++++------- .../phases/02-context-gathering.md | 6 +- .../phases/02-task-generate-tdd.md | 2 +- .../phases/02-test-cycle-execute.md | 2 +- INSTALL.md | 6 +- INSTALL_CN.md | 6 +- .../build/assets/js/19b64556.267a65e7.js | 2 +- .../build/workflows/level-2-rapid.html | 2 +- .../build/zh/assets/js/05467734.307672f8.js | 2 +- .../docs/workflows/level-2-rapid.mdx | 2 +- .../current/workflows/level-2-rapid.mdx | 2 +- .../src/components/layout/AppShell.tsx | 1 - .../src/components/layout/Sidebar.tsx | 2 - ccw/frontend/src/hooks/useCommands.ts | 31 +- .../src/pages/CommandsManagerPage.tsx | 49 +- ccw/frontend/src/pages/QueuePage.tsx | 2 +- ccw/src/core/routes/claude-routes.ts | 12 +- ccw/src/tools/claude-cli-tools.ts | 6 +- ccw/src/tools/template-discovery.ts | 2 +- 175 files changed, 691 insertions(+), 1479 deletions(-) rename {.claude => .ccw}/workflows/_template-compare-matrix.html (100%) rename {.claude => .ccw}/workflows/chinese-response.md (100%) rename {.claude => .ccw}/workflows/cli-templates/fix-plan-template.json (100%) rename {.claude => .ccw}/workflows/cli-templates/fix-progress-template.json (100%) rename {.claude => .ccw}/workflows/cli-templates/memory/style-skill-memory/skill-md-template.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/data-architect.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/product-manager.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/product-owner.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/scrum-master.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/subject-matter-expert.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/synthesis-role.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/system-architect.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/test-strategist.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/ui-designer.md (100%) rename {.claude => .ccw}/workflows/cli-templates/planning-roles/ux-expert.md (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/analysis-analyze-code-patterns.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/analysis-analyze-performance.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/analysis-analyze-technical-document.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/analysis-assess-security-risks.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/analysis-diagnose-bug-root-cause.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/analysis-review-architecture.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/analysis-review-code-quality.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/analysis-review-quality-standards.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/analysis-trace-code-execution.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/development-debug-runtime-issues.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/development-generate-tests.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/development-implement-component-ui.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/development-implement-feature.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/development-refactor-codebase.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/documentation-api.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/documentation-folder-navigation.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/documentation-module-readme.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/documentation-project-architecture.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/documentation-project-examples.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/documentation-project-readme.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/documentation-swagger-api.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/memory-document-module-structure.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/planning-breakdown-task-steps.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/planning-design-component-spec.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/planning-evaluate-concept-feasibility.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/planning-plan-architecture-design.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/planning-plan-migration-strategy.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/rules-rule-api.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/rules-rule-components.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/rules-rule-config.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/rules-rule-core.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/rules-rule-patterns.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/rules-rule-testing.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/rules-tech-rules-agent-prompt.txt (84%) rename {.claude => .ccw}/workflows/cli-templates/prompts/tech-tech-module-format.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/tech-tech-skill-index.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/test-suggestions-enhancement.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/test-test-concept-analysis.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/universal-universal-creative-style.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/universal-universal-rigorous-style.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/verification-codex-technical.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/verification-cross-validation.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/verification-gemini-strategic.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-analysis-results-structure.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-codex-feasibility-validation.txt (98%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-gemini-solution-design.txt (97%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-impl-plan-template.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-skill-aggregation.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-skill-conflict-patterns.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-skill-index.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-skill-lessons-learned.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-skill-sessions-timeline.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-task-json-agent-mode.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/prompts/workflow-task-json-cli-mode.txt (100%) rename {.claude => .ccw}/workflows/cli-templates/protocols/analysis-protocol.md (100%) rename {.claude => .ccw}/workflows/cli-templates/protocols/write-protocol.md (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/conflict-resolution-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/debug-log-json-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/diagnosis-json-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/discovery-finding-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/discovery-state-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/explore-json-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/fix-plan-json-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/issues-jsonl-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/multi-cli-discussion-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/plan-json-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/plan-verify-agent-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/project-guidelines-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/project-tech-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/queue-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/registry-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/review-dimension-results-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/solution-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/schemas/verify-json-schema.json (100%) rename {.claude => .ccw}/workflows/cli-templates/tech-stacks/go-dev.md (100%) rename {.claude => .ccw}/workflows/cli-templates/tech-stacks/java-dev.md (100%) rename {.claude => .ccw}/workflows/cli-templates/tech-stacks/javascript-dev.md (100%) rename {.claude => .ccw}/workflows/cli-templates/tech-stacks/python-dev.md (100%) rename {.claude => .ccw}/workflows/cli-templates/tech-stacks/react-dev.md (100%) rename {.claude => .ccw}/workflows/cli-templates/tech-stacks/typescript-dev.md (100%) rename {.claude => .ccw}/workflows/cli-templates/ui-design/systems/animation-tokens.json (100%) rename {.claude => .ccw}/workflows/cli-templates/ui-design/systems/design-tokens.json (100%) rename {.claude => .ccw}/workflows/cli-templates/ui-design/systems/layout-templates.json (100%) rename {.claude => .ccw}/workflows/cli-tools-usage.md (100%) rename {.claude => .ccw}/workflows/coding-philosophy.md (100%) rename {.claude => .ccw}/workflows/context-tools.md (100%) rename {.claude => .ccw}/workflows/file-modification.md (100%) rename {.claude => .ccw}/workflows/review-directory-specification.md (100%) rename {.claude => .ccw}/workflows/task-core.md (100%) rename {.claude => .ccw}/workflows/test-quality-config.json (100%) rename {.claude => .ccw}/workflows/tool-strategy.md (100%) rename {.claude => .ccw}/workflows/windows-platform.md (100%) rename {.claude => .ccw}/workflows/workflow-architecture.md (99%) diff --git a/.claude/workflows/_template-compare-matrix.html b/.ccw/workflows/_template-compare-matrix.html similarity index 100% rename from .claude/workflows/_template-compare-matrix.html rename to .ccw/workflows/_template-compare-matrix.html diff --git a/.claude/workflows/chinese-response.md b/.ccw/workflows/chinese-response.md similarity index 100% rename from .claude/workflows/chinese-response.md rename to .ccw/workflows/chinese-response.md diff --git a/.claude/workflows/cli-templates/fix-plan-template.json b/.ccw/workflows/cli-templates/fix-plan-template.json similarity index 100% rename from .claude/workflows/cli-templates/fix-plan-template.json rename to .ccw/workflows/cli-templates/fix-plan-template.json diff --git a/.claude/workflows/cli-templates/fix-progress-template.json b/.ccw/workflows/cli-templates/fix-progress-template.json similarity index 100% rename from .claude/workflows/cli-templates/fix-progress-template.json rename to .ccw/workflows/cli-templates/fix-progress-template.json diff --git a/.claude/workflows/cli-templates/memory/style-skill-memory/skill-md-template.md b/.ccw/workflows/cli-templates/memory/style-skill-memory/skill-md-template.md similarity index 100% rename from .claude/workflows/cli-templates/memory/style-skill-memory/skill-md-template.md rename to .ccw/workflows/cli-templates/memory/style-skill-memory/skill-md-template.md diff --git a/.claude/workflows/cli-templates/planning-roles/data-architect.md b/.ccw/workflows/cli-templates/planning-roles/data-architect.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/data-architect.md rename to .ccw/workflows/cli-templates/planning-roles/data-architect.md diff --git a/.claude/workflows/cli-templates/planning-roles/product-manager.md b/.ccw/workflows/cli-templates/planning-roles/product-manager.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/product-manager.md rename to .ccw/workflows/cli-templates/planning-roles/product-manager.md diff --git a/.claude/workflows/cli-templates/planning-roles/product-owner.md b/.ccw/workflows/cli-templates/planning-roles/product-owner.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/product-owner.md rename to .ccw/workflows/cli-templates/planning-roles/product-owner.md diff --git a/.claude/workflows/cli-templates/planning-roles/scrum-master.md b/.ccw/workflows/cli-templates/planning-roles/scrum-master.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/scrum-master.md rename to .ccw/workflows/cli-templates/planning-roles/scrum-master.md diff --git a/.claude/workflows/cli-templates/planning-roles/subject-matter-expert.md b/.ccw/workflows/cli-templates/planning-roles/subject-matter-expert.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/subject-matter-expert.md rename to .ccw/workflows/cli-templates/planning-roles/subject-matter-expert.md diff --git a/.claude/workflows/cli-templates/planning-roles/synthesis-role.md b/.ccw/workflows/cli-templates/planning-roles/synthesis-role.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/synthesis-role.md rename to .ccw/workflows/cli-templates/planning-roles/synthesis-role.md diff --git a/.claude/workflows/cli-templates/planning-roles/system-architect.md b/.ccw/workflows/cli-templates/planning-roles/system-architect.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/system-architect.md rename to .ccw/workflows/cli-templates/planning-roles/system-architect.md diff --git a/.claude/workflows/cli-templates/planning-roles/test-strategist.md b/.ccw/workflows/cli-templates/planning-roles/test-strategist.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/test-strategist.md rename to .ccw/workflows/cli-templates/planning-roles/test-strategist.md diff --git a/.claude/workflows/cli-templates/planning-roles/ui-designer.md b/.ccw/workflows/cli-templates/planning-roles/ui-designer.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/ui-designer.md rename to .ccw/workflows/cli-templates/planning-roles/ui-designer.md diff --git a/.claude/workflows/cli-templates/planning-roles/ux-expert.md b/.ccw/workflows/cli-templates/planning-roles/ux-expert.md similarity index 100% rename from .claude/workflows/cli-templates/planning-roles/ux-expert.md rename to .ccw/workflows/cli-templates/planning-roles/ux-expert.md diff --git a/.claude/workflows/cli-templates/prompts/analysis-analyze-code-patterns.txt b/.ccw/workflows/cli-templates/prompts/analysis-analyze-code-patterns.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/analysis-analyze-code-patterns.txt rename to .ccw/workflows/cli-templates/prompts/analysis-analyze-code-patterns.txt diff --git a/.claude/workflows/cli-templates/prompts/analysis-analyze-performance.txt b/.ccw/workflows/cli-templates/prompts/analysis-analyze-performance.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/analysis-analyze-performance.txt rename to .ccw/workflows/cli-templates/prompts/analysis-analyze-performance.txt diff --git a/.claude/workflows/cli-templates/prompts/analysis-analyze-technical-document.txt b/.ccw/workflows/cli-templates/prompts/analysis-analyze-technical-document.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/analysis-analyze-technical-document.txt rename to .ccw/workflows/cli-templates/prompts/analysis-analyze-technical-document.txt diff --git a/.claude/workflows/cli-templates/prompts/analysis-assess-security-risks.txt b/.ccw/workflows/cli-templates/prompts/analysis-assess-security-risks.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/analysis-assess-security-risks.txt rename to .ccw/workflows/cli-templates/prompts/analysis-assess-security-risks.txt diff --git a/.claude/workflows/cli-templates/prompts/analysis-diagnose-bug-root-cause.txt b/.ccw/workflows/cli-templates/prompts/analysis-diagnose-bug-root-cause.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/analysis-diagnose-bug-root-cause.txt rename to .ccw/workflows/cli-templates/prompts/analysis-diagnose-bug-root-cause.txt diff --git a/.claude/workflows/cli-templates/prompts/analysis-review-architecture.txt b/.ccw/workflows/cli-templates/prompts/analysis-review-architecture.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/analysis-review-architecture.txt rename to .ccw/workflows/cli-templates/prompts/analysis-review-architecture.txt diff --git a/.claude/workflows/cli-templates/prompts/analysis-review-code-quality.txt b/.ccw/workflows/cli-templates/prompts/analysis-review-code-quality.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/analysis-review-code-quality.txt rename to .ccw/workflows/cli-templates/prompts/analysis-review-code-quality.txt diff --git a/.claude/workflows/cli-templates/prompts/analysis-review-quality-standards.txt b/.ccw/workflows/cli-templates/prompts/analysis-review-quality-standards.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/analysis-review-quality-standards.txt rename to .ccw/workflows/cli-templates/prompts/analysis-review-quality-standards.txt diff --git a/.claude/workflows/cli-templates/prompts/analysis-trace-code-execution.txt b/.ccw/workflows/cli-templates/prompts/analysis-trace-code-execution.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/analysis-trace-code-execution.txt rename to .ccw/workflows/cli-templates/prompts/analysis-trace-code-execution.txt diff --git a/.claude/workflows/cli-templates/prompts/development-debug-runtime-issues.txt b/.ccw/workflows/cli-templates/prompts/development-debug-runtime-issues.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/development-debug-runtime-issues.txt rename to .ccw/workflows/cli-templates/prompts/development-debug-runtime-issues.txt diff --git a/.claude/workflows/cli-templates/prompts/development-generate-tests.txt b/.ccw/workflows/cli-templates/prompts/development-generate-tests.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/development-generate-tests.txt rename to .ccw/workflows/cli-templates/prompts/development-generate-tests.txt diff --git a/.claude/workflows/cli-templates/prompts/development-implement-component-ui.txt b/.ccw/workflows/cli-templates/prompts/development-implement-component-ui.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/development-implement-component-ui.txt rename to .ccw/workflows/cli-templates/prompts/development-implement-component-ui.txt diff --git a/.claude/workflows/cli-templates/prompts/development-implement-feature.txt b/.ccw/workflows/cli-templates/prompts/development-implement-feature.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/development-implement-feature.txt rename to .ccw/workflows/cli-templates/prompts/development-implement-feature.txt diff --git a/.claude/workflows/cli-templates/prompts/development-refactor-codebase.txt b/.ccw/workflows/cli-templates/prompts/development-refactor-codebase.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/development-refactor-codebase.txt rename to .ccw/workflows/cli-templates/prompts/development-refactor-codebase.txt diff --git a/.claude/workflows/cli-templates/prompts/documentation-api.txt b/.ccw/workflows/cli-templates/prompts/documentation-api.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/documentation-api.txt rename to .ccw/workflows/cli-templates/prompts/documentation-api.txt diff --git a/.claude/workflows/cli-templates/prompts/documentation-folder-navigation.txt b/.ccw/workflows/cli-templates/prompts/documentation-folder-navigation.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/documentation-folder-navigation.txt rename to .ccw/workflows/cli-templates/prompts/documentation-folder-navigation.txt diff --git a/.claude/workflows/cli-templates/prompts/documentation-module-readme.txt b/.ccw/workflows/cli-templates/prompts/documentation-module-readme.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/documentation-module-readme.txt rename to .ccw/workflows/cli-templates/prompts/documentation-module-readme.txt diff --git a/.claude/workflows/cli-templates/prompts/documentation-project-architecture.txt b/.ccw/workflows/cli-templates/prompts/documentation-project-architecture.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/documentation-project-architecture.txt rename to .ccw/workflows/cli-templates/prompts/documentation-project-architecture.txt diff --git a/.claude/workflows/cli-templates/prompts/documentation-project-examples.txt b/.ccw/workflows/cli-templates/prompts/documentation-project-examples.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/documentation-project-examples.txt rename to .ccw/workflows/cli-templates/prompts/documentation-project-examples.txt diff --git a/.claude/workflows/cli-templates/prompts/documentation-project-readme.txt b/.ccw/workflows/cli-templates/prompts/documentation-project-readme.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/documentation-project-readme.txt rename to .ccw/workflows/cli-templates/prompts/documentation-project-readme.txt diff --git a/.claude/workflows/cli-templates/prompts/documentation-swagger-api.txt b/.ccw/workflows/cli-templates/prompts/documentation-swagger-api.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/documentation-swagger-api.txt rename to .ccw/workflows/cli-templates/prompts/documentation-swagger-api.txt diff --git a/.claude/workflows/cli-templates/prompts/memory-document-module-structure.txt b/.ccw/workflows/cli-templates/prompts/memory-document-module-structure.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/memory-document-module-structure.txt rename to .ccw/workflows/cli-templates/prompts/memory-document-module-structure.txt diff --git a/.claude/workflows/cli-templates/prompts/planning-breakdown-task-steps.txt b/.ccw/workflows/cli-templates/prompts/planning-breakdown-task-steps.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/planning-breakdown-task-steps.txt rename to .ccw/workflows/cli-templates/prompts/planning-breakdown-task-steps.txt diff --git a/.claude/workflows/cli-templates/prompts/planning-design-component-spec.txt b/.ccw/workflows/cli-templates/prompts/planning-design-component-spec.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/planning-design-component-spec.txt rename to .ccw/workflows/cli-templates/prompts/planning-design-component-spec.txt diff --git a/.claude/workflows/cli-templates/prompts/planning-evaluate-concept-feasibility.txt b/.ccw/workflows/cli-templates/prompts/planning-evaluate-concept-feasibility.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/planning-evaluate-concept-feasibility.txt rename to .ccw/workflows/cli-templates/prompts/planning-evaluate-concept-feasibility.txt diff --git a/.claude/workflows/cli-templates/prompts/planning-plan-architecture-design.txt b/.ccw/workflows/cli-templates/prompts/planning-plan-architecture-design.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/planning-plan-architecture-design.txt rename to .ccw/workflows/cli-templates/prompts/planning-plan-architecture-design.txt diff --git a/.claude/workflows/cli-templates/prompts/planning-plan-migration-strategy.txt b/.ccw/workflows/cli-templates/prompts/planning-plan-migration-strategy.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/planning-plan-migration-strategy.txt rename to .ccw/workflows/cli-templates/prompts/planning-plan-migration-strategy.txt diff --git a/.claude/workflows/cli-templates/prompts/rules-rule-api.txt b/.ccw/workflows/cli-templates/prompts/rules-rule-api.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/rules-rule-api.txt rename to .ccw/workflows/cli-templates/prompts/rules-rule-api.txt diff --git a/.claude/workflows/cli-templates/prompts/rules-rule-components.txt b/.ccw/workflows/cli-templates/prompts/rules-rule-components.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/rules-rule-components.txt rename to .ccw/workflows/cli-templates/prompts/rules-rule-components.txt diff --git a/.claude/workflows/cli-templates/prompts/rules-rule-config.txt b/.ccw/workflows/cli-templates/prompts/rules-rule-config.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/rules-rule-config.txt rename to .ccw/workflows/cli-templates/prompts/rules-rule-config.txt diff --git a/.claude/workflows/cli-templates/prompts/rules-rule-core.txt b/.ccw/workflows/cli-templates/prompts/rules-rule-core.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/rules-rule-core.txt rename to .ccw/workflows/cli-templates/prompts/rules-rule-core.txt diff --git a/.claude/workflows/cli-templates/prompts/rules-rule-patterns.txt b/.ccw/workflows/cli-templates/prompts/rules-rule-patterns.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/rules-rule-patterns.txt rename to .ccw/workflows/cli-templates/prompts/rules-rule-patterns.txt diff --git a/.claude/workflows/cli-templates/prompts/rules-rule-testing.txt b/.ccw/workflows/cli-templates/prompts/rules-rule-testing.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/rules-rule-testing.txt rename to .ccw/workflows/cli-templates/prompts/rules-rule-testing.txt diff --git a/.claude/workflows/cli-templates/prompts/rules-tech-rules-agent-prompt.txt b/.ccw/workflows/cli-templates/prompts/rules-tech-rules-agent-prompt.txt similarity index 84% rename from .claude/workflows/cli-templates/prompts/rules-tech-rules-agent-prompt.txt rename to .ccw/workflows/cli-templates/prompts/rules-tech-rules-agent-prompt.txt index c8952e8e..2dfaab34 100644 --- a/.claude/workflows/cli-templates/prompts/rules-tech-rules-agent-prompt.txt +++ b/.ccw/workflows/cli-templates/prompts/rules-tech-rules-agent-prompt.txt @@ -33,12 +33,12 @@ mcp__exa__get_code_context_exa(query: "{PRIMARY_LANG} {component} integration pa Read each template file before generating content: ``` -Read(~/.claude/workflows/cli-templates/prompts/rules/rule-core.txt) -Read(~/.claude/workflows/cli-templates/prompts/rules/rule-patterns.txt) -Read(~/.claude/workflows/cli-templates/prompts/rules/rule-testing.txt) -Read(~/.claude/workflows/cli-templates/prompts/rules/rule-config.txt) -Read(~/.claude/workflows/cli-templates/prompts/rules/rule-api.txt) # Only if backend/fullstack -Read(~/.claude/workflows/cli-templates/prompts/rules/rule-components.txt) # Only if frontend/fullstack +Read(~/.ccw/workflows/cli-templates/prompts/rules/rule-core.txt) +Read(~/.ccw/workflows/cli-templates/prompts/rules/rule-patterns.txt) +Read(~/.ccw/workflows/cli-templates/prompts/rules/rule-testing.txt) +Read(~/.ccw/workflows/cli-templates/prompts/rules/rule-config.txt) +Read(~/.ccw/workflows/cli-templates/prompts/rules/rule-api.txt) # Only if backend/fullstack +Read(~/.ccw/workflows/cli-templates/prompts/rules/rule-components.txt) # Only if frontend/fullstack ``` ### Step 3: Generate Rule Files diff --git a/.claude/workflows/cli-templates/prompts/tech-tech-module-format.txt b/.ccw/workflows/cli-templates/prompts/tech-tech-module-format.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/tech-tech-module-format.txt rename to .ccw/workflows/cli-templates/prompts/tech-tech-module-format.txt diff --git a/.claude/workflows/cli-templates/prompts/tech-tech-skill-index.txt b/.ccw/workflows/cli-templates/prompts/tech-tech-skill-index.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/tech-tech-skill-index.txt rename to .ccw/workflows/cli-templates/prompts/tech-tech-skill-index.txt diff --git a/.claude/workflows/cli-templates/prompts/test-suggestions-enhancement.txt b/.ccw/workflows/cli-templates/prompts/test-suggestions-enhancement.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/test-suggestions-enhancement.txt rename to .ccw/workflows/cli-templates/prompts/test-suggestions-enhancement.txt diff --git a/.claude/workflows/cli-templates/prompts/test-test-concept-analysis.txt b/.ccw/workflows/cli-templates/prompts/test-test-concept-analysis.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/test-test-concept-analysis.txt rename to .ccw/workflows/cli-templates/prompts/test-test-concept-analysis.txt diff --git a/.claude/workflows/cli-templates/prompts/universal-universal-creative-style.txt b/.ccw/workflows/cli-templates/prompts/universal-universal-creative-style.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/universal-universal-creative-style.txt rename to .ccw/workflows/cli-templates/prompts/universal-universal-creative-style.txt diff --git a/.claude/workflows/cli-templates/prompts/universal-universal-rigorous-style.txt b/.ccw/workflows/cli-templates/prompts/universal-universal-rigorous-style.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/universal-universal-rigorous-style.txt rename to .ccw/workflows/cli-templates/prompts/universal-universal-rigorous-style.txt diff --git a/.claude/workflows/cli-templates/prompts/verification-codex-technical.txt b/.ccw/workflows/cli-templates/prompts/verification-codex-technical.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/verification-codex-technical.txt rename to .ccw/workflows/cli-templates/prompts/verification-codex-technical.txt diff --git a/.claude/workflows/cli-templates/prompts/verification-cross-validation.txt b/.ccw/workflows/cli-templates/prompts/verification-cross-validation.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/verification-cross-validation.txt rename to .ccw/workflows/cli-templates/prompts/verification-cross-validation.txt diff --git a/.claude/workflows/cli-templates/prompts/verification-gemini-strategic.txt b/.ccw/workflows/cli-templates/prompts/verification-gemini-strategic.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/verification-gemini-strategic.txt rename to .ccw/workflows/cli-templates/prompts/verification-gemini-strategic.txt diff --git a/.claude/workflows/cli-templates/prompts/workflow-analysis-results-structure.txt b/.ccw/workflows/cli-templates/prompts/workflow-analysis-results-structure.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/workflow-analysis-results-structure.txt rename to .ccw/workflows/cli-templates/prompts/workflow-analysis-results-structure.txt diff --git a/.claude/workflows/cli-templates/prompts/workflow-codex-feasibility-validation.txt b/.ccw/workflows/cli-templates/prompts/workflow-codex-feasibility-validation.txt similarity index 98% rename from .claude/workflows/cli-templates/prompts/workflow-codex-feasibility-validation.txt rename to .ccw/workflows/cli-templates/prompts/workflow-codex-feasibility-validation.txt index 3b8cade8..2875b101 100644 --- a/.claude/workflows/cli-templates/prompts/workflow-codex-feasibility-validation.txt +++ b/.ccw/workflows/cli-templates/prompts/workflow-codex-feasibility-validation.txt @@ -95,7 +95,7 @@ Review Gemini's proposed code targets: ### Output File **Path**: `.workflow/active/{session_id}/.process/codex-feasibility-validation.md` -**Format**: Follow structure from `~/.claude/workflows/cli-templates/prompts/workflow/analysis-results-structure.txt` +**Format**: Follow structure from `~/.ccw/workflows/cli-templates/prompts/workflow/analysis-results-structure.txt` ### Required Sections Focus on these sections from the template: diff --git a/.claude/workflows/cli-templates/prompts/workflow-gemini-solution-design.txt b/.ccw/workflows/cli-templates/prompts/workflow-gemini-solution-design.txt similarity index 97% rename from .claude/workflows/cli-templates/prompts/workflow-gemini-solution-design.txt rename to .ccw/workflows/cli-templates/prompts/workflow-gemini-solution-design.txt index 032d6cb1..739bb1e1 100644 --- a/.claude/workflows/cli-templates/prompts/workflow-gemini-solution-design.txt +++ b/.ccw/workflows/cli-templates/prompts/workflow-gemini-solution-design.txt @@ -74,7 +74,7 @@ For each target: ### Output File **Path**: `.workflow/active/{session_id}/.process/gemini-solution-design.md` -**Format**: Follow structure from `~/.claude/workflows/cli-templates/prompts/workflow/analysis-results-structure.txt` +**Format**: Follow structure from `~/.ccw/workflows/cli-templates/prompts/workflow/analysis-results-structure.txt` ### Required Sections - Executive Summary with feasibility score diff --git a/.claude/workflows/cli-templates/prompts/workflow-impl-plan-template.txt b/.ccw/workflows/cli-templates/prompts/workflow-impl-plan-template.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/workflow-impl-plan-template.txt rename to .ccw/workflows/cli-templates/prompts/workflow-impl-plan-template.txt diff --git a/.claude/workflows/cli-templates/prompts/workflow-skill-aggregation.txt b/.ccw/workflows/cli-templates/prompts/workflow-skill-aggregation.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/workflow-skill-aggregation.txt rename to .ccw/workflows/cli-templates/prompts/workflow-skill-aggregation.txt diff --git a/.claude/workflows/cli-templates/prompts/workflow-skill-conflict-patterns.txt b/.ccw/workflows/cli-templates/prompts/workflow-skill-conflict-patterns.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/workflow-skill-conflict-patterns.txt rename to .ccw/workflows/cli-templates/prompts/workflow-skill-conflict-patterns.txt diff --git a/.claude/workflows/cli-templates/prompts/workflow-skill-index.txt b/.ccw/workflows/cli-templates/prompts/workflow-skill-index.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/workflow-skill-index.txt rename to .ccw/workflows/cli-templates/prompts/workflow-skill-index.txt diff --git a/.claude/workflows/cli-templates/prompts/workflow-skill-lessons-learned.txt b/.ccw/workflows/cli-templates/prompts/workflow-skill-lessons-learned.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/workflow-skill-lessons-learned.txt rename to .ccw/workflows/cli-templates/prompts/workflow-skill-lessons-learned.txt diff --git a/.claude/workflows/cli-templates/prompts/workflow-skill-sessions-timeline.txt b/.ccw/workflows/cli-templates/prompts/workflow-skill-sessions-timeline.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/workflow-skill-sessions-timeline.txt rename to .ccw/workflows/cli-templates/prompts/workflow-skill-sessions-timeline.txt diff --git a/.claude/workflows/cli-templates/prompts/workflow-task-json-agent-mode.txt b/.ccw/workflows/cli-templates/prompts/workflow-task-json-agent-mode.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/workflow-task-json-agent-mode.txt rename to .ccw/workflows/cli-templates/prompts/workflow-task-json-agent-mode.txt diff --git a/.claude/workflows/cli-templates/prompts/workflow-task-json-cli-mode.txt b/.ccw/workflows/cli-templates/prompts/workflow-task-json-cli-mode.txt similarity index 100% rename from .claude/workflows/cli-templates/prompts/workflow-task-json-cli-mode.txt rename to .ccw/workflows/cli-templates/prompts/workflow-task-json-cli-mode.txt diff --git a/.claude/workflows/cli-templates/protocols/analysis-protocol.md b/.ccw/workflows/cli-templates/protocols/analysis-protocol.md similarity index 100% rename from .claude/workflows/cli-templates/protocols/analysis-protocol.md rename to .ccw/workflows/cli-templates/protocols/analysis-protocol.md diff --git a/.claude/workflows/cli-templates/protocols/write-protocol.md b/.ccw/workflows/cli-templates/protocols/write-protocol.md similarity index 100% rename from .claude/workflows/cli-templates/protocols/write-protocol.md rename to .ccw/workflows/cli-templates/protocols/write-protocol.md diff --git a/.claude/workflows/cli-templates/schemas/conflict-resolution-schema.json b/.ccw/workflows/cli-templates/schemas/conflict-resolution-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/conflict-resolution-schema.json rename to .ccw/workflows/cli-templates/schemas/conflict-resolution-schema.json diff --git a/.claude/workflows/cli-templates/schemas/debug-log-json-schema.json b/.ccw/workflows/cli-templates/schemas/debug-log-json-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/debug-log-json-schema.json rename to .ccw/workflows/cli-templates/schemas/debug-log-json-schema.json diff --git a/.claude/workflows/cli-templates/schemas/diagnosis-json-schema.json b/.ccw/workflows/cli-templates/schemas/diagnosis-json-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/diagnosis-json-schema.json rename to .ccw/workflows/cli-templates/schemas/diagnosis-json-schema.json diff --git a/.claude/workflows/cli-templates/schemas/discovery-finding-schema.json b/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/discovery-finding-schema.json rename to .ccw/workflows/cli-templates/schemas/discovery-finding-schema.json diff --git a/.claude/workflows/cli-templates/schemas/discovery-state-schema.json b/.ccw/workflows/cli-templates/schemas/discovery-state-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/discovery-state-schema.json rename to .ccw/workflows/cli-templates/schemas/discovery-state-schema.json diff --git a/.claude/workflows/cli-templates/schemas/explore-json-schema.json b/.ccw/workflows/cli-templates/schemas/explore-json-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/explore-json-schema.json rename to .ccw/workflows/cli-templates/schemas/explore-json-schema.json diff --git a/.claude/workflows/cli-templates/schemas/fix-plan-json-schema.json b/.ccw/workflows/cli-templates/schemas/fix-plan-json-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/fix-plan-json-schema.json rename to .ccw/workflows/cli-templates/schemas/fix-plan-json-schema.json diff --git a/.claude/workflows/cli-templates/schemas/issues-jsonl-schema.json b/.ccw/workflows/cli-templates/schemas/issues-jsonl-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/issues-jsonl-schema.json rename to .ccw/workflows/cli-templates/schemas/issues-jsonl-schema.json diff --git a/.claude/workflows/cli-templates/schemas/multi-cli-discussion-schema.json b/.ccw/workflows/cli-templates/schemas/multi-cli-discussion-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/multi-cli-discussion-schema.json rename to .ccw/workflows/cli-templates/schemas/multi-cli-discussion-schema.json diff --git a/.claude/workflows/cli-templates/schemas/plan-json-schema.json b/.ccw/workflows/cli-templates/schemas/plan-json-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/plan-json-schema.json rename to .ccw/workflows/cli-templates/schemas/plan-json-schema.json diff --git a/.claude/workflows/cli-templates/schemas/plan-verify-agent-schema.json b/.ccw/workflows/cli-templates/schemas/plan-verify-agent-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/plan-verify-agent-schema.json rename to .ccw/workflows/cli-templates/schemas/plan-verify-agent-schema.json diff --git a/.claude/workflows/cli-templates/schemas/project-guidelines-schema.json b/.ccw/workflows/cli-templates/schemas/project-guidelines-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/project-guidelines-schema.json rename to .ccw/workflows/cli-templates/schemas/project-guidelines-schema.json diff --git a/.claude/workflows/cli-templates/schemas/project-tech-schema.json b/.ccw/workflows/cli-templates/schemas/project-tech-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/project-tech-schema.json rename to .ccw/workflows/cli-templates/schemas/project-tech-schema.json diff --git a/.claude/workflows/cli-templates/schemas/queue-schema.json b/.ccw/workflows/cli-templates/schemas/queue-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/queue-schema.json rename to .ccw/workflows/cli-templates/schemas/queue-schema.json diff --git a/.claude/workflows/cli-templates/schemas/registry-schema.json b/.ccw/workflows/cli-templates/schemas/registry-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/registry-schema.json rename to .ccw/workflows/cli-templates/schemas/registry-schema.json diff --git a/.claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json b/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json rename to .ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json diff --git a/.claude/workflows/cli-templates/schemas/review-dimension-results-schema.json b/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/review-dimension-results-schema.json rename to .ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json diff --git a/.claude/workflows/cli-templates/schemas/solution-schema.json b/.ccw/workflows/cli-templates/schemas/solution-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/solution-schema.json rename to .ccw/workflows/cli-templates/schemas/solution-schema.json diff --git a/.claude/workflows/cli-templates/schemas/verify-json-schema.json b/.ccw/workflows/cli-templates/schemas/verify-json-schema.json similarity index 100% rename from .claude/workflows/cli-templates/schemas/verify-json-schema.json rename to .ccw/workflows/cli-templates/schemas/verify-json-schema.json diff --git a/.claude/workflows/cli-templates/tech-stacks/go-dev.md b/.ccw/workflows/cli-templates/tech-stacks/go-dev.md similarity index 100% rename from .claude/workflows/cli-templates/tech-stacks/go-dev.md rename to .ccw/workflows/cli-templates/tech-stacks/go-dev.md diff --git a/.claude/workflows/cli-templates/tech-stacks/java-dev.md b/.ccw/workflows/cli-templates/tech-stacks/java-dev.md similarity index 100% rename from .claude/workflows/cli-templates/tech-stacks/java-dev.md rename to .ccw/workflows/cli-templates/tech-stacks/java-dev.md diff --git a/.claude/workflows/cli-templates/tech-stacks/javascript-dev.md b/.ccw/workflows/cli-templates/tech-stacks/javascript-dev.md similarity index 100% rename from .claude/workflows/cli-templates/tech-stacks/javascript-dev.md rename to .ccw/workflows/cli-templates/tech-stacks/javascript-dev.md diff --git a/.claude/workflows/cli-templates/tech-stacks/python-dev.md b/.ccw/workflows/cli-templates/tech-stacks/python-dev.md similarity index 100% rename from .claude/workflows/cli-templates/tech-stacks/python-dev.md rename to .ccw/workflows/cli-templates/tech-stacks/python-dev.md diff --git a/.claude/workflows/cli-templates/tech-stacks/react-dev.md b/.ccw/workflows/cli-templates/tech-stacks/react-dev.md similarity index 100% rename from .claude/workflows/cli-templates/tech-stacks/react-dev.md rename to .ccw/workflows/cli-templates/tech-stacks/react-dev.md diff --git a/.claude/workflows/cli-templates/tech-stacks/typescript-dev.md b/.ccw/workflows/cli-templates/tech-stacks/typescript-dev.md similarity index 100% rename from .claude/workflows/cli-templates/tech-stacks/typescript-dev.md rename to .ccw/workflows/cli-templates/tech-stacks/typescript-dev.md diff --git a/.claude/workflows/cli-templates/ui-design/systems/animation-tokens.json b/.ccw/workflows/cli-templates/ui-design/systems/animation-tokens.json similarity index 100% rename from .claude/workflows/cli-templates/ui-design/systems/animation-tokens.json rename to .ccw/workflows/cli-templates/ui-design/systems/animation-tokens.json diff --git a/.claude/workflows/cli-templates/ui-design/systems/design-tokens.json b/.ccw/workflows/cli-templates/ui-design/systems/design-tokens.json similarity index 100% rename from .claude/workflows/cli-templates/ui-design/systems/design-tokens.json rename to .ccw/workflows/cli-templates/ui-design/systems/design-tokens.json diff --git a/.claude/workflows/cli-templates/ui-design/systems/layout-templates.json b/.ccw/workflows/cli-templates/ui-design/systems/layout-templates.json similarity index 100% rename from .claude/workflows/cli-templates/ui-design/systems/layout-templates.json rename to .ccw/workflows/cli-templates/ui-design/systems/layout-templates.json diff --git a/.claude/workflows/cli-tools-usage.md b/.ccw/workflows/cli-tools-usage.md similarity index 100% rename from .claude/workflows/cli-tools-usage.md rename to .ccw/workflows/cli-tools-usage.md diff --git a/.claude/workflows/coding-philosophy.md b/.ccw/workflows/coding-philosophy.md similarity index 100% rename from .claude/workflows/coding-philosophy.md rename to .ccw/workflows/coding-philosophy.md diff --git a/.claude/workflows/context-tools.md b/.ccw/workflows/context-tools.md similarity index 100% rename from .claude/workflows/context-tools.md rename to .ccw/workflows/context-tools.md diff --git a/.claude/workflows/file-modification.md b/.ccw/workflows/file-modification.md similarity index 100% rename from .claude/workflows/file-modification.md rename to .ccw/workflows/file-modification.md diff --git a/.claude/workflows/review-directory-specification.md b/.ccw/workflows/review-directory-specification.md similarity index 100% rename from .claude/workflows/review-directory-specification.md rename to .ccw/workflows/review-directory-specification.md diff --git a/.claude/workflows/task-core.md b/.ccw/workflows/task-core.md similarity index 100% rename from .claude/workflows/task-core.md rename to .ccw/workflows/task-core.md diff --git a/.claude/workflows/test-quality-config.json b/.ccw/workflows/test-quality-config.json similarity index 100% rename from .claude/workflows/test-quality-config.json rename to .ccw/workflows/test-quality-config.json diff --git a/.claude/workflows/tool-strategy.md b/.ccw/workflows/tool-strategy.md similarity index 100% rename from .claude/workflows/tool-strategy.md rename to .ccw/workflows/tool-strategy.md diff --git a/.claude/workflows/windows-platform.md b/.ccw/workflows/windows-platform.md similarity index 100% rename from .claude/workflows/windows-platform.md rename to .ccw/workflows/windows-platform.md diff --git a/.claude/workflows/workflow-architecture.md b/.ccw/workflows/workflow-architecture.md similarity index 99% rename from .claude/workflows/workflow-architecture.md rename to .ccw/workflows/workflow-architecture.md index 12842c87..8ddb4d5c 100644 --- a/.claude/workflows/workflow-architecture.md +++ b/.ccw/workflows/workflow-architecture.md @@ -306,7 +306,7 @@ The `[FLOW_CONTROL]` marker indicates that a task or prompt contains flow contro 2. **load_role_template** - Action: Load role-specific planning template - - Command: bash($(cat "~/.claude/workflows/cli-templates/planning-roles/{role}.md")) + - Command: bash($(cat "~/.ccw/workflows/cli-templates/planning-roles/{role}.md")) - Output: role_template 3. **load_session_metadata** diff --git a/.claude/CLAUDE.md b/.claude/CLAUDE.md index 5ce4309e..6a9269cc 100644 --- a/.claude/CLAUDE.md +++ b/.claude/CLAUDE.md @@ -1,10 +1,10 @@ # Claude Instructions -- **Coding Philosophy**: @~/.claude/workflows/coding-philosophy.md +- **Coding Philosophy**: @~/.ccw/workflows/coding-philosophy.md ## CLI Endpoints -- **CLI Tools Usage**: @~/.claude/workflows/cli-tools-usage.md +- **CLI Tools Usage**: @~/.ccw/workflows/cli-tools-usage.md - **CLI Endpoints Config**: @~/.claude/cli-tools.json **Strictly follow the cli-tools.json configuration** @@ -12,8 +12,8 @@ Available CLI endpoints are dynamically defined by the config file ## Tool Execution -- **Context Requirements**: @~/.claude/workflows/context-tools.md -- **File Modification**: @~/.claude/workflows/file-modification.md +- **Context Requirements**: @~/.ccw/workflows/context-tools.md +- **File Modification**: @~/.ccw/workflows/file-modification.md ### Agent Calls - **Always use `run_in_background: false`** for Task tool agent calls: `Task({ subagent_type: "xxx", prompt: "...", run_in_background: false })` to ensure synchronous execution and immediate result visibility diff --git a/.claude/agents/action-planning-agent.md b/.claude/agents/action-planning-agent.md index c0e7a907..28e51171 100644 --- a/.claude/agents/action-planning-agent.md +++ b/.claude/agents/action-planning-agent.md @@ -186,7 +186,7 @@ if (contextPackage.brainstorm_artifacts?.role_analyses?.length > 0) { - Add quantified requirements and measurable acceptance criteria 3. Create IMPL_PLAN.md - - Load template: Read(~/.claude/workflows/cli-templates/prompts/workflow/impl-plan-template.txt) + - Load template: Read(~/.ccw/workflows/cli-templates/prompts/workflow/impl-plan-template.txt) - Follow template structure and validation checklist - Populate all 8 sections with synthesized context - Document CCW workflow phase progression @@ -661,7 +661,7 @@ The `implementation_approach` defines sequential implementation steps. Execution **Template-Based Generation**: ``` -1. Load template: Read(~/.claude/workflows/cli-templates/prompts/workflow/impl-plan-template.txt) +1. Load template: Read(~/.ccw/workflows/cli-templates/prompts/workflow/impl-plan-template.txt) 2. Populate all sections following template structure 3. Complete template validation checklist 4. Generate at .workflow/active/{session_id}/IMPL_PLAN.md @@ -852,7 +852,7 @@ Use `analysis_results.complexity` or task count to determine structure: - **Record N+1 Context**: Update `## N+1 Context` section with key decisions and deferred items - **Search Tool Priority**: ACE (`mcp__ace-tool__search_context`) → CCW (`mcp__ccw-tools__smart_search`) / Built-in (`Grep`, `Glob`, `Read`) - Apply Quantification Requirements to all requirements, acceptance criteria, and modification points -- Load IMPL_PLAN template: `Read(~/.claude/workflows/cli-templates/prompts/workflow/impl-plan-template.txt)` before generating IMPL_PLAN.md +- Load IMPL_PLAN template: `Read(~/.ccw/workflows/cli-templates/prompts/workflow/impl-plan-template.txt)` before generating IMPL_PLAN.md - Use provided context package: Extract all information from structured context - Respect memory-first rule: Use provided content (already loaded from memory/file) - Follow 6-field schema: All task JSONs must have id, title, status, context_package_path, meta, context, flow_control diff --git a/.claude/agents/cli-execution-agent.md b/.claude/agents/cli-execution-agent.md index 2b100b60..4326c913 100644 --- a/.claude/agents/cli-execution-agent.md +++ b/.claude/agents/cli-execution-agent.md @@ -14,13 +14,13 @@ You are an intelligent CLI execution specialist that autonomously orchestrates c 2. **Qwen (Fallback)** - Same capabilities as Gemini, use when unavailable 3. **Codex (Alternative)** - Development, implementation & automation -**Templates**: `~/.claude/workflows/cli-templates/prompts/` +**Templates**: `~/.ccw/workflows/cli-templates/prompts/` - `analysis/` - pattern.txt, architecture.txt, code-execution-tracing.txt, security.txt, quality.txt - `development/` - feature.txt, refactor.txt, testing.txt, bug-diagnosis.txt - `planning/` - task-breakdown.txt, architecture-planning.txt - `memory/` - claude-module-unified.txt -**Reference**: See `~/.claude/workflows/intelligent-tools-strategy.md` for complete usage guide +**Reference**: See `~/.ccw/workflows/intelligent-tools-strategy.md` for complete usage guide ## 5-Phase Execution Workflow @@ -129,7 +129,7 @@ CONTEXT: @CLAUDE.md @src/**/* @*.ts CONTEXT: @**/* @../shared/**/* @../types/**/* ``` -**2. Template Selection** (`~/.claude/workflows/cli-templates/prompts/`): +**2. Template Selection** (`~/.ccw/workflows/cli-templates/prompts/`): ``` analyze → analysis/code-execution-tracing.txt | analysis/pattern.txt execute → development/feature.txt @@ -308,7 +308,7 @@ Codex unavailable → Gemini/Qwen write mode ## Templates Reference -**Location**: `~/.claude/workflows/cli-templates/prompts/` +**Location**: `~/.ccw/workflows/cli-templates/prompts/` **Analysis** (`analysis/`): - `pattern.txt` - Code pattern analysis diff --git a/.claude/agents/code-developer.md b/.claude/agents/code-developer.md index e6ffd58e..6b183de7 100644 --- a/.claude/agents/code-developer.md +++ b/.claude/agents/code-developer.md @@ -77,24 +77,24 @@ if [[ -n "$TASK_JSON_TECH_STACK" ]]; then # Map tech stack names to guideline files # e.g., ["FastAPI", "SQLAlchemy"] → python-dev.md case "$TASK_JSON_TECH_STACK" in - *FastAPI*|*Django*|*SQLAlchemy*) TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/python-dev.md) ;; - *React*|*Next*) TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/react-dev.md) ;; - *TypeScript*) TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/typescript-dev.md) ;; + *FastAPI*|*Django*|*SQLAlchemy*) TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/python-dev.md) ;; + *React*|*Next*) TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/react-dev.md) ;; + *TypeScript*) TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/typescript-dev.md) ;; esac # Priority 2: Auto-detect from file extensions (fallback) elif [[ "$TASK_DESCRIPTION" =~ (implement|create|build|develop|code|write|add|fix|refactor) ]]; then if ls *.ts *.tsx 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/typescript-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/typescript-dev.md) elif grep -q "react" package.json 2>/dev/null; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/react-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/react-dev.md) elif ls *.py requirements.txt 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/python-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/python-dev.md) elif ls *.java pom.xml build.gradle 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/java-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/java-dev.md) elif ls *.go go.mod 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/go-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/go-dev.md) elif ls *.js package.json 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/javascript-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/javascript-dev.md) fi fi ``` diff --git a/.claude/agents/conceptual-planning-agent.md b/.claude/agents/conceptual-planning-agent.md index 2a06e0a8..f50447f2 100644 --- a/.claude/agents/conceptual-planning-agent.md +++ b/.claude/agents/conceptual-planning-agent.md @@ -70,7 +70,7 @@ def handle_brainstorm_assignment(prompt): # Execute role template loading via $(cat template) if step_name == "load_role_template": - processed_command = f"bash($(cat ~/.claude/workflows/cli-templates/planning-roles/{role}.md))" + processed_command = f"bash($(cat ~/.ccw/workflows/cli-templates/planning-roles/{role}.md))" else: processed_command = process_context_variables(command, context_vars) @@ -106,7 +106,7 @@ This agent processes **simplified inline [FLOW_CONTROL]** format from brainstorm 2. **load_role_template** - Action: Load role-specific planning template - - Command: bash($(cat "~/.claude/workflows/cli-templates/planning-roles/{role}.md")) + - Command: bash($(cat "~/.ccw/workflows/cli-templates/planning-roles/{role}.md")) - Output: role_template 3. **load_session_metadata** @@ -165,7 +165,7 @@ When called, you receive: **Auto Brainstorm Integration**: Role assignment comes from auto.md workflow: 1. **Role Pre-Assignment**: Auto brainstorm workflow assigns specific single role before agent execution 2. **Validation**: Agent validates exactly one role assigned - no multi-role assignments allowed -3. **Template Loading**: Use `$(cat ~/.claude/workflows/cli-templates/planning-roles/.md)` for role template +3. **Template Loading**: Use `$(cat ~/.ccw/workflows/cli-templates/planning-roles/.md)` for role template 4. **Output Directory**: Use designated `.brainstorming/[role]/` directory for role-specific outputs ### Role Options Include: @@ -190,7 +190,7 @@ When called, you receive: ### Role Template Integration Documentation formats and structures are defined in role-specific templates loaded via: ```bash -$(cat ~/.claude/workflows/cli-templates/planning-roles/.md) +$(cat ~/.ccw/workflows/cli-templates/planning-roles/.md) ``` Each planning role template contains: diff --git a/.claude/agents/ui-design-agent.md b/.claude/agents/ui-design-agent.md index fbe8dabe..1a9e966d 100644 --- a/.claude/agents/ui-design-agent.md +++ b/.claude/agents/ui-design-agent.md @@ -320,7 +320,7 @@ You execute 6 distinct task types organized into 3 patterns. Each task includes ### design-tokens.json -**Template Reference**: `~/.claude/workflows/cli-templates/ui-design/systems/design-tokens.json` +**Template Reference**: `~/.ccw/workflows/cli-templates/ui-design/systems/design-tokens.json` **Format**: W3C Design Tokens Community Group Specification @@ -385,7 +385,7 @@ You execute 6 distinct task types organized into 3 patterns. Each task includes ### layout-templates.json -**Template Reference**: `~/.claude/workflows/cli-templates/ui-design/systems/layout-templates.json` +**Template Reference**: `~/.ccw/workflows/cli-templates/ui-design/systems/layout-templates.json` **Optimization**: Unified structure combining DOM and styling into single hierarchy @@ -426,7 +426,7 @@ You execute 6 distinct task types organized into 3 patterns. Each task includes ### animation-tokens.json -**Template Reference**: `~/.claude/workflows/cli-templates/ui-design/systems/animation-tokens.json` +**Template Reference**: `~/.ccw/workflows/cli-templates/ui-design/systems/animation-tokens.json` **Structure Overview**: - **duration**: instant (0ms), fast (150ms), normal (300ms), slow (500ms), slower (1000ms) diff --git a/.claude/commands/issue/discover-by-prompt.md b/.claude/commands/issue/discover-by-prompt.md index b1af0bd5..db1269f8 100644 --- a/.claude/commands/issue/discover-by-prompt.md +++ b/.claude/commands/issue/discover-by-prompt.md @@ -508,7 +508,7 @@ function buildDimensionPromptWithACE(dimension, iteration, previousFindings, ace ## MANDATORY FIRST STEPS 1. Read exploration plan: ${outputDir}/../exploration-plan.json - 2. Read schema: ~/.claude/workflows/cli-templates/schemas/discovery-finding-schema.json + 2. Read schema: ~/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json 3. Review ACE results above for starting points 4. Explore files identified by ACE diff --git a/.claude/commands/issue/discover.md b/.claude/commands/issue/discover.md index 68d83f9b..f0cfab7d 100644 --- a/.claude/commands/issue/discover.md +++ b/.claude/commands/issue/discover.md @@ -303,8 +303,8 @@ if (response === "Export to Issues") { | Schema | Path | Purpose | |--------|------|---------| -| **Discovery State** | `~/.claude/workflows/cli-templates/schemas/discovery-state-schema.json` | Session state machine | -| **Discovery Finding** | `~/.claude/workflows/cli-templates/schemas/discovery-finding-schema.json` | Perspective analysis results | +| **Discovery State** | `~/.ccw/workflows/cli-templates/schemas/discovery-state-schema.json` | Session state machine | +| **Discovery Finding** | `~/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json` | Perspective analysis results | ### Agent Invocation Template @@ -328,7 +328,7 @@ Task({ ## MANDATORY FIRST STEPS 1. Read discovery state: ${outputDir}/discovery-state.json - 2. Read schema: ~/.claude/workflows/cli-templates/schemas/discovery-finding-schema.json + 2. Read schema: ~/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json 3. Analyze target files for ${perspective} concerns ## Output Requirements diff --git a/.claude/commands/memory/docs-full-cli.md b/.claude/commands/memory/docs-full-cli.md index dbe494e3..c99f592f 100644 --- a/.claude/commands/memory/docs-full-cli.md +++ b/.claude/commands/memory/docs-full-cli.md @@ -459,7 +459,7 @@ Documentation Generation Summary: ## Template Reference -Templates used from `~/.claude/workflows/cli-templates/prompts/documentation/`: +Templates used from `~/.ccw/workflows/cli-templates/prompts/documentation/`: - `api.txt`: Code API documentation (Part A: Code API, Part B: HTTP API) - `module-readme.txt`: Module purpose, usage, dependencies - `folder-navigation.txt`: Navigation README for folders with subdirectories diff --git a/.claude/commands/memory/docs-related-cli.md b/.claude/commands/memory/docs-related-cli.md index 84c77ab4..3dcc61a9 100644 --- a/.claude/commands/memory/docs-related-cli.md +++ b/.claude/commands/memory/docs-related-cli.md @@ -374,7 +374,7 @@ Documentation Generation Summary: ## Template Reference -Templates used from `~/.claude/workflows/cli-templates/prompts/documentation/`: +Templates used from `~/.ccw/workflows/cli-templates/prompts/documentation/`: - `api.txt`: Code API documentation - `module-readme.txt`: Module purpose, usage, dependencies - `folder-navigation.txt`: Navigation README for folders diff --git a/.claude/commands/memory/style-skill-memory.md b/.claude/commands/memory/style-skill-memory.md index 0cae3998..eaa74ace 100644 --- a/.claude/commands/memory/style-skill-memory.md +++ b/.claude/commands/memory/style-skill-memory.md @@ -271,7 +271,7 @@ bash(mkdir -p .claude/skills/style-${package_name}) **⚠️ CRITICAL - Execute First**: ```bash -bash(cat ~/.claude/workflows/cli-templates/memory/style-skill-memory/skill-md-template.md) +bash(cat ~/.ccw/workflows/cli-templates/memory/style-skill-memory/skill-md-template.md) ``` **Template Processing**: @@ -355,7 +355,7 @@ Variables: `{package_name}`, `{component_count}`, `{universal_count}`, `{special 1. **Check Before Generate**: Verify package exists before attempting SKILL generation 2. **Respect Existing SKILL**: Don't overwrite unless --regenerate flag provided -3. **Load Templates via cat**: Use `cat ~/.claude/workflows/cli-templates/memory/style-skill-memory/{template}` to load templates +3. **Load Templates via cat**: Use `cat ~/.ccw/workflows/cli-templates/memory/style-skill-memory/{template}` to load templates 4. **Variable Substitution**: Replace all `{variable}` placeholders with actual values 5. **Technical Feature Detection**: Analyze tokens for modern features (oklch, calc, dark mode) and generate appropriate Prerequisites section 6. **Dynamic Content Generation**: Generate sections based on DESIGN_ANALYSIS characteristics diff --git a/.claude/commands/workflow/brainstorm/auto-parallel.md b/.claude/commands/workflow/brainstorm/auto-parallel.md index 98d57723..ab2dd117 100644 --- a/.claude/commands/workflow/brainstorm/auto-parallel.md +++ b/.claude/commands/workflow/brainstorm/auto-parallel.md @@ -430,4 +430,4 @@ CONTEXT_VARS: └── synthesis-specification.md # Integration (Phase 3) ``` -**Template Source**: `~/.claude/workflows/cli-templates/planning-roles/` +**Template Source**: `~/.ccw/workflows/cli-templates/planning-roles/` diff --git a/.claude/commands/workflow/brainstorm/role-analysis.md b/.claude/commands/workflow/brainstorm/role-analysis.md index debda864..ae44bdf7 100644 --- a/.claude/commands/workflow/brainstorm/role-analysis.md +++ b/.claude/commands/workflow/brainstorm/role-analysis.md @@ -123,63 +123,63 @@ const roleConfig = { focus_area: 'User research, information architecture, user journey', question_categories: ['User Intent', 'Requirements', 'UX'], question_count: 4, - template: '~/.claude/workflows/cli-templates/planning-roles/ux-expert.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/ux-expert.md' }, 'ui-designer': { title: 'UI设计师', focus_area: 'Visual design, high-fidelity mockups, design systems', question_categories: ['Requirements', 'UX', 'Feasibility'], question_count: 4, - template: '~/.claude/workflows/cli-templates/planning-roles/ui-designer.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/ui-designer.md' }, 'system-architect': { title: '系统架构师', focus_area: 'Technical architecture, scalability, integration patterns', question_categories: ['Scale & Performance', 'Technical Constraints', 'Architecture Complexity', 'Non-Functional Requirements'], question_count: 5, - template: '~/.claude/workflows/cli-templates/planning-roles/system-architect.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/system-architect.md' }, 'product-manager': { title: '产品经理', focus_area: 'Product strategy, roadmap, prioritization', question_categories: ['User Intent', 'Requirements', 'Process'], question_count: 4, - template: '~/.claude/workflows/cli-templates/planning-roles/product-manager.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/product-manager.md' }, 'product-owner': { title: '产品负责人', focus_area: 'Backlog management, user stories, acceptance criteria', question_categories: ['Requirements', 'Decisions', 'Process'], question_count: 4, - template: '~/.claude/workflows/cli-templates/planning-roles/product-owner.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/product-owner.md' }, 'scrum-master': { title: '敏捷教练', focus_area: 'Process facilitation, impediment removal, team dynamics', question_categories: ['Process', 'Risk', 'Decisions'], question_count: 3, - template: '~/.claude/workflows/cli-templates/planning-roles/scrum-master.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/scrum-master.md' }, 'subject-matter-expert': { title: '领域专家', focus_area: 'Domain knowledge, business rules, compliance', question_categories: ['Requirements', 'Feasibility', 'Terminology'], question_count: 4, - template: '~/.claude/workflows/cli-templates/planning-roles/subject-matter-expert.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/subject-matter-expert.md' }, 'data-architect': { title: '数据架构师', focus_area: 'Data models, storage strategies, data flow', question_categories: ['Architecture', 'Scale & Performance', 'Technical Constraints', 'Feasibility'], question_count: 5, - template: '~/.claude/workflows/cli-templates/planning-roles/data-architect.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/data-architect.md' }, 'api-designer': { title: 'API设计师', focus_area: 'API contracts, versioning, integration patterns', question_categories: ['Architecture', 'Requirements', 'Feasibility', 'Decisions'], question_count: 4, - template: '~/.claude/workflows/cli-templates/planning-roles/api-designer.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/api-designer.md' } }; @@ -690,7 +690,7 @@ Action: Retry with --skip-questions or check framework validity ## 📚 **Reference Information** ### Role Template Locations -- Templates: `~/.claude/workflows/cli-templates/planning-roles/` +- Templates: `~/.ccw/workflows/cli-templates/planning-roles/` - Format: `{role-name}.md` (e.g., `ux-expert.md`, `system-architect.md`) ### Related Commands diff --git a/.claude/commands/workflow/collaborative-plan-with-file.md b/.claude/commands/workflow/collaborative-plan-with-file.md index 03a2989b..03bdab9a 100644 --- a/.claude/commands/workflow/collaborative-plan-with-file.md +++ b/.claude/commands/workflow/collaborative-plan-with-file.md @@ -349,7 +349,7 @@ subDomains.map(sub => ### Task 1: Generate Complete plan.json Output: ${sessionFolder}/agents/${sub.focus_area}/plan.json -Schema: ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json +Schema: ~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json ### Task 2: Sync Summary to plan-note.md diff --git a/.claude/commands/workflow/init.md b/.claude/commands/workflow/init.md index 78133ee2..0334c6a4 100644 --- a/.claude/commands/workflow/init.md +++ b/.claude/commands/workflow/init.md @@ -109,7 +109,7 @@ Task( Analyze project for workflow initialization and generate .workflow/project-tech.json. ## MANDATORY FIRST STEPS -1. Execute: cat ~/.claude/workflows/cli-templates/schemas/project-tech-schema.json (get schema reference) +1. Execute: cat ~/.ccw/workflows/cli-templates/schemas/project-tech-schema.json (get schema reference) 2. Execute: ccw tool exec get_modules_by_depth '{}' (get project structure) ## Task diff --git a/.claude/commands/workflow/lite-fix.md b/.claude/commands/workflow/lite-fix.md index 95a86d05..d0188034 100644 --- a/.claude/commands/workflow/lite-fix.md +++ b/.claude/commands/workflow/lite-fix.md @@ -52,7 +52,7 @@ Intelligent lightweight bug fixing command with dynamic workflow adaptation base - Low/Medium severity → Direct Claude planning (no agent) - High/Critical severity → `cli-lite-planning-agent` generates `fix-plan.json` -**Schema Reference**: `~/.claude/workflows/cli-templates/schemas/fix-plan-json-schema.json` +**Schema Reference**: `~/.ccw/workflows/cli-templates/schemas/fix-plan-json-schema.json` ## Auto Mode Defaults @@ -91,7 +91,7 @@ Phase 2: Clarification (optional, multi-round) Phase 3: Fix Planning (NO CODE EXECUTION - planning only) +- Decision (based on Phase 1 severity): - |- Low/Medium -> Load schema: cat ~/.claude/workflows/cli-templates/schemas/fix-plan-json-schema.json -> Direct Claude planning (following schema) -> fix-plan.json -> MUST proceed to Phase 4 + |- Low/Medium -> Load schema: cat ~/.ccw/workflows/cli-templates/schemas/fix-plan-json-schema.json -> Direct Claude planning (following schema) -> fix-plan.json -> MUST proceed to Phase 4 +- High/Critical -> cli-lite-planning-agent -> fix-plan.json -> MUST proceed to Phase 4 Phase 4: Confirmation & Selection @@ -223,7 +223,7 @@ Execute **${angle}** diagnosis for bug root cause analysis. Analyze codebase fro **You (cli-explore-agent) MUST execute these steps in order:** 1. Run: ccw tool exec get_modules_by_depth '{}' (project structure) 2. Run: rg -l "{error_keyword_from_bug}" --type ts (locate relevant files) -3. Execute: cat ~/.claude/workflows/cli-templates/schemas/diagnosis-json-schema.json (get output schema reference) +3. Execute: cat ~/.ccw/workflows/cli-templates/schemas/diagnosis-json-schema.json (get output schema reference) 4. Read: .workflow/project-tech.json (technology stack and architecture context) 5. Read: .workflow/project-guidelines.json (user-defined constraints and conventions) @@ -426,7 +426,7 @@ if (autoYes) { **Low/Medium Severity** - Direct planning by Claude: ```javascript // Step 1: Read schema -const schema = Bash(`cat ~/.claude/workflows/cli-templates/schemas/fix-plan-json-schema.json`) +const schema = Bash(`cat ~/.ccw/workflows/cli-templates/schemas/fix-plan-json-schema.json`) // Step 2: Generate fix-plan following schema (Claude directly, no agent) // For Medium complexity: include rationale + verification (optional, but recommended) @@ -520,7 +520,7 @@ Generate fix plan and write fix-plan.json. - ${sessionFolder}/fix-plan.json (fix plan) ## Output Schema Reference -Execute: cat ~/.claude/workflows/cli-templates/schemas/fix-plan-json-schema.json (get schema reference before generating plan) +Execute: cat ~/.ccw/workflows/cli-templates/schemas/fix-plan-json-schema.json (get schema reference before generating plan) ## Project Context (MANDATORY - Read Both Files) 1. Read: .workflow/project-tech.json (technology stack, architecture, key components) diff --git a/.claude/commands/workflow/lite-plan.md b/.claude/commands/workflow/lite-plan.md index d85c4240..0fa6fdf3 100644 --- a/.claude/commands/workflow/lite-plan.md +++ b/.claude/commands/workflow/lite-plan.md @@ -52,7 +52,7 @@ Intelligent lightweight planning command with dynamic workflow adaptation based - Low complexity → Direct Claude planning (no agent) - Medium/High complexity → `cli-lite-planning-agent` generates `plan.json` -**Schema Reference**: `~/.claude/workflows/cli-templates/schemas/plan-json-schema.json` +**Schema Reference**: `~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json` ## Auto Mode Defaults @@ -89,7 +89,7 @@ Phase 2: Clarification (optional, multi-round) Phase 3: Planning (NO CODE EXECUTION - planning only) └─ Decision (based on Phase 1 complexity): - ├─ Low → Load schema: cat ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json → Direct Claude planning (following schema) → plan.json + ├─ Low → Load schema: cat ~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json → Direct Claude planning (following schema) → plan.json └─ Medium/High → cli-lite-planning-agent → plan.json (agent internally executes quality check) Phase 4: Confirmation & Selection @@ -224,7 +224,7 @@ Execute **${angle}** exploration for task planning context. Analyze codebase fro **You (cli-explore-agent) MUST execute these steps in order:** 1. Run: ccw tool exec get_modules_by_depth '{}' (project structure) 2. Run: rg -l "{keyword_from_task}" --type ts (locate relevant files) -3. Execute: cat ~/.claude/workflows/cli-templates/schemas/explore-json-schema.json (get output schema reference) +3. Execute: cat ~/.ccw/workflows/cli-templates/schemas/explore-json-schema.json (get output schema reference) 4. Read: .workflow/project-tech.json (technology stack and architecture context) 5. Read: .workflow/project-guidelines.json (user-defined constraints and conventions) @@ -425,7 +425,7 @@ plan.tasks.forEach(task => { **Low Complexity** - Direct planning by Claude: ```javascript // Step 1: Read schema -const schema = Bash(`cat ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json`) +const schema = Bash(`cat ~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json`) // Step 2: ⚠️ MANDATORY - Read and review ALL exploration files const manifest = JSON.parse(Read(`${sessionFolder}/explorations-manifest.json`)) @@ -470,7 +470,7 @@ Generate implementation plan and write plan.json. - ${sessionFolder}/plan.json (implementation plan) ## Output Schema Reference -Execute: cat ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json (get schema reference before generating plan) +Execute: cat ~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json (get schema reference before generating plan) ## Project Context (MANDATORY - Read Both Files) 1. Read: .workflow/project-tech.json (technology stack, architecture, key components) diff --git a/.claude/commands/workflow/multi-cli-plan.md b/.claude/commands/workflow/multi-cli-plan.md index 42484b88..e4323d17 100644 --- a/.claude/commands/workflow/multi-cli-plan.md +++ b/.claude/commands/workflow/multi-cli-plan.md @@ -360,7 +360,7 @@ Task({ description: "Generate implementation plan", prompt: ` ## Schema Reference -Execute: cat ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json +Execute: cat ~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json ## Context-Package (from orchestrator) ${JSON.stringify(contextPackage, null, 2)} diff --git a/.claude/commands/workflow/plan-verify.md b/.claude/commands/workflow/plan-verify.md index 7f53b3eb..c08b2782 100644 --- a/.claude/commands/workflow/plan-verify.md +++ b/.claude/commands/workflow/plan-verify.md @@ -192,8 +192,8 @@ Task( ## Plan Verification Task ### MANDATORY FIRST STEPS -1. Read: ~/.claude/workflows/cli-templates/schemas/plan-verify-agent-schema.json (dimensions & rules) -2. Read: ~/.claude/workflows/cli-templates/schemas/verify-json-schema.json (output schema) +1. Read: ~/.ccw/workflows/cli-templates/schemas/plan-verify-agent-schema.json (dimensions & rules) +2. Read: ~/.ccw/workflows/cli-templates/schemas/verify-json-schema.json (output schema) 3. Read: ${session_file} (user intent) 4. Read: ${PLANNING_NOTES} (constraints & N+1 context) 5. Read: ${IMPL_PLAN} (implementation plan) diff --git a/.claude/commands/workflow/review-module-cycle.md b/.claude/commands/workflow/review-module-cycle.md index 7da3deb1..8748487a 100644 --- a/.claude/commands/workflow/review-module-cycle.md +++ b/.claude/commands/workflow/review-module-cycle.md @@ -375,12 +375,12 @@ done **Agent-produced JSON files follow standardized schemas**: 1. **Dimension Results** (cli-explore-agent output from parallel reviews) - - Schema: `~/.claude/workflows/cli-templates/schemas/review-dimension-results-schema.json` + - Schema: `~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json` - Output: `{output-dir}/dimensions/{dimension}.json` - Contains: findings array, summary statistics, cross_references 2. **Deep-Dive Results** (cli-explore-agent output from iterations) - - Schema: `~/.claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json` + - Schema: `~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json` - Output: `{output-dir}/iterations/iteration-{N}-finding-{uuid}.json` - Contains: root_cause, remediation_plan, impact_assessment, reassessed_severity @@ -408,7 +408,7 @@ Task( 1. Read review state: ${reviewStateJsonPath} 2. Get target files: Read resolved_files from review-state.json 3. Validate file access: bash(ls -la ${targetFiles.join(' ')}) - 4. Execute: cat ~/.claude/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) + 4. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) 5. Read: .workflow/project-tech.json (technology stack and architecture context) 6. Read: .workflow/project-guidelines.json (user-defined constraints and conventions to validate against) @@ -512,13 +512,13 @@ Task( 2. Read affected file: ${file} 3. Identify related code: bash(grep -r "import.*${basename(file)}" ${projectDir}/src --include="*.ts") 4. Read test files: bash(find ${projectDir}/tests -name "*${basename(file, '.ts')}*" -type f) - 5. Execute: cat ~/.claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) + 5. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) 6. Read: .workflow/project-tech.json (technology stack and architecture context) 7. Read: .workflow/project-guidelines.json (user-defined constraints for remediation compliance) ## CLI Configuration - Tool Priority: gemini → qwen → codex - - Template: ~/.claude/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt + - Template: ~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt - Mode: analysis (READ-ONLY) ## Expected Deliverables diff --git a/.claude/commands/workflow/review-session-cycle.md b/.claude/commands/workflow/review-session-cycle.md index 73e26af7..25003d94 100644 --- a/.claude/commands/workflow/review-session-cycle.md +++ b/.claude/commands/workflow/review-session-cycle.md @@ -385,12 +385,12 @@ git log --since="${sessionCreatedAt}" --name-only --pretty=format: | sort -u **Agent-produced JSON files follow standardized schemas**: 1. **Dimension Results** (cli-explore-agent output from parallel reviews) - - Schema: `~/.claude/workflows/cli-templates/schemas/review-dimension-results-schema.json` + - Schema: `~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json` - Output: `.review-cycle/dimensions/{dimension}.json` - Contains: findings array, summary statistics, cross_references 2. **Deep-Dive Results** (cli-explore-agent output from iterations) - - Schema: `~/.claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json` + - Schema: `~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json` - Output: `.review-cycle/iterations/iteration-{N}-finding-{uuid}.json` - Contains: root_cause, remediation_plan, impact_assessment, reassessed_severity @@ -419,7 +419,7 @@ Task( 2. Read completed task summaries: bash(find ${summariesDir} -name "IMPL-*.md" -type f) 3. Get changed files: bash(cd ${workflowDir} && git log --since="${sessionCreatedAt}" --name-only --pretty=format: | sort -u) 4. Read review state: ${reviewStateJsonPath} - 5. Execute: cat ~/.claude/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) + 5. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) 6. Read: .workflow/project-tech.json (technology stack and architecture context) 7. Read: .workflow/project-guidelines.json (user-defined constraints and conventions to validate against) @@ -432,7 +432,7 @@ Task( ## CLI Configuration - Tool Priority: gemini → qwen → codex (fallback chain) - - Template: ~/.claude/workflows/cli-templates/prompts/analysis/${dimensionTemplate} + - Template: ~/.ccw/workflows/cli-templates/prompts/analysis/${dimensionTemplate} - Custom Focus: ${customFocus || 'Standard dimension analysis'} - Timeout: ${timeout}ms - Mode: analysis (READ-ONLY) @@ -523,13 +523,13 @@ Task( 2. Read affected file: ${file} 3. Identify related code: bash(grep -r "import.*${basename(file)}" ${workflowDir}/src --include="*.ts") 4. Read test files: bash(find ${workflowDir}/tests -name "*${basename(file, '.ts')}*" -type f) - 5. Execute: cat ~/.claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) + 5. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) 6. Read: .workflow/project-tech.json (technology stack and architecture context) 7. Read: .workflow/project-guidelines.json (user-defined constraints for remediation compliance) ## CLI Configuration - Tool Priority: gemini → qwen → codex - - Template: ~/.claude/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt + - Template: ~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt - Timeout: 2400000ms (40 minutes) - Mode: analysis (READ-ONLY) diff --git a/.claude/commands/workflow/session/complete.md b/.claude/commands/workflow/session/complete.md index 7519e67e..ab325183 100644 --- a/.claude/commands/workflow/session/complete.md +++ b/.claude/commands/workflow/session/complete.md @@ -82,7 +82,7 @@ Read the key files above, then build this structure: } ``` -**Lessons Generation**: Use gemini with `~/.claude/workflows/cli-templates/prompts/archive/analysis-simple.txt` +**Lessons Generation**: Use gemini with `~/.ccw/workflows/cli-templates/prompts/archive/analysis-simple.txt` ### Phase 3: Atomic Commit (4 commands) diff --git a/.claude/commands/workflow/test-cycle-execute.md b/.claude/commands/workflow/test-cycle-execute.md index 3dfd30c4..22ce48b0 100644 --- a/.claude/commands/workflow/test-cycle-execute.md +++ b/.claude/commands/workflow/test-cycle-execute.md @@ -147,7 +147,7 @@ return "conservative"; ### CLI Tool Configuration **Fallback Chain**: Gemini → Qwen → Codex -**Template**: `~/.claude/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt` +**Template**: `~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt` **Timeout**: 40min (2400000ms) **Tool Details**: diff --git a/.claude/commands/workflow/tools/code-validation-gate.md b/.claude/commands/workflow/tools/code-validation-gate.md index 7a7a21a7..96f7daab 100644 --- a/.claude/commands/workflow/tools/code-validation-gate.md +++ b/.claude/commands/workflow/tools/code-validation-gate.md @@ -354,7 +354,7 @@ When used in test-fix workflow, generates task: "requirements": "Validate generated code for AI common errors" }, "flow_control": { - "validation_config": "~/.claude/workflows/test-quality-config.json", + "validation_config": "~/.ccw/workflows/test-quality-config.json", "max_retries": 2, "auto_fix_enabled": true }, diff --git a/.claude/commands/workflow/tools/conflict-resolution.md b/.claude/commands/workflow/tools/conflict-resolution.md index 15bceaba..04d80a41 100644 --- a/.claude/commands/workflow/tools/conflict-resolution.md +++ b/.claude/commands/workflow/tools/conflict-resolution.md @@ -129,7 +129,7 @@ Task(subagent_type="cli-execution-agent", run_in_background=false, prompt=` ## Analysis Steps ### 0. Load Output Schema (MANDATORY) - Execute: cat ~/.claude/workflows/cli-templates/schemas/conflict-resolution-schema.json + Execute: cat ~/.ccw/workflows/cli-templates/schemas/conflict-resolution-schema.json ### 1. Load Context - Read existing files from conflict_detection.existing_files @@ -178,7 +178,7 @@ Task(subagent_type="cli-execution-agent", run_in_background=false, prompt=` ⚠️ Output to conflict-resolution.json (generated in Phase 4) - **Schema Reference**: Execute \`cat ~/.claude/workflows/cli-templates/schemas/conflict-resolution-schema.json\` to get full schema + **Schema Reference**: Execute \`cat ~/.ccw/workflows/cli-templates/schemas/conflict-resolution-schema.json\` to get full schema Return JSON following the schema above. Key requirements: - Minimum 2 strategies per conflict, max 4 diff --git a/.claude/commands/workflow/tools/context-gather.md b/.claude/commands/workflow/tools/context-gather.md index 0c2075e1..05e653f1 100644 --- a/.claude/commands/workflow/tools/context-gather.md +++ b/.claude/commands/workflow/tools/context-gather.md @@ -137,7 +137,7 @@ Execute **${angle}** exploration for task planning context. Analyze codebase fro **You (cli-explore-agent) MUST execute these steps in order:** 1. Run: ccw tool exec get_modules_by_depth '{}' (project structure) 2. Run: rg -l "{keyword_from_task}" --type ts (locate relevant files) -3. Execute: cat ~/.claude/workflows/cli-templates/schemas/explore-json-schema.json (get output schema reference) +3. Execute: cat ~/.ccw/workflows/cli-templates/schemas/explore-json-schema.json (get output schema reference) ## Exploration Strategy (${angle} focus) diff --git a/.claude/commands/workflow/tools/task-generate-tdd.md b/.claude/commands/workflow/tools/task-generate-tdd.md index 95f94e78..fb6540fc 100644 --- a/.claude/commands/workflow/tools/task-generate-tdd.md +++ b/.claude/commands/workflow/tools/task-generate-tdd.md @@ -439,7 +439,7 @@ IMPORTANT: Do NOT add command field to implementation_approach steps. Execution ##### 2. IMPL_PLAN.md (TDD Variant) - **Location**: `.workflow/active/{session-id}/IMPL_PLAN.md` -- **Template**: `~/.claude/workflows/cli-templates/prompts/workflow/impl-plan-template.txt` +- **Template**: `~/.ccw/workflows/cli-templates/prompts/workflow/impl-plan-template.txt` - **TDD-Specific Frontmatter**: workflow_type="tdd", tdd_workflow=true, feature_count, task_breakdown - **TDD Implementation Tasks Section**: Feature-by-feature with internal Red-Green-Refactor cycles - **Context Analysis**: Artifact references and exploration insights diff --git a/.claude/commands/workflow/tools/test-concept-enhanced.md b/.claude/commands/workflow/tools/test-concept-enhanced.md index b9ea9bb3..67dce103 100644 --- a/.claude/commands/workflow/tools/test-concept-enhanced.md +++ b/.claude/commands/workflow/tools/test-concept-enhanced.md @@ -86,7 +86,7 @@ Analyze test requirements and generate comprehensive test generation strategy us Session: {test_session_id} Source Session: {source_session_id} Working Dir: .workflow/active/{test_session_id}/.process -Template: ~/.claude/workflows/cli-templates/prompts/test/test-concept-analysis.txt +Template: ~/.ccw/workflows/cli-templates/prompts/test/test-concept-analysis.txt ## EXECUTION STEPS 1. Execute Gemini analysis: diff --git a/.claude/commands/workflow/tools/test-task-generate.md b/.claude/commands/workflow/tools/test-task-generate.md index 97d5e04f..4973b836 100644 --- a/.claude/commands/workflow/tools/test-task-generate.md +++ b/.claude/commands/workflow/tools/test-task-generate.md @@ -155,7 +155,7 @@ Write(testPlanningNotesPath, `# Test Planning Notes **Execution Steps**: 1. Load TEST_ANALYSIS_RESULTS.md from `.workflow/active/{test-session-id}/.process/` 2. Invoke `cli-execution-agent` with Gemini for test enhancement analysis -3. Use template: `~/.claude/workflows/cli-templates/prompts/test-suggestions-enhancement.txt` +3. Use template: `~/.ccw/workflows/cli-templates/prompts/test-suggestions-enhancement.txt` 4. Gemini generates enriched test suggestions across L1-L3 layers → gemini-enriched-suggestions.md 5. Record enriched suggestions to test-planning-notes.md (Gemini Enhancement section) diff --git a/.claude/skills/issue-discover/phases/02-discover.md b/.claude/skills/issue-discover/phases/02-discover.md index 84ffb0b0..6049a69f 100644 --- a/.claude/skills/issue-discover/phases/02-discover.md +++ b/.claude/skills/issue-discover/phases/02-discover.md @@ -209,7 +209,7 @@ Task({ ## MANDATORY FIRST STEPS 1. Read discovery state: ${outputDir}/discovery-state.json - 2. Read schema: ~/.claude/workflows/cli-templates/schemas/discovery-finding-schema.json + 2. Read schema: ~/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json 3. Analyze target files for ${perspective} concerns ## Output Requirements @@ -304,8 +304,8 @@ function getPerspectiveGuidance(perspective) { | Schema | Path | Purpose | |--------|------|---------| -| **Discovery State** | `~/.claude/workflows/cli-templates/schemas/discovery-state-schema.json` | Session state machine | -| **Discovery Finding** | `~/.claude/workflows/cli-templates/schemas/discovery-finding-schema.json` | Perspective analysis results | +| **Discovery State** | `~/.ccw/workflows/cli-templates/schemas/discovery-state-schema.json` | Session state machine | +| **Discovery Finding** | `~/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json` | Perspective analysis results | ## Error Handling diff --git a/.claude/skills/issue-discover/phases/03-discover-by-prompt.md b/.claude/skills/issue-discover/phases/03-discover-by-prompt.md index e5c17f57..985b70ee 100644 --- a/.claude/skills/issue-discover/phases/03-discover-by-prompt.md +++ b/.claude/skills/issue-discover/phases/03-discover-by-prompt.md @@ -424,7 +424,7 @@ function buildDimensionPromptWithACE(dimension, iteration, previousFindings, ace ` : ''} ## MANDATORY FIRST STEPS - 1. Read schema: ~/.claude/workflows/cli-templates/schemas/discovery-finding-schema.json + 1. Read schema: ~/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json 2. Review ACE results above for starting points 3. Explore files identified by ACE diff --git a/.claude/skills/review-cycle/phases/02-parallel-review.md b/.claude/skills/review-cycle/phases/02-parallel-review.md index f90ffc00..96c6c718 100644 --- a/.claude/skills/review-cycle/phases/02-parallel-review.md +++ b/.claude/skills/review-cycle/phases/02-parallel-review.md @@ -62,12 +62,12 @@ const CATEGORIES = { **Agent-produced JSON files follow standardized schemas**: 1. **Dimension Results** (cli-explore-agent output from parallel reviews) - - Schema: `~/.claude/workflows/cli-templates/schemas/review-dimension-results-schema.json` + - Schema: `~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json` - Output: `{output-dir}/dimensions/{dimension}.json` - Contains: findings array, summary statistics, cross_references 2. **Deep-Dive Results** (cli-explore-agent output from iterations) - - Schema: `~/.claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json` + - Schema: `~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json` - Output: `{output-dir}/iterations/iteration-{N}-finding-{uuid}.json` - Contains: root_cause, remediation_plan, impact_assessment, reassessed_severity @@ -97,7 +97,7 @@ Task( 1. Read review state: ${reviewStateJsonPath} 2. Get target files: Read resolved_files from review-state.json 3. Validate file access: bash(ls -la ${targetFiles.join(' ')}) - 4. Execute: cat ~/.claude/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) + 4. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) 5. Read: .workflow/project-tech.json (technology stack and architecture context) 6. Read: .workflow/project-guidelines.json (user-defined constraints and conventions to validate against) @@ -188,7 +188,7 @@ Task( 2. Read completed task summaries: bash(find ${summariesDir} -name "IMPL-*.md" -type f) 3. Get changed files: bash(cd ${workflowDir} && git log --since="${sessionCreatedAt}" --name-only --pretty=format: | sort -u) 4. Read review state: ${reviewStateJsonPath} - 5. Execute: cat ~/.claude/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) + 5. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) 6. Read: .workflow/project-tech.json (technology stack and architecture context) 7. Read: .workflow/project-guidelines.json (user-defined constraints and conventions to validate against) @@ -201,7 +201,7 @@ Task( ## CLI Configuration - Tool Priority: gemini → qwen → codex (fallback chain) - - Template: ~/.claude/workflows/cli-templates/prompts/analysis/${dimensionTemplate} + - Template: ~/.ccw/workflows/cli-templates/prompts/analysis/${dimensionTemplate} - Custom Focus: ${customFocus || 'Standard dimension analysis'} - Timeout: ${timeout}ms - Mode: analysis (READ-ONLY) @@ -294,13 +294,13 @@ Task( 2. Read affected file: ${file} 3. Identify related code: bash(grep -r "import.*${basename(file)}" ${projectDir}/src --include="*.ts") 4. Read test files: bash(find ${projectDir}/tests -name "*${basename(file, '.ts')}*" -type f) - 5. Execute: cat ~/.claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) + 5. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) 6. Read: .workflow/project-tech.json (technology stack and architecture context) 7. Read: .workflow/project-guidelines.json (user-defined constraints for remediation compliance) ## CLI Configuration - Tool Priority: gemini → qwen → codex - - Template: ~/.claude/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt + - Template: ~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt - Mode: analysis (READ-ONLY) ## Expected Deliverables diff --git a/.claude/skills/review-cycle/phases/04-iterative-deep-dive.md b/.claude/skills/review-cycle/phases/04-iterative-deep-dive.md index 91675edd..e8172ffd 100644 --- a/.claude/skills/review-cycle/phases/04-iterative-deep-dive.md +++ b/.claude/skills/review-cycle/phases/04-iterative-deep-dive.md @@ -108,13 +108,13 @@ Task( 2. Read affected file: ${file} 3. Identify related code: bash(grep -r "import.*${basename(file)}" ${projectDir}/src --include="*.ts") 4. Read test files: bash(find ${projectDir}/tests -name "*${basename(file, '.ts')}*" -type f) - 5. Execute: cat ~/.claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) + 5. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) 6. Read: .workflow/project-tech.json (technology stack and architecture context) 7. Read: .workflow/project-guidelines.json (user-defined constraints for remediation compliance) ## CLI Configuration - Tool Priority: gemini → qwen → codex - - Template: ~/.claude/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt + - Template: ~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt - Mode: analysis (READ-ONLY) ## Expected Deliverables @@ -192,13 +192,13 @@ Task( 2. Read affected file: ${file} 3. Identify related code: bash(grep -r "import.*${basename(file)}" ${workflowDir}/src --include="*.ts") 4. Read test files: bash(find ${workflowDir}/tests -name "*${basename(file, '.ts')}*" -type f) - 5. Execute: cat ~/.claude/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) + 5. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) 6. Read: .workflow/project-tech.json (technology stack and architecture context) 7. Read: .workflow/project-guidelines.json (user-defined constraints for remediation compliance) ## CLI Configuration - Tool Priority: gemini → qwen → codex - - Template: ~/.claude/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt + - Template: ~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt - Timeout: 2400000ms (40 minutes) - Mode: analysis (READ-ONLY) diff --git a/.claude/skills/skill-generator/templates/llm-action.md b/.claude/skills/skill-generator/templates/llm-action.md index 22cc45b5..0d3d9264 100644 --- a/.claude/skills/skill-generator/templates/llm-action.md +++ b/.claude/skills/skill-generator/templates/llm-action.md @@ -177,7 +177,7 @@ prompt: MODE: analysis CONTEXT: {{code_context}} EXPECTED: JSON formatted analysis report with modules, dependencies, patterns, quality_score - RULES: $(cat ~/.claude/workflows/cli-templates/protocols/analysis-protocol.md) + RULES: $(cat ~/.ccw/workflows/cli-templates/protocols/analysis-protocol.md) variables: - code_context input: @@ -207,7 +207,7 @@ prompt: MODE: write CONTEXT: {{analysis_report}} EXPECTED: Complete Markdown documentation with table of contents, chapters, diagrams - RULES: $(cat ~/.claude/workflows/cli-templates/protocols/write-protocol.md) + RULES: $(cat ~/.ccw/workflows/cli-templates/protocols/write-protocol.md) variables: - analysis_report input: @@ -237,7 +237,7 @@ prompt: MODE: analysis CONTEXT: {{source_code}} EXPECTED: List of refactoring suggestions with location, issue, suggestion, impact fields - RULES: $(cat ~/.claude/workflows/cli-templates/protocols/analysis-protocol.md) + RULES: $(cat ~/.ccw/workflows/cli-templates/protocols/analysis-protocol.md) variables: - source_code input: diff --git a/.claude/skills/workflow-tdd-plan/phases/02-task-generate-tdd.md b/.claude/skills/workflow-tdd-plan/phases/02-task-generate-tdd.md index 459ff754..7f18d6ff 100644 --- a/.claude/skills/workflow-tdd-plan/phases/02-task-generate-tdd.md +++ b/.claude/skills/workflow-tdd-plan/phases/02-task-generate-tdd.md @@ -430,7 +430,7 @@ IMPORTANT: Do NOT add command field to implementation_approach steps. Execution ##### 2. IMPL_PLAN.md (TDD Variant) - **Location**: \`.workflow/active/{session-id}/IMPL_PLAN.md\` -- **Template**: \`~/.claude/workflows/cli-templates/prompts/workflow/impl-plan-template.txt\` +- **Template**: \`~/.ccw/workflows/cli-templates/prompts/workflow/impl-plan-template.txt\` - **TDD-Specific Frontmatter**: workflow_type="tdd", tdd_workflow=true, feature_count, task_breakdown - **TDD Implementation Tasks Section**: Feature-by-feature with internal Red-Green-Refactor cycles - **Context Analysis**: Artifact references and exploration insights diff --git a/.codex/agents/action-planning-agent.md b/.codex/agents/action-planning-agent.md index c0e7a907..28e51171 100644 --- a/.codex/agents/action-planning-agent.md +++ b/.codex/agents/action-planning-agent.md @@ -186,7 +186,7 @@ if (contextPackage.brainstorm_artifacts?.role_analyses?.length > 0) { - Add quantified requirements and measurable acceptance criteria 3. Create IMPL_PLAN.md - - Load template: Read(~/.claude/workflows/cli-templates/prompts/workflow/impl-plan-template.txt) + - Load template: Read(~/.ccw/workflows/cli-templates/prompts/workflow/impl-plan-template.txt) - Follow template structure and validation checklist - Populate all 8 sections with synthesized context - Document CCW workflow phase progression @@ -661,7 +661,7 @@ The `implementation_approach` defines sequential implementation steps. Execution **Template-Based Generation**: ``` -1. Load template: Read(~/.claude/workflows/cli-templates/prompts/workflow/impl-plan-template.txt) +1. Load template: Read(~/.ccw/workflows/cli-templates/prompts/workflow/impl-plan-template.txt) 2. Populate all sections following template structure 3. Complete template validation checklist 4. Generate at .workflow/active/{session_id}/IMPL_PLAN.md @@ -852,7 +852,7 @@ Use `analysis_results.complexity` or task count to determine structure: - **Record N+1 Context**: Update `## N+1 Context` section with key decisions and deferred items - **Search Tool Priority**: ACE (`mcp__ace-tool__search_context`) → CCW (`mcp__ccw-tools__smart_search`) / Built-in (`Grep`, `Glob`, `Read`) - Apply Quantification Requirements to all requirements, acceptance criteria, and modification points -- Load IMPL_PLAN template: `Read(~/.claude/workflows/cli-templates/prompts/workflow/impl-plan-template.txt)` before generating IMPL_PLAN.md +- Load IMPL_PLAN template: `Read(~/.ccw/workflows/cli-templates/prompts/workflow/impl-plan-template.txt)` before generating IMPL_PLAN.md - Use provided context package: Extract all information from structured context - Respect memory-first rule: Use provided content (already loaded from memory/file) - Follow 6-field schema: All task JSONs must have id, title, status, context_package_path, meta, context, flow_control diff --git a/.codex/agents/cli-execution-agent.md b/.codex/agents/cli-execution-agent.md index 2b100b60..4326c913 100644 --- a/.codex/agents/cli-execution-agent.md +++ b/.codex/agents/cli-execution-agent.md @@ -14,13 +14,13 @@ You are an intelligent CLI execution specialist that autonomously orchestrates c 2. **Qwen (Fallback)** - Same capabilities as Gemini, use when unavailable 3. **Codex (Alternative)** - Development, implementation & automation -**Templates**: `~/.claude/workflows/cli-templates/prompts/` +**Templates**: `~/.ccw/workflows/cli-templates/prompts/` - `analysis/` - pattern.txt, architecture.txt, code-execution-tracing.txt, security.txt, quality.txt - `development/` - feature.txt, refactor.txt, testing.txt, bug-diagnosis.txt - `planning/` - task-breakdown.txt, architecture-planning.txt - `memory/` - claude-module-unified.txt -**Reference**: See `~/.claude/workflows/intelligent-tools-strategy.md` for complete usage guide +**Reference**: See `~/.ccw/workflows/intelligent-tools-strategy.md` for complete usage guide ## 5-Phase Execution Workflow @@ -129,7 +129,7 @@ CONTEXT: @CLAUDE.md @src/**/* @*.ts CONTEXT: @**/* @../shared/**/* @../types/**/* ``` -**2. Template Selection** (`~/.claude/workflows/cli-templates/prompts/`): +**2. Template Selection** (`~/.ccw/workflows/cli-templates/prompts/`): ``` analyze → analysis/code-execution-tracing.txt | analysis/pattern.txt execute → development/feature.txt @@ -308,7 +308,7 @@ Codex unavailable → Gemini/Qwen write mode ## Templates Reference -**Location**: `~/.claude/workflows/cli-templates/prompts/` +**Location**: `~/.ccw/workflows/cli-templates/prompts/` **Analysis** (`analysis/`): - `pattern.txt` - Code pattern analysis diff --git a/.codex/agents/code-developer.md b/.codex/agents/code-developer.md index e6ffd58e..6b183de7 100644 --- a/.codex/agents/code-developer.md +++ b/.codex/agents/code-developer.md @@ -77,24 +77,24 @@ if [[ -n "$TASK_JSON_TECH_STACK" ]]; then # Map tech stack names to guideline files # e.g., ["FastAPI", "SQLAlchemy"] → python-dev.md case "$TASK_JSON_TECH_STACK" in - *FastAPI*|*Django*|*SQLAlchemy*) TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/python-dev.md) ;; - *React*|*Next*) TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/react-dev.md) ;; - *TypeScript*) TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/typescript-dev.md) ;; + *FastAPI*|*Django*|*SQLAlchemy*) TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/python-dev.md) ;; + *React*|*Next*) TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/react-dev.md) ;; + *TypeScript*) TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/typescript-dev.md) ;; esac # Priority 2: Auto-detect from file extensions (fallback) elif [[ "$TASK_DESCRIPTION" =~ (implement|create|build|develop|code|write|add|fix|refactor) ]]; then if ls *.ts *.tsx 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/typescript-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/typescript-dev.md) elif grep -q "react" package.json 2>/dev/null; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/react-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/react-dev.md) elif ls *.py requirements.txt 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/python-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/python-dev.md) elif ls *.java pom.xml build.gradle 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/java-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/java-dev.md) elif ls *.go go.mod 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/go-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/go-dev.md) elif ls *.js package.json 2>/dev/null | head -1; then - TECH_GUIDELINES=$(cat ~/.claude/workflows/cli-templates/tech-stacks/javascript-dev.md) + TECH_GUIDELINES=$(cat ~/.ccw/workflows/cli-templates/tech-stacks/javascript-dev.md) fi fi ``` diff --git a/.codex/agents/conceptual-planning-agent.md b/.codex/agents/conceptual-planning-agent.md index 2a06e0a8..f50447f2 100644 --- a/.codex/agents/conceptual-planning-agent.md +++ b/.codex/agents/conceptual-planning-agent.md @@ -70,7 +70,7 @@ def handle_brainstorm_assignment(prompt): # Execute role template loading via $(cat template) if step_name == "load_role_template": - processed_command = f"bash($(cat ~/.claude/workflows/cli-templates/planning-roles/{role}.md))" + processed_command = f"bash($(cat ~/.ccw/workflows/cli-templates/planning-roles/{role}.md))" else: processed_command = process_context_variables(command, context_vars) @@ -106,7 +106,7 @@ This agent processes **simplified inline [FLOW_CONTROL]** format from brainstorm 2. **load_role_template** - Action: Load role-specific planning template - - Command: bash($(cat "~/.claude/workflows/cli-templates/planning-roles/{role}.md")) + - Command: bash($(cat "~/.ccw/workflows/cli-templates/planning-roles/{role}.md")) - Output: role_template 3. **load_session_metadata** @@ -165,7 +165,7 @@ When called, you receive: **Auto Brainstorm Integration**: Role assignment comes from auto.md workflow: 1. **Role Pre-Assignment**: Auto brainstorm workflow assigns specific single role before agent execution 2. **Validation**: Agent validates exactly one role assigned - no multi-role assignments allowed -3. **Template Loading**: Use `$(cat ~/.claude/workflows/cli-templates/planning-roles/.md)` for role template +3. **Template Loading**: Use `$(cat ~/.ccw/workflows/cli-templates/planning-roles/.md)` for role template 4. **Output Directory**: Use designated `.brainstorming/[role]/` directory for role-specific outputs ### Role Options Include: @@ -190,7 +190,7 @@ When called, you receive: ### Role Template Integration Documentation formats and structures are defined in role-specific templates loaded via: ```bash -$(cat ~/.claude/workflows/cli-templates/planning-roles/.md) +$(cat ~/.ccw/workflows/cli-templates/planning-roles/.md) ``` Each planning role template contains: diff --git a/.codex/agents/ui-design-agent.md b/.codex/agents/ui-design-agent.md index fbe8dabe..1a9e966d 100644 --- a/.codex/agents/ui-design-agent.md +++ b/.codex/agents/ui-design-agent.md @@ -320,7 +320,7 @@ You execute 6 distinct task types organized into 3 patterns. Each task includes ### design-tokens.json -**Template Reference**: `~/.claude/workflows/cli-templates/ui-design/systems/design-tokens.json` +**Template Reference**: `~/.ccw/workflows/cli-templates/ui-design/systems/design-tokens.json` **Format**: W3C Design Tokens Community Group Specification @@ -385,7 +385,7 @@ You execute 6 distinct task types organized into 3 patterns. Each task includes ### layout-templates.json -**Template Reference**: `~/.claude/workflows/cli-templates/ui-design/systems/layout-templates.json` +**Template Reference**: `~/.ccw/workflows/cli-templates/ui-design/systems/layout-templates.json` **Optimization**: Unified structure combining DOM and styling into single hierarchy @@ -426,7 +426,7 @@ You execute 6 distinct task types organized into 3 patterns. Each task includes ### animation-tokens.json -**Template Reference**: `~/.claude/workflows/cli-templates/ui-design/systems/animation-tokens.json` +**Template Reference**: `~/.ccw/workflows/cli-templates/ui-design/systems/animation-tokens.json` **Structure Overview**: - **duration**: instant (0ms), fast (150ms), normal (300ms), slow (500ms), slower (1000ms) diff --git a/.codex/skills/issue-discover/phases/02-discover.md b/.codex/skills/issue-discover/phases/02-discover.md index 28b89010..7196624d 100644 --- a/.codex/skills/issue-discover/phases/02-discover.md +++ b/.codex/skills/issue-discover/phases/02-discover.md @@ -134,7 +134,7 @@ Discover potential ${perspective} issues in specified module files. ## MANDATORY FIRST STEPS 1. Read discovery state: ${outputDir}/discovery-state.json -2. Read schema: ~/.codex/workflows/cli-templates/schemas/discovery-finding-schema.json +2. Read schema: ~/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json 3. Analyze target files for ${perspective} concerns ## Output Requirements @@ -335,8 +335,8 @@ function getPerspectiveGuidance(perspective) { | Schema | Path | Purpose | |--------|------|---------| -| **Discovery State** | `~/.codex/workflows/cli-templates/schemas/discovery-state-schema.json` | Session state machine | -| **Discovery Finding** | `~/.codex/workflows/cli-templates/schemas/discovery-finding-schema.json` | Perspective analysis results | +| **Discovery State** | `~/.ccw/workflows/cli-templates/schemas/discovery-state-schema.json` | Session state machine | +| **Discovery Finding** | `~/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json` | Perspective analysis results | ## Error Handling diff --git a/.codex/skills/issue-discover/phases/03-discover-by-prompt.md b/.codex/skills/issue-discover/phases/03-discover-by-prompt.md index 0d14b02a..a61c5745 100644 --- a/.codex/skills/issue-discover/phases/03-discover-by-prompt.md +++ b/.codex/skills/issue-discover/phases/03-discover-by-prompt.md @@ -445,7 +445,7 @@ ${summarizePreviousFindings(previousFindings, dimension.name)} ` : ''} ## MANDATORY FIRST STEPS -1. Read schema: ~/.codex/workflows/cli-templates/schemas/discovery-finding-schema.json +1. Read schema: ~/.ccw/workflows/cli-templates/schemas/discovery-finding-schema.json 2. Review ACE results above for starting points 3. Explore files identified by ACE diff --git a/.codex/skills/issue-execute/SKILL.md b/.codex/skills/issue-execute/SKILL.md index ff7bbb4b..1f79429a 100644 --- a/.codex/skills/issue-execute/SKILL.md +++ b/.codex/skills/issue-execute/SKILL.md @@ -16,7 +16,7 @@ Before starting execution, load project context: 1. **Read project tech stack**: `.workflow/project-tech.json` 2. **Read project guidelines**: `.workflow/project-guidelines.json` -3. **Read solution schema**: `~/.claude/workflows/cli-templates/schemas/solution-schema.json` +3. **Read solution schema**: `~/.ccw/workflows/cli-templates/schemas/solution-schema.json` This ensures execution follows project conventions and patterns. diff --git a/.codex/skills/review-cycle/phases/02-parallel-review.md b/.codex/skills/review-cycle/phases/02-parallel-review.md index 42dd27bf..3c98873a 100644 --- a/.codex/skills/review-cycle/phases/02-parallel-review.md +++ b/.codex/skills/review-cycle/phases/02-parallel-review.md @@ -63,12 +63,12 @@ const CATEGORIES = { **Agent-produced JSON files follow standardized schemas**: 1. **Dimension Results** (cli-explore-agent output from parallel reviews) - - Schema: `~/.codex/workflows/cli-templates/schemas/review-dimension-results-schema.json` + - Schema: `~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json` - Output: `{output-dir}/dimensions/{dimension}.json` - Contains: findings array, summary statistics, cross_references 2. **Deep-Dive Results** (cli-explore-agent output from iterations) - - Schema: `~/.codex/workflows/cli-templates/schemas/review-deep-dive-results-schema.json` + - Schema: `~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json` - Output: `{output-dir}/iterations/iteration-{N}-finding-{uuid}.json` - Contains: root_cause, remediation_plan, impact_assessment, reassessed_severity @@ -93,7 +93,7 @@ dimensions.forEach(dimension => { 2. Read review state: ${reviewStateJsonPath} 3. Get target files: Read resolved_files from review-state.json 4. Validate file access: bash(ls -la ${targetFiles.join(' ')}) -5. Execute: cat ~/.codex/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) +5. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) 6. Read: .workflow/project-tech.json (technology stack and architecture context) 7. Read: .workflow/project-guidelines.json (user-defined constraints and conventions to validate against) @@ -216,7 +216,7 @@ dimensions.forEach(dimension => { 3. Read completed task summaries: bash(find ${summariesDir} -name "IMPL-*.md" -type f) 4. Get changed files: bash(cd ${workflowDir} && git log --since="${sessionCreatedAt}" --name-only --pretty=format: | sort -u) 5. Read review state: ${reviewStateJsonPath} -6. Execute: cat ~/.codex/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) +6. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-dimension-results-schema.json (get output schema reference) 7. Read: .workflow/project-tech.json (technology stack and architecture context) 8. Read: .workflow/project-guidelines.json (user-defined constraints and conventions to validate against) @@ -240,7 +240,7 @@ Use **Deep Scan mode** for this review: ## CLI Configuration - Tool Priority: gemini → qwen → codex (fallback chain) -- Template: ~/.codex/workflows/cli-templates/prompts/analysis/${dimensionTemplate} +- Template: ~/.ccw/workflows/cli-templates/prompts/analysis/${dimensionTemplate} - Custom Focus: ${customFocus || 'Standard dimension analysis'} - Timeout: ${timeout}ms - Mode: analysis (READ-ONLY) @@ -335,7 +335,7 @@ const deepDiveAgentId = spawn_agent({ 3. Read affected file: ${file} 4. Identify related code: bash(grep -r "import.*${basename(file)}" ${projectDir}/src --include="*.ts") 5. Read test files: bash(find ${projectDir}/tests -name "*${basename(file, '.ts')}*" -type f) -6. Execute: cat ~/.codex/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) +6. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) 7. Read: .workflow/project-tech.json (technology stack and architecture context) 8. Read: .workflow/project-guidelines.json (user-defined constraints for remediation compliance) @@ -367,7 +367,7 @@ Then apply **Deep Scan mode** for semantic analysis: ## CLI Configuration - Tool Priority: gemini → qwen → codex -- Template: ~/.codex/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt +- Template: ~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt - Mode: analysis (READ-ONLY) ## Expected Deliverables diff --git a/.codex/skills/review-cycle/phases/04-iterative-deep-dive.md b/.codex/skills/review-cycle/phases/04-iterative-deep-dive.md index 75add650..54ef301c 100644 --- a/.codex/skills/review-cycle/phases/04-iterative-deep-dive.md +++ b/.codex/skills/review-cycle/phases/04-iterative-deep-dive.md @@ -88,7 +88,7 @@ selectedFindings.forEach(finding => { 3. Read affected file: ${finding.file} 4. Identify related code: bash(grep -r "import.*${basename(finding.file)}" ${projectDir}/src --include="*.ts") 5. Read test files: bash(find ${projectDir}/tests -name "*${basename(finding.file, '.ts')}*" -type f) -6. Execute: cat ~/.codex/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) +6. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) 7. Read: .workflow/project-tech.json (technology stack and architecture context) 8. Read: .workflow/project-guidelines.json (user-defined constraints for remediation compliance) @@ -120,7 +120,7 @@ Then apply **Deep Scan mode** for semantic analysis: ## CLI Configuration - Tool Priority: gemini → qwen → codex -- Template: ~/.codex/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt +- Template: ~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt - Mode: analysis (READ-ONLY) ## Expected Deliverables @@ -199,7 +199,7 @@ selectedFindings.forEach(finding => { 3. Read affected file: ${finding.file} 4. Identify related code: bash(grep -r "import.*${basename(finding.file)}" ${workflowDir}/src --include="*.ts") 5. Read test files: bash(find ${workflowDir}/tests -name "*${basename(finding.file, '.ts')}*" -type f) -6. Execute: cat ~/.codex/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) +6. Execute: cat ~/.ccw/workflows/cli-templates/schemas/review-deep-dive-results-schema.json (get output schema reference) 7. Read: .workflow/project-tech.json (technology stack and architecture context) 8. Read: .workflow/project-guidelines.json (user-defined constraints for remediation compliance) @@ -231,7 +231,7 @@ Then apply **Deep Scan mode** for semantic analysis: ## CLI Configuration - Tool Priority: gemini → qwen → codex -- Template: ~/.codex/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt +- Template: ~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt - Timeout: 2400000ms (40 minutes) - Mode: analysis (READ-ONLY) diff --git a/.codex/skills/workflow-brainstorm-auto-parallel/phases/02-parallel-role-analysis.md b/.codex/skills/workflow-brainstorm-auto-parallel/phases/02-parallel-role-analysis.md index f7d00527..d866162a 100644 --- a/.codex/skills/workflow-brainstorm-auto-parallel/phases/02-parallel-role-analysis.md +++ b/.codex/skills/workflow-brainstorm-auto-parallel/phases/02-parallel-role-analysis.md @@ -116,63 +116,63 @@ const roleConfig = { focus_area: 'User research, information architecture, user journey', question_categories: ['User Intent', 'Requirements', 'UX'], question_count: 4, - template: '~/.codex/workflows/cli-templates/planning-roles/ux-expert.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/ux-expert.md' }, 'ui-designer': { title: 'UI设计师', focus_area: 'Visual design, high-fidelity mockups, design systems', question_categories: ['Requirements', 'UX', 'Feasibility'], question_count: 4, - template: '~/.codex/workflows/cli-templates/planning-roles/ui-designer.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/ui-designer.md' }, 'system-architect': { title: '系统架构师', focus_area: 'Technical architecture, scalability, integration patterns', question_categories: ['Scale & Performance', 'Technical Constraints', 'Architecture Complexity', 'Non-Functional Requirements'], question_count: 5, - template: '~/.codex/workflows/cli-templates/planning-roles/system-architect.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/system-architect.md' }, 'product-manager': { title: '产品经理', focus_area: 'Product strategy, roadmap, prioritization', question_categories: ['User Intent', 'Requirements', 'Process'], question_count: 4, - template: '~/.codex/workflows/cli-templates/planning-roles/product-manager.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/product-manager.md' }, 'product-owner': { title: '产品负责人', focus_area: 'Backlog management, user stories, acceptance criteria', question_categories: ['Requirements', 'Decisions', 'Process'], question_count: 4, - template: '~/.codex/workflows/cli-templates/planning-roles/product-owner.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/product-owner.md' }, 'scrum-master': { title: '敏捷教练', focus_area: 'Process facilitation, impediment removal, team dynamics', question_categories: ['Process', 'Risk', 'Decisions'], question_count: 3, - template: '~/.codex/workflows/cli-templates/planning-roles/scrum-master.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/scrum-master.md' }, 'subject-matter-expert': { title: '领域专家', focus_area: 'Domain knowledge, business rules, compliance', question_categories: ['Requirements', 'Feasibility', 'Terminology'], question_count: 4, - template: '~/.codex/workflows/cli-templates/planning-roles/subject-matter-expert.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/subject-matter-expert.md' }, 'data-architect': { title: '数据架构师', focus_area: 'Data models, storage strategies, data flow', question_categories: ['Architecture', 'Scale & Performance', 'Technical Constraints', 'Feasibility'], question_count: 5, - template: '~/.codex/workflows/cli-templates/planning-roles/data-architect.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/data-architect.md' }, 'api-designer': { title: 'API设计师', focus_area: 'API contracts, versioning, integration patterns', question_categories: ['Architecture', 'Requirements', 'Feasibility', 'Decisions'], question_count: 4, - template: '~/.codex/workflows/cli-templates/planning-roles/api-designer.md' + template: '~/.ccw/workflows/cli-templates/planning-roles/api-designer.md' } }; @@ -747,7 +747,7 @@ try { ## Reference Information ### Role Template Locations -- Templates: `~/.codex/workflows/cli-templates/planning-roles/` +- Templates: `~/.ccw/workflows/cli-templates/planning-roles/` - Format: `{role-name}.md` (e.g., `ux-expert.md`, `system-architect.md`) ### Context Package diff --git a/.codex/skills/workflow-lite-plan-execute/phases/01-lite-plan.md b/.codex/skills/workflow-lite-plan-execute/phases/01-lite-plan.md index a4a7cb13..aca3193d 100644 --- a/.codex/skills/workflow-lite-plan-execute/phases/01-lite-plan.md +++ b/.codex/skills/workflow-lite-plan-execute/phases/01-lite-plan.md @@ -2,7 +2,7 @@ ## Overview -Intelligent lightweight planning command with dynamic workflow adaptation based on task complexity. Focuses on planning phases (exploration, clarification, planning, confirmation) and delegates execution to Phase 4: Lite Execute (phases/04-lite-execute.md). +Intelligent lightweight planning command with dynamic workflow adaptation based on task complexity. Focuses on planning phases (exploration, clarification, planning, confirmation) and delegates execution to Phase 2: Lite Execute (phases/02-lite-execute.md). **Core capabilities:** - Intelligent task analysis with automatic exploration detection @@ -10,7 +10,7 @@ Intelligent lightweight planning command with dynamic workflow adaptation based - Interactive clarification after exploration to gather missing information - Adaptive planning: Low complexity → Direct Claude; Medium/High → cli-lite-planning-agent - Two-step confirmation: plan display → multi-dimensional input collection -- Execution execute with complete context handoff to lite-execute +- Execution handoff with complete context to lite-execute ## Parameters @@ -37,7 +37,7 @@ Intelligent lightweight planning command with dynamic workflow adaptation based - Low complexity → Direct Claude planning (no agent) - Medium/High complexity → `cli-lite-planning-agent` generates `plan.json` -**Schema Reference**: `~/.claude/workflows/cli-templates/schemas/plan-json-schema.json` +**Schema Reference**: `~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json` ## Auto Mode Defaults @@ -58,7 +58,7 @@ const forceExplore = $ARGUMENTS.includes('--explore') || $ARGUMENTS.includes('-e ``` Phase 1: Task Analysis & Exploration ├─ Parse input (description or .md file) - ├─ intelligent complexity assessment (Low/Medium/High) + ├─ Intelligent complexity assessment (Low/Medium/High) ├─ Exploration decision (auto-detect or --explore flag) ├─ Context protection: If file reading ≥50k chars → force cli-explore-agent └─ Decision: @@ -74,7 +74,7 @@ Phase 2: Clarification (optional, multi-round) Phase 3: Planning (NO CODE EXECUTION - planning only) └─ Decision (based on Phase 1 complexity): - ├─ Low → Load schema: cat ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json → Direct Claude planning (following schema) → plan.json + ├─ Low → Load schema: cat ~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json → Direct Claude planning (following schema) → plan.json └─ Medium/High → cli-lite-planning-agent → plan.json (agent internally executes quality check) Phase 4: Confirmation & Selection @@ -86,112 +86,93 @@ Phase 4: Confirmation & Selection Phase 5: Execute ├─ Build executionContext (plan + explorations + clarifications + selections) - └─ → Hand off to Phase 4: Lite Execute (phases/04-lite-execute.md) --in-memory + └─ → Hand off to Phase 2: Lite Execute (phases/02-lite-execute.md) --in-memory ``` ## Implementation ### Phase 1: Intelligent Multi-Angle Exploration -**Session Setup** (MANDATORY - follow exactly): -```javascript -// Helper: Get UTC+8 (China Standard Time) ISO string -const getUtc8ISOString = () => new Date(Date.now() + 8 * 60 * 60 * 1000).toISOString() +#### Session Setup (MANDATORY) -const taskSlug = task_description.toLowerCase().replace(/[^a-z0-9]+/g, '-').substring(0, 40) -const dateStr = getUtc8ISOString().substring(0, 10) // Format: 2025-11-29 +Generate session ID and create session folder: -const sessionId = `${taskSlug}-${dateStr}` // e.g., "implement-jwt-refresh-2025-11-29" -const sessionFolder = `.workflow/.lite-plan/${sessionId}` +- **Session ID format**: `{task-slug}-{YYYY-MM-DD}` + - `task-slug`: lowercase task description, non-alphanumeric replaced with `-`, max 40 chars + - Date: UTC+8 (China Standard Time), format `2025-11-29` + - Example: `implement-jwt-refresh-2025-11-29` +- **Session Folder**: `.workflow/.lite-plan/{session-id}/` +- Create folder via `mkdir -p` and verify existence -bash(`mkdir -p ${sessionFolder} && test -d ${sessionFolder} && echo "SUCCESS: ${sessionFolder}" || echo "FAILED: ${sessionFolder}"`) +#### Exploration Decision + +Exploration is needed when **ANY** of these conditions are met: + +- `--explore` / `-e` flag is set +- Task mentions specific files +- Task requires codebase context understanding +- Task needs architecture understanding +- Task modifies existing code + +If none apply → skip to Phase 2 (Clarification) or Phase 3 (Planning). + +**⚠️ Context Protection**: If file reading would exceed ≥50k chars → force exploration (delegate to cli-explore-agent). + +#### Complexity Assessment + +Analyze task complexity based on four dimensions: + +| Dimension | Low | Medium | High | +|-----------|-----|--------|------| +| **Scope** | Single file, isolated | Multiple files, some dependencies | Cross-module, architectural | +| **Depth** | Surface change | Moderate structural impact | Architectural impact | +| **Risk** | Minimal | Moderate | High risk of breaking | +| **Dependencies** | None | Some interconnection | Highly interconnected | + +#### Exploration Angle Selection + +Angles are assigned based on task type keyword matching, then sliced by complexity: + +| Task Type | Keywords | Angle Presets (priority order) | +|-----------|----------|-------------------------------| +| Architecture | refactor, architect, restructure, modular | architecture, dependencies, modularity, integration-points | +| Security | security, auth, permission, access | security, auth-patterns, dataflow, validation | +| Performance | performance, slow, optimi, cache | performance, bottlenecks, caching, data-access | +| Bugfix | fix, bug, error, issue, broken | error-handling, dataflow, state-management, edge-cases | +| Feature (default) | — | patterns, integration-points, testing, dependencies | + +**Angle count by complexity**: Low → 1, Medium → 3, High → 4 + +**Planning strategy**: Low → "Direct Claude Planning", Medium/High → "cli-lite-planning-agent" + +Display exploration plan summary (complexity, selected angles, planning strategy) before launching agents. + +#### Launch Parallel Explorations + +**⚠️ CRITICAL — SYNCHRONOUS EXECUTION**: Exploration results are REQUIRED before planning. Use `spawn_agent` + `wait` pattern. + +**Orchestration Flow**: + +``` +1. Spawn agents + └─ For each selected angle → create cli-explore-agent with Agent Prompt (below) + +2. Batch wait + └─ Wait for ALL agents (timeout: 10 minutes) + +3. Handle timeout + └─ If partial timeout → log warning, continue with completed results + +4. Collect results + └─ For each completed agent → store exploration data keyed by angle + +5. Close agents + └─ Close ALL exploration agents after collection ``` -**Exploration Decision Logic**: -```javascript -needsExploration = ( - flags.includes('--explore') || flags.includes('-e') || - task.mentions_specific_files || - task.requires_codebase_context || - task.needs_architecture_understanding || - task.modifies_existing_code -) +**Agent Prompt Template** (per angle): -if (!needsExploration) { - // Skip to Phase 2 (Clarification) or Phase 3 (Planning) - proceed_to_next_phase() -} ``` - -**⚠️ Context Protection**: File reading ≥50k chars → force `needsExploration=true` (delegate to cli-explore-agent) - -**Complexity Assessment** (Intelligent Analysis): -```javascript -// analyzes task complexity based on: -// - Scope: How many systems/modules are affected? -// - Depth: Surface change vs architectural impact? -// - Risk: Potential for breaking existing functionality? -// - Dependencies: How interconnected is the change? - -const complexity = analyzeTaskComplexity(task_description) -// Returns: 'Low' | 'Medium' | 'High' -// Low: Single file, isolated change, minimal risk -// Medium: Multiple files, some dependencies, moderate risk -// High: Cross-module, architectural, high risk - -// Angle assignment based on task type (orchestrator decides, not agent) -const ANGLE_PRESETS = { - architecture: ['architecture', 'dependencies', 'modularity', 'integration-points'], - security: ['security', 'auth-patterns', 'dataflow', 'validation'], - performance: ['performance', 'bottlenecks', 'caching', 'data-access'], - bugfix: ['error-handling', 'dataflow', 'state-management', 'edge-cases'], - feature: ['patterns', 'integration-points', 'testing', 'dependencies'] -} - -function selectAngles(taskDescription, count) { - const text = taskDescription.toLowerCase() - let preset = 'feature' // default - - if (/refactor|architect|restructure|modular/.test(text)) preset = 'architecture' - else if (/security|auth|permission|access/.test(text)) preset = 'security' - else if (/performance|slow|optimi|cache/.test(text)) preset = 'performance' - else if (/fix|bug|error|issue|broken/.test(text)) preset = 'bugfix' - - return ANGLE_PRESETS[preset].slice(0, count) -} - -const selectedAngles = selectAngles(task_description, complexity === 'High' ? 4 : (complexity === 'Medium' ? 3 : 1)) - -// Planning strategy determination -const planningStrategy = complexity === 'Low' - ? 'Direct Claude Planning' - : 'cli-lite-planning-agent' - -console.log(` -## Exploration Plan - -Task Complexity: ${complexity} -Selected Angles: ${selectedAngles.join(', ')} -Planning Strategy: ${planningStrategy} - -Launching ${selectedAngles.length} parallel explorations... -`) -``` - -**Launch Parallel Explorations** - Orchestrator assigns angle to each agent: - -**⚠️ CRITICAL - SYNCHRONOUS EXECUTION**: -- **Exploration results are REQUIRED before planning** -- Use `spawn_agent` + `wait` pattern to ensure results are collected - - -```javascript -// Step 1: Create exploration agents in parallel -const explorationAgents = [] - -selectedAngles.forEach((angle, index) => { - const agentId = spawn_agent({ - message: ` ## TASK ASSIGNMENT ### MANDATORY FIRST STEPS (Agent Execute) @@ -202,386 +183,224 @@ selectedAngles.forEach((angle, index) => { --- ## Task Objective -Execute **${angle}** exploration for task planning context. Analyze codebase from this specific angle to discover relevant structure, patterns, and constraints. +Execute **{angle}** exploration for task planning context. Analyze codebase from this specific angle to discover relevant structure, patterns, and constraints. ## Output Location -**Session Folder**: ${sessionFolder} -**Output File**: ${sessionFolder}/exploration-${angle}.json +**Session Folder**: {sessionFolder} +**Output File**: {sessionFolder}/exploration-{angle}.json ## Assigned Context -- **Exploration Angle**: ${angle} -- **Task Description**: ${task_description} -- **Exploration Index**: ${index + 1} of ${selectedAngles.length} +- **Exploration Angle**: {angle} +- **Task Description**: {task_description} +- **Exploration Index**: {index} of {total} ## MANDATORY STEPS (Execute by Agent) **You (cli-explore-agent) MUST execute these steps in order:** 1. Run: ccw tool exec get_modules_by_depth '{}' (project structure) 2. Run: rg -l "{keyword_from_task}" --type ts (locate relevant files) -3. Execute: cat ~/.claude/workflows/cli-templates/schemas/explore-json-schema.json (get output schema reference) +3. Execute: cat ~/.ccw/workflows/cli-templates/schemas/explore-json-schema.json (get output schema reference) 4. Read: .workflow/project-tech.json (technology stack and architecture context) 5. Read: .workflow/project-guidelines.json (user-defined constraints and conventions) -## Exploration Strategy (${angle} focus) +## Exploration Strategy ({angle} focus) **Step 1: Structural Scan** (Bash) -- get_modules_by_depth.sh → identify modules related to ${angle} -- find/rg → locate files relevant to ${angle} aspect -- Analyze imports/dependencies from ${angle} perspective +- get_modules_by_depth.sh → identify modules related to {angle} +- find/rg → locate files relevant to {angle} aspect +- Analyze imports/dependencies from {angle} perspective **Step 2: Semantic Analysis** (Gemini CLI) -- How does existing code handle ${angle} concerns? -- What patterns are used for ${angle}? -- Where would new code integrate from ${angle} viewpoint? +- How does existing code handle {angle} concerns? +- What patterns are used for {angle}? +- Where would new code integrate from {angle} viewpoint? **Step 3: Write Output** -- Consolidate ${angle} findings into JSON -- Identify ${angle}-specific clarification needs +- Consolidate {angle} findings into JSON +- Identify {angle}-specific clarification needs ## Expected Output **Schema Reference**: Schema obtained in MANDATORY FIRST STEPS step 3, follow schema exactly -**Required Fields** (all ${angle} focused): -- project_structure: Modules/architecture relevant to ${angle} -- relevant_files: Files affected from ${angle} perspective +**Required Fields** (all {angle} focused): +- project_structure: Modules/architecture relevant to {angle} +- relevant_files: Files affected from {angle} perspective **IMPORTANT**: Use object format with relevance scores for synthesis: - \`[{path: "src/file.ts", relevance: 0.85, rationale: "Core ${angle} logic"}]\` + `[{path: "src/file.ts", relevance: 0.85, rationale: "Core {angle} logic"}]` Scores: 0.7+ high priority, 0.5-0.7 medium, <0.5 low -- patterns: ${angle}-related patterns to follow -- dependencies: Dependencies relevant to ${angle} -- integration_points: Where to integrate from ${angle} viewpoint (include file:line locations) -- constraints: ${angle}-specific limitations/conventions -- clarification_needs: ${angle}-related ambiguities (options array + recommended index) -- _metadata.exploration_angle: "${angle}" +- patterns: {angle}-related patterns to follow +- dependencies: Dependencies relevant to {angle} +- integration_points: Where to integrate from {angle} viewpoint (include file:line locations) +- constraints: {angle}-specific limitations/conventions +- clarification_needs: {angle}-related ambiguities (options array + recommended index) +- _metadata.exploration_angle: "{angle}" ## Success Criteria - [ ] Schema obtained via cat explore-json-schema.json - [ ] get_modules_by_depth.sh executed -- [ ] At least 3 relevant files identified with ${angle} rationale +- [ ] At least 3 relevant files identified with {angle} rationale - [ ] Patterns are actionable (code examples, not generic advice) - [ ] Integration points include file:line locations -- [ ] Constraints are project-specific to ${angle} +- [ ] Constraints are project-specific to {angle} - [ ] JSON output follows schema exactly - [ ] clarification_needs includes options + recommended ## Execution -**Write**: \`${sessionFolder}/exploration-${angle}.json\` -**Return**: 2-3 sentence summary of ${angle} findings -` - }) - - explorationAgents.push({ agentId, angle, index }) -}) - -// Step 2: Batch wait for all exploration agents -const explorationResults = wait({ - ids: explorationAgents.map(a => a.agentId), - timeout_ms: 600000 // 10 minutes -}) - -// Step 3: Check for timeout -if (explorationResults.timed_out) { - console.log('部分探索超时,继续使用已完成结果') -} - -// Step 4: Collect completed results -const completedExplorations = {} -explorationAgents.forEach(({ agentId, angle }) => { - if (explorationResults.status[agentId].completed) { - completedExplorations[angle] = explorationResults.status[agentId].completed - } -}) - -// Step 5: Close all exploration agents -explorationAgents.forEach(({ agentId }) => close_agent({ id: agentId })) +**Write**: `{sessionFolder}/exploration-{angle}.json` +**Return**: 2-3 sentence summary of {angle} findings ``` -**Auto-discover Generated Exploration Files**: -```javascript -// After explorations complete, auto-discover all exploration-*.json files -const explorationFiles = bash(`find ${sessionFolder} -name "exploration-*.json" -type f`) - .split('\n') - .filter(f => f.trim()) +#### Auto-discover & Manifest Generation -// Read metadata to build manifest -const explorationManifest = { - session_id: sessionId, - task_description: task_description, - timestamp: getUtc8ISOString(), - complexity: complexity, - exploration_count: explorationCount, - explorations: explorationFiles.map(file => { - const data = JSON.parse(Read(file)) - const filename = path.basename(file) - return { - angle: data._metadata.exploration_angle, - file: filename, - path: file, - index: data._metadata.exploration_index - } - }) -} +After explorations complete: -Write(`${sessionFolder}/explorations-manifest.json`, JSON.stringify(explorationManifest, null, 2)) - -console.log(` -## Exploration Complete - -Generated exploration files in ${sessionFolder}: -${explorationManifest.explorations.map(e => `- exploration-${e.angle}.json (angle: ${e.angle})`).join('\n')} - -Manifest: explorations-manifest.json -Angles explored: ${explorationManifest.explorations.map(e => e.angle).join(', ')} -`) -``` +1. **Discover** — Find all `exploration-*.json` files in session folder +2. **Read metadata** — Extract `_metadata.exploration_angle` and `_metadata.exploration_index` from each file +3. **Build manifest** — Create `explorations-manifest.json` containing: + - `session_id`, `task_description`, `timestamp`, `complexity`, `exploration_count` + - `explorations[]`: array of `{ angle, file, path, index }` per exploration +4. **Write** — Save manifest to `{sessionFolder}/explorations-manifest.json` +5. **Display** — Summary of generated files and explored angles **Output**: -- `${sessionFolder}/exploration-{angle1}.json` -- `${sessionFolder}/exploration-{angle2}.json` +- `{sessionFolder}/exploration-{angle1}.json` +- `{sessionFolder}/exploration-{angle2}.json` - ... (1-4 files based on complexity) -- `${sessionFolder}/explorations-manifest.json` +- `{sessionFolder}/explorations-manifest.json` -**Generate Exploration Notes** (auto-generated after exploration completes): +#### Generate Exploration Notes -```javascript -// Step 1: Load all exploration JSON files -const manifest = JSON.parse(Read(`${sessionFolder}/explorations-manifest.json`)) -const explorations = manifest.explorations.map(exp => ({ - angle: exp.angle, - data: JSON.parse(Read(exp.path)) -})) +Auto-generated after exploration completes. -// Step 2: Extract core files (relevance ≥ 0.7) -const coreFiles = [] -explorations.forEach(exp => { - if (Array.isArray(exp.data.relevant_files)) { - exp.data.relevant_files.forEach(f => { - if (typeof f === 'object' && f.relevance >= 0.7) { - coreFiles.push({ path: f.path, relevance: f.relevance, rationale: f.rationale, angle: exp.angle }) - } - }) - } -}) -const uniqueCoreFiles = deduplicateByPath(coreFiles.sort((a, b) => b.relevance - a.relevance)) +**Steps**: -// Step 3: Build exploration notes Markdown (6 sections) -const explorationLog = `# Exploration Notes: ${task_description.slice(0, 60)} +1. **Load** all exploration JSON files via manifest +2. **Extract core files** — Filter `relevant_files` with relevance ≥ 0.7, sort by relevance descending, deduplicate by path +3. **Build exploration notes** — 6-part Markdown document (structure below) +4. **Write** to `{sessionFolder}/exploration-notes.md` -**Generated**: ${getUtc8ISOString()} -**Task**: ${task_description} -**Complexity**: ${complexity} -**Exploration Angles**: ${explorations.map(e => e.angle).join(', ')} +**Exploration Notes Structure** (`exploration-notes.md`): + +```markdown +# Exploration Notes: {task_description} + +**Generated**: {timestamp} | **Complexity**: {complexity} +**Exploration Angles**: {angles} --- ## Part 1: Multi-Angle Exploration Summary - -${explorations.map(exp => `### Angle: ${exp.angle} - -**Key Files** (priority sorted): -${formatFileList(exp.data.relevant_files)} - -**Code Patterns**: ${exp.data.patterns} - -**Integration Points**: ${exp.data.integration_points} - -**Dependencies**: ${exp.data.dependencies} - -**Constraints**: ${exp.data.constraints} -`).join('\n---\n')} - ---- +Per angle: Key Files (priority sorted), Code Patterns, Integration Points, Dependencies, Constraints ## Part 2: File Deep-Dive Summary - -${uniqueCoreFiles.slice(0, 10).map(file => { - const content = Read(file.path) - const refs = Bash(\`rg "from ['\"].*${path.basename(file.path, path.extname(file.path))}['\"]" --type ts -n | head -10\`) - return formatFileDeepDive(file, content, refs) -}).join('\n---\n')} - ---- +Top 10 core files: read content, find cross-references via rg, format structural details ## Part 3: Architecture Reasoning Chains - -${buildReasoningChains(explorations, task_description)} - ---- +Synthesized from exploration findings and task description ## Part 4: Potential Risks and Mitigations - -${buildRiskMitigations(explorations, uniqueCoreFiles)} - ---- +Derived from explorations and core file analysis ## Part 5: Clarification Questions Summary - -${aggregateClarifications(explorations)} - ---- +Aggregated from all exploration angles ## Part 6: Execution Recommendations Checklist - -${generateExecutionChecklist(task_description, explorations, uniqueCoreFiles)} +Generated from task description, explorations, and core files --- ## Appendix: Key Code Location Index | Component | File Path | Key Lines | Purpose | -|-----------|-----------|-----------|---------| -${uniqueCoreFiles.slice(0, 15).map(f => `| ${path.basename(f.path)} | ${f.path} | - | ${f.rationale} |`).join('\n')} -` - -// Step 4: Write initial exploration notes -Write(`${sessionFolder}/exploration-notes.md`, explorationLog) - -console.log(` -## Exploration Notes Generated - -File: ${sessionFolder}/exploration-notes.md -Core files: ${uniqueCoreFiles.length} -Angles: ${explorations.map(e => e.angle).join(', ')} - -This log will be fully consumed by planning phase, then refined for execution. -`) ``` -**Output (new)**: -- `${sessionFolder}/exploration-notes.md` (full version, consumed by Plan phase) +**Output**: `{sessionFolder}/exploration-notes.md` (full version, consumed by Plan phase) --- ### Phase 2: Clarification (Optional, Multi-Round) -**Skip if**: No exploration or `clarification_needs` is empty across all explorations +**Skip Conditions**: No exploration performed OR `clarification_needs` empty across all explorations -**⚠️ CRITICAL**: ASK_USER tool limits max 4 questions per call. **MUST execute multiple rounds** to exhaust all clarification needs - do NOT stop at round 1. +**⚠️ CRITICAL**: ASK_USER limits max 4 questions per call. **MUST execute multiple rounds** to exhaust all clarification needs — do NOT stop at round 1. -**Aggregate clarification needs from all exploration angles**: -```javascript -// Load manifest and all exploration files -const manifest = JSON.parse(Read(`${sessionFolder}/explorations-manifest.json`)) -const explorations = manifest.explorations.map(exp => ({ - angle: exp.angle, - data: JSON.parse(Read(exp.path)) -})) +**Flow**: -// Aggregate clarification needs from all explorations -const allClarifications = [] -explorations.forEach(exp => { - if (exp.data.clarification_needs?.length > 0) { - exp.data.clarification_needs.forEach(need => { - allClarifications.push({ - ...need, - source_angle: exp.angle - }) - }) - } -}) +``` +1. Load manifest + all exploration files -// Intelligent deduplication: analyze allClarifications by intent -// - Identify questions with similar intent across different angles -// - Merge similar questions: combine options, consolidate context -// - Produce dedupedClarifications with unique intents only -const dedupedClarifications = intelligentMerge(allClarifications) +2. Aggregate clarification_needs + └─ For each exploration → collect needs, tag each with source_angle -// Parse --yes flag -const autoYes = $ARGUMENTS.includes('--yes') || $ARGUMENTS.includes('-y') +3. Deduplicate + └─ Intelligent merge: identify similar intent across angles + → combine options, consolidate context + → produce unique-intent questions only -if (autoYes) { - // Auto mode: Skip clarification phase - console.log(`[--yes] Skipping ${dedupedClarifications.length} clarification questions`) - console.log(`Proceeding to planning with exploration results...`) - // Continue to Phase 3 -} else if (dedupedClarifications.length > 0) { - // Interactive mode: Multi-round clarification - const BATCH_SIZE = 4 - const totalRounds = Math.ceil(dedupedClarifications.length / BATCH_SIZE) - - for (let i = 0; i < dedupedClarifications.length; i += BATCH_SIZE) { - const batch = dedupedClarifications.slice(i, i + BATCH_SIZE) - const currentRound = Math.floor(i / BATCH_SIZE) + 1 - - console.log(`### Clarification Round ${currentRound}/${totalRounds}`) - - ASK_USER(batch.map(need => ({ - id: `clarify-${need.source_angle}`, - type: "select", - prompt: `[${need.source_angle}] ${need.question}\n\nContext: ${need.context}`, - options: need.options.map((opt, index) => ({ - label: need.recommended === index ? `${opt} ★` : opt, - description: need.recommended === index ? `Recommended` : `Use ${opt}` - })), - default: need.recommended - }))) // BLOCKS (wait for user response) - - // Store batch responses in clarificationContext before next round - } -} +4. Route by mode: + ├─ --yes mode → Skip all clarifications, log count, proceed to Phase 3 + └─ Interactive mode → Multi-round clarification: + ├─ Batch size: 4 questions per round + ├─ Per round: display "Round N/M", present via ASK_USER + │ └─ Each question: [source_angle] question + context + │ Options with recommended marked ★ + ├─ Store responses in clarificationContext after each round + └─ Repeat until all questions exhausted ``` -**Output**: `clarificationContext` (in-memory) +**Output**: `clarificationContext` (in-memory, keyed by question) --- ### Phase 3: Planning -**Planning Strategy Selection** (based on Phase 1 complexity): +**IMPORTANT**: Phase 3 is **planning only** — NO code execution. All execution happens in Phase 5 via lite-execute. -**IMPORTANT**: Phase 3 is **planning only** - NO code execution. All execution happens in Phase 5 via lite-execute. +#### Executor Assignment Rules -**Executor Assignment** (Claude 智能分配,plan 生成后执行): +Applied after plan generation. Priority (high → low): +1. **User explicit** — If task description specifies tool (e.g., "用 gemini 分析...") → use that executor +2. **Default** → agent + +Result: `executorAssignments` map — `{ taskId: { executor: 'gemini'|'codex'|'agent', reason: string } }` + +#### Low Complexity — Direct Planning by Claude + +1. **Read schema** — `cat ~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json` +2. **Read ALL exploration files** (⚠️ MANDATORY) — Load manifest, read each exploration JSON, review findings +3. **Generate plan** following schema — Claude directly generates plan incorporating exploration insights + +**plan.json structure** (Low complexity): ```javascript -// 分配规则(优先级从高到低): -// 1. 用户明确指定:"用 gemini 分析..." → gemini, "codex 实现..." → codex -// 2. 默认 → agent - -const executorAssignments = {} // { taskId: { executor: 'gemini'|'codex'|'agent', reason: string } } -plan.tasks.forEach(task => { - // Claude 根据上述规则语义分析,为每个 task 分配 executor - executorAssignments[task.id] = { executor: '...', reason: '...' } -}) -``` - -**Low Complexity** - Direct planning by Claude: -```javascript -// Step 1: Read schema -const schema = Bash(`cat ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json`) - -// Step 2: ⚠️ MANDATORY - Read and review ALL exploration files -const manifest = JSON.parse(Read(`${sessionFolder}/explorations-manifest.json`)) -manifest.explorations.forEach(exp => { - const explorationData = Read(exp.path) - console.log(`\n### Exploration: ${exp.angle}\n${explorationData}`) -}) - -// Step 3: Generate plan following schema (Claude directly, no agent) -// ⚠️ Plan MUST incorporate insights from exploration files read in Step 2 -const plan = { +{ summary: "...", approach: "...", - tasks: [...], // Each task: { id, title, scope, ..., depends_on, execution_group, complexity } + tasks: [...], // Each: { id, title, scope, ..., depends_on, execution_group, complexity } estimated_time: "...", recommended_execution: "Agent", complexity: "Low", - _metadata: { timestamp: getUtc8ISOString(), source: "direct-planning", planning_mode: "direct" } + _metadata: { timestamp, source: "direct-planning", planning_mode: "direct" } } - -// Step 4: Write plan to session folder -Write(`${sessionFolder}/plan.json`, JSON.stringify(plan, null, 2)) - -// Step 5: MUST continue to Phase 4 (Confirmation) - DO NOT execute code here ``` -**Medium/High Complexity** - Invoke cli-lite-planning-agent: +4. **Write** `{sessionFolder}/plan.json` +5. **Continue** to Phase 4 (Confirmation) — DO NOT execute code here -```javascript -// Step 1: Create planning agent -const planningAgentId = spawn_agent({ - message: ` +#### Medium/High Complexity — Invoke cli-lite-planning-agent + +**Orchestration**: + +``` +1. Spawn planning agent → with Agent Prompt (below) +2. Wait for completion → timeout: 15 minutes +3. Close agent → after completion +``` + +**Agent Prompt Template**: + +``` ## TASK ASSIGNMENT ### MANDATORY FIRST STEPS (Agent Execute) @@ -595,13 +414,14 @@ Generate implementation plan and write plan.json. ## Output Location -**Session Folder**: ${sessionFolder} +**Session Folder**: {sessionFolder} **Output Files**: -- ${sessionFolder}/planning-context.md (evidence + understanding) -- ${sessionFolder}/plan.json (implementation plan) +- {sessionFolder}/planning-context.md (evidence + understanding) +- {sessionFolder}/plan.json (implementation plan) +- {sessionFolder}/exploration-notes-refined.md (refined exploration notes for Execute phase) ## Output Schema Reference -Execute: cat ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json (get schema reference before generating plan) +Execute: cat ~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json (get schema reference before generating plan) ## Project Context (MANDATORY - Read Both Files) 1. Read: .workflow/project-tech.json (technology stack, architecture, key components) @@ -610,30 +430,32 @@ Execute: cat ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json (ge **CRITICAL**: All generated tasks MUST comply with constraints in project-guidelines.json ## Task Description -${task_description} +{task_description} ## Multi-Angle Exploration Context -${manifest.explorations.map(exp => `### Exploration: ${exp.angle} (${exp.file}) -Path: ${exp.path} +{For each exploration: +### Exploration: {angle} ({file}) +Path: {path} -Read this file for detailed ${exp.angle} analysis.`).join('\n\n')} +Read this file for detailed {angle} analysis. +} -Total explorations: ${manifest.exploration_count} -Angles covered: ${manifest.explorations.map(e => e.angle).join(', ')} +Total explorations: {count} +Angles covered: {angles} -Manifest: ${sessionFolder}/explorations-manifest.json +Manifest: {sessionFolder}/explorations-manifest.json ## User Clarifications -${JSON.stringify(clarificationContext) || "None"} +{clarificationContext or "None"} ## Complexity Level -${complexity} +{complexity} ## Requirements Generate plan.json following the schema obtained above. Key constraints: - tasks: 2-7 structured tasks (**group by feature/module, NOT by file**) -- _metadata.exploration_angles: ${JSON.stringify(manifest.explorations.map(e => e.angle))} +- _metadata.exploration_angles: {angles} ## Task Grouping Rules 1. **Group by feature**: All changes for one feature = one task (even if 3-5 files) @@ -649,435 +471,97 @@ Generate plan.json following the schema obtained above. Key constraints: 2. Execute CLI planning using Gemini (Qwen fallback) 3. Read ALL exploration files for comprehensive context 4. Synthesize findings and generate plan following schema -5. **Write**: \`${sessionFolder}/planning-context.md\` (evidence paths + understanding) -6. **Write**: \`${sessionFolder}/plan.json\` -7. Return brief completion summary -` -}) - -// Step 2: Wait for planning completion -const planResult = wait({ - ids: [planningAgentId], - timeout_ms: 900000 // 15 minutes -}) - -// Step 3: Close planning agent -close_agent({ id: planningAgentId }) +5. **Write**: `{sessionFolder}/planning-context.md` (evidence paths + understanding) +6. **Write**: `{sessionFolder}/plan.json` +7. Execute Phase 5 (Plan Quality Check) and Phase 6 (Refine Exploration Notes) per agent role definition +8. **Write**: `{sessionFolder}/exploration-notes-refined.md` (Phase 6 output) +9. Return brief completion summary ``` -**Output**: `${sessionFolder}/plan.json` +**Output**: `{sessionFolder}/plan.json` + `{sessionFolder}/exploration-notes-refined.md` -**Refine Exploration Notes** (auto-executed after Plan completes): - -**Purpose**: Generate a self-contained execution reference from exploration-notes.md + plan.json. Execution agents should be able to implement tasks **without re-reading source files**. - -**Key Principle**: Each file entry must include enough structural detail (exports, key functions, types, line ranges) that an execution agent can write correct code (imports, function signatures, integration points) without opening the file. - -```javascript -// Step 1: Load plan, exploration notes, and exploration JSON files -const plan = JSON.parse(Read(`${sessionFolder}/plan.json`)) -const explorationLog = Read(`${sessionFolder}/exploration-notes.md`) -const manifest = JSON.parse(Read(`${sessionFolder}/explorations-manifest.json`)) -const explorations = manifest.explorations.map(exp => ({ - angle: exp.angle, - data: JSON.parse(Read(exp.path)) -})) - -// Step 2: Extract ALL files referenced in plan (modification_points + reference.files) -const planFiles = new Set() -const planScopes = new Set() -const fileTaskMap = {} // file → [taskIds] mapping for cross-reference - -plan.tasks.forEach(task => { - if (task.scope) planScopes.add(task.scope) - const taskFiles = [] - if (task.modification_points) { - task.modification_points.forEach(mp => { - planFiles.add(mp.file) - taskFiles.push(mp.file) - }) - } - if (task.reference?.files) { - task.reference.files.forEach(f => { - planFiles.add(f) - taskFiles.push(f) - }) - } - taskFiles.forEach(f => { - if (!fileTaskMap[f]) fileTaskMap[f] = [] - fileTaskMap[f].push(task.id) - }) -}) - -// Step 3: Read each plan-referenced file and extract structural details -const fileProfiles = {} - -Array.from(planFiles).forEach(filePath => { - try { - const content = Read(filePath) - const lines = content.split('\n') - const totalLines = lines.length - - // Extract exports (named + default) - const namedExports = [] - const defaultExport = [] - lines.forEach((line, idx) => { - if (/^export\s+(function|const|class|interface|type|enum|async\s+function)\s+(\w+)/.test(line)) { - const match = line.match(/^export\s+(?:async\s+)?(?:function|const|class|interface|type|enum)\s+(\w+)/) - if (match) namedExports.push({ name: match[1], line: idx + 1, declaration: line.trim().substring(0, 120) }) - } - if (/^export\s+default/.test(line)) { - defaultExport.push({ line: idx + 1, declaration: line.trim().substring(0, 120) }) - } - }) - - // Extract imports (first 30 lines typically) - const imports = [] - lines.slice(0, 50).forEach((line, idx) => { - if (/^import\s/.test(line)) { - imports.push({ line: idx + 1, statement: line.trim() }) - } - }) - - // Extract key function/class signatures (non-exported too) - const signatures = [] - lines.forEach((line, idx) => { - // Function declarations - if (/^\s*(async\s+)?function\s+\w+/.test(line) || /^\s*(export\s+)?(async\s+)?function\s+\w+/.test(line)) { - signatures.push({ line: idx + 1, signature: line.trim().substring(0, 150) }) - } - // Class declarations - if (/^\s*(export\s+)?class\s+\w+/.test(line)) { - signatures.push({ line: idx + 1, signature: line.trim().substring(0, 150) }) - } - // Arrow function assignments (const foo = ...) - if (/^\s*(export\s+)?(const|let)\s+\w+\s*=\s*(async\s+)?\(/.test(line)) { - signatures.push({ line: idx + 1, signature: line.trim().substring(0, 150) }) - } - }) - - // Extract modification points context (±5 lines around each modification_points.line) - const modificationContexts = [] - plan.tasks.forEach(task => { - if (task.modification_points) { - task.modification_points.filter(mp => mp.file === filePath && mp.line).forEach(mp => { - const startLine = Math.max(0, mp.line - 6) - const endLine = Math.min(totalLines, mp.line + 5) - modificationContexts.push({ - taskId: task.id, - taskTitle: task.title, - line: mp.line, - description: mp.description || '', - context: lines.slice(startLine, endLine).map((l, i) => `${startLine + i + 1}: ${l}`).join('\n') - }) - }) - } - }) - - fileProfiles[filePath] = { - totalLines, - imports, - namedExports, - defaultExport, - signatures, - modificationContexts, - relatedTasks: fileTaskMap[filePath] || [] - } - } catch (e) { - fileProfiles[filePath] = { error: `Failed to read: ${e.message}`, relatedTasks: fileTaskMap[filePath] || [] } - } -}) - -// Step 4: Build refined exploration notes with full file profiles -const refinedLog = `# Exploration Notes (Refined): ${task_description.slice(0, 60)} - -**Generated**: ${getUtc8ISOString()} -**Task**: ${task_description} -**Plan Tasks**: ${plan.tasks.length} -**Referenced Files**: ${planFiles.size} -**Refined For**: Execution phase — self-contained, no need to re-read source files - ---- - -## Part 1: File Profiles (Execution Reference) - -> Each profile contains enough detail for execution agents to write correct imports, -> call correct functions, and integrate at the right locations WITHOUT opening the file. - -${Array.from(planFiles).map(filePath => { - const profile = fileProfiles[filePath] - if (!profile || profile.error) { - return `### \`${filePath}\`\n\n⚠️ ${profile?.error || 'File not found'}\n**Related Tasks**: ${(profile?.relatedTasks || []).join(', ')}` - } - - return `### \`${filePath}\` - -**Lines**: ${profile.totalLines} | **Related Tasks**: ${profile.relatedTasks.join(', ')} - -**Imports**: -\`\`\` -${profile.imports.map(i => i.statement).join('\n') || '(none)'} -\`\`\` - -**Exports** (named): -${profile.namedExports.length > 0 - ? profile.namedExports.map(e => `- L${e.line}: \`${e.declaration}\``).join('\n') - : '(none)'} -${profile.defaultExport.length > 0 - ? `\n**Default Export**: L${profile.defaultExport[0].line}: \`${profile.defaultExport[0].declaration}\`` - : ''} - -**Key Signatures**: -${profile.signatures.slice(0, 15).map(s => `- L${s.line}: \`${s.signature}\``).join('\n') || '(none)'} - -${profile.modificationContexts.length > 0 ? `**Modification Points** (with surrounding code): -${profile.modificationContexts.map(mc => ` -#### → Task ${mc.taskId}: ${mc.taskTitle} -**Target Line ${mc.line}**: ${mc.description} -\`\`\` -${mc.context} -\`\`\` -`).join('\n')}` : ''} -` -}).join('\n---\n')} - ---- - -## Part 2: Task-Specific Execution Context - -${plan.tasks.map(task => { - const taskFiles = [] - if (task.modification_points) taskFiles.push(...task.modification_points.map(mp => mp.file)) - if (task.reference?.files) taskFiles.push(...task.reference.files) - const uniqueFiles = [...new Set(taskFiles)] - - return `### Task ${task.id}: ${task.title} - -**Scope**: \`${task.scope}\` -**Complexity**: ${task.complexity || 'N/A'} -**Depends On**: ${task.depends_on?.join(', ') || 'None (parallel-safe)'} - -**Files to Modify**: -${uniqueFiles.map(f => { - const profile = fileProfiles[f] - if (!profile || profile.error) return `- \`${f}\` — ⚠️ ${profile?.error || 'not profiled'}` - return `- \`${f}\` (${profile.totalLines} lines, ${profile.namedExports.length} exports)` -}).join('\n')} - -**Relevant Exploration Findings**: -${extractRelevantExploration(explorationLog, task)} - -**Reference Patterns**: -${task.reference?.pattern || 'Follow existing patterns in referenced files'} - -**Risk Notes**: -${extractRelevantRisks(explorationLog, task)} -` -}).join('\n---\n')} - ---- - -## Part 3: Cross-Cutting Concerns - -### Key Constraints (from exploration) -${extractConstraints(explorationLog)} - -### Integration Points (plan-task related) -${extractIntegrationPoints(explorationLog, planFiles)} - -### Dependencies (external packages & internal modules) -${extractDependencies(explorationLog, planFiles)} - -### Shared Patterns Across Tasks -${explorations.map(exp => { - if (exp.data.patterns) { - return `- **${exp.angle}**: ${typeof exp.data.patterns === 'string' ? exp.data.patterns.substring(0, 200) : JSON.stringify(exp.data.patterns).substring(0, 200)}` - } - return null -}).filter(Boolean).join('\n') || '(none extracted)'} - ---- - -## Appendix: Quick Lookup - -### File → Task Mapping - -| File | Tasks | Exports Count | Lines | -|------|-------|---------------|-------| -${Array.from(planFiles).map(f => { - const p = fileProfiles[f] - if (!p || p.error) return `| \`${f}\` | ${(p?.relatedTasks || []).join(', ')} | — | — |` - return `| \`${f}\` | ${p.relatedTasks.join(', ')} | ${p.namedExports.length} | ${p.totalLines} |` -}).join('\n')} - -### Original Exploration Notes - -Full exploration notes: \`${sessionFolder}/exploration-notes.md\` -` - -// Step 5: Write refined exploration notes -Write(`${sessionFolder}/exploration-notes-refined.md`, refinedLog) - -// Step 6: Update session artifacts -console.log(` -## Exploration Notes Refined - -Original: ${sessionFolder}/exploration-notes.md (full version, for Plan reference) -Refined: ${sessionFolder}/exploration-notes-refined.md (self-contained, for Execute consumption) - -File profiles: ${Object.keys(fileProfiles).length} files with structural details -Modification contexts: ${Object.values(fileProfiles).reduce((sum, p) => sum + (p.modificationContexts?.length || 0), 0)} code snippets -`) -``` - -**Output (new)**: `${sessionFolder}/exploration-notes-refined.md` +> **Note**: `exploration-notes-refined.md` is generated by cli-lite-planning-agent (Phase 6) as part of its execution flow. See `~/.codex/agents/cli-lite-planning-agent.md` Phase 6 for structure and generation logic. --- ### Phase 4: Task Confirmation & Execution Selection -**Step 4.1: Display Plan** -```javascript -const plan = JSON.parse(Read(`${sessionFolder}/plan.json`)) +#### Step 4.1: Display Plan -console.log(` -## Implementation Plan +Read `{sessionFolder}/plan.json` and display summary: -**Summary**: ${plan.summary} -**Approach**: ${plan.approach} +- **Summary**: plan.summary +- **Approach**: plan.approach +- **Tasks**: numbered list with title and file +- **Complexity**: plan.complexity +- **Estimated Time**: plan.estimated_time +- **Recommended**: plan.recommended_execution -**Tasks** (${plan.tasks.length}): -${plan.tasks.map((t, i) => `${i+1}. ${t.title} (${t.file})`).join('\n')} +#### Step 4.2: Collect Confirmation -**Complexity**: ${plan.complexity} -**Estimated Time**: ${plan.estimated_time} -**Recommended**: ${plan.recommended_execution} -`) +**Route by mode**: + +``` +├─ --yes mode → Auto-confirm with defaults: +│ ├─ Confirmation: "Allow" +│ ├─ Execution: "Auto" +│ └─ Review: "Skip" +│ +└─ Interactive mode → ASK_USER with 3 questions: ``` -**Step 4.2: Collect Confirmation** -```javascript -// Parse --yes flag -const autoYes = $ARGUMENTS.includes('--yes') || $ARGUMENTS.includes('-y') +**Interactive Questions**: -let userSelection +| Question | Options | Default | +|----------|---------|---------| +| Confirm plan? ({N} tasks, {complexity}) | Allow (proceed as-is), Modify (adjust before execution), Cancel (abort workflow) | Allow | +| Execution method | Agent (@code-developer), Codex (codex CLI), Auto (Low→Agent, else→Codex) | Auto | +| Code review after execution? | Gemini Review, Codex Review (git-aware), Agent Review, Skip | Skip | -if (autoYes) { - // Auto mode: Use defaults - console.log(`[--yes] Auto-confirming plan:`) - console.log(` - Confirmation: Allow`) - console.log(` - Execution: Auto`) - console.log(` - Review: Skip`) - - userSelection = { - confirmation: "Allow", - executionMethod: "Auto", - codeReviewTool: "Skip" - } -} else { - // Interactive mode: Ask user - const rawSelection = ASK_USER([ - { - id: "confirm", - type: "select", - prompt: `Confirm plan? (${plan.tasks.length} tasks, ${plan.complexity})`, - options: [ - { label: "Allow", description: "Proceed as-is" }, - { label: "Modify", description: "Adjust before execution" }, - { label: "Cancel", description: "Abort workflow" } - ], - default: "Allow" - }, - { - id: "execution", - type: "select", - prompt: "Execution method:", - options: [ - { label: "Agent", description: "@code-developer agent" }, - { label: "Codex", description: "codex CLI tool" }, - { label: "Auto", description: `Auto: ${plan.complexity === 'Low' ? 'Agent' : 'Codex'}` } - ], - default: "Auto" - }, - { - id: "review", - type: "select", - prompt: "Code review after execution?", - options: [ - { label: "Gemini Review", description: "Gemini CLI review" }, - { label: "Codex Review", description: "Git-aware review (prompt OR --uncommitted)" }, - { label: "Agent Review", description: "@code-reviewer agent" }, - { label: "Skip", description: "No review" } - ], - default: "Skip" - } - ]) // BLOCKS (wait for user response) - - userSelection = { - confirmation: rawSelection.confirm, - executionMethod: rawSelection.execution, - codeReviewTool: rawSelection.review - } -} -``` +**Output**: `userSelection` — `{ confirmation, executionMethod, codeReviewTool }` --- -### Phase 5: Execute to Execution +### Phase 5: Handoff to Execution **CRITICAL**: lite-plan NEVER executes code directly. ALL execution MUST go through lite-execute. -**Step 5.1: Build executionContext** +#### Step 5.1: Build executionContext + +Assemble the complete execution context from all planning phase outputs: ```javascript -// Load manifest and all exploration files -const manifest = JSON.parse(Read(`${sessionFolder}/explorations-manifest.json`)) -const explorations = {} - -manifest.explorations.forEach(exp => { - if (file_exists(exp.path)) { - explorations[exp.angle] = JSON.parse(Read(exp.path)) - } -}) - -const plan = JSON.parse(Read(`${sessionFolder}/plan.json`)) - -executionContext = { - planObject: plan, - explorationsContext: explorations, - explorationAngles: manifest.explorations.map(e => e.angle), - explorationManifest: manifest, - clarificationContext: clarificationContext || null, - userSelection: userSelection, - executionMethod: userSelection.executionMethod, // Global default; may be overridden by executorAssignments +{ + planObject: plan, // From plan.json + explorationsContext: { [angle]: explorationData }, // From exploration JSONs + explorationAngles: ["angle1", "angle2", ...], // From manifest + explorationManifest: manifest, // Full manifest object + clarificationContext: { [question]: answer } | null, + userSelection: { confirmation, executionMethod, codeReviewTool }, + executionMethod: userSelection.executionMethod, // Global default; may be overridden by executorAssignments codeReviewTool: userSelection.codeReviewTool, originalUserInput: task_description, // Task-level executor assignments (priority over global executionMethod) - executorAssignments: executorAssignments, // { taskId: { executor, reason } } + executorAssignments: { [taskId]: { executor, reason } }, session: { id: sessionId, folder: sessionFolder, artifacts: { - explorations: manifest.explorations.map(exp => ({ - angle: exp.angle, - path: exp.path - })), - explorations_manifest: `${sessionFolder}/explorations-manifest.json`, - exploration_log: `${sessionFolder}/exploration-notes.md`, // Full version (Plan consumption) - exploration_log_refined: `${sessionFolder}/exploration-notes-refined.md`, // Refined version (Execute consumption) - plan: `${sessionFolder}/plan.json` + explorations: [{ angle, path }], // Per-angle exploration paths + explorations_manifest: "{sessionFolder}/explorations-manifest.json", + exploration_log: "{sessionFolder}/exploration-notes.md", // Full version (Plan consumption) + exploration_log_refined: "{sessionFolder}/exploration-notes-refined.md", // Refined version (Execute consumption) + plan: "{sessionFolder}/plan.json" } } } ``` -**Step 5.2: Execute** +#### Step 5.2: Execute -```javascript -// → Hand off to Phase 4: Lite Execute (phases/04-lite-execute.md) --in-memory -``` +→ Hand off to Phase 2: Lite Execute (`phases/02-lite-execute.md`) with `--in-memory` flag ## Session Folder Structure @@ -1120,5 +604,5 @@ executionContext = { After Phase 1 (Lite Plan) completes: - **Output Created**: `executionContext` with plan.json, explorations, clarifications, user selections - **Session Artifacts**: All files in `.workflow/.lite-plan/{session-id}/` -- **Next Action**: Auto-continue to [Phase 4: Lite Execute](04-lite-execute.md) with --in-memory -- **TodoWrite**: Mark "Lite Plan - Planning" as completed, start "Execution (Phase 4)" +- **Next Action**: Auto-continue to [Phase 2: Lite Execute](02-lite-execute.md) with --in-memory +- **TodoWrite**: Mark "Lite Plan - Planning" as completed, start "Execution (Phase 2)" diff --git a/.codex/skills/workflow-lite-plan-execute/phases/02-lite-execute.md b/.codex/skills/workflow-lite-plan-execute/phases/02-lite-execute.md index 21ac091a..91d4c94f 100644 --- a/.codex/skills/workflow-lite-plan-execute/phases/02-lite-execute.md +++ b/.codex/skills/workflow-lite-plan-execute/phases/02-lite-execute.md @@ -1,4 +1,4 @@ -# Phase 4: Lite Execute +# Phase 2: Lite Execute ## Overview @@ -46,50 +46,16 @@ Flexible task execution phase supporting three input modes: in-memory plan (from - Proceed to execution with `originalUserInput` included **User Interaction**: -```javascript -// Parse --yes flag -const autoYes = $ARGUMENTS.includes('--yes') || $ARGUMENTS.includes('-y') -let userSelection - -if (autoYes) { - // Auto mode: Use defaults - console.log(`[--yes] Auto-confirming execution:`) - console.log(` - Execution method: Auto`) - console.log(` - Code review: Skip`) - - userSelection = { - execution_method: "Auto", - code_review_tool: "Skip" - } -} else { - // Interactive mode: Ask user - userSelection = ASK_USER([ - { - id: "execution", - type: "select", - prompt: "Select execution method:", - options: [ - { label: "Agent", description: "@code-developer agent" }, - { label: "Codex", description: "codex CLI tool" }, - { label: "Auto", description: "Auto-select based on complexity" } - ], - default: "Auto" - }, - { - id: "review", - type: "select", - prompt: "Enable code review after execution?", - options: [ - { label: "Skip", description: "No review" }, - { label: "Gemini Review", description: "Gemini CLI tool" }, - { label: "Codex Review", description: "Git-aware review (prompt OR --uncommitted)" }, - { label: "Agent Review", description: "Current agent review" } - ], - default: "Skip" - } - ]) // BLOCKS (wait for user response) -} +``` +Route by mode: +├─ --yes mode → Auto-confirm with defaults: +│ ├─ Execution method: Auto +│ └─ Code review: Skip +│ +└─ Interactive mode → ASK_USER with 2 questions: + ├─ Execution method: Agent (@code-developer) / Codex (codex CLI) / Auto (complexity-based) + └─ Code review: Skip / Gemini Review / Codex Review (git-aware) / Agent Review ``` ### Mode 3: File Content @@ -98,47 +64,18 @@ if (autoYes) { **Input**: Path to file containing task description or plan.json -**Step 1: Read and Detect Format** +**Format Detection**: -```javascript -fileContent = Read(filePath) - -// Attempt JSON parsing -try { - jsonData = JSON.parse(fileContent) - - // Check if plan.json from lite-plan session - if (jsonData.summary && jsonData.approach && jsonData.tasks) { - planObject = jsonData - originalUserInput = jsonData.summary - isPlanJson = true - } else { - // Valid JSON but not plan.json - treat as plain text - originalUserInput = fileContent - isPlanJson = false - } -} catch { - // Not valid JSON - treat as plain text prompt - originalUserInput = fileContent - isPlanJson = false -} ``` - -**Step 2: Create Execution Plan** - -If `isPlanJson === true`: -- Use `planObject` directly -- User selects execution method and code review - -If `isPlanJson === false`: -- Treat file content as prompt (same behavior as Mode 2) -- Create simple execution plan from content - -**Step 3: User Interaction** - -- ASK_USER: Select execution method (Agent/Codex/Auto) -- ASK_USER: Select code review tool -- Proceed to execution with full context +1. Read file content +2. Attempt JSON parsing + ├─ Valid JSON with summary + approach + tasks fields → plan.json format + │ ├─ Use parsed data as planObject + │ └─ Set originalUserInput = summary + └─ Not valid JSON or missing required fields → plain text format + └─ Set originalUserInput = file content (same as Mode 2) +3. User selects execution method + code review (same as Mode 2) +``` ## Execution Process @@ -173,379 +110,213 @@ Output: ### Step 1: Initialize Execution Tracking **Operations**: -- Initialize result tracking for multi-execution scenarios -- Set up `previousExecutionResults` array for context continuity +- Initialize `previousExecutionResults` array for context continuity - **In-Memory Mode**: Echo execution strategy from planning phase for transparency - -```javascript -// Initialize result tracking -previousExecutionResults = [] - -// In-Memory Mode: Echo execution strategy (transparency before execution) -if (executionContext) { - console.log(` -Execution Strategy (from planning phase): - Method: ${executionContext.executionMethod} - Review: ${executionContext.codeReviewTool} - Tasks: ${executionContext.planObject.tasks.length} - Complexity: ${executionContext.planObject.complexity} -${executionContext.executorAssignments ? ` Assignments: ${JSON.stringify(executionContext.executorAssignments)}` : ''} - `) -} -``` + - Display: Method, Review tool, Task count, Complexity, Executor assignments (if present) ### Step 2: Task Grouping & Batch Creation -**Dependency Analysis & Grouping Algorithm**: -```javascript -// Use explicit depends_on from plan.json (no inference from file/keywords) -function extractDependencies(tasks) { - const taskIdToIndex = {} - tasks.forEach((t, i) => { taskIdToIndex[t.id] = i }) +**Dependency Analysis**: Use **explicit** `depends_on` from plan.json only — no inference from file paths or keywords. - return tasks.map((task, i) => { - // Only use explicit depends_on from plan.json - const deps = (task.depends_on || []) - .map(depId => taskIdToIndex[depId]) - .filter(idx => idx !== undefined && idx < i) - return { ...task, taskIndex: i, dependencies: deps } - }) -} +``` +1. Build task ID → index mapping -// Group into batches: maximize parallel execution -function createExecutionCalls(tasks, executionMethod) { - const tasksWithDeps = extractDependencies(tasks) - const processed = new Set() - const calls = [] +2. For each task: + └─ Resolve depends_on IDs to task indices + └─ Filter: only valid IDs that reference earlier tasks - // Phase 1: All independent tasks → single parallel batch (maximize utilization) - const independentTasks = tasksWithDeps.filter(t => t.dependencies.length === 0) - if (independentTasks.length > 0) { - independentTasks.forEach(t => processed.add(t.taskIndex)) - calls.push({ - method: executionMethod, - executionType: "parallel", - groupId: "P1", - taskSummary: independentTasks.map(t => t.title).join(' | '), - tasks: independentTasks - }) - } +3. Group into execution batches: + ├─ Phase 1: All tasks with NO dependencies → single parallel batch + │ └─ Mark as processed + └─ Phase 2+: Iterative dependency resolution + ├─ Find tasks whose ALL dependencies are satisfied (processed) + ├─ Group ready tasks as batch (parallel within batch if multiple) + ├─ Mark as processed + ├─ Repeat until no tasks remain + └─ Safety: If no ready tasks found → circular dependency warning → force remaining - // Phase 2: Dependent tasks → sequential batches (respect dependencies) - let sequentialIndex = 1 - let remaining = tasksWithDeps.filter(t => !processed.has(t.taskIndex)) +4. Assign batch IDs: + ├─ Parallel batches: P1, P2, P3... + └─ Sequential batches: S1, S2, S3... - while (remaining.length > 0) { - // Find tasks whose dependencies are all satisfied - const ready = remaining.filter(t => - t.dependencies.every(d => processed.has(d)) - ) - - if (ready.length === 0) { - console.warn('Circular dependency detected, forcing remaining tasks') - ready.push(...remaining) - } - - // Group ready tasks (can run in parallel within this phase) - ready.forEach(t => processed.add(t.taskIndex)) - calls.push({ - method: executionMethod, - executionType: ready.length > 1 ? "parallel" : "sequential", - groupId: ready.length > 1 ? `P${calls.length + 1}` : `S${sequentialIndex++}`, - taskSummary: ready.map(t => t.title).join(ready.length > 1 ? ' | ' : ' → '), - tasks: ready - }) - - remaining = remaining.filter(t => !processed.has(t.taskIndex)) - } - - return calls -} - -executionCalls = createExecutionCalls(planObject.tasks, executionMethod).map(c => ({ ...c, id: `[${c.groupId}]` })) - -TodoWrite({ - todos: executionCalls.map(c => ({ - content: `${c.executionType === "parallel" ? "⚡" : "→"} ${c.id} (${c.tasks.length} tasks)`, - status: "pending", - activeForm: `Executing ${c.id}` - })) -}) +5. Create TodoWrite list with batch indicators: + ├─ ⚡ for parallel batches (concurrent) + └─ → for sequential batches (one-by-one) ``` ### Step 3: Launch Execution -**Executor Resolution** (任务级 executor 优先于全局设置): -```javascript -// 获取任务的 executor(优先使用 executorAssignments,fallback 到全局 executionMethod) -function getTaskExecutor(task) { - const assignments = executionContext?.executorAssignments || {} - if (assignments[task.id]) { - return assignments[task.id].executor // 'gemini' | 'codex' | 'agent' - } - // Fallback: 全局 executionMethod 映射 - const method = executionContext?.executionMethod || 'Auto' - if (method === 'Agent') return 'agent' - if (method === 'Codex') return 'codex' - // Auto: 根据复杂度 - return planObject.complexity === 'Low' ? 'agent' : 'codex' -} +#### Executor Resolution -// 按 executor 分组任务 -function groupTasksByExecutor(tasks) { - const groups = { gemini: [], codex: [], agent: [] } - tasks.forEach(task => { - const executor = getTaskExecutor(task) - groups[executor].push(task) - }) - return groups -} +Task-level executor assignment takes priority over global execution method: + +``` +Resolution order (per task): +├─ 1. executorAssignments[task.id] → use assigned executor (gemini/codex/agent) +└─ 2. Fallback to global executionMethod: + ├─ "Agent" → agent + ├─ "Codex" → codex + └─ "Auto" → Low complexity → agent; Medium/High → codex ``` -**Execution Flow**: Parallel batches concurrently → Sequential batches in order -```javascript -const parallel = executionCalls.filter(c => c.executionType === "parallel") -const sequential = executionCalls.filter(c => c.executionType === "sequential") +#### Execution Flow -// Phase 1: Launch all parallel batches (single message with multiple tool calls) -if (parallel.length > 0) { - TodoWrite({ todos: executionCalls.map(c => ({ status: c.executionType === "parallel" ? "in_progress" : "pending" })) }) - parallelResults = await Promise.all(parallel.map(c => executeBatch(c))) - previousExecutionResults.push(...parallelResults) - TodoWrite({ todos: executionCalls.map(c => ({ status: parallel.includes(c) ? "completed" : "pending" })) }) -} +``` +1. Separate batches into parallel and sequential groups -// Phase 2: Execute sequential batches one by one -for (const call of sequential) { - TodoWrite({ todos: executionCalls.map(c => ({ status: c === call ? "in_progress" : "..." })) }) - result = await executeBatch(call) - previousExecutionResults.push(result) - TodoWrite({ todos: executionCalls.map(c => ({ status: "completed" or "pending" })) }) -} +2. Phase 1 — Launch all parallel batches concurrently: + ├─ Update TodoWrite: all parallel → in_progress + ├─ Execute all parallel batches simultaneously (single message, multiple tool calls) + ├─ Collect results → append to previousExecutionResults + └─ Update TodoWrite: all parallel → completed + +3. Phase 2+ — Execute sequential batches in order: + ├─ For each sequential batch: + │ ├─ Update TodoWrite: current batch → in_progress + │ ├─ Execute batch + │ ├─ Collect result → append to previousExecutionResults + │ └─ Update TodoWrite: current batch → completed + └─ Continue until all batches completed ``` ### Unified Task Prompt Builder -**Task Formatting Principle**: Each task is a self-contained checklist. The executor only needs to know what THIS task requires. Same template for Agent and CLI. +Each task is formatted as a **self-contained checklist**. The executor only needs to know what THIS task requires. Same template for Agent and CLI. -```javascript -function buildExecutionPrompt(batch) { - // Task template (6 parts: Modification Points → Why → How → Reference → Risks → Done) - const formatTask = (t) => ` -## ${t.title} +**Prompt Structure** (assembled from batch tasks): -**Scope**: \`${t.scope}\` | **Action**: ${t.action} +``` +## Goal +{originalUserInput} -### Modification Points -${t.modification_points.map(p => `- **${p.file}** → \`${p.target}\`: ${p.change}`).join('\n')} +## Tasks +(For each task in batch, separated by ---) -${t.rationale ? ` -### Why this approach (Medium/High) -${t.rationale.chosen_approach} -${t.rationale.decision_factors?.length > 0 ? `\nKey factors: ${t.rationale.decision_factors.join(', ')}` : ''} -${t.rationale.tradeoffs ? `\nTradeoffs: ${t.rationale.tradeoffs}` : ''} -` : ''} +### {task.title} +**Scope**: {task.scope} | **Action**: {task.action} -### How to do it -${t.description} +#### Modification Points +- **{file}** → `{target}`: {change} -${t.implementation.map(step => `- ${step}`).join('\n')} +#### Why this approach (Medium/High only) +{rationale.chosen_approach} +Key factors: {decision_factors} +Tradeoffs: {tradeoffs} -${t.code_skeleton ? ` -### Code skeleton (High) -${t.code_skeleton.interfaces?.length > 0 ? `**Interfaces**: ${t.code_skeleton.interfaces.map(i => `\`${i.name}\` - ${i.purpose}`).join(', ')}` : ''} -${t.code_skeleton.key_functions?.length > 0 ? `\n**Functions**: ${t.code_skeleton.key_functions.map(f => `\`${f.signature}\` - ${f.purpose}`).join(', ')}` : ''} -${t.code_skeleton.classes?.length > 0 ? `\n**Classes**: ${t.code_skeleton.classes.map(c => `\`${c.name}\` - ${c.purpose}`).join(', ')}` : ''} -` : ''} +#### How to do it +{description} +{implementation steps} -### Reference -- Pattern: ${t.reference?.pattern || 'N/A'} -- Files: ${t.reference?.files?.join(', ') || 'N/A'} -${t.reference?.examples ? `- Notes: ${t.reference.examples}` : ''} +#### Code skeleton (High only) +Interfaces: {interfaces} +Functions: {key_functions} +Classes: {classes} -${t.risks?.length > 0 ? ` -### Risk mitigations (High) -${t.risks.map(r => `- ${r.description} → **${r.mitigation}**`).join('\n')} -` : ''} +#### Reference +- Pattern: {pattern} +- Files: {files} +- Notes: {examples} -### Done when -${t.acceptance.map(c => `- [ ] ${c}`).join('\n')} -${t.verification?.success_metrics?.length > 0 ? `\n**Success metrics**: ${t.verification.success_metrics.join(', ')}` : ''}` +#### Risk mitigations (High only) +- {risk.description} → **{risk.mitigation}** - // Build prompt - const sections = [] +#### Done when +- [ ] {acceptance criteria} +Success metrics: {verification.success_metrics} - if (originalUserInput) sections.push(`## Goal\n${originalUserInput}`) +## Context +(Assembled from available sources, reference only) - sections.push(`## Tasks\n${batch.tasks.map(formatTask).join('\n\n---\n')}`) +### Exploration Notes (Refined) +**Read first**: {exploration_log_refined path} +Contains: file index, task-relevant context, code reference, execution notes +**IMPORTANT**: Use to avoid re-exploring already analyzed files - // Context (reference only) - const context = [] +### Previous Work +{previousExecutionResults summaries} - // Priority: reference refined exploration notes (Execute phase specific) - if (executionContext?.session?.artifacts?.exploration_log_refined) { - context.push(`### Exploration Notes (Refined) -**Read first**: ${executionContext.session.artifacts.exploration_log_refined} +### Clarifications +{clarificationContext entries} -This refined notes contains only execution-relevant context: -- Execution-relevant file index (files directly related to plan tasks) -- Task-relevant exploration context (findings, patterns, risks per task) -- Condensed code reference (code snippets with line numbers) -- Execution notes (constraints, integration points, dependencies) +### Data Flow +{planObject.data_flow.diagram} -**IMPORTANT**: Use this refined notes to avoid re-exploring files. DO NOT re-read files already analyzed in the notes unless verifying specific implementation details.`) - } +### Artifacts +Plan: {plan path} - if (previousExecutionResults.length > 0) { - context.push(`### Previous Work\n${previousExecutionResults.map(r => `- ${r.tasksSummary}: ${r.status}`).join('\n')}`) - } - if (clarificationContext) { - context.push(`### Clarifications\n${Object.entries(clarificationContext).map(([q, a]) => `- ${q}: ${a}`).join('\n')}`) - } - if (executionContext?.planObject?.data_flow?.diagram) { - context.push(`### Data Flow\n${executionContext.planObject.data_flow.diagram}`) - } - if (executionContext?.session?.artifacts?.plan) { - context.push(`### Artifacts\nPlan: ${executionContext.session.artifacts.plan}`) - } - // Project guidelines (user-defined constraints) - context.push(`### Project Guidelines\n@.workflow/project-guidelines.json`) - if (context.length > 0) sections.push(`## Context\n${context.join('\n\n')}`) +### Project Guidelines +@.workflow/project-guidelines.json - sections.push(`Complete each task according to its "Done when" checklist.`) - - return sections.join('\n\n') -} +Complete each task according to its "Done when" checklist. ``` -**Option A: Agent Execution** +#### Option A: Agent Execution -When to use: -- `getTaskExecutor(task) === "agent"` -- or `executionMethod = "Agent"` (global fallback) -- or `executionMethod = "Auto" AND complexity = "Low"` (global fallback) +**When to use**: `getTaskExecutor(task) === "agent"`, or global `executionMethod = "Agent"`, or `Auto AND complexity = Low` -```javascript -// Step 1: Create execution agent with mandatory context reading -const executionAgentId = spawn_agent({ - message: ` -## TASK ASSIGNMENT +**Execution Flow**: -### MANDATORY FIRST STEPS (Agent Execute) -1. **Read role definition**: ~/.codex/agents/code-developer.md (MUST read first) -2. Read: .workflow/project-tech.json -3. Read: .workflow/project-guidelines.json -4. **Read refined exploration log**: ${executionContext?.session?.artifacts?.exploration_log_refined || 'N/A'} +``` +1. Spawn code-developer agent with prompt: + ├─ MANDATORY FIRST STEPS: + │ ├─ Read: ~/.codex/agents/code-developer.md + │ ├─ Read: .workflow/project-tech.json + │ ├─ Read: .workflow/project-guidelines.json + │ └─ Read: {exploration_log_refined} (execution-relevant context) + └─ Body: {buildExecutionPrompt(batch)} -**CRITICAL**: Step 4 contains execution-relevant context including: -- Task-relevant code patterns and integration points -- Condensed code reference (with line numbers) -- Execution constraints and risk notes +2. Wait for completion (timeout: 10 minutes) -Use the notes to avoid re-exploring files - the analysis is already done. +3. Close agent after collection ---- - -${buildExecutionPrompt(batch)} -` -}) - -// Step 2: Wait for execution completion -const execResult = wait({ - ids: [executionAgentId], - timeout_ms: 600000 // 10 minutes -}) - -// Step 3: Close execution agent -close_agent({ id: executionAgentId }) +4. Collect result → executionResult structure ``` -**Result Collection**: After completion, collect result following `executionResult` structure (see Data Structures section) +#### Option B: CLI Execution (Codex) -**Option B: CLI Execution (Codex)** +**When to use**: `getTaskExecutor(task) === "codex"`, or global `executionMethod = "Codex"`, or `Auto AND complexity = Medium/High` -When to use: -- `getTaskExecutor(task) === "codex"` -- or `executionMethod = "Codex"` (global fallback) -- or `executionMethod = "Auto" AND complexity = "Medium/High"` (global fallback) +**Execution**: ```bash -ccw cli -p "${buildExecutionPrompt(batch)}" --tool codex --mode write +ccw cli -p "{buildExecutionPrompt(batch)}" --tool codex --mode write --id {sessionId}-{groupId} ``` -**Execution with fixed IDs** (predictable ID pattern): -```javascript -// Launch CLI in background, wait for task hook callback -// Generate fixed execution ID: ${sessionId}-${groupId} -const sessionId = executionContext?.session?.id || 'standalone' -const fixedExecutionId = `${sessionId}-${batch.groupId}` // e.g., "implement-auth-2025-12-13-P1" +**Fixed ID Pattern**: `{sessionId}-{groupId}` (e.g., `implement-auth-2025-12-13-P1`) -// Check if resuming from previous failed execution -const previousCliId = batch.resumeFromCliId || null +**Execution Mode**: Background (`run_in_background=true`) → Stop output → Wait for task hook callback -// Build command with fixed ID (and optional resume for continuation) -const cli_command = previousCliId - ? `ccw cli -p "${buildExecutionPrompt(batch)}" --tool codex --mode write --id ${fixedExecutionId} --resume ${previousCliId}` - : `ccw cli -p "${buildExecutionPrompt(batch)}" --tool codex --mode write --id ${fixedExecutionId}` +**Resume on Failure**: -// Execute in background, stop output and wait for task hook callback -Bash( - command=cli_command, - run_in_background=true -) -// STOP HERE - CLI executes in background, task hook will notify on completion +``` +If status = failed or timeout: +├─ Display: Fixed ID, lookup command, resume command +├─ Lookup: ccw cli detail {fixedExecutionId} +└─ Resume: ccw cli -p "Continue tasks" --resume {fixedExecutionId} --tool codex --mode write --id {fixedExecutionId}-retry ``` -**Resume on Failure** (with fixed ID): -```javascript -// If execution failed or timed out, offer resume option -if (bash_result.status === 'failed' || bash_result.status === 'timeout') { - console.log(` -Execution incomplete. Resume available: - Fixed ID: ${fixedExecutionId} - Lookup: ccw cli detail ${fixedExecutionId} - Resume: ccw cli -p "Continue tasks" --resume ${fixedExecutionId} --tool codex --mode write --id ${fixedExecutionId}-retry -`) +#### Option C: CLI Execution (Gemini) - // Store for potential retry in same session - batch.resumeFromCliId = fixedExecutionId -} -``` - -**Result Collection**: After completion, analyze output and collect result following `executionResult` structure (include `cliExecutionId` for resume capability) - -**Option C: CLI Execution (Gemini)** - -When to use: `getTaskExecutor(task) === "gemini"` (analysis tasks) +**When to use**: `getTaskExecutor(task) === "gemini"` (analysis tasks) ```bash -# Use unified buildExecutionPrompt, switch tool and mode -ccw cli -p "${buildExecutionPrompt(batch)}" --tool gemini --mode analysis --id ${sessionId}-${batch.groupId} +ccw cli -p "{buildExecutionPrompt(batch)}" --tool gemini --mode analysis --id {sessionId}-{groupId} ``` ### Step 4: Progress Tracking -Progress tracked at batch level (not individual task level). Icons: ⚡ (parallel, concurrent), → (sequential, one-by-one) +Progress tracked at **batch level** (not individual task level). + +| Icon | Meaning | +|------|---------| +| ⚡ | Parallel batch (concurrent execution) | +| → | Sequential batch (one-by-one execution) | ### Step 5: Code Review (Optional) **Skip Condition**: Only run if `codeReviewTool ≠ "Skip"` -**Review Focus**: Verify implementation against plan acceptance criteria and verification requirements -- Read plan.json for task acceptance criteria and verification checklist -- Check each acceptance criterion is fulfilled -- Verify success metrics from verification field (Medium/High complexity) -- Run unit/integration tests specified in verification field -- Validate code quality and identify issues -- Ensure alignment with planned approach and risk mitigations - -**Operations**: -- Agent Review: Current agent performs direct review -- Gemini Review: Execute gemini CLI with review prompt -- Codex Review: Two options - (A) with prompt for complex reviews, (B) `--uncommitted` flag only for quick reviews -- Custom tool: Execute specified CLI tool (qwen, etc.) - -**Unified Review Template** (All tools use same standard): +**Review Focus**: Verify implementation against plan acceptance criteria and verification requirements. **Review Criteria**: - **Acceptance Criteria**: Verify each criterion from plan.tasks[].acceptance @@ -553,7 +324,8 @@ Progress tracked at batch level (not individual task level). Icons: ⚡ (paralle - **Code Quality**: Analyze quality, identify issues, suggest improvements - **Plan Alignment**: Validate implementation matches planned approach and risk mitigations -**Shared Prompt Template** (used by all CLI tools): +**Shared Review Prompt Template**: + ``` PURPOSE: Code review for implemented changes against plan acceptance criteria and verification requirements TASK: • Verify plan acceptance criteria fulfillment • Check verification requirements (unit tests, success metrics) • Analyze code quality • Identify issues • Suggest improvements • Validate plan adherence and risk mitigations @@ -568,52 +340,26 @@ EXPECTED: Quality assessment with: CONSTRAINTS: Focus on plan acceptance criteria, verification requirements, and plan adherence | analysis=READ-ONLY ``` -**Tool-Specific Execution** (Apply shared prompt template above): +**Tool-Specific Execution**: + +| Tool | Command | Notes | +|------|---------|-------| +| Agent Review | Direct review by current agent | Read plan.json, apply review criteria, report findings | +| Gemini Review | `ccw cli -p "[review prompt]" --tool gemini --mode analysis` | Recommended | +| Qwen Review | `ccw cli -p "[review prompt]" --tool qwen --mode analysis` | Alternative | +| Codex Review (A) | `ccw cli -p "[review prompt]" --tool codex --mode review` | Complex reviews with focus areas | +| Codex Review (B) | `ccw cli --tool codex --mode review --uncommitted` | Quick review, no custom prompt | + +> **IMPORTANT**: `-p` prompt and target flags (`--uncommitted`/`--base`/`--commit`) are **mutually exclusive** for codex review. + +**Multi-Round Review**: Generate fixed review ID (`{sessionId}-review`). If issues found, resume with follow-up: ```bash -# Method 1: Agent Review (current agent) -# - Read plan.json: ${executionContext.session.artifacts.plan} -# - Apply unified review criteria (see Shared Prompt Template) -# - Report findings directly - -# Method 2: Gemini Review (recommended) -ccw cli -p "[Shared Prompt Template with artifacts]" --tool gemini --mode analysis -# CONTEXT includes: @**/* @${plan.json} [@${exploration.json}] - -# Method 3: Qwen Review (alternative) -ccw cli -p "[Shared Prompt Template with artifacts]" --tool qwen --mode analysis -# Same prompt as Gemini, different execution engine - -# Method 4: Codex Review (git-aware) - Two mutually exclusive options: - -# Option A: With custom prompt (reviews uncommitted by default) -ccw cli -p "[Shared Prompt Template with artifacts]" --tool codex --mode review -# Use for complex reviews with specific focus areas - -# Option B: Target flag only (no prompt allowed) -ccw cli --tool codex --mode review --uncommitted -# Quick review of uncommitted changes without custom instructions - -# IMPORTANT: -p prompt and target flags (--uncommitted/--base/--commit) are MUTUALLY EXCLUSIVE +ccw cli -p "Clarify the security concerns" --resume {reviewId} --tool gemini --mode analysis --id {reviewId}-followup ``` -**Multi-Round Review with Fixed IDs**: -```javascript -// Generate fixed review ID -const reviewId = `${sessionId}-review` - -// First review pass with fixed ID -const reviewResult = Bash(`ccw cli -p "[Review prompt]" --tool gemini --mode analysis --id ${reviewId}`) - -// If issues found, continue review dialog with fixed ID chain -if (hasUnresolvedIssues(reviewResult)) { - // Resume with follow-up questions - Bash(`ccw cli -p "Clarify the security concerns you mentioned" --resume ${reviewId} --tool gemini --mode analysis --id ${reviewId}-followup`) -} -``` - -**Implementation Note**: Replace `[Shared Prompt Template with artifacts]` placeholder with actual template content, substituting: -- `@{plan.json}` → `@${executionContext.session.artifacts.plan}` +**Implementation Note**: Replace `[review prompt]` placeholder with actual Shared Review Prompt Template content, substituting: +- `@{plan.json}` → `@{executionContext.session.artifacts.plan}` - `[@{exploration.json}]` → exploration files from artifacts (if exists) ### Step 6: Update Development Index @@ -623,49 +369,35 @@ if (hasUnresolvedIssues(reviewResult)) { **Skip Condition**: Skip if `.workflow/project-tech.json` does not exist **Operations**: -```javascript -const projectJsonPath = '.workflow/project-tech.json' -if (!fileExists(projectJsonPath)) return // Silent skip -const projectJson = JSON.parse(Read(projectJsonPath)) +``` +1. Read .workflow/project-tech.json + └─ If not found → silent skip -// Initialize if needed -if (!projectJson.development_index) { - projectJson.development_index = { feature: [], enhancement: [], bugfix: [], refactor: [], docs: [] } -} +2. Initialize development_index if missing + └─ Categories: feature, enhancement, bugfix, refactor, docs -// Detect category from keywords -function detectCategory(text) { - text = text.toLowerCase() - if (/\b(fix|bug|error|issue|crash)\b/.test(text)) return 'bugfix' - if (/\b(refactor|cleanup|reorganize)\b/.test(text)) return 'refactor' - if (/\b(doc|readme|comment)\b/.test(text)) return 'docs' - if (/\b(add|new|create|implement)\b/.test(text)) return 'feature' - return 'enhancement' -} +3. Detect category from task keywords: + ├─ fix/bug/error/issue/crash → bugfix + ├─ refactor/cleanup/reorganize → refactor + ├─ doc/readme/comment → docs + ├─ add/new/create/implement → feature + └─ (default) → enhancement -// Detect sub_feature from task file paths -function detectSubFeature(tasks) { - const dirs = tasks.map(t => t.file?.split('/').slice(-2, -1)[0]).filter(Boolean) - const counts = dirs.reduce((a, d) => { a[d] = (a[d] || 0) + 1; return a }, {}) - return Object.entries(counts).sort((a, b) => b[1] - a[1])[0]?.[0] || 'general' -} +4. Detect sub_feature from task file paths + └─ Extract parent directory names, return most frequent -const category = detectCategory(`${planObject.summary} ${planObject.approach}`) -const entry = { - title: planObject.summary.slice(0, 60), - sub_feature: detectSubFeature(planObject.tasks), - date: new Date().toISOString().split('T')[0], - description: planObject.approach.slice(0, 100), - status: previousExecutionResults.every(r => r.status === 'completed') ? 'completed' : 'partial', - session_id: executionContext?.session?.id || null -} +5. Create entry: + ├─ title: plan summary (max 60 chars) + ├─ sub_feature: detected from file paths + ├─ date: current date (YYYY-MM-DD) + ├─ description: plan approach (max 100 chars) + ├─ status: "completed" if all results completed, else "partial" + └─ session_id: from executionContext -projectJson.development_index[category].push(entry) -projectJson.statistics.last_updated = new Date().toISOString() -Write(projectJsonPath, JSON.stringify(projectJson, null, 2)) - -console.log(`Development index: [${category}] ${entry.title}`) +6. Append entry to development_index[category] +7. Update statistics.last_updated timestamp +8. Write updated project-tech.json ``` ## Best Practices @@ -683,7 +415,7 @@ console.log(`Development index: [${category}] ${entry.title}`) | Empty file | File exists but no content | Error: "File is empty: {path}. Provide task description." | | Invalid Enhanced Task JSON | JSON missing required fields | Warning: "Missing required fields. Treating as plain text." | | Malformed JSON | JSON parsing fails | Treat as plain text (expected for non-JSON files) | -| Execution failure | Agent/Codex crashes | Display error, use fixed ID `${sessionId}-${groupId}` for resume: `ccw cli -p "Continue" --resume --id -retry` | +| Execution failure | Agent/Codex crashes | Display error, use fixed ID `{sessionId}-{groupId}` for resume | | Execution timeout | CLI exceeded timeout | Use fixed ID for resume with extended timeout | | Codex unavailable | Codex not installed | Show installation instructions, offer Agent execution | | Fixed ID not found | Custom ID lookup failed | Check `ccw cli history`, verify date directories | @@ -760,22 +492,23 @@ Appended to `previousExecutionResults` array for context continuity in multi-exe After completion, ask user whether to expand as issue (test/enhance/refactor/doc). Selected items create new issues accordingly. -**Fixed ID Pattern**: `${sessionId}-${groupId}` enables predictable lookup without auto-generated timestamps. +**Fixed ID Pattern**: `{sessionId}-{groupId}` enables predictable lookup without auto-generated timestamps. **Resume Usage**: If `status` is "partial" or "failed", use `fixedCliId` to resume: + ```bash # Lookup previous execution -ccw cli detail ${fixedCliId} +ccw cli detail {fixedCliId} # Resume with new fixed ID for retry -ccw cli -p "Continue from where we left off" --resume ${fixedCliId} --tool codex --mode write --id ${fixedCliId}-retry +ccw cli -p "Continue from where we left off" --resume {fixedCliId} --tool codex --mode write --id {fixedCliId}-retry ``` --- ## Post-Phase Update -After Phase 4 (Lite Execute) completes: +After Phase 2 (Lite Execute) completes: - **Output Created**: Executed tasks, optional code review results, updated development index - **Execution Results**: `previousExecutionResults[]` with status per batch - **Next Action**: Workflow complete. Optionally expand to issue (test/enhance/refactor/doc) diff --git a/.codex/skills/workflow-plan-execute/phases/02-context-gathering.md b/.codex/skills/workflow-plan-execute/phases/02-context-gathering.md index 8268de7a..ed1521c2 100644 --- a/.codex/skills/workflow-plan-execute/phases/02-context-gathering.md +++ b/.codex/skills/workflow-plan-execute/phases/02-context-gathering.md @@ -156,7 +156,7 @@ Execute **${angle}** exploration for task planning context. Analyze codebase fro **You (cli-explore-agent) MUST execute these steps in order:** 1. Run: ccw tool exec get_modules_by_depth '{}' (project structure) 2. Run: rg -l "{keyword_from_task}" --type ts (locate relevant files) -3. Execute: cat ~/.claude/workflows/cli-templates/schemas/explore-json-schema.json (get output schema reference) +3. Execute: cat ~/.ccw/workflows/cli-templates/schemas/explore-json-schema.json (get output schema reference) ## Exploration Strategy (${angle} focus) @@ -313,7 +313,7 @@ const conflictAgentId = spawn_agent({ ## Analysis Steps ### 0. Load Output Schema (MANDATORY) -Execute: cat ~/.claude/workflows/cli-templates/schemas/conflict-resolution-schema.json +Execute: cat ~/.ccw/workflows/cli-templates/schemas/conflict-resolution-schema.json ### 1. Load Context - Read existing files from conflict indicators @@ -357,7 +357,7 @@ Template per conflict: ### 4. Return Structured Conflict Data -**Schema Reference**: Execute \`cat ~/.claude/workflows/cli-templates/schemas/conflict-resolution-schema.json\` to get full schema +**Schema Reference**: Execute \`cat ~/.ccw/workflows/cli-templates/schemas/conflict-resolution-schema.json\` to get full schema Return JSON following the schema above. Key requirements: - Minimum 2 strategies per conflict, max 4 diff --git a/.codex/skills/workflow-tdd-plan/phases/02-task-generate-tdd.md b/.codex/skills/workflow-tdd-plan/phases/02-task-generate-tdd.md index ad47a7e6..2ac6ac1a 100644 --- a/.codex/skills/workflow-tdd-plan/phases/02-task-generate-tdd.md +++ b/.codex/skills/workflow-tdd-plan/phases/02-task-generate-tdd.md @@ -435,7 +435,7 @@ IMPORTANT: Do NOT add command field to implementation_approach steps. Execution ##### 2. IMPL_PLAN.md (TDD Variant) - **Location**: \`.workflow/active/{session-id}/IMPL_PLAN.md\` -- **Template**: \`~/.claude/workflows/cli-templates/prompts/workflow/impl-plan-template.txt\` +- **Template**: \`~/.ccw/workflows/cli-templates/prompts/workflow/impl-plan-template.txt\` - **TDD-Specific Frontmatter**: workflow_type="tdd", tdd_workflow=true, feature_count, task_breakdown - **TDD Implementation Tasks Section**: Feature-by-feature with internal Red-Green-Refactor cycles - **Context Analysis**: Artifact references and exploration insights diff --git a/.codex/skills/workflow-test-fix-cycle/phases/02-test-cycle-execute.md b/.codex/skills/workflow-test-fix-cycle/phases/02-test-cycle-execute.md index f97b4a16..0a259f66 100644 --- a/.codex/skills/workflow-test-fix-cycle/phases/02-test-cycle-execute.md +++ b/.codex/skills/workflow-test-fix-cycle/phases/02-test-cycle-execute.md @@ -263,7 +263,7 @@ const taskTypeSuccessCriteria = { ## CLI Tool Configuration **Fallback Chain**: Gemini → Qwen → Codex -**Template**: `~/.codex/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt` +**Template**: `~/.ccw/workflows/cli-templates/prompts/analysis/01-diagnose-bug-root-cause.txt` **Timeout**: 40min (2400000ms) **Tool Details**: diff --git a/INSTALL.md b/INSTALL.md index 7e02cc35..c8459ae9 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -24,7 +24,7 @@ ccw install ``` The `ccw install` command will: -- Install workflow definitions to `~/.claude/workflows/` +- Install workflow definitions to `~/.ccw/workflows/` - Install utility scripts to `~/.claude/scripts/` - Install prompt templates to `~/.claude/templates/` - Install skill definitions to `~/.codex/skills/` @@ -80,7 +80,7 @@ CCW uses a **configuration-based tool control system** that makes external CLI t - ✅ **Graceful degradation** - Automatic fallback when tools are unavailable - ✅ **Flexible configuration** - Control tool availability per project -**Configuration File**: `~/.claude/workflows/tool-control.yaml` +**Configuration File**: `~/.ccw/workflows/tool-control.yaml` ```yaml tools: @@ -110,7 +110,7 @@ While CCW works with Claude alone, installing these tools provides enhanced anal #### External AI Tools -Configure these tools in `~/.claude/workflows/tool-control.yaml` after installation: +Configure these tools in `~/.ccw/workflows/tool-control.yaml` after installation: | Tool | Purpose | Installation | |------|---------|--------------| diff --git a/INSTALL_CN.md b/INSTALL_CN.md index e4c459ef..b8c6332f 100644 --- a/INSTALL_CN.md +++ b/INSTALL_CN.md @@ -24,7 +24,7 @@ ccw install ``` `ccw install` 命令将会: -- 安装工作流定义到 `~/.claude/workflows/` +- 安装工作流定义到 `~/.ccw/workflows/` - 安装实用脚本到 `~/.claude/scripts/` - 安装提示模板到 `~/.claude/templates/` - 安装技能定义到 `~/.codex/skills/` @@ -80,7 +80,7 @@ CCW 使用**基于配置的工具控制系统**,使外部 CLI 工具成为** - ✅ **优雅降级** - 工具不可用时自动回退 - ✅ **灵活配置** - 每个项目控制工具可用性 -**配置文件**:`~/.claude/workflows/tool-control.yaml` +**配置文件**:`~/.ccw/workflows/tool-control.yaml` ```yaml tools: @@ -110,7 +110,7 @@ tools: #### 外部 AI 工具 -在 `~/.claude/workflows/tool-control.yaml` 中配置这些工具: +在 `~/.ccw/workflows/tool-control.yaml` 中配置这些工具: | 工具 | 用途 | 安装方式 | |------|------|----------| diff --git a/ccw/docs-site/build/assets/js/19b64556.267a65e7.js b/ccw/docs-site/build/assets/js/19b64556.267a65e7.js index 81946479..59365b55 100644 --- a/ccw/docs-site/build/assets/js/19b64556.267a65e7.js +++ b/ccw/docs-site/build/assets/js/19b64556.267a65e7.js @@ -1 +1 @@ -"use strict";(globalThis.webpackChunkccw_docs=globalThis.webpackChunkccw_docs||[]).push([[57],{1184(e,n,i){i.d(n,{R:()=>t,x:()=>c});var s=i(3696);const l={},r=s.createContext(l);function t(e){const n=s.useContext(r);return s.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(l):e.components||l:t(e.components),s.createElement(r.Provider,{value:n},e.children)}},7259(e,n,i){i.r(n),i.d(n,{assets:()=>o,contentTitle:()=>d,default:()=>h,frontMatter:()=>c,metadata:()=>s,toc:()=>a});const s=JSON.parse('{"id":"workflows/level-2-rapid","title":"Level 2 - Rapid Workflows","description":"Lightweight planning and bug diagnosis workflows for single-module features","source":"@site/docs/workflows/level-2-rapid.mdx","sourceDirName":"workflows","slug":"/workflows/level-2-rapid","permalink":"/docs/workflows/level-2-rapid","draft":false,"unlisted":false,"editUrl":"https://github.com/ccw/docs/tree/main/docs/workflows/level-2-rapid.mdx","tags":[],"version":"current","sidebarPosition":3,"frontMatter":{"title":"Level 2 - Rapid Workflows","description":"Lightweight planning and bug diagnosis workflows for single-module features","sidebar_position":3},"sidebar":"docs","previous":{"title":"Level 1: Ultra Lightweight","permalink":"/docs/workflows/level-1-ultra-lightweight"},"next":{"title":"Level 3: Standard","permalink":"/docs/workflows/level-3-standard"}}');var l=i(2540),r=i(1184),t=i(1540);const c={title:"Level 2 - Rapid Workflows",description:"Lightweight planning and bug diagnosis workflows for single-module features",sidebar_position:3},d="Level 2: Rapid Workflows",o={},a=[{value:"Overview",id:"overview",level:2},{value:"Included Workflows",id:"included-workflows",level:2},{value:"Common Characteristics",id:"common-characteristics",level:3},{value:"Workflow 1: lite-plan -> lite-execute",id:"workflow-1-lite-plan---lite-execute",level:2},{value:"Command",id:"command",level:3},{value:"Flow Diagram",id:"flow-diagram",level:3},{value:"Process Phases",id:"process-phases",level:3},{value:"Artifacts",id:"artifacts",level:3},{value:"Use Case",id:"use-case",level:3},{value:"Workflow 2: lite-fix",id:"workflow-2-lite-fix",level:2},{value:"Command",id:"command-1",level:3},{value:"Flow Diagram",id:"flow-diagram-1",level:3},{value:"Process Phases",id:"process-phases-1",level:3},{value:"Artifacts",id:"artifacts-1",level:3},{value:"Severity Levels",id:"severity-levels",level:3},{value:"Hotfix Mode",id:"hotfix-mode",level:3},{value:"Use Cases",id:"use-cases",level:3},{value:"Workflow 3: multi-cli-plan -> lite-execute",id:"workflow-3-multi-cli-plan---lite-execute",level:2},{value:"Command",id:"command-2",level:3},{value:"Flow Diagram",id:"flow-diagram-2",level:3},{value:"Process Phases",id:"process-phases-2",level:3},{value:"Artifacts",id:"artifacts-2",level:3},{value:"vs lite-plan Comparison",id:"vs-lite-plan-comparison",level:3},{value:"Use Cases",id:"use-cases-1",level:3},{value:"Level 2 Comparison Table",id:"level-2-comparison-table",level:2},{value:"Execution: lite-execute",id:"execution-lite-execute",level:2},{value:"Execution Flow",id:"execution-flow",level:3},{value:"Features",id:"features",level:3},{value:"Related Workflows",id:"related-workflows",level:2}];function x(e){const n={a:"a",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",hr:"hr",li:"li",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,r.R)(),...e.components};return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(n.header,{children:(0,l.jsx)(n.h1,{id:"level-2-rapid-workflows",children:"Level 2: Rapid Workflows"})}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Complexity"}),": Low-Medium | ",(0,l.jsx)(n.strong,{children:"Artifacts"}),": Memory/Lightweight files | ",(0,l.jsx)(n.strong,{children:"State"}),": Session-scoped"]}),"\n",(0,l.jsx)(n.p,{children:"Level 2 workflows provide lightweight planning or single analysis with fast iteration. They're designed for tasks with relatively clear requirements that don't need full session persistence."}),"\n",(0,l.jsx)(n.h2,{id:"overview",children:"Overview"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n Start([User Input]) --\x3e Select{Select Workflow}\n\n Select --\x3e|Clear
requirements| LP[lite-plan]\n Select --\x3e|Bug fix| LF[lite-fix]\n Select --\x3e|Multi-CLI
needed| MCP[multi-cli-plan]\n\n LP --\x3e LE[lite-execute]\n LF --\x3e LE\n MCP --\x3e LE\n\n LE --\x3e Test{Tests?}\n Test --\x3e|Yes| TFG[test-fix-gen]\n Test --\x3e|No| Done([Complete])\n TFG --\x3e TCE[test-cycle-execute]\n TCE --\x3e Done\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef workflow fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef execute fill:#c5e1a5,stroke:#388e3c\n\n class Start,Done startend,Select,Test decision,LP,LF,MCP workflow,LE execute,TFG,TCE execute\n"}),"\n",(0,l.jsx)(n.h2,{id:"included-workflows",children:"Included Workflows"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Workflow"}),(0,l.jsx)(n.th,{children:"Purpose"}),(0,l.jsx)(n.th,{children:"Artifacts"}),(0,l.jsx)(n.th,{children:"Execution"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:"lite-plan"})}),(0,l.jsx)(n.td,{children:"Clear requirement development"}),(0,l.jsx)(n.td,{children:"memory://plan"}),(0,l.jsxs)(n.td,{children:["-> ",(0,l.jsx)(n.code,{children:"lite-execute"})]})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:"lite-fix"})}),(0,l.jsx)(n.td,{children:"Bug diagnosis and fix"}),(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:".workflow/.lite-fix/"})}),(0,l.jsxs)(n.td,{children:["-> ",(0,l.jsx)(n.code,{children:"lite-execute"})]})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:"multi-cli-plan"})}),(0,l.jsx)(n.td,{children:"Multi-perspective tasks"}),(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:".workflow/.multi-cli-plan/"})}),(0,l.jsxs)(n.td,{children:["-> ",(0,l.jsx)(n.code,{children:"lite-execute"})]})]})]})]}),"\n",(0,l.jsx)(n.h3,{id:"common-characteristics",children:"Common Characteristics"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Property"}),(0,l.jsx)(n.th,{children:"Value"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Complexity"})}),(0,l.jsx)(n.td,{children:"Low-Medium"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"State"})}),(0,l.jsx)(n.td,{children:"Session-scoped / Lightweight persistence"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Execution"})}),(0,l.jsxs)(n.td,{children:["Unified via ",(0,l.jsx)(n.code,{children:"lite-execute"})]})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Use Case"})}),(0,l.jsx)(n.td,{children:"Relatively clear requirements"})]})]})]}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h2,{id:"workflow-1-lite-plan---lite-execute",children:"Workflow 1: lite-plan -> lite-execute"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"In-memory planning + Direct execution"})}),"\n",(0,l.jsx)(n.h3,{id:"command",children:"Command"}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-plan "Add user authentication API"\n/workflow:lite-execute\n'})}),"\n",(0,l.jsx)(n.h3,{id:"flow-diagram",children:"Flow Diagram"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n A([Start]) --\x3e B[Phase 1: Code Exploration]\n B --\x3e C{Code
Exploration?}\n C --\x3e|Yes| D[cli-explore-agent
Multi-angle analysis]\n C --\x3e|No| E[Skip exploration]\n\n D --\x3e F[Phase 2: Complexity Assessment]\n E --\x3e F\n\n F --\x3e G{Complexity}\n G --\x3e|Low| H[Direct Claude
Planning]\n G --\x3e|Medium| H\n G --\x3e|High| I[cli-lite-planning
-agent]\n\n H --\x3e J[Phase 3: Planning]\n I --\x3e J\n\n J --\x3e K[Phase 4: Confirmation]\n K --\x3e L{Confirm?}\n L --\x3e|Modify| M[Adjust plan]\n M --\x3e K\n L --\x3e|Allow| N[Phase 5: Execute]\n L --\x3e|Cancel| O([Abort])\n\n N --\x3e P[Build executionContext]\n P --\x3e Q[/workflow:lite-execute]\n Q --\x3e R([Complete])\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n\n class A,R,O startend,B,D,E,J,M,P,Q action,C,G,L decision,F,H,I agent\n"}),"\n",(0,l.jsx)(n.h3,{id:"process-phases",children:"Process Phases"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Phase 1: Code Exploration"})," (Optional)"]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'# If -e flag specified\n/workflow:lite-plan -e "Add user authentication API"\n'})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Multi-angle code analysis via cli-explore-agent"}),"\n",(0,l.jsx)(n.li,{children:"Identifies patterns, dependencies, integration points"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 2: Complexity Assessment"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Low: Direct planning without agent"}),"\n",(0,l.jsx)(n.li,{children:"Medium/High: Use cli-lite-planning-agent"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 3: Planning"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:["Load plan schema: ",(0,l.jsx)(n.code,{children:"~/.claude/workflows/cli-templates/schemas/plan-json-schema.json"})]}),"\n",(0,l.jsx)(n.li,{children:"Generate plan.json following schema"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 4: Confirmation & Selection"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Display plan summary (tasks, complexity, estimated time)"}),"\n",(0,l.jsxs)(n.li,{children:["Ask user selections:","\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Confirm: Allow / Modify / Cancel"}),"\n",(0,l.jsx)(n.li,{children:"Execution: Agent / Codex / Auto"}),"\n",(0,l.jsx)(n.li,{children:"Review: Gemini / Agent / Skip"}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 5: Execute"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Build executionContext (plan + explorations + clarifications + selections)"}),"\n",(0,l.jsxs)(n.li,{children:["Execute via ",(0,l.jsx)(n.code,{children:"/workflow:lite-execute --in-memory"})]}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"artifacts",children:"Artifacts"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"In-memory"}),": ",(0,l.jsx)(n.code,{children:"memory://plan"})," (not persisted)"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"Optional"}),": ",(0,l.jsx)(n.code,{children:".workflow/.lite-exploration/"})," (if code exploration used)"]}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"use-case",children:"Use Case"}),"\n",(0,l.jsx)(n.p,{children:"Clear single-module features"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Example"}),":"]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-plan "Add email validation to user registration form"\n/workflow:lite-execute\n'})}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h2,{id:"workflow-2-lite-fix",children:"Workflow 2: lite-fix"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Intelligent diagnosis + Fix (5 phases)"})}),"\n",(0,l.jsx)(n.h3,{id:"command-1",children:"Command"}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-fix "Login timeout after 30 seconds"\n/workflow:lite-execute --in-memory --mode bugfix\n\n# Emergency hotfix mode\n/workflow:lite-fix --hotfix "Production database connection failing"\n'})}),"\n",(0,l.jsx)(n.h3,{id:"flow-diagram-1",children:"Flow Diagram"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n A([Start]) --\x3e B[Phase 1: Bug Analysis
& Diagnosis]\n B --\x3e C[Severity Pre-assessment
Low/Medium/High/Critical]\n C --\x3e D[Parallel cli-explore
-agent Diagnosis
1-4 angles]\n\n D --\x3e E[Phase 2: Clarification]\n E --\x3e F{More info
needed?}\n F --\x3e|Yes| G[AskUserQuestion
Aggregate clarifications]\n F --\x3e|No| H[Phase 3: Fix Planning]\n G --\x3e H\n\n H --\x3e I{Severity}\n I --\x3e|Low/Medium| J[Direct Claude
Planning]\n I --\x3e|High/Critical| K[cli-lite-planning
-agent]\n\n J --\x3e L[Phase 4: Confirmation]\n K --\x3e L\n\n L --\x3e M[User confirms
execution method]\n M --\x3e N[Phase 5: Execute]\n N --\x3e O[/workflow:lite-execute
--in-memory --mode bugfix/]\n O --\x3e P([Complete])\n\n Q[Hotfix Mode] --\x3e R[Skip diagnosis
Minimal planning]\n R --\x3e N\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n classDef hotfix fill:#ffccbc,stroke:#bf360c\n\n class A,P startend,B,E,G,H,L,M,N,O action,F,I decision,C,D,J,K agent,Q,R hotfix\n"}),"\n",(0,l.jsx)(n.h3,{id:"process-phases-1",children:"Process Phases"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 1: Bug Analysis & Diagnosis"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Intelligent severity pre-assessment (Low/Medium/High/Critical)"}),"\n",(0,l.jsx)(n.li,{children:"Parallel cli-explore-agent diagnosis (1-4 angles)"}),"\n"]}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Phase 2: Clarification"})," (Optional)"]}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Aggregate clarification needs"}),"\n",(0,l.jsx)(n.li,{children:"AskUserQuestion for missing info"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 3: Fix Planning"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Low/Medium severity -> Direct Claude planning"}),"\n",(0,l.jsx)(n.li,{children:"High/Critical severity -> cli-lite-planning-agent"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 4: Confirmation & Selection"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Display fix-plan summary"}),"\n",(0,l.jsx)(n.li,{children:"User confirms execution method"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 5: Execute"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:["Execute via ",(0,l.jsx)(n.code,{children:"/workflow:lite-execute --in-memory --mode bugfix"})]}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"artifacts-1",children:"Artifacts"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Location"}),": ",(0,l.jsx)(n.code,{children:".workflow/.lite-fix/{bug-slug}-{YYYY-MM-DD}/"})]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{children:".workflow/.lite-fix/\n\u2514\u2500\u2500 login-timeout-fix-2025-02-03/\n \u251c\u2500\u2500 diagnosis-root-cause.json\n \u251c\u2500\u2500 diagnosis-impact.json\n \u251c\u2500\u2500 diagnosis-code-flow.json\n \u251c\u2500\u2500 diagnosis-similar.json\n \u251c\u2500\u2500 diagnoses-manifest.json\n \u251c\u2500\u2500 fix-plan.json\n \u2514\u2500\u2500 README.md\n"})}),"\n",(0,l.jsx)(n.h3,{id:"severity-levels",children:"Severity Levels"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Severity"}),(0,l.jsx)(n.th,{children:"Description"}),(0,l.jsx)(n.th,{children:"Planning Method"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Low"})}),(0,l.jsx)(n.td,{children:"Simple fix, clear root cause"}),(0,l.jsx)(n.td,{children:"Direct Claude (optional rationale)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Medium"})}),(0,l.jsx)(n.td,{children:"Moderate complexity, some investigation"}),(0,l.jsx)(n.td,{children:"Direct Claude (with rationale)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"High"})}),(0,l.jsx)(n.td,{children:"Complex, multiple components affected"}),(0,l.jsx)(n.td,{children:"cli-lite-planning-agent (full schema)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Critical"})}),(0,l.jsx)(n.td,{children:"Production incident, urgent"}),(0,l.jsx)(n.td,{children:"cli-lite-planning-agent + hotfix mode"})]})]})]}),"\n",(0,l.jsx)(n.h3,{id:"hotfix-mode",children:"Hotfix Mode"}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-fix --hotfix "Production API returning 500 errors"\n'})}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Characteristics"}),":"]}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Skip most diagnosis phases"}),"\n",(0,l.jsx)(n.li,{children:"Minimal planning (direct execution)"}),"\n",(0,l.jsx)(n.li,{children:"Auto-generate follow-up tasks for complete fix + post-mortem"}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"use-cases",children:"Use Cases"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Bug diagnosis"}),"\n",(0,l.jsx)(n.li,{children:"Production emergencies"}),"\n",(0,l.jsx)(n.li,{children:"Root cause analysis"}),"\n"]}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h2,{id:"workflow-3-multi-cli-plan---lite-execute",children:"Workflow 3: multi-cli-plan -> lite-execute"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Multi-CLI collaborative analysis + Consensus convergence"})}),"\n",(0,l.jsx)(n.h3,{id:"command-2",children:"Command"}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:multi-cli-plan "Compare Redis vs Memcached for caching"\n/workflow:lite-execute\n'})}),"\n",(0,l.jsx)(n.h3,{id:"flow-diagram-2",children:"Flow Diagram"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n A([Start]) --\x3e B[Phase 1: Context Gathering]\n B --\x3e C[ACE semantic search
Build context package]\n\n C --\x3e D[Phase 2: Multi-CLI Discussion
Iterative]\n D --\x3e E[cli-discuss-agent]\n E --\x3e F[Gemini + Codex + Claude]\n\n F --\x3e G{Converged?}\n G --\x3e|No| H[Cross-verification
Synthesize solutions]\n H --\x3e D\n G --\x3e|Yes| I[Phase 3: Present Options]\n\n I --\x3e J[Display solutions
with trade-offs]\n\n J --\x3e K[Phase 4: User Decision]\n K --\x3e L[User selects solution]\n\n L --\x3e M[Phase 5: Plan Generation]\n M --\x3e N[cli-lite-planning
-agent]\n N --\x3e O[-> lite-execute]\n\n O --\x3e P([Complete])\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n\n class A,P startend,B,C,E,H,J,L,M,O action,G,K decision,F,N agent\n"}),"\n",(0,l.jsx)(n.h3,{id:"process-phases-2",children:"Process Phases"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 1: Context Gathering"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"ACE semantic search"}),"\n",(0,l.jsx)(n.li,{children:"Build context package"}),"\n"]}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Phase 2: Multi-CLI Discussion"})," (Iterative)"]}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"cli-discuss-agent executes Gemini + Codex + Claude"}),"\n",(0,l.jsx)(n.li,{children:"Cross-verification, synthesize solutions"}),"\n",(0,l.jsx)(n.li,{children:"Loop until convergence or max rounds"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 3: Present Options"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Display solutions with trade-offs"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 4: User Decision"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"User selects solution"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 5: Plan Generation"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"cli-lite-planning-agent generates plan"}),"\n",(0,l.jsx)(n.li,{children:"-> lite-execute"}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"artifacts-2",children:"Artifacts"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Location"}),": ",(0,l.jsx)(n.code,{children:".workflow/.multi-cli-plan/{MCP-task-slug-date}/"})]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{children:".workflow/.multi-cli-plan/\n\u2514\u2500\u2500 redis-vs-memcached-2025-02-03/\n \u251c\u2500\u2500 context-package.json\n \u251c\u2500\u2500 rounds/\n \u2502 \u251c\u2500\u2500 round-1/\n \u2502 \u2502 \u251c\u2500\u2500 gemini-analysis.md\n \u2502 \u2502 \u251c\u2500\u2500 codex-analysis.md\n \u2502 \u2502 \u251c\u2500\u2500 claude-analysis.md\n \u2502 \u2502 \u2514\u2500\u2500 synthesis.json\n \u2502 \u251c\u2500\u2500 round-2/\n \u2502 \u2514\u2500\u2500 ...\n \u251c\u2500\u2500 selected-solution.json\n \u251c\u2500\u2500 IMPL_PLAN.md\n \u2514\u2500\u2500 plan.json\n"})}),"\n",(0,l.jsx)(n.h3,{id:"vs-lite-plan-comparison",children:"vs lite-plan Comparison"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Aspect"}),(0,l.jsx)(n.th,{children:"multi-cli-plan"}),(0,l.jsx)(n.th,{children:"lite-plan"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Context"})}),(0,l.jsx)(n.td,{children:"ACE semantic search"}),(0,l.jsx)(n.td,{children:"Manual file patterns"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Analysis"})}),(0,l.jsx)(n.td,{children:"Multi-CLI cross-verification"}),(0,l.jsx)(n.td,{children:"Single planning"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Iteration"})}),(0,l.jsx)(n.td,{children:"Multiple rounds until convergence"}),(0,l.jsx)(n.td,{children:"Single round"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Confidence"})}),(0,l.jsx)(n.td,{children:"High (consensus-driven)"}),(0,l.jsx)(n.td,{children:"Medium (single perspective)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Time"})}),(0,l.jsx)(n.td,{children:"Longer (multi-round)"}),(0,l.jsx)(n.td,{children:"Faster"})]})]})]}),"\n",(0,l.jsx)(n.h3,{id:"use-cases-1",children:"Use Cases"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Multi-perspective analysis"}),"\n",(0,l.jsx)(n.li,{children:"Technology selection"}),"\n",(0,l.jsx)(n.li,{children:"Solution comparison"}),"\n",(0,l.jsx)(n.li,{children:"Architecture decisions"}),"\n"]}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h2,{id:"level-2-comparison-table",children:"Level 2 Comparison Table"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Aspect"}),(0,l.jsx)(n.th,{children:"lite-plan"}),(0,l.jsx)(n.th,{children:"lite-fix"}),(0,l.jsx)(n.th,{children:"multi-cli-plan"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Purpose"})}),(0,l.jsx)(n.td,{children:"Clear requirements"}),(0,l.jsx)(n.td,{children:"Bug diagnosis"}),(0,l.jsx)(n.td,{children:"Multi-perspective"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Planning"})}),(0,l.jsx)(n.td,{children:"In-memory"}),(0,l.jsx)(n.td,{children:"Severity-based"}),(0,l.jsx)(n.td,{children:"Consensus-driven"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Artifacts"})}),(0,l.jsx)(n.td,{children:"memory://plan"}),(0,l.jsx)(n.td,{children:".lite-fix/"}),(0,l.jsx)(n.td,{children:".multi-cli-plan/"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Code Exploration"})}),(0,l.jsx)(n.td,{children:"Optional (-e flag)"}),(0,l.jsx)(n.td,{children:"Built-in diagnosis"}),(0,l.jsx)(n.td,{children:"ACE search"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Multi-CLI"})}),(0,l.jsx)(n.td,{children:"No"}),(0,l.jsx)(n.td,{children:"No"}),(0,l.jsx)(n.td,{children:"Yes (Gemini/Codex/Claude)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Best For"})}),(0,l.jsx)(n.td,{children:"Single-module features"}),(0,l.jsx)(n.td,{children:"Bug fixes"}),(0,l.jsx)(n.td,{children:"Technology decisions"})]})]})]}),"\n",(0,l.jsx)(n.h2,{id:"execution-lite-execute",children:"Execution: lite-execute"}),"\n",(0,l.jsxs)(n.p,{children:["All Level 2 workflows execute via ",(0,l.jsx)(n.code,{children:"lite-execute"}),":"]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:"/workflow:lite-execute --in-memory\n"})}),"\n",(0,l.jsx)(n.h3,{id:"execution-flow",children:"Execution Flow"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n A([Start]) --\x3e B[Initialize tracking
previousExecutionResults]\n B --\x3e C[Task grouping
& batch creation]\n\n C --\x3e D[Extract explicit
depends_on]\n D --\x3e E[Group: independent
tasks -> parallel batch]\n E --\x3e F[Group: dependent
tasks -> sequential phases]\n\n F --\x3e G[Create TodoWrite
list for batches]\n G --\x3e H[Launch execution]\n\n H --\x3e I[Phase 1: All independent
tasks - Single batch]\n I --\x3e J[Phase 2+: Dependent tasks
by dependency order]\n\n J --\x3e K[Track progress
TodoWrite updates]\n K --\x3e L{Code review?}\n L --\x3e|Yes| M[Review process]\n L --\x3e|No| N([Complete])\n M --\x3e N\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n\n class A,N startend,B,D,E,F,G,I,J,K,M action,C,L decision\n"}),"\n",(0,l.jsx)(n.h3,{id:"features",children:"Features"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"Parallel execution"})," for independent tasks"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"Sequential phases"})," for dependent tasks"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"Progress tracking"})," via TodoWrite"]}),"\n",(0,l.jsx)(n.li,{children:(0,l.jsx)(n.strong,{children:"Optional code review"})}),"\n"]}),"\n",(0,l.jsx)(n.h2,{id:"related-workflows",children:"Related Workflows"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.a,{href:"/docs/workflows/level-1-ultra-lightweight",children:"Level 1: Ultra-Lightweight"})," - Simpler workflow"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.a,{href:"/docs/workflows/level-3-standard",children:"Level 3: Standard"})," - Full session management"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.a,{href:"/docs/workflows/level-4-brainstorm",children:"Level 4: Brainstorm"})," - Multi-role exploration"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.a,{href:"/docs/workflows/faq",children:"FAQ"})," - Common questions"]}),"\n"]})]})}function h(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,l.jsx)(n,{...e,children:(0,l.jsx)(x,{...e})}):x(e)}}}]); \ No newline at end of file +"use strict";(globalThis.webpackChunkccw_docs=globalThis.webpackChunkccw_docs||[]).push([[57],{1184(e,n,i){i.d(n,{R:()=>t,x:()=>c});var s=i(3696);const l={},r=s.createContext(l);function t(e){const n=s.useContext(r);return s.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(l):e.components||l:t(e.components),s.createElement(r.Provider,{value:n},e.children)}},7259(e,n,i){i.r(n),i.d(n,{assets:()=>o,contentTitle:()=>d,default:()=>h,frontMatter:()=>c,metadata:()=>s,toc:()=>a});const s=JSON.parse('{"id":"workflows/level-2-rapid","title":"Level 2 - Rapid Workflows","description":"Lightweight planning and bug diagnosis workflows for single-module features","source":"@site/docs/workflows/level-2-rapid.mdx","sourceDirName":"workflows","slug":"/workflows/level-2-rapid","permalink":"/docs/workflows/level-2-rapid","draft":false,"unlisted":false,"editUrl":"https://github.com/ccw/docs/tree/main/docs/workflows/level-2-rapid.mdx","tags":[],"version":"current","sidebarPosition":3,"frontMatter":{"title":"Level 2 - Rapid Workflows","description":"Lightweight planning and bug diagnosis workflows for single-module features","sidebar_position":3},"sidebar":"docs","previous":{"title":"Level 1: Ultra Lightweight","permalink":"/docs/workflows/level-1-ultra-lightweight"},"next":{"title":"Level 3: Standard","permalink":"/docs/workflows/level-3-standard"}}');var l=i(2540),r=i(1184),t=i(1540);const c={title:"Level 2 - Rapid Workflows",description:"Lightweight planning and bug diagnosis workflows for single-module features",sidebar_position:3},d="Level 2: Rapid Workflows",o={},a=[{value:"Overview",id:"overview",level:2},{value:"Included Workflows",id:"included-workflows",level:2},{value:"Common Characteristics",id:"common-characteristics",level:3},{value:"Workflow 1: lite-plan -> lite-execute",id:"workflow-1-lite-plan---lite-execute",level:2},{value:"Command",id:"command",level:3},{value:"Flow Diagram",id:"flow-diagram",level:3},{value:"Process Phases",id:"process-phases",level:3},{value:"Artifacts",id:"artifacts",level:3},{value:"Use Case",id:"use-case",level:3},{value:"Workflow 2: lite-fix",id:"workflow-2-lite-fix",level:2},{value:"Command",id:"command-1",level:3},{value:"Flow Diagram",id:"flow-diagram-1",level:3},{value:"Process Phases",id:"process-phases-1",level:3},{value:"Artifacts",id:"artifacts-1",level:3},{value:"Severity Levels",id:"severity-levels",level:3},{value:"Hotfix Mode",id:"hotfix-mode",level:3},{value:"Use Cases",id:"use-cases",level:3},{value:"Workflow 3: multi-cli-plan -> lite-execute",id:"workflow-3-multi-cli-plan---lite-execute",level:2},{value:"Command",id:"command-2",level:3},{value:"Flow Diagram",id:"flow-diagram-2",level:3},{value:"Process Phases",id:"process-phases-2",level:3},{value:"Artifacts",id:"artifacts-2",level:3},{value:"vs lite-plan Comparison",id:"vs-lite-plan-comparison",level:3},{value:"Use Cases",id:"use-cases-1",level:3},{value:"Level 2 Comparison Table",id:"level-2-comparison-table",level:2},{value:"Execution: lite-execute",id:"execution-lite-execute",level:2},{value:"Execution Flow",id:"execution-flow",level:3},{value:"Features",id:"features",level:3},{value:"Related Workflows",id:"related-workflows",level:2}];function x(e){const n={a:"a",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",hr:"hr",li:"li",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,r.R)(),...e.components};return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(n.header,{children:(0,l.jsx)(n.h1,{id:"level-2-rapid-workflows",children:"Level 2: Rapid Workflows"})}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Complexity"}),": Low-Medium | ",(0,l.jsx)(n.strong,{children:"Artifacts"}),": Memory/Lightweight files | ",(0,l.jsx)(n.strong,{children:"State"}),": Session-scoped"]}),"\n",(0,l.jsx)(n.p,{children:"Level 2 workflows provide lightweight planning or single analysis with fast iteration. They're designed for tasks with relatively clear requirements that don't need full session persistence."}),"\n",(0,l.jsx)(n.h2,{id:"overview",children:"Overview"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n Start([User Input]) --\x3e Select{Select Workflow}\n\n Select --\x3e|Clear
requirements| LP[lite-plan]\n Select --\x3e|Bug fix| LF[lite-fix]\n Select --\x3e|Multi-CLI
needed| MCP[multi-cli-plan]\n\n LP --\x3e LE[lite-execute]\n LF --\x3e LE\n MCP --\x3e LE\n\n LE --\x3e Test{Tests?}\n Test --\x3e|Yes| TFG[test-fix-gen]\n Test --\x3e|No| Done([Complete])\n TFG --\x3e TCE[test-cycle-execute]\n TCE --\x3e Done\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef workflow fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef execute fill:#c5e1a5,stroke:#388e3c\n\n class Start,Done startend,Select,Test decision,LP,LF,MCP workflow,LE execute,TFG,TCE execute\n"}),"\n",(0,l.jsx)(n.h2,{id:"included-workflows",children:"Included Workflows"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Workflow"}),(0,l.jsx)(n.th,{children:"Purpose"}),(0,l.jsx)(n.th,{children:"Artifacts"}),(0,l.jsx)(n.th,{children:"Execution"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:"lite-plan"})}),(0,l.jsx)(n.td,{children:"Clear requirement development"}),(0,l.jsx)(n.td,{children:"memory://plan"}),(0,l.jsxs)(n.td,{children:["-> ",(0,l.jsx)(n.code,{children:"lite-execute"})]})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:"lite-fix"})}),(0,l.jsx)(n.td,{children:"Bug diagnosis and fix"}),(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:".workflow/.lite-fix/"})}),(0,l.jsxs)(n.td,{children:["-> ",(0,l.jsx)(n.code,{children:"lite-execute"})]})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:"multi-cli-plan"})}),(0,l.jsx)(n.td,{children:"Multi-perspective tasks"}),(0,l.jsx)(n.td,{children:(0,l.jsx)(n.code,{children:".workflow/.multi-cli-plan/"})}),(0,l.jsxs)(n.td,{children:["-> ",(0,l.jsx)(n.code,{children:"lite-execute"})]})]})]})]}),"\n",(0,l.jsx)(n.h3,{id:"common-characteristics",children:"Common Characteristics"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Property"}),(0,l.jsx)(n.th,{children:"Value"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Complexity"})}),(0,l.jsx)(n.td,{children:"Low-Medium"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"State"})}),(0,l.jsx)(n.td,{children:"Session-scoped / Lightweight persistence"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Execution"})}),(0,l.jsxs)(n.td,{children:["Unified via ",(0,l.jsx)(n.code,{children:"lite-execute"})]})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Use Case"})}),(0,l.jsx)(n.td,{children:"Relatively clear requirements"})]})]})]}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h2,{id:"workflow-1-lite-plan---lite-execute",children:"Workflow 1: lite-plan -> lite-execute"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"In-memory planning + Direct execution"})}),"\n",(0,l.jsx)(n.h3,{id:"command",children:"Command"}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-plan "Add user authentication API"\n/workflow:lite-execute\n'})}),"\n",(0,l.jsx)(n.h3,{id:"flow-diagram",children:"Flow Diagram"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n A([Start]) --\x3e B[Phase 1: Code Exploration]\n B --\x3e C{Code
Exploration?}\n C --\x3e|Yes| D[cli-explore-agent
Multi-angle analysis]\n C --\x3e|No| E[Skip exploration]\n\n D --\x3e F[Phase 2: Complexity Assessment]\n E --\x3e F\n\n F --\x3e G{Complexity}\n G --\x3e|Low| H[Direct Claude
Planning]\n G --\x3e|Medium| H\n G --\x3e|High| I[cli-lite-planning
-agent]\n\n H --\x3e J[Phase 3: Planning]\n I --\x3e J\n\n J --\x3e K[Phase 4: Confirmation]\n K --\x3e L{Confirm?}\n L --\x3e|Modify| M[Adjust plan]\n M --\x3e K\n L --\x3e|Allow| N[Phase 5: Execute]\n L --\x3e|Cancel| O([Abort])\n\n N --\x3e P[Build executionContext]\n P --\x3e Q[/workflow:lite-execute]\n Q --\x3e R([Complete])\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n\n class A,R,O startend,B,D,E,J,M,P,Q action,C,G,L decision,F,H,I agent\n"}),"\n",(0,l.jsx)(n.h3,{id:"process-phases",children:"Process Phases"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Phase 1: Code Exploration"})," (Optional)"]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'# If -e flag specified\n/workflow:lite-plan -e "Add user authentication API"\n'})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Multi-angle code analysis via cli-explore-agent"}),"\n",(0,l.jsx)(n.li,{children:"Identifies patterns, dependencies, integration points"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 2: Complexity Assessment"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Low: Direct planning without agent"}),"\n",(0,l.jsx)(n.li,{children:"Medium/High: Use cli-lite-planning-agent"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 3: Planning"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:["Load plan schema: ",(0,l.jsx)(n.code,{children:"~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json"})]}),"\n",(0,l.jsx)(n.li,{children:"Generate plan.json following schema"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 4: Confirmation & Selection"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Display plan summary (tasks, complexity, estimated time)"}),"\n",(0,l.jsxs)(n.li,{children:["Ask user selections:","\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Confirm: Allow / Modify / Cancel"}),"\n",(0,l.jsx)(n.li,{children:"Execution: Agent / Codex / Auto"}),"\n",(0,l.jsx)(n.li,{children:"Review: Gemini / Agent / Skip"}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 5: Execute"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Build executionContext (plan + explorations + clarifications + selections)"}),"\n",(0,l.jsxs)(n.li,{children:["Execute via ",(0,l.jsx)(n.code,{children:"/workflow:lite-execute --in-memory"})]}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"artifacts",children:"Artifacts"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"In-memory"}),": ",(0,l.jsx)(n.code,{children:"memory://plan"})," (not persisted)"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"Optional"}),": ",(0,l.jsx)(n.code,{children:".workflow/.lite-exploration/"})," (if code exploration used)"]}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"use-case",children:"Use Case"}),"\n",(0,l.jsx)(n.p,{children:"Clear single-module features"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Example"}),":"]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-plan "Add email validation to user registration form"\n/workflow:lite-execute\n'})}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h2,{id:"workflow-2-lite-fix",children:"Workflow 2: lite-fix"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Intelligent diagnosis + Fix (5 phases)"})}),"\n",(0,l.jsx)(n.h3,{id:"command-1",children:"Command"}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-fix "Login timeout after 30 seconds"\n/workflow:lite-execute --in-memory --mode bugfix\n\n# Emergency hotfix mode\n/workflow:lite-fix --hotfix "Production database connection failing"\n'})}),"\n",(0,l.jsx)(n.h3,{id:"flow-diagram-1",children:"Flow Diagram"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n A([Start]) --\x3e B[Phase 1: Bug Analysis
& Diagnosis]\n B --\x3e C[Severity Pre-assessment
Low/Medium/High/Critical]\n C --\x3e D[Parallel cli-explore
-agent Diagnosis
1-4 angles]\n\n D --\x3e E[Phase 2: Clarification]\n E --\x3e F{More info
needed?}\n F --\x3e|Yes| G[AskUserQuestion
Aggregate clarifications]\n F --\x3e|No| H[Phase 3: Fix Planning]\n G --\x3e H\n\n H --\x3e I{Severity}\n I --\x3e|Low/Medium| J[Direct Claude
Planning]\n I --\x3e|High/Critical| K[cli-lite-planning
-agent]\n\n J --\x3e L[Phase 4: Confirmation]\n K --\x3e L\n\n L --\x3e M[User confirms
execution method]\n M --\x3e N[Phase 5: Execute]\n N --\x3e O[/workflow:lite-execute
--in-memory --mode bugfix/]\n O --\x3e P([Complete])\n\n Q[Hotfix Mode] --\x3e R[Skip diagnosis
Minimal planning]\n R --\x3e N\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n classDef hotfix fill:#ffccbc,stroke:#bf360c\n\n class A,P startend,B,E,G,H,L,M,N,O action,F,I decision,C,D,J,K agent,Q,R hotfix\n"}),"\n",(0,l.jsx)(n.h3,{id:"process-phases-1",children:"Process Phases"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 1: Bug Analysis & Diagnosis"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Intelligent severity pre-assessment (Low/Medium/High/Critical)"}),"\n",(0,l.jsx)(n.li,{children:"Parallel cli-explore-agent diagnosis (1-4 angles)"}),"\n"]}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Phase 2: Clarification"})," (Optional)"]}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Aggregate clarification needs"}),"\n",(0,l.jsx)(n.li,{children:"AskUserQuestion for missing info"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 3: Fix Planning"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Low/Medium severity -> Direct Claude planning"}),"\n",(0,l.jsx)(n.li,{children:"High/Critical severity -> cli-lite-planning-agent"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 4: Confirmation & Selection"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Display fix-plan summary"}),"\n",(0,l.jsx)(n.li,{children:"User confirms execution method"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 5: Execute"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:["Execute via ",(0,l.jsx)(n.code,{children:"/workflow:lite-execute --in-memory --mode bugfix"})]}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"artifacts-1",children:"Artifacts"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Location"}),": ",(0,l.jsx)(n.code,{children:".workflow/.lite-fix/{bug-slug}-{YYYY-MM-DD}/"})]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{children:".workflow/.lite-fix/\n\u2514\u2500\u2500 login-timeout-fix-2025-02-03/\n \u251c\u2500\u2500 diagnosis-root-cause.json\n \u251c\u2500\u2500 diagnosis-impact.json\n \u251c\u2500\u2500 diagnosis-code-flow.json\n \u251c\u2500\u2500 diagnosis-similar.json\n \u251c\u2500\u2500 diagnoses-manifest.json\n \u251c\u2500\u2500 fix-plan.json\n \u2514\u2500\u2500 README.md\n"})}),"\n",(0,l.jsx)(n.h3,{id:"severity-levels",children:"Severity Levels"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Severity"}),(0,l.jsx)(n.th,{children:"Description"}),(0,l.jsx)(n.th,{children:"Planning Method"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Low"})}),(0,l.jsx)(n.td,{children:"Simple fix, clear root cause"}),(0,l.jsx)(n.td,{children:"Direct Claude (optional rationale)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Medium"})}),(0,l.jsx)(n.td,{children:"Moderate complexity, some investigation"}),(0,l.jsx)(n.td,{children:"Direct Claude (with rationale)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"High"})}),(0,l.jsx)(n.td,{children:"Complex, multiple components affected"}),(0,l.jsx)(n.td,{children:"cli-lite-planning-agent (full schema)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Critical"})}),(0,l.jsx)(n.td,{children:"Production incident, urgent"}),(0,l.jsx)(n.td,{children:"cli-lite-planning-agent + hotfix mode"})]})]})]}),"\n",(0,l.jsx)(n.h3,{id:"hotfix-mode",children:"Hotfix Mode"}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-fix --hotfix "Production API returning 500 errors"\n'})}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Characteristics"}),":"]}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Skip most diagnosis phases"}),"\n",(0,l.jsx)(n.li,{children:"Minimal planning (direct execution)"}),"\n",(0,l.jsx)(n.li,{children:"Auto-generate follow-up tasks for complete fix + post-mortem"}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"use-cases",children:"Use Cases"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Bug diagnosis"}),"\n",(0,l.jsx)(n.li,{children:"Production emergencies"}),"\n",(0,l.jsx)(n.li,{children:"Root cause analysis"}),"\n"]}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h2,{id:"workflow-3-multi-cli-plan---lite-execute",children:"Workflow 3: multi-cli-plan -> lite-execute"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Multi-CLI collaborative analysis + Consensus convergence"})}),"\n",(0,l.jsx)(n.h3,{id:"command-2",children:"Command"}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:'/workflow:multi-cli-plan "Compare Redis vs Memcached for caching"\n/workflow:lite-execute\n'})}),"\n",(0,l.jsx)(n.h3,{id:"flow-diagram-2",children:"Flow Diagram"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n A([Start]) --\x3e B[Phase 1: Context Gathering]\n B --\x3e C[ACE semantic search
Build context package]\n\n C --\x3e D[Phase 2: Multi-CLI Discussion
Iterative]\n D --\x3e E[cli-discuss-agent]\n E --\x3e F[Gemini + Codex + Claude]\n\n F --\x3e G{Converged?}\n G --\x3e|No| H[Cross-verification
Synthesize solutions]\n H --\x3e D\n G --\x3e|Yes| I[Phase 3: Present Options]\n\n I --\x3e J[Display solutions
with trade-offs]\n\n J --\x3e K[Phase 4: User Decision]\n K --\x3e L[User selects solution]\n\n L --\x3e M[Phase 5: Plan Generation]\n M --\x3e N[cli-lite-planning
-agent]\n N --\x3e O[-> lite-execute]\n\n O --\x3e P([Complete])\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n\n class A,P startend,B,C,E,H,J,L,M,O action,G,K decision,F,N agent\n"}),"\n",(0,l.jsx)(n.h3,{id:"process-phases-2",children:"Process Phases"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 1: Context Gathering"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"ACE semantic search"}),"\n",(0,l.jsx)(n.li,{children:"Build context package"}),"\n"]}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Phase 2: Multi-CLI Discussion"})," (Iterative)"]}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"cli-discuss-agent executes Gemini + Codex + Claude"}),"\n",(0,l.jsx)(n.li,{children:"Cross-verification, synthesize solutions"}),"\n",(0,l.jsx)(n.li,{children:"Loop until convergence or max rounds"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 3: Present Options"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Display solutions with trade-offs"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 4: User Decision"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"User selects solution"}),"\n"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:"Phase 5: Plan Generation"})}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"cli-lite-planning-agent generates plan"}),"\n",(0,l.jsx)(n.li,{children:"-> lite-execute"}),"\n"]}),"\n",(0,l.jsx)(n.h3,{id:"artifacts-2",children:"Artifacts"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.strong,{children:"Location"}),": ",(0,l.jsx)(n.code,{children:".workflow/.multi-cli-plan/{MCP-task-slug-date}/"})]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{children:".workflow/.multi-cli-plan/\n\u2514\u2500\u2500 redis-vs-memcached-2025-02-03/\n \u251c\u2500\u2500 context-package.json\n \u251c\u2500\u2500 rounds/\n \u2502 \u251c\u2500\u2500 round-1/\n \u2502 \u2502 \u251c\u2500\u2500 gemini-analysis.md\n \u2502 \u2502 \u251c\u2500\u2500 codex-analysis.md\n \u2502 \u2502 \u251c\u2500\u2500 claude-analysis.md\n \u2502 \u2502 \u2514\u2500\u2500 synthesis.json\n \u2502 \u251c\u2500\u2500 round-2/\n \u2502 \u2514\u2500\u2500 ...\n \u251c\u2500\u2500 selected-solution.json\n \u251c\u2500\u2500 IMPL_PLAN.md\n \u2514\u2500\u2500 plan.json\n"})}),"\n",(0,l.jsx)(n.h3,{id:"vs-lite-plan-comparison",children:"vs lite-plan Comparison"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Aspect"}),(0,l.jsx)(n.th,{children:"multi-cli-plan"}),(0,l.jsx)(n.th,{children:"lite-plan"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Context"})}),(0,l.jsx)(n.td,{children:"ACE semantic search"}),(0,l.jsx)(n.td,{children:"Manual file patterns"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Analysis"})}),(0,l.jsx)(n.td,{children:"Multi-CLI cross-verification"}),(0,l.jsx)(n.td,{children:"Single planning"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Iteration"})}),(0,l.jsx)(n.td,{children:"Multiple rounds until convergence"}),(0,l.jsx)(n.td,{children:"Single round"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Confidence"})}),(0,l.jsx)(n.td,{children:"High (consensus-driven)"}),(0,l.jsx)(n.td,{children:"Medium (single perspective)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Time"})}),(0,l.jsx)(n.td,{children:"Longer (multi-round)"}),(0,l.jsx)(n.td,{children:"Faster"})]})]})]}),"\n",(0,l.jsx)(n.h3,{id:"use-cases-1",children:"Use Cases"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"Multi-perspective analysis"}),"\n",(0,l.jsx)(n.li,{children:"Technology selection"}),"\n",(0,l.jsx)(n.li,{children:"Solution comparison"}),"\n",(0,l.jsx)(n.li,{children:"Architecture decisions"}),"\n"]}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h2,{id:"level-2-comparison-table",children:"Level 2 Comparison Table"}),"\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{children:"Aspect"}),(0,l.jsx)(n.th,{children:"lite-plan"}),(0,l.jsx)(n.th,{children:"lite-fix"}),(0,l.jsx)(n.th,{children:"multi-cli-plan"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Purpose"})}),(0,l.jsx)(n.td,{children:"Clear requirements"}),(0,l.jsx)(n.td,{children:"Bug diagnosis"}),(0,l.jsx)(n.td,{children:"Multi-perspective"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Planning"})}),(0,l.jsx)(n.td,{children:"In-memory"}),(0,l.jsx)(n.td,{children:"Severity-based"}),(0,l.jsx)(n.td,{children:"Consensus-driven"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Artifacts"})}),(0,l.jsx)(n.td,{children:"memory://plan"}),(0,l.jsx)(n.td,{children:".lite-fix/"}),(0,l.jsx)(n.td,{children:".multi-cli-plan/"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Code Exploration"})}),(0,l.jsx)(n.td,{children:"Optional (-e flag)"}),(0,l.jsx)(n.td,{children:"Built-in diagnosis"}),(0,l.jsx)(n.td,{children:"ACE search"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Multi-CLI"})}),(0,l.jsx)(n.td,{children:"No"}),(0,l.jsx)(n.td,{children:"No"}),(0,l.jsx)(n.td,{children:"Yes (Gemini/Codex/Claude)"})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{children:(0,l.jsx)(n.strong,{children:"Best For"})}),(0,l.jsx)(n.td,{children:"Single-module features"}),(0,l.jsx)(n.td,{children:"Bug fixes"}),(0,l.jsx)(n.td,{children:"Technology decisions"})]})]})]}),"\n",(0,l.jsx)(n.h2,{id:"execution-lite-execute",children:"Execution: lite-execute"}),"\n",(0,l.jsxs)(n.p,{children:["All Level 2 workflows execute via ",(0,l.jsx)(n.code,{children:"lite-execute"}),":"]}),"\n",(0,l.jsx)(n.pre,{children:(0,l.jsx)(n.code,{className:"language-bash",children:"/workflow:lite-execute --in-memory\n"})}),"\n",(0,l.jsx)(n.h3,{id:"execution-flow",children:"Execution Flow"}),"\n",(0,l.jsx)(t.A,{chart:"\n flowchart TD\n A([Start]) --\x3e B[Initialize tracking
previousExecutionResults]\n B --\x3e C[Task grouping
& batch creation]\n\n C --\x3e D[Extract explicit
depends_on]\n D --\x3e E[Group: independent
tasks -> parallel batch]\n E --\x3e F[Group: dependent
tasks -> sequential phases]\n\n F --\x3e G[Create TodoWrite
list for batches]\n G --\x3e H[Launch execution]\n\n H --\x3e I[Phase 1: All independent
tasks - Single batch]\n I --\x3e J[Phase 2+: Dependent tasks
by dependency order]\n\n J --\x3e K[Track progress
TodoWrite updates]\n K --\x3e L{Code review?}\n L --\x3e|Yes| M[Review process]\n L --\x3e|No| N([Complete])\n M --\x3e N\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n\n class A,N startend,B,D,E,F,G,I,J,K,M action,C,L decision\n"}),"\n",(0,l.jsx)(n.h3,{id:"features",children:"Features"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"Parallel execution"})," for independent tasks"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"Sequential phases"})," for dependent tasks"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.strong,{children:"Progress tracking"})," via TodoWrite"]}),"\n",(0,l.jsx)(n.li,{children:(0,l.jsx)(n.strong,{children:"Optional code review"})}),"\n"]}),"\n",(0,l.jsx)(n.h2,{id:"related-workflows",children:"Related Workflows"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.a,{href:"/docs/workflows/level-1-ultra-lightweight",children:"Level 1: Ultra-Lightweight"})," - Simpler workflow"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.a,{href:"/docs/workflows/level-3-standard",children:"Level 3: Standard"})," - Full session management"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.a,{href:"/docs/workflows/level-4-brainstorm",children:"Level 4: Brainstorm"})," - Multi-role exploration"]}),"\n",(0,l.jsxs)(n.li,{children:[(0,l.jsx)(n.a,{href:"/docs/workflows/faq",children:"FAQ"})," - Common questions"]}),"\n"]})]})}function h(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,l.jsx)(n,{...e,children:(0,l.jsx)(x,{...e})}):x(e)}}}]); \ No newline at end of file diff --git a/ccw/docs-site/build/workflows/level-2-rapid.html b/ccw/docs-site/build/workflows/level-2-rapid.html index ccc05ca9..6e45b6dc 100644 --- a/ccw/docs-site/build/workflows/level-2-rapid.html +++ b/ccw/docs-site/build/workflows/level-2-rapid.html @@ -41,7 +41,7 @@

Phase 3: Planning

    -
  • Load plan schema: ~/.claude/workflows/cli-templates/schemas/plan-json-schema.json
  • +
  • Load plan schema: ~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json
  • Generate plan.json following schema

Phase 4: Confirmation & Selection

diff --git a/ccw/docs-site/build/zh/assets/js/05467734.307672f8.js b/ccw/docs-site/build/zh/assets/js/05467734.307672f8.js index 3a6fa351..0c40cf17 100644 --- a/ccw/docs-site/build/zh/assets/js/05467734.307672f8.js +++ b/ccw/docs-site/build/zh/assets/js/05467734.307672f8.js @@ -1 +1 @@ -"use strict";(globalThis.webpackChunkccw_docs=globalThis.webpackChunkccw_docs||[]).push([[139],{1184(e,n,l){l.d(n,{R:()=>d,x:()=>c});var i=l(3696);const s={},r=i.createContext(s);function d(e){const n=i.useContext(r);return i.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:d(e.components),i.createElement(r.Provider,{value:n},e.children)}},1923(e,n,l){l.r(n),l.d(n,{assets:()=>x,contentTitle:()=>t,default:()=>o,frontMatter:()=>c,metadata:()=>i,toc:()=>h});const i=JSON.parse('{"id":"workflows/level-2-rapid","title":"\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41","description":"\u8f7b\u91cf\u89c4\u5212\u548c\u6f0f\u6d1e\u8bca\u65ad\u5de5\u4f5c\u6d41 - \u9002\u7528\u4e8e\u5355\u6a21\u5757\u529f\u80fd","source":"@site/i18n/zh/docusaurus-plugin-content-docs/current/workflows/level-2-rapid.mdx","sourceDirName":"workflows","slug":"/workflows/level-2-rapid","permalink":"/docs/zh/workflows/level-2-rapid","draft":false,"unlisted":false,"editUrl":"https://github.com/ccw/docs/tree/main/docs/workflows/level-2-rapid.mdx","tags":[],"version":"current","sidebarPosition":3,"frontMatter":{"title":"\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41","description":"\u8f7b\u91cf\u89c4\u5212\u548c\u6f0f\u6d1e\u8bca\u65ad\u5de5\u4f5c\u6d41 - \u9002\u7528\u4e8e\u5355\u6a21\u5757\u529f\u80fd","sidebar_position":3},"sidebar":"docs","previous":{"title":"Level 1: Ultra Lightweight","permalink":"/docs/zh/workflows/level-1-ultra-lightweight"},"next":{"title":"Level 3: Standard","permalink":"/docs/zh/workflows/level-3-standard"}}');var s=l(2540),r=l(1184),d=l(1540);const c={title:"\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41",description:"\u8f7b\u91cf\u89c4\u5212\u548c\u6f0f\u6d1e\u8bca\u65ad\u5de5\u4f5c\u6d41 - \u9002\u7528\u4e8e\u5355\u6a21\u5757\u529f\u80fd",sidebar_position:3},t="\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41",x={},h=[{value:"\u6982\u8ff0",id:"\u6982\u8ff0",level:2},{value:"\u5305\u542b\u7684\u5de5\u4f5c\u6d41",id:"\u5305\u542b\u7684\u5de5\u4f5c\u6d41",level:2},{value:"\u5171\u540c\u7279\u5f81",id:"\u5171\u540c\u7279\u5f81",level:3},{value:"\u5de5\u4f5c\u6d41 1: lite-plan -> lite-execute",id:"\u5de5\u4f5c\u6d41-1-lite-plan---lite-execute",level:2},{value:"\u547d\u4ee4",id:"\u547d\u4ee4",level:3},{value:"\u6d41\u7a0b\u56fe",id:"\u6d41\u7a0b\u56fe",level:3},{value:"\u6d41\u7a0b\u9636\u6bb5",id:"\u6d41\u7a0b\u9636\u6bb5",level:3},{value:"\u4ea7\u7269",id:"\u4ea7\u7269",level:3},{value:"\u4f7f\u7528\u573a\u666f",id:"\u4f7f\u7528\u573a\u666f",level:3},{value:"\u5de5\u4f5c\u6d41 2: lite-fix",id:"\u5de5\u4f5c\u6d41-2-lite-fix",level:2},{value:"\u547d\u4ee4",id:"\u547d\u4ee4-1",level:3},{value:"\u6d41\u7a0b\u56fe",id:"\u6d41\u7a0b\u56fe-1",level:3},{value:"\u6d41\u7a0b\u9636\u6bb5",id:"\u6d41\u7a0b\u9636\u6bb5-1",level:3},{value:"\u4ea7\u7269",id:"\u4ea7\u7269-1",level:3},{value:"\u4e25\u91cd\u7a0b\u5ea6\u7ea7\u522b",id:"\u4e25\u91cd\u7a0b\u5ea6\u7ea7\u522b",level:3},{value:"\u70ed\u4fee\u590d\u6a21\u5f0f",id:"\u70ed\u4fee\u590d\u6a21\u5f0f",level:3},{value:"\u4f7f\u7528\u573a\u666f",id:"\u4f7f\u7528\u573a\u666f-1",level:3},{value:"\u5de5\u4f5c\u6d41 3: multi-cli-plan -> lite-execute",id:"\u5de5\u4f5c\u6d41-3-multi-cli-plan---lite-execute",level:2},{value:"\u547d\u4ee4",id:"\u547d\u4ee4-2",level:3},{value:"\u6d41\u7a0b\u56fe",id:"\u6d41\u7a0b\u56fe-2",level:3},{value:"\u6d41\u7a0b\u9636\u6bb5",id:"\u6d41\u7a0b\u9636\u6bb5-2",level:3},{value:"\u4ea7\u7269",id:"\u4ea7\u7269-2",level:3},{value:"\u4e0e lite-plan \u5bf9\u6bd4",id:"\u4e0e-lite-plan-\u5bf9\u6bd4",level:3},{value:"\u4f7f\u7528\u573a\u666f",id:"\u4f7f\u7528\u573a\u666f-2",level:3},{value:"Level 2 \u5bf9\u6bd4\u8868",id:"level-2-\u5bf9\u6bd4\u8868",level:2},{value:"\u6267\u884c: lite-execute",id:"\u6267\u884c-lite-execute",level:2},{value:"\u6267\u884c\u6d41\u7a0b",id:"\u6267\u884c\u6d41\u7a0b",level:3},{value:"\u7279\u6027",id:"\u7279\u6027",level:3},{value:"\u76f8\u5173\u5de5\u4f5c\u6d41",id:"\u76f8\u5173\u5de5\u4f5c\u6d41",level:2}];function j(e){const n={a:"a",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",hr:"hr",li:"li",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,r.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.header,{children:(0,s.jsx)(n.h1,{id:"\u5c42\u7ea7-2-\u5feb\u901f\u5de5\u4f5c\u6d41",children:"\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41"})}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u590d\u6742\u5ea6"}),": \u4f4e-\u4e2d\u7b49 | ",(0,s.jsx)(n.strong,{children:"\u4ea7\u7269"}),": \u5185\u5b58/\u8f7b\u91cf\u6587\u4ef6 | ",(0,s.jsx)(n.strong,{children:"\u72b6\u6001"}),": \u4f1a\u8bdd\u4f5c\u7528\u57df"]}),"\n",(0,s.jsx)(n.p,{children:"Level 2 \u5de5\u4f5c\u6d41\u63d0\u4f9b\u8f7b\u91cf\u7ea7\u89c4\u5212\u6216\u5355\u6b21\u5206\u6790\uff0c\u652f\u6301\u5feb\u901f\u8fed\u4ee3\u3002\u5b83\u4eec\u4e13\u4e3a\u9700\u6c42\u76f8\u5bf9\u660e\u786e\u3001\u4e0d\u9700\u8981\u5b8c\u6574\u4f1a\u8bdd\u6301\u4e45\u5316\u7684\u4efb\u52a1\u800c\u8bbe\u8ba1\u3002"}),"\n",(0,s.jsx)(n.h2,{id:"\u6982\u8ff0",children:"\u6982\u8ff0"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n Start([\u7528\u6237\u8f93\u5165]) --\x3e Select{\u9009\u62e9\u5de5\u4f5c\u6d41}\n\n Select --\x3e|\u9700\u6c42
\u660e\u786e| LP[lite-plan]\n Select --\x3e|\u6f0f\u6d1e\u4fee\u590d| LF[lite-fix]\n Select --\x3e|\u9700\u8981
\u591aCLI| MCP[multi-cli-plan]\n\n LP --\x3e LE[lite-execute]\n LF --\x3e LE\n MCP --\x3e LE\n\n LE --\x3e Test{\u9700\u8981
\u6d4b\u8bd5?}\n Test --\x3e|\u662f| TFG[test-fix-gen]\n Test --\x3e|\u5426| Done([\u5b8c\u6210])\n TFG --\x3e TCE[test-cycle-execute]\n TCE --\x3e Done\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef workflow fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef execute fill:#c5e1a5,stroke:#388e3c\n\n class Start,Done startend,Select,Test decision,LP,LF,MCP workflow,LE execute,TFG,TCE execute\n"}),"\n",(0,s.jsx)(n.h2,{id:"\u5305\u542b\u7684\u5de5\u4f5c\u6d41",children:"\u5305\u542b\u7684\u5de5\u4f5c\u6d41"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u5de5\u4f5c\u6d41"}),(0,s.jsx)(n.th,{children:"\u7528\u9014"}),(0,s.jsx)(n.th,{children:"\u4ea7\u7269"}),(0,s.jsx)(n.th,{children:"\u6267\u884c\u65b9\u5f0f"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"lite-plan"})}),(0,s.jsx)(n.td,{children:"\u9700\u6c42\u660e\u786e\u7684\u5f00\u53d1"}),(0,s.jsx)(n.td,{children:"memory://plan"}),(0,s.jsxs)(n.td,{children:["-> ",(0,s.jsx)(n.code,{children:"lite-execute"})]})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"lite-fix"})}),(0,s.jsx)(n.td,{children:"\u6f0f\u6d1e\u8bca\u65ad\u4e0e\u4fee\u590d"}),(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:".workflow/.lite-fix/"})}),(0,s.jsxs)(n.td,{children:["-> ",(0,s.jsx)(n.code,{children:"lite-execute"})]})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"multi-cli-plan"})}),(0,s.jsx)(n.td,{children:"\u591a\u89c6\u89d2\u4efb\u52a1"}),(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:".workflow/.multi-cli-plan/"})}),(0,s.jsxs)(n.td,{children:["-> ",(0,s.jsx)(n.code,{children:"lite-execute"})]})]})]})]}),"\n",(0,s.jsx)(n.h3,{id:"\u5171\u540c\u7279\u5f81",children:"\u5171\u540c\u7279\u5f81"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u5c5e\u6027"}),(0,s.jsx)(n.th,{children:"\u503c"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u590d\u6742\u5ea6"})}),(0,s.jsx)(n.td,{children:"\u4f4e-\u4e2d\u7b49"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u72b6\u6001"})}),(0,s.jsx)(n.td,{children:"\u4f1a\u8bdd\u4f5c\u7528\u57df / \u8f7b\u91cf\u6301\u4e45\u5316"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u6267\u884c"})}),(0,s.jsxs)(n.td,{children:["\u7edf\u4e00\u901a\u8fc7 ",(0,s.jsx)(n.code,{children:"lite-execute"})]})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4f7f\u7528\u573a\u666f"})}),(0,s.jsx)(n.td,{children:"\u9700\u6c42\u76f8\u5bf9\u660e\u786e"})]})]})]}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"\u5de5\u4f5c\u6d41-1-lite-plan---lite-execute",children:"\u5de5\u4f5c\u6d41 1: lite-plan -> lite-execute"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u5185\u5b58\u89c4\u5212 + \u76f4\u63a5\u6267\u884c"})}),"\n",(0,s.jsx)(n.h3,{id:"\u547d\u4ee4",children:"\u547d\u4ee4"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-plan "Add user authentication API"\n/workflow:lite-execute\n'})}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u56fe",children:"\u6d41\u7a0b\u56fe"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n A([\u5f00\u59cb]) --\x3e B[\u9636\u6bb5 1: \u4ee3\u7801\u63a2\u7d22]\n B --\x3e C{\u9700\u8981
\u4ee3\u7801\u63a2\u7d22?}\n C --\x3e|\u662f| D[cli-explore-agent
\u591a\u89d2\u5ea6\u5206\u6790]\n C --\x3e|\u5426| E[\u8df3\u8fc7\u63a2\u7d22]\n\n D --\x3e F[\u9636\u6bb5 2: \u590d\u6742\u5ea6\u8bc4\u4f30]\n E --\x3e F\n\n F --\x3e G{\u590d\u6742\u5ea6}\n G --\x3e|\u4f4e| H[\u76f4\u63a5 Claude
\u89c4\u5212]\n G --\x3e|\u4e2d| H\n G --\x3e|\u9ad8| I[cli-lite-planning
-agent]\n\n H --\x3e J[\u9636\u6bb5 3: \u89c4\u5212]\n I --\x3e J\n\n J --\x3e K[\u9636\u6bb5 4: \u786e\u8ba4]\n K --\x3e L{\u786e\u8ba4?}\n L --\x3e|\u4fee\u6539| M[\u8c03\u6574\u8ba1\u5212]\n M --\x3e K\n L --\x3e|\u5141\u8bb8| N[\u9636\u6bb5 5: \u6267\u884c]\n L --\x3e|\u53d6\u6d88| O([\u4e2d\u6b62])\n\n N --\x3e P[\u6784\u5efa\u6267\u884c\u4e0a\u4e0b\u6587]\n P --\x3e Q[/workflow:lite-execute]\n Q --\x3e R([\u5b8c\u6210])\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n\n class A,R,O startend,B,D,E,J,M,P,Q action,C,G,L decision,F,H,I agent\n"}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u9636\u6bb5",children:"\u6d41\u7a0b\u9636\u6bb5"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 1: \u4ee3\u7801\u63a2\u7d22"})," (\u53ef\u9009)"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'# \u5982\u679c\u6307\u5b9a\u4e86 -e \u53c2\u6570\n/workflow:lite-plan -e "Add user authentication API"\n'})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u901a\u8fc7 cli-explore-agent \u8fdb\u884c\u591a\u89d2\u5ea6\u4ee3\u7801\u5206\u6790"}),"\n",(0,s.jsx)(n.li,{children:"\u8bc6\u522b\u6a21\u5f0f\u3001\u4f9d\u8d56\u5173\u7cfb\u3001\u96c6\u6210\u70b9"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 2: \u590d\u6742\u5ea6\u8bc4\u4f30"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u4f4e: \u65e0\u9700\u4ee3\u7406\uff0c\u76f4\u63a5\u89c4\u5212"}),"\n",(0,s.jsx)(n.li,{children:"\u4e2d/\u9ad8: \u4f7f\u7528 cli-lite-planning-agent"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 3: \u89c4\u5212"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["\u52a0\u8f7d\u8ba1\u5212 schema: ",(0,s.jsx)(n.code,{children:"~/.claude/workflows/cli-templates/schemas/plan-json-schema.json"})]}),"\n",(0,s.jsx)(n.li,{children:"\u6309\u7167\u751f\u6210\u8ba1\u5212 schema \u751f\u6210 plan.json"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 4: \u786e\u8ba4\u4e0e\u9009\u62e9"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u663e\u793a\u8ba1\u5212\u6458\u8981\uff08\u4efb\u52a1\u3001\u590d\u6742\u5ea6\u3001\u9884\u4f30\u65f6\u95f4\uff09"}),"\n",(0,s.jsxs)(n.li,{children:["\u8be2\u95ee\u7528\u6237\u9009\u62e9:","\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u786e\u8ba4: \u5141\u8bb8 / \u4fee\u6539 / \u53d6\u6d88"}),"\n",(0,s.jsx)(n.li,{children:"\u6267\u884c: Agent / Codex / Auto"}),"\n",(0,s.jsx)(n.li,{children:"\u5ba1\u6838: Gemini / Agent / \u8df3\u8fc7"}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 5: \u6267\u884c"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u6784\u5efa\u6267\u884c\u4e0a\u4e0b\u6587\uff08\u8ba1\u5212 + \u63a2\u7d22 + \u6f84\u6e05 + \u9009\u62e9\uff09"}),"\n",(0,s.jsxs)(n.li,{children:["\u901a\u8fc7 ",(0,s.jsx)(n.code,{children:"/workflow:lite-execute --in-memory"})," \u6267\u884c"]}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4ea7\u7269",children:"\u4ea7\u7269"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u5185\u5b58"}),": ",(0,s.jsx)(n.code,{children:"memory://plan"})," (\u4e0d\u6301\u4e45\u5316)"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u53ef\u9009"}),": ",(0,s.jsx)(n.code,{children:".workflow/.lite-exploration/"})," (\u5982\u679c\u4f7f\u7528\u4e86\u4ee3\u7801\u63a2\u7d22)"]}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4f7f\u7528\u573a\u666f",children:"\u4f7f\u7528\u573a\u666f"}),"\n",(0,s.jsx)(n.p,{children:"\u9700\u6c42\u660e\u786e\u7684\u5355\u6a21\u5757\u529f\u80fd"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u793a\u4f8b"}),":"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-plan "Add email validation to user registration form"\n/workflow:lite-execute\n'})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"\u5de5\u4f5c\u6d41-2-lite-fix",children:"\u5de5\u4f5c\u6d41 2: lite-fix"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u667a\u80fd\u8bca\u65ad + \u4fee\u590d (5 \u9636\u6bb5)"})}),"\n",(0,s.jsx)(n.h3,{id:"\u547d\u4ee4-1",children:"\u547d\u4ee4"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-fix "Login timeout after 30 seconds"\n/workflow:lite-execute --in-memory --mode bugfix\n\n# \u7d27\u6025\u70ed\u4fee\u590d\u6a21\u5f0f\n/workflow:lite-fix --hotfix "Production database connection failing"\n'})}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u56fe-1",children:"\u6d41\u7a0b\u56fe"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n A([\u5f00\u59cb]) --\x3e B[\u9636\u6bb5 1: \u6f0f\u6d1e\u5206\u6790
& \u8bca\u65ad]\n B --\x3e C[\u4e25\u91cd\u7a0b\u5ea6\u9884\u8bc4\u4f30
\u4f4e/\u4e2d/\u9ad8/\u4e25\u91cd]\n C --\x3e D[\u5e76\u884c cli-explore
-agent \u8bca\u65ad
1-4 \u89d2\u5ea6]\n\n D --\x3e E[\u9636\u6bb5 2: \u6f84\u6e05]\n E --\x3e F{\u9700\u8981
\u66f4\u591a\u4fe1\u606f?}\n F --\x3e|\u662f| G[AskUserQuestion
\u805a\u5408\u6f84\u6e05]\n F --\x3e|\u5426| H[\u9636\u6bb5 3: \u4fee\u590d\u89c4\u5212]\n G --\x3e H\n\n H --\x3e I{\u4e25\u91cd\u7a0b\u5ea6}\n I --\x3e|\u4f4e/\u4e2d| J[\u76f4\u63a5 Claude
\u89c4\u5212]\n I --\x3e|\u9ad8/\u4e25\u91cd| K[cli-lite-planning
-agent]\n\n J --\x3e L[\u9636\u6bb5 4: \u786e\u8ba4]\n K --\x3e L\n\n L --\x3e M[\u7528\u6237\u786e\u8ba4
\u6267\u884c\u65b9\u6cd5]\n M --\x3e N[\u9636\u6bb5 5: \u6267\u884c]\n N --\x3e O[/workflow:lite-execute
--in-memory --mode bugfix/]\n O --\x3e P([\u5b8c\u6210])\n\n Q[\u70ed\u4fee\u590d\u6a21\u5f0f] --\x3e R[\u8df3\u8fc7\u8bca\u65ad
\u6700\u5c0f\u89c4\u5212]\n R --\x3e N\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n classDef hotfix fill:#ffccbc,stroke:#bf360c\n\n class A,P startend,B,E,G,H,L,M,N,O action,F,I decision,C,D,J,K agent,Q,R hotfix\n"}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u9636\u6bb5-1",children:"\u6d41\u7a0b\u9636\u6bb5"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 1: \u6f0f\u6d1e\u5206\u6790\u4e0e\u8bca\u65ad"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u667a\u80fd\u4e25\u91cd\u7a0b\u5ea6\u9884\u8bc4\u4f30\uff08\u4f4e/\u4e2d/\u9ad8/\u4e25\u91cd\uff09"}),"\n",(0,s.jsx)(n.li,{children:"\u5e76\u884c cli-explore-agent \u8bca\u65ad\uff081-4 \u89d2\u5ea6\uff09"}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 2: \u6f84\u6e05"})," (\u53ef\u9009)"]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u805a\u5408\u6f84\u6e05\u9700\u6c42"}),"\n",(0,s.jsx)(n.li,{children:"AskUserQuestion \u83b7\u53d6\u7f3a\u5931\u4fe1\u606f"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 3: \u4fee\u590d\u89c4\u5212"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u4f4e/\u4e2d\u4e25\u91cd\u7a0b\u5ea6 -> \u76f4\u63a5 Claude \u89c4\u5212"}),"\n",(0,s.jsx)(n.li,{children:"\u9ad8/\u4e25\u91cd\u7a0b\u5ea6 -> cli-lite-planning-agent"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 4: \u786e\u8ba4\u4e0e\u9009\u62e9"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u663e\u793a\u4fee\u590d\u8ba1\u5212\u6458\u8981"}),"\n",(0,s.jsx)(n.li,{children:"\u7528\u6237\u786e\u8ba4\u6267\u884c\u65b9\u6cd5"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 5: \u6267\u884c"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["\u901a\u8fc7 ",(0,s.jsx)(n.code,{children:"/workflow:lite-execute --in-memory --mode bugfix"})," \u6267\u884c"]}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4ea7\u7269-1",children:"\u4ea7\u7269"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u4f4d\u7f6e"}),": ",(0,s.jsx)(n.code,{children:".workflow/.lite-fix/{bug-slug}-{YYYY-MM-DD}/"})]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{children:".workflow/.lite-fix/\n\u2514\u2500\u2500 login-timeout-fix-2025-02-03/\n \u251c\u2500\u2500 diagnosis-root-cause.json\n \u251c\u2500\u2500 diagnosis-impact.json\n \u251c\u2500\u2500 diagnosis-code-flow.json\n \u251c\u2500\u2500 diagnosis-similar.json\n \u251c\u2500\u2500 diagnoses-manifest.json\n \u251c\u2500\u2500 fix-plan.json\n \u2514\u2500\u2500 README.md\n"})}),"\n",(0,s.jsx)(n.h3,{id:"\u4e25\u91cd\u7a0b\u5ea6\u7ea7\u522b",children:"\u4e25\u91cd\u7a0b\u5ea6\u7ea7\u522b"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u4e25\u91cd\u7a0b\u5ea6"}),(0,s.jsx)(n.th,{children:"\u63cf\u8ff0"}),(0,s.jsx)(n.th,{children:"\u89c4\u5212\u65b9\u6cd5"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4f4e"})}),(0,s.jsx)(n.td,{children:"\u7b80\u5355\u4fee\u590d\uff0c\u6839\u56e0\u660e\u786e"}),(0,s.jsx)(n.td,{children:"\u76f4\u63a5 Claude\uff08\u53ef\u9009\u7406\u7531\uff09"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4e2d"})}),(0,s.jsx)(n.td,{children:"\u4e2d\u7b49\u590d\u6742\u5ea6\uff0c\u9700\u8c03\u67e5"}),(0,s.jsx)(n.td,{children:"\u76f4\u63a5 Claude\uff08\u542b\u7406\u7531\uff09"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u9ad8"})}),(0,s.jsx)(n.td,{children:"\u590d\u6742\uff0c\u5f71\u54cd\u591a\u4e2a\u7ec4\u4ef6"}),(0,s.jsx)(n.td,{children:"cli-lite-planning-agent\uff08\u5b8c\u6574 schema\uff09"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4e25\u91cd"})}),(0,s.jsx)(n.td,{children:"\u751f\u4ea7\u4e8b\u6545\uff0c\u7d27\u6025"}),(0,s.jsx)(n.td,{children:"cli-lite-planning-agent + \u70ed\u4fee\u590d\u6a21\u5f0f"})]})]})]}),"\n",(0,s.jsx)(n.h3,{id:"\u70ed\u4fee\u590d\u6a21\u5f0f",children:"\u70ed\u4fee\u590d\u6a21\u5f0f"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-fix --hotfix "Production API returning 500 errors"\n'})}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u7279\u70b9"}),":"]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u8df3\u8fc7\u5927\u90e8\u5206\u8bca\u65ad\u9636\u6bb5"}),"\n",(0,s.jsx)(n.li,{children:"\u6700\u5c0f\u89c4\u5212\uff08\u76f4\u63a5\u6267\u884c\uff09"}),"\n",(0,s.jsx)(n.li,{children:"\u81ea\u52a8\u751f\u6210\u540e\u7eed\u4efb\u52a1\u7528\u4e8e\u5b8c\u6574\u4fee\u590d + \u4e8b\u540e\u5206\u6790"}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4f7f\u7528\u573a\u666f-1",children:"\u4f7f\u7528\u573a\u666f"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u6f0f\u6d1e\u8bca\u65ad"}),"\n",(0,s.jsx)(n.li,{children:"\u751f\u4ea7\u73af\u5883\u7d27\u6025\u60c5\u51b5"}),"\n",(0,s.jsx)(n.li,{children:"\u6839\u56e0\u5206\u6790"}),"\n"]}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"\u5de5\u4f5c\u6d41-3-multi-cli-plan---lite-execute",children:"\u5de5\u4f5c\u6d41 3: multi-cli-plan -> lite-execute"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u591aCLI \u534f\u4f5c\u5206\u6790 + \u5171\u8bc6\u6536\u655b"})}),"\n",(0,s.jsx)(n.h3,{id:"\u547d\u4ee4-2",children:"\u547d\u4ee4"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:multi-cli-plan "Compare Redis vs Memcached for caching"\n/workflow:lite-execute\n'})}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u56fe-2",children:"\u6d41\u7a0b\u56fe"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n A([\u5f00\u59cb]) --\x3e B[\u9636\u6bb5 1: \u4e0a\u4e0b\u6587\u6536\u96c6]\n B --\x3e C[ACE \u8bed\u4e49\u641c\u7d22
\u6784\u5efa\u4e0a\u4e0b\u6587\u5305]\n\n C --\x3e D[\u9636\u6bb5 2: \u591aCLI \u8ba8\u8bba
\u8fed\u4ee3]\n D --\x3e E[cli-discuss-agent]\n E --\x3e F[Gemini + Codex + Claude]\n\n F --\x3e G{\u5df2\u6536\u655b?}\n G --\x3e|\u5426| H[\u4ea4\u53c9\u9a8c\u8bc1
\u7efc\u5408\u89e3\u51b3\u65b9\u6848]\n H --\x3e D\n G --\x3e|\u662f| I[\u9636\u6bb5 3: \u5c55\u793a\u9009\u9879]\n\n I --\x3e J[\u5c55\u793a\u89e3\u51b3\u65b9\u6848
\u53ca\u6743\u8861]\n\n J --\x3e K[\u9636\u6bb5 4: \u7528\u6237\u51b3\u7b56]\n K --\x3e L[\u7528\u6237\u9009\u62e9\u89e3\u51b3\u65b9\u6848]\n\n L --\x3e M[\u9636\u6bb5 5: \u8ba1\u5212\u751f\u6210]\n M --\x3e N[cli-lite-planning
-agent]\n N --\x3e O[-> lite-execute]\n\n O --\x3e P([\u5b8c\u6210])\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n\n class A,P startend,B,C,E,H,J,L,M,O action,G,K decision,F,N agent\n"}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u9636\u6bb5-2",children:"\u6d41\u7a0b\u9636\u6bb5"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 1: \u4e0a\u4e0b\u6587\u6536\u96c6"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"ACE \u8bed\u4e49\u641c\u7d22"}),"\n",(0,s.jsx)(n.li,{children:"\u6784\u5efa\u4e0a\u4e0b\u6587\u5305"}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 2: \u591aCLI \u8ba8\u8bba"})," (\u8fed\u4ee3)"]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"cli-discuss-agent \u6267\u884c Gemini + Codex + Claude"}),"\n",(0,s.jsx)(n.li,{children:"\u4ea4\u53c9\u9a8c\u8bc1\uff0c\u7efc\u5408\u89e3\u51b3\u65b9\u6848"}),"\n",(0,s.jsx)(n.li,{children:"\u5faa\u73af\u76f4\u81f3\u6536\u655b\u6216\u8fbe\u5230\u6700\u5927\u8f6e\u6b21"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 3: \u5c55\u793a\u9009\u9879"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u5c55\u793a\u89e3\u51b3\u65b9\u6848\u53ca\u6743\u8861"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 4: \u7528\u6237\u51b3\u7b56"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u7528\u6237\u9009\u62e9\u89e3\u51b3\u65b9\u6848"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 5: \u8ba1\u5212\u751f\u6210"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"cli-lite-planning-agent \u751f\u6210\u8ba1\u5212"}),"\n",(0,s.jsx)(n.li,{children:"-> lite-execute"}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4ea7\u7269-2",children:"\u4ea7\u7269"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u4f4d\u7f6e"}),": ",(0,s.jsx)(n.code,{children:".workflow/.multi-cli-plan/{MCP-task-slug-date}/"})]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{children:".workflow/.multi-cli-plan/\n\u2514\u2500\u2500 redis-vs-memcached-2025-02-03/\n \u251c\u2500\u2500 context-package.json\n \u251c\u2500\u2500 rounds/\n \u2502 \u251c\u2500\u2500 round-1/\n \u2502 \u2502 \u251c\u2500\u2500 gemini-analysis.md\n \u2502 \u2502 \u251c\u2500\u2500 codex-analysis.md\n \u2502 \u2502 \u251c\u2500\u2500 claude-analysis.md\n \u2502 \u2502 \u2514\u2500\u2500 synthesis.json\n \u2502 \u251c\u2500\u2500 round-2/\n \u2502 \u2514\u2500\u2500 ...\n \u251c\u2500\u2500 selected-solution.json\n \u251c\u2500\u2500 IMPL_PLAN.md\n \u2514\u2500\u2500 plan.json\n"})}),"\n",(0,s.jsx)(n.h3,{id:"\u4e0e-lite-plan-\u5bf9\u6bd4",children:"\u4e0e lite-plan \u5bf9\u6bd4"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u65b9\u9762"}),(0,s.jsx)(n.th,{children:"multi-cli-plan"}),(0,s.jsx)(n.th,{children:"lite-plan"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4e0a\u4e0b\u6587"})}),(0,s.jsx)(n.td,{children:"ACE \u8bed\u4e49\u641c\u7d22"}),(0,s.jsx)(n.td,{children:"\u624b\u52a8\u6587\u4ef6\u6a21\u5f0f"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u5206\u6790"})}),(0,s.jsx)(n.td,{children:"\u591aCLI \u4ea4\u53c9\u9a8c\u8bc1"}),(0,s.jsx)(n.td,{children:"\u5355\u6b21\u89c4\u5212"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u8fed\u4ee3"})}),(0,s.jsx)(n.td,{children:"\u591a\u8f6e\u81f3\u6536\u655b"}),(0,s.jsx)(n.td,{children:"\u5355\u8f6e"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u53ef\u4fe1\u5ea6"})}),(0,s.jsx)(n.td,{children:"\u9ad8\uff08\u5171\u8bc6\u9a71\u52a8\uff09"}),(0,s.jsx)(n.td,{children:"\u4e2d\uff08\u5355\u89c6\u89d2\uff09"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u65f6\u95f4"})}),(0,s.jsx)(n.td,{children:"\u8f83\u957f\uff08\u591a\u8f6e\uff09"}),(0,s.jsx)(n.td,{children:"\u66f4\u5feb"})]})]})]}),"\n",(0,s.jsx)(n.h3,{id:"\u4f7f\u7528\u573a\u666f-2",children:"\u4f7f\u7528\u573a\u666f"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u591a\u89c6\u89d2\u5206\u6790"}),"\n",(0,s.jsx)(n.li,{children:"\u6280\u672f\u9009\u578b"}),"\n",(0,s.jsx)(n.li,{children:"\u65b9\u6848\u5bf9\u6bd4"}),"\n",(0,s.jsx)(n.li,{children:"\u67b6\u6784\u51b3\u7b56"}),"\n"]}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"level-2-\u5bf9\u6bd4\u8868",children:"Level 2 \u5bf9\u6bd4\u8868"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u65b9\u9762"}),(0,s.jsx)(n.th,{children:"lite-plan"}),(0,s.jsx)(n.th,{children:"lite-fix"}),(0,s.jsx)(n.th,{children:"multi-cli-plan"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u7528\u9014"})}),(0,s.jsx)(n.td,{children:"\u9700\u6c42\u660e\u786e"}),(0,s.jsx)(n.td,{children:"\u6f0f\u6d1e\u8bca\u65ad"}),(0,s.jsx)(n.td,{children:"\u591a\u89c6\u89d2"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u89c4\u5212"})}),(0,s.jsx)(n.td,{children:"\u5185\u5b58\u4e2d"}),(0,s.jsx)(n.td,{children:"\u57fa\u4e8e\u4e25\u91cd\u7a0b\u5ea6"}),(0,s.jsx)(n.td,{children:"\u5171\u8bc6\u9a71\u52a8"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4ea7\u7269"})}),(0,s.jsx)(n.td,{children:"memory://plan"}),(0,s.jsx)(n.td,{children:".lite-fix/"}),(0,s.jsx)(n.td,{children:".multi-cli-plan/"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4ee3\u7801\u63a2\u7d22"})}),(0,s.jsx)(n.td,{children:"\u53ef\u9009 (-e \u53c2\u6570)"}),(0,s.jsx)(n.td,{children:"\u5185\u7f6e\u8bca\u65ad"}),(0,s.jsx)(n.td,{children:"ACE \u641c\u7d22"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u591aCLI"})}),(0,s.jsx)(n.td,{children:"\u5426"}),(0,s.jsx)(n.td,{children:"\u5426"}),(0,s.jsx)(n.td,{children:"\u662f (Gemini/Codex/Claude)"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u6700\u9002\u5408"})}),(0,s.jsx)(n.td,{children:"\u5355\u6a21\u5757\u529f\u80fd"}),(0,s.jsx)(n.td,{children:"\u6f0f\u6d1e\u4fee\u590d"}),(0,s.jsx)(n.td,{children:"\u6280\u672f\u51b3\u7b56"})]})]})]}),"\n",(0,s.jsx)(n.h2,{id:"\u6267\u884c-lite-execute",children:"\u6267\u884c: lite-execute"}),"\n",(0,s.jsxs)(n.p,{children:["\u6240\u6709 Level 2 \u5de5\u4f5c\u6d41\u901a\u8fc7 ",(0,s.jsx)(n.code,{children:"lite-execute"})," \u6267\u884c:"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:"/workflow:lite-execute --in-memory\n"})}),"\n",(0,s.jsx)(n.h3,{id:"\u6267\u884c\u6d41\u7a0b",children:"\u6267\u884c\u6d41\u7a0b"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n A([\u5f00\u59cb]) --\x3e B[\u521d\u59cb\u5316\u8ffd\u8e2a
previousExecutionResults]\n B --\x3e C[\u4efb\u52a1\u5206\u7ec4
& \u6279\u91cf\u521b\u5efa]\n\n C --\x3e D[\u63d0\u53d6\u663e\u5f0f
depends_on]\n D --\x3e E[\u5206\u7ec4: \u72ec\u7acb
\u4efb\u52a1 -> \u5e76\u884c\u6279\u6b21]\n E --\x3e F[\u5206\u7ec4: \u4f9d\u8d56
\u4efb\u52a1 -> \u987a\u5e8f\u9636\u6bb5]\n\n F --\x3e G[\u521b\u5efa TodoWrite
\u6279\u6b21\u5217\u8868]\n G --\x3e H[\u542f\u52a8\u6267\u884c]\n\n H --\x3e I[\u9636\u6bb5 1: \u6240\u6709\u72ec\u7acb
\u4efb\u52a1 - \u5355\u6279\u6b21]\n I --\x3e J[\u9636\u6bb5 2+: \u4f9d\u8d56\u4efb\u52a1
\u6309\u4f9d\u8d56\u987a\u5e8f]\n\n J --\x3e K[\u8ffd\u8e2a\u8fdb\u5ea6
TodoWrite \u66f4\u65b0]\n K --\x3e L{\u9700\u8981
\u4ee3\u7801\u5ba1\u6838?}\n L --\x3e|\u662f| M[\u5ba1\u6838\u6d41\u7a0b]\n L --\x3e|\u5426| N([\u5b8c\u6210])\n M --\x3e N\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n\n class A,N startend,B,D,E,F,G,I,J,K,M action,C,L decision\n"}),"\n",(0,s.jsx)(n.h3,{id:"\u7279\u6027",children:"\u7279\u6027"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u5e76\u884c\u6267\u884c"})," \u72ec\u7acb\u4efb\u52a1"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u987a\u5e8f\u9636\u6bb5"})," \u4f9d\u8d56\u4efb\u52a1"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u8fdb\u5ea6\u8ffd\u8e2a"})," \u901a\u8fc7 TodoWrite"]}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.strong,{children:"\u53ef\u9009\u4ee3\u7801\u5ba1\u6838"})}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"\u76f8\u5173\u5de5\u4f5c\u6d41",children:"\u76f8\u5173\u5de5\u4f5c\u6d41"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"/docs/zh/workflows/level-1-ultra-lightweight",children:"Level 1: \u8d85\u8f7b\u91cf\u7ea7"})," - \u66f4\u7b80\u5355\u7684\u5de5\u4f5c\u6d41"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"/docs/zh/workflows/level-3-standard",children:"Level 3: \u6807\u51c6\u7ea7"})," - \u5b8c\u6574\u4f1a\u8bdd\u7ba1\u7406"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"/docs/zh/workflows/level-4-brainstorm",children:"Level 4: \u5934\u8111\u98ce\u66b4"})," - \u591a\u89d2\u8272\u63a2\u7d22"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"/docs/zh/workflows/faq",children:"\u5e38\u89c1\u95ee\u9898"})," - \u5e38\u89c1\u95ee\u9898\u89e3\u7b54"]}),"\n"]})]})}function o(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(j,{...e})}):j(e)}}}]); \ No newline at end of file +"use strict";(globalThis.webpackChunkccw_docs=globalThis.webpackChunkccw_docs||[]).push([[139],{1184(e,n,l){l.d(n,{R:()=>d,x:()=>c});var i=l(3696);const s={},r=i.createContext(s);function d(e){const n=i.useContext(r);return i.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:d(e.components),i.createElement(r.Provider,{value:n},e.children)}},1923(e,n,l){l.r(n),l.d(n,{assets:()=>x,contentTitle:()=>t,default:()=>o,frontMatter:()=>c,metadata:()=>i,toc:()=>h});const i=JSON.parse('{"id":"workflows/level-2-rapid","title":"\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41","description":"\u8f7b\u91cf\u89c4\u5212\u548c\u6f0f\u6d1e\u8bca\u65ad\u5de5\u4f5c\u6d41 - \u9002\u7528\u4e8e\u5355\u6a21\u5757\u529f\u80fd","source":"@site/i18n/zh/docusaurus-plugin-content-docs/current/workflows/level-2-rapid.mdx","sourceDirName":"workflows","slug":"/workflows/level-2-rapid","permalink":"/docs/zh/workflows/level-2-rapid","draft":false,"unlisted":false,"editUrl":"https://github.com/ccw/docs/tree/main/docs/workflows/level-2-rapid.mdx","tags":[],"version":"current","sidebarPosition":3,"frontMatter":{"title":"\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41","description":"\u8f7b\u91cf\u89c4\u5212\u548c\u6f0f\u6d1e\u8bca\u65ad\u5de5\u4f5c\u6d41 - \u9002\u7528\u4e8e\u5355\u6a21\u5757\u529f\u80fd","sidebar_position":3},"sidebar":"docs","previous":{"title":"Level 1: Ultra Lightweight","permalink":"/docs/zh/workflows/level-1-ultra-lightweight"},"next":{"title":"Level 3: Standard","permalink":"/docs/zh/workflows/level-3-standard"}}');var s=l(2540),r=l(1184),d=l(1540);const c={title:"\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41",description:"\u8f7b\u91cf\u89c4\u5212\u548c\u6f0f\u6d1e\u8bca\u65ad\u5de5\u4f5c\u6d41 - \u9002\u7528\u4e8e\u5355\u6a21\u5757\u529f\u80fd",sidebar_position:3},t="\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41",x={},h=[{value:"\u6982\u8ff0",id:"\u6982\u8ff0",level:2},{value:"\u5305\u542b\u7684\u5de5\u4f5c\u6d41",id:"\u5305\u542b\u7684\u5de5\u4f5c\u6d41",level:2},{value:"\u5171\u540c\u7279\u5f81",id:"\u5171\u540c\u7279\u5f81",level:3},{value:"\u5de5\u4f5c\u6d41 1: lite-plan -> lite-execute",id:"\u5de5\u4f5c\u6d41-1-lite-plan---lite-execute",level:2},{value:"\u547d\u4ee4",id:"\u547d\u4ee4",level:3},{value:"\u6d41\u7a0b\u56fe",id:"\u6d41\u7a0b\u56fe",level:3},{value:"\u6d41\u7a0b\u9636\u6bb5",id:"\u6d41\u7a0b\u9636\u6bb5",level:3},{value:"\u4ea7\u7269",id:"\u4ea7\u7269",level:3},{value:"\u4f7f\u7528\u573a\u666f",id:"\u4f7f\u7528\u573a\u666f",level:3},{value:"\u5de5\u4f5c\u6d41 2: lite-fix",id:"\u5de5\u4f5c\u6d41-2-lite-fix",level:2},{value:"\u547d\u4ee4",id:"\u547d\u4ee4-1",level:3},{value:"\u6d41\u7a0b\u56fe",id:"\u6d41\u7a0b\u56fe-1",level:3},{value:"\u6d41\u7a0b\u9636\u6bb5",id:"\u6d41\u7a0b\u9636\u6bb5-1",level:3},{value:"\u4ea7\u7269",id:"\u4ea7\u7269-1",level:3},{value:"\u4e25\u91cd\u7a0b\u5ea6\u7ea7\u522b",id:"\u4e25\u91cd\u7a0b\u5ea6\u7ea7\u522b",level:3},{value:"\u70ed\u4fee\u590d\u6a21\u5f0f",id:"\u70ed\u4fee\u590d\u6a21\u5f0f",level:3},{value:"\u4f7f\u7528\u573a\u666f",id:"\u4f7f\u7528\u573a\u666f-1",level:3},{value:"\u5de5\u4f5c\u6d41 3: multi-cli-plan -> lite-execute",id:"\u5de5\u4f5c\u6d41-3-multi-cli-plan---lite-execute",level:2},{value:"\u547d\u4ee4",id:"\u547d\u4ee4-2",level:3},{value:"\u6d41\u7a0b\u56fe",id:"\u6d41\u7a0b\u56fe-2",level:3},{value:"\u6d41\u7a0b\u9636\u6bb5",id:"\u6d41\u7a0b\u9636\u6bb5-2",level:3},{value:"\u4ea7\u7269",id:"\u4ea7\u7269-2",level:3},{value:"\u4e0e lite-plan \u5bf9\u6bd4",id:"\u4e0e-lite-plan-\u5bf9\u6bd4",level:3},{value:"\u4f7f\u7528\u573a\u666f",id:"\u4f7f\u7528\u573a\u666f-2",level:3},{value:"Level 2 \u5bf9\u6bd4\u8868",id:"level-2-\u5bf9\u6bd4\u8868",level:2},{value:"\u6267\u884c: lite-execute",id:"\u6267\u884c-lite-execute",level:2},{value:"\u6267\u884c\u6d41\u7a0b",id:"\u6267\u884c\u6d41\u7a0b",level:3},{value:"\u7279\u6027",id:"\u7279\u6027",level:3},{value:"\u76f8\u5173\u5de5\u4f5c\u6d41",id:"\u76f8\u5173\u5de5\u4f5c\u6d41",level:2}];function j(e){const n={a:"a",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",hr:"hr",li:"li",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,r.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.header,{children:(0,s.jsx)(n.h1,{id:"\u5c42\u7ea7-2-\u5feb\u901f\u5de5\u4f5c\u6d41",children:"\u5c42\u7ea7 2: \u5feb\u901f\u5de5\u4f5c\u6d41"})}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u590d\u6742\u5ea6"}),": \u4f4e-\u4e2d\u7b49 | ",(0,s.jsx)(n.strong,{children:"\u4ea7\u7269"}),": \u5185\u5b58/\u8f7b\u91cf\u6587\u4ef6 | ",(0,s.jsx)(n.strong,{children:"\u72b6\u6001"}),": \u4f1a\u8bdd\u4f5c\u7528\u57df"]}),"\n",(0,s.jsx)(n.p,{children:"Level 2 \u5de5\u4f5c\u6d41\u63d0\u4f9b\u8f7b\u91cf\u7ea7\u89c4\u5212\u6216\u5355\u6b21\u5206\u6790\uff0c\u652f\u6301\u5feb\u901f\u8fed\u4ee3\u3002\u5b83\u4eec\u4e13\u4e3a\u9700\u6c42\u76f8\u5bf9\u660e\u786e\u3001\u4e0d\u9700\u8981\u5b8c\u6574\u4f1a\u8bdd\u6301\u4e45\u5316\u7684\u4efb\u52a1\u800c\u8bbe\u8ba1\u3002"}),"\n",(0,s.jsx)(n.h2,{id:"\u6982\u8ff0",children:"\u6982\u8ff0"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n Start([\u7528\u6237\u8f93\u5165]) --\x3e Select{\u9009\u62e9\u5de5\u4f5c\u6d41}\n\n Select --\x3e|\u9700\u6c42
\u660e\u786e| LP[lite-plan]\n Select --\x3e|\u6f0f\u6d1e\u4fee\u590d| LF[lite-fix]\n Select --\x3e|\u9700\u8981
\u591aCLI| MCP[multi-cli-plan]\n\n LP --\x3e LE[lite-execute]\n LF --\x3e LE\n MCP --\x3e LE\n\n LE --\x3e Test{\u9700\u8981
\u6d4b\u8bd5?}\n Test --\x3e|\u662f| TFG[test-fix-gen]\n Test --\x3e|\u5426| Done([\u5b8c\u6210])\n TFG --\x3e TCE[test-cycle-execute]\n TCE --\x3e Done\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef workflow fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef execute fill:#c5e1a5,stroke:#388e3c\n\n class Start,Done startend,Select,Test decision,LP,LF,MCP workflow,LE execute,TFG,TCE execute\n"}),"\n",(0,s.jsx)(n.h2,{id:"\u5305\u542b\u7684\u5de5\u4f5c\u6d41",children:"\u5305\u542b\u7684\u5de5\u4f5c\u6d41"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u5de5\u4f5c\u6d41"}),(0,s.jsx)(n.th,{children:"\u7528\u9014"}),(0,s.jsx)(n.th,{children:"\u4ea7\u7269"}),(0,s.jsx)(n.th,{children:"\u6267\u884c\u65b9\u5f0f"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"lite-plan"})}),(0,s.jsx)(n.td,{children:"\u9700\u6c42\u660e\u786e\u7684\u5f00\u53d1"}),(0,s.jsx)(n.td,{children:"memory://plan"}),(0,s.jsxs)(n.td,{children:["-> ",(0,s.jsx)(n.code,{children:"lite-execute"})]})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"lite-fix"})}),(0,s.jsx)(n.td,{children:"\u6f0f\u6d1e\u8bca\u65ad\u4e0e\u4fee\u590d"}),(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:".workflow/.lite-fix/"})}),(0,s.jsxs)(n.td,{children:["-> ",(0,s.jsx)(n.code,{children:"lite-execute"})]})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"multi-cli-plan"})}),(0,s.jsx)(n.td,{children:"\u591a\u89c6\u89d2\u4efb\u52a1"}),(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:".workflow/.multi-cli-plan/"})}),(0,s.jsxs)(n.td,{children:["-> ",(0,s.jsx)(n.code,{children:"lite-execute"})]})]})]})]}),"\n",(0,s.jsx)(n.h3,{id:"\u5171\u540c\u7279\u5f81",children:"\u5171\u540c\u7279\u5f81"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u5c5e\u6027"}),(0,s.jsx)(n.th,{children:"\u503c"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u590d\u6742\u5ea6"})}),(0,s.jsx)(n.td,{children:"\u4f4e-\u4e2d\u7b49"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u72b6\u6001"})}),(0,s.jsx)(n.td,{children:"\u4f1a\u8bdd\u4f5c\u7528\u57df / \u8f7b\u91cf\u6301\u4e45\u5316"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u6267\u884c"})}),(0,s.jsxs)(n.td,{children:["\u7edf\u4e00\u901a\u8fc7 ",(0,s.jsx)(n.code,{children:"lite-execute"})]})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4f7f\u7528\u573a\u666f"})}),(0,s.jsx)(n.td,{children:"\u9700\u6c42\u76f8\u5bf9\u660e\u786e"})]})]})]}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"\u5de5\u4f5c\u6d41-1-lite-plan---lite-execute",children:"\u5de5\u4f5c\u6d41 1: lite-plan -> lite-execute"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u5185\u5b58\u89c4\u5212 + \u76f4\u63a5\u6267\u884c"})}),"\n",(0,s.jsx)(n.h3,{id:"\u547d\u4ee4",children:"\u547d\u4ee4"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-plan "Add user authentication API"\n/workflow:lite-execute\n'})}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u56fe",children:"\u6d41\u7a0b\u56fe"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n A([\u5f00\u59cb]) --\x3e B[\u9636\u6bb5 1: \u4ee3\u7801\u63a2\u7d22]\n B --\x3e C{\u9700\u8981
\u4ee3\u7801\u63a2\u7d22?}\n C --\x3e|\u662f| D[cli-explore-agent
\u591a\u89d2\u5ea6\u5206\u6790]\n C --\x3e|\u5426| E[\u8df3\u8fc7\u63a2\u7d22]\n\n D --\x3e F[\u9636\u6bb5 2: \u590d\u6742\u5ea6\u8bc4\u4f30]\n E --\x3e F\n\n F --\x3e G{\u590d\u6742\u5ea6}\n G --\x3e|\u4f4e| H[\u76f4\u63a5 Claude
\u89c4\u5212]\n G --\x3e|\u4e2d| H\n G --\x3e|\u9ad8| I[cli-lite-planning
-agent]\n\n H --\x3e J[\u9636\u6bb5 3: \u89c4\u5212]\n I --\x3e J\n\n J --\x3e K[\u9636\u6bb5 4: \u786e\u8ba4]\n K --\x3e L{\u786e\u8ba4?}\n L --\x3e|\u4fee\u6539| M[\u8c03\u6574\u8ba1\u5212]\n M --\x3e K\n L --\x3e|\u5141\u8bb8| N[\u9636\u6bb5 5: \u6267\u884c]\n L --\x3e|\u53d6\u6d88| O([\u4e2d\u6b62])\n\n N --\x3e P[\u6784\u5efa\u6267\u884c\u4e0a\u4e0b\u6587]\n P --\x3e Q[/workflow:lite-execute]\n Q --\x3e R([\u5b8c\u6210])\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n\n class A,R,O startend,B,D,E,J,M,P,Q action,C,G,L decision,F,H,I agent\n"}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u9636\u6bb5",children:"\u6d41\u7a0b\u9636\u6bb5"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 1: \u4ee3\u7801\u63a2\u7d22"})," (\u53ef\u9009)"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'# \u5982\u679c\u6307\u5b9a\u4e86 -e \u53c2\u6570\n/workflow:lite-plan -e "Add user authentication API"\n'})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u901a\u8fc7 cli-explore-agent \u8fdb\u884c\u591a\u89d2\u5ea6\u4ee3\u7801\u5206\u6790"}),"\n",(0,s.jsx)(n.li,{children:"\u8bc6\u522b\u6a21\u5f0f\u3001\u4f9d\u8d56\u5173\u7cfb\u3001\u96c6\u6210\u70b9"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 2: \u590d\u6742\u5ea6\u8bc4\u4f30"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u4f4e: \u65e0\u9700\u4ee3\u7406\uff0c\u76f4\u63a5\u89c4\u5212"}),"\n",(0,s.jsx)(n.li,{children:"\u4e2d/\u9ad8: \u4f7f\u7528 cli-lite-planning-agent"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 3: \u89c4\u5212"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["\u52a0\u8f7d\u8ba1\u5212 schema: ",(0,s.jsx)(n.code,{children:"~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json"})]}),"\n",(0,s.jsx)(n.li,{children:"\u6309\u7167\u751f\u6210\u8ba1\u5212 schema \u751f\u6210 plan.json"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 4: \u786e\u8ba4\u4e0e\u9009\u62e9"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u663e\u793a\u8ba1\u5212\u6458\u8981\uff08\u4efb\u52a1\u3001\u590d\u6742\u5ea6\u3001\u9884\u4f30\u65f6\u95f4\uff09"}),"\n",(0,s.jsxs)(n.li,{children:["\u8be2\u95ee\u7528\u6237\u9009\u62e9:","\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u786e\u8ba4: \u5141\u8bb8 / \u4fee\u6539 / \u53d6\u6d88"}),"\n",(0,s.jsx)(n.li,{children:"\u6267\u884c: Agent / Codex / Auto"}),"\n",(0,s.jsx)(n.li,{children:"\u5ba1\u6838: Gemini / Agent / \u8df3\u8fc7"}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 5: \u6267\u884c"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u6784\u5efa\u6267\u884c\u4e0a\u4e0b\u6587\uff08\u8ba1\u5212 + \u63a2\u7d22 + \u6f84\u6e05 + \u9009\u62e9\uff09"}),"\n",(0,s.jsxs)(n.li,{children:["\u901a\u8fc7 ",(0,s.jsx)(n.code,{children:"/workflow:lite-execute --in-memory"})," \u6267\u884c"]}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4ea7\u7269",children:"\u4ea7\u7269"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u5185\u5b58"}),": ",(0,s.jsx)(n.code,{children:"memory://plan"})," (\u4e0d\u6301\u4e45\u5316)"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u53ef\u9009"}),": ",(0,s.jsx)(n.code,{children:".workflow/.lite-exploration/"})," (\u5982\u679c\u4f7f\u7528\u4e86\u4ee3\u7801\u63a2\u7d22)"]}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4f7f\u7528\u573a\u666f",children:"\u4f7f\u7528\u573a\u666f"}),"\n",(0,s.jsx)(n.p,{children:"\u9700\u6c42\u660e\u786e\u7684\u5355\u6a21\u5757\u529f\u80fd"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u793a\u4f8b"}),":"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-plan "Add email validation to user registration form"\n/workflow:lite-execute\n'})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"\u5de5\u4f5c\u6d41-2-lite-fix",children:"\u5de5\u4f5c\u6d41 2: lite-fix"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u667a\u80fd\u8bca\u65ad + \u4fee\u590d (5 \u9636\u6bb5)"})}),"\n",(0,s.jsx)(n.h3,{id:"\u547d\u4ee4-1",children:"\u547d\u4ee4"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-fix "Login timeout after 30 seconds"\n/workflow:lite-execute --in-memory --mode bugfix\n\n# \u7d27\u6025\u70ed\u4fee\u590d\u6a21\u5f0f\n/workflow:lite-fix --hotfix "Production database connection failing"\n'})}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u56fe-1",children:"\u6d41\u7a0b\u56fe"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n A([\u5f00\u59cb]) --\x3e B[\u9636\u6bb5 1: \u6f0f\u6d1e\u5206\u6790
& \u8bca\u65ad]\n B --\x3e C[\u4e25\u91cd\u7a0b\u5ea6\u9884\u8bc4\u4f30
\u4f4e/\u4e2d/\u9ad8/\u4e25\u91cd]\n C --\x3e D[\u5e76\u884c cli-explore
-agent \u8bca\u65ad
1-4 \u89d2\u5ea6]\n\n D --\x3e E[\u9636\u6bb5 2: \u6f84\u6e05]\n E --\x3e F{\u9700\u8981
\u66f4\u591a\u4fe1\u606f?}\n F --\x3e|\u662f| G[AskUserQuestion
\u805a\u5408\u6f84\u6e05]\n F --\x3e|\u5426| H[\u9636\u6bb5 3: \u4fee\u590d\u89c4\u5212]\n G --\x3e H\n\n H --\x3e I{\u4e25\u91cd\u7a0b\u5ea6}\n I --\x3e|\u4f4e/\u4e2d| J[\u76f4\u63a5 Claude
\u89c4\u5212]\n I --\x3e|\u9ad8/\u4e25\u91cd| K[cli-lite-planning
-agent]\n\n J --\x3e L[\u9636\u6bb5 4: \u786e\u8ba4]\n K --\x3e L\n\n L --\x3e M[\u7528\u6237\u786e\u8ba4
\u6267\u884c\u65b9\u6cd5]\n M --\x3e N[\u9636\u6bb5 5: \u6267\u884c]\n N --\x3e O[/workflow:lite-execute
--in-memory --mode bugfix/]\n O --\x3e P([\u5b8c\u6210])\n\n Q[\u70ed\u4fee\u590d\u6a21\u5f0f] --\x3e R[\u8df3\u8fc7\u8bca\u65ad
\u6700\u5c0f\u89c4\u5212]\n R --\x3e N\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n classDef hotfix fill:#ffccbc,stroke:#bf360c\n\n class A,P startend,B,E,G,H,L,M,N,O action,F,I decision,C,D,J,K agent,Q,R hotfix\n"}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u9636\u6bb5-1",children:"\u6d41\u7a0b\u9636\u6bb5"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 1: \u6f0f\u6d1e\u5206\u6790\u4e0e\u8bca\u65ad"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u667a\u80fd\u4e25\u91cd\u7a0b\u5ea6\u9884\u8bc4\u4f30\uff08\u4f4e/\u4e2d/\u9ad8/\u4e25\u91cd\uff09"}),"\n",(0,s.jsx)(n.li,{children:"\u5e76\u884c cli-explore-agent \u8bca\u65ad\uff081-4 \u89d2\u5ea6\uff09"}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 2: \u6f84\u6e05"})," (\u53ef\u9009)"]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u805a\u5408\u6f84\u6e05\u9700\u6c42"}),"\n",(0,s.jsx)(n.li,{children:"AskUserQuestion \u83b7\u53d6\u7f3a\u5931\u4fe1\u606f"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 3: \u4fee\u590d\u89c4\u5212"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u4f4e/\u4e2d\u4e25\u91cd\u7a0b\u5ea6 -> \u76f4\u63a5 Claude \u89c4\u5212"}),"\n",(0,s.jsx)(n.li,{children:"\u9ad8/\u4e25\u91cd\u7a0b\u5ea6 -> cli-lite-planning-agent"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 4: \u786e\u8ba4\u4e0e\u9009\u62e9"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u663e\u793a\u4fee\u590d\u8ba1\u5212\u6458\u8981"}),"\n",(0,s.jsx)(n.li,{children:"\u7528\u6237\u786e\u8ba4\u6267\u884c\u65b9\u6cd5"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 5: \u6267\u884c"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["\u901a\u8fc7 ",(0,s.jsx)(n.code,{children:"/workflow:lite-execute --in-memory --mode bugfix"})," \u6267\u884c"]}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4ea7\u7269-1",children:"\u4ea7\u7269"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u4f4d\u7f6e"}),": ",(0,s.jsx)(n.code,{children:".workflow/.lite-fix/{bug-slug}-{YYYY-MM-DD}/"})]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{children:".workflow/.lite-fix/\n\u2514\u2500\u2500 login-timeout-fix-2025-02-03/\n \u251c\u2500\u2500 diagnosis-root-cause.json\n \u251c\u2500\u2500 diagnosis-impact.json\n \u251c\u2500\u2500 diagnosis-code-flow.json\n \u251c\u2500\u2500 diagnosis-similar.json\n \u251c\u2500\u2500 diagnoses-manifest.json\n \u251c\u2500\u2500 fix-plan.json\n \u2514\u2500\u2500 README.md\n"})}),"\n",(0,s.jsx)(n.h3,{id:"\u4e25\u91cd\u7a0b\u5ea6\u7ea7\u522b",children:"\u4e25\u91cd\u7a0b\u5ea6\u7ea7\u522b"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u4e25\u91cd\u7a0b\u5ea6"}),(0,s.jsx)(n.th,{children:"\u63cf\u8ff0"}),(0,s.jsx)(n.th,{children:"\u89c4\u5212\u65b9\u6cd5"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4f4e"})}),(0,s.jsx)(n.td,{children:"\u7b80\u5355\u4fee\u590d\uff0c\u6839\u56e0\u660e\u786e"}),(0,s.jsx)(n.td,{children:"\u76f4\u63a5 Claude\uff08\u53ef\u9009\u7406\u7531\uff09"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4e2d"})}),(0,s.jsx)(n.td,{children:"\u4e2d\u7b49\u590d\u6742\u5ea6\uff0c\u9700\u8c03\u67e5"}),(0,s.jsx)(n.td,{children:"\u76f4\u63a5 Claude\uff08\u542b\u7406\u7531\uff09"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u9ad8"})}),(0,s.jsx)(n.td,{children:"\u590d\u6742\uff0c\u5f71\u54cd\u591a\u4e2a\u7ec4\u4ef6"}),(0,s.jsx)(n.td,{children:"cli-lite-planning-agent\uff08\u5b8c\u6574 schema\uff09"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4e25\u91cd"})}),(0,s.jsx)(n.td,{children:"\u751f\u4ea7\u4e8b\u6545\uff0c\u7d27\u6025"}),(0,s.jsx)(n.td,{children:"cli-lite-planning-agent + \u70ed\u4fee\u590d\u6a21\u5f0f"})]})]})]}),"\n",(0,s.jsx)(n.h3,{id:"\u70ed\u4fee\u590d\u6a21\u5f0f",children:"\u70ed\u4fee\u590d\u6a21\u5f0f"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:lite-fix --hotfix "Production API returning 500 errors"\n'})}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u7279\u70b9"}),":"]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u8df3\u8fc7\u5927\u90e8\u5206\u8bca\u65ad\u9636\u6bb5"}),"\n",(0,s.jsx)(n.li,{children:"\u6700\u5c0f\u89c4\u5212\uff08\u76f4\u63a5\u6267\u884c\uff09"}),"\n",(0,s.jsx)(n.li,{children:"\u81ea\u52a8\u751f\u6210\u540e\u7eed\u4efb\u52a1\u7528\u4e8e\u5b8c\u6574\u4fee\u590d + \u4e8b\u540e\u5206\u6790"}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4f7f\u7528\u573a\u666f-1",children:"\u4f7f\u7528\u573a\u666f"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u6f0f\u6d1e\u8bca\u65ad"}),"\n",(0,s.jsx)(n.li,{children:"\u751f\u4ea7\u73af\u5883\u7d27\u6025\u60c5\u51b5"}),"\n",(0,s.jsx)(n.li,{children:"\u6839\u56e0\u5206\u6790"}),"\n"]}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"\u5de5\u4f5c\u6d41-3-multi-cli-plan---lite-execute",children:"\u5de5\u4f5c\u6d41 3: multi-cli-plan -> lite-execute"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u591aCLI \u534f\u4f5c\u5206\u6790 + \u5171\u8bc6\u6536\u655b"})}),"\n",(0,s.jsx)(n.h3,{id:"\u547d\u4ee4-2",children:"\u547d\u4ee4"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'/workflow:multi-cli-plan "Compare Redis vs Memcached for caching"\n/workflow:lite-execute\n'})}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u56fe-2",children:"\u6d41\u7a0b\u56fe"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n A([\u5f00\u59cb]) --\x3e B[\u9636\u6bb5 1: \u4e0a\u4e0b\u6587\u6536\u96c6]\n B --\x3e C[ACE \u8bed\u4e49\u641c\u7d22
\u6784\u5efa\u4e0a\u4e0b\u6587\u5305]\n\n C --\x3e D[\u9636\u6bb5 2: \u591aCLI \u8ba8\u8bba
\u8fed\u4ee3]\n D --\x3e E[cli-discuss-agent]\n E --\x3e F[Gemini + Codex + Claude]\n\n F --\x3e G{\u5df2\u6536\u655b?}\n G --\x3e|\u5426| H[\u4ea4\u53c9\u9a8c\u8bc1
\u7efc\u5408\u89e3\u51b3\u65b9\u6848]\n H --\x3e D\n G --\x3e|\u662f| I[\u9636\u6bb5 3: \u5c55\u793a\u9009\u9879]\n\n I --\x3e J[\u5c55\u793a\u89e3\u51b3\u65b9\u6848
\u53ca\u6743\u8861]\n\n J --\x3e K[\u9636\u6bb5 4: \u7528\u6237\u51b3\u7b56]\n K --\x3e L[\u7528\u6237\u9009\u62e9\u89e3\u51b3\u65b9\u6848]\n\n L --\x3e M[\u9636\u6bb5 5: \u8ba1\u5212\u751f\u6210]\n M --\x3e N[cli-lite-planning
-agent]\n N --\x3e O[-> lite-execute]\n\n O --\x3e P([\u5b8c\u6210])\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n classDef agent fill:#ffecb3,stroke:#ffa000\n\n class A,P startend,B,C,E,H,J,L,M,O action,G,K decision,F,N agent\n"}),"\n",(0,s.jsx)(n.h3,{id:"\u6d41\u7a0b\u9636\u6bb5-2",children:"\u6d41\u7a0b\u9636\u6bb5"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 1: \u4e0a\u4e0b\u6587\u6536\u96c6"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"ACE \u8bed\u4e49\u641c\u7d22"}),"\n",(0,s.jsx)(n.li,{children:"\u6784\u5efa\u4e0a\u4e0b\u6587\u5305"}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 2: \u591aCLI \u8ba8\u8bba"})," (\u8fed\u4ee3)"]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"cli-discuss-agent \u6267\u884c Gemini + Codex + Claude"}),"\n",(0,s.jsx)(n.li,{children:"\u4ea4\u53c9\u9a8c\u8bc1\uff0c\u7efc\u5408\u89e3\u51b3\u65b9\u6848"}),"\n",(0,s.jsx)(n.li,{children:"\u5faa\u73af\u76f4\u81f3\u6536\u655b\u6216\u8fbe\u5230\u6700\u5927\u8f6e\u6b21"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 3: \u5c55\u793a\u9009\u9879"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u5c55\u793a\u89e3\u51b3\u65b9\u6848\u53ca\u6743\u8861"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 4: \u7528\u6237\u51b3\u7b56"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u7528\u6237\u9009\u62e9\u89e3\u51b3\u65b9\u6848"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:"\u9636\u6bb5 5: \u8ba1\u5212\u751f\u6210"})}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"cli-lite-planning-agent \u751f\u6210\u8ba1\u5212"}),"\n",(0,s.jsx)(n.li,{children:"-> lite-execute"}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"\u4ea7\u7269-2",children:"\u4ea7\u7269"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"\u4f4d\u7f6e"}),": ",(0,s.jsx)(n.code,{children:".workflow/.multi-cli-plan/{MCP-task-slug-date}/"})]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{children:".workflow/.multi-cli-plan/\n\u2514\u2500\u2500 redis-vs-memcached-2025-02-03/\n \u251c\u2500\u2500 context-package.json\n \u251c\u2500\u2500 rounds/\n \u2502 \u251c\u2500\u2500 round-1/\n \u2502 \u2502 \u251c\u2500\u2500 gemini-analysis.md\n \u2502 \u2502 \u251c\u2500\u2500 codex-analysis.md\n \u2502 \u2502 \u251c\u2500\u2500 claude-analysis.md\n \u2502 \u2502 \u2514\u2500\u2500 synthesis.json\n \u2502 \u251c\u2500\u2500 round-2/\n \u2502 \u2514\u2500\u2500 ...\n \u251c\u2500\u2500 selected-solution.json\n \u251c\u2500\u2500 IMPL_PLAN.md\n \u2514\u2500\u2500 plan.json\n"})}),"\n",(0,s.jsx)(n.h3,{id:"\u4e0e-lite-plan-\u5bf9\u6bd4",children:"\u4e0e lite-plan \u5bf9\u6bd4"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u65b9\u9762"}),(0,s.jsx)(n.th,{children:"multi-cli-plan"}),(0,s.jsx)(n.th,{children:"lite-plan"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4e0a\u4e0b\u6587"})}),(0,s.jsx)(n.td,{children:"ACE \u8bed\u4e49\u641c\u7d22"}),(0,s.jsx)(n.td,{children:"\u624b\u52a8\u6587\u4ef6\u6a21\u5f0f"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u5206\u6790"})}),(0,s.jsx)(n.td,{children:"\u591aCLI \u4ea4\u53c9\u9a8c\u8bc1"}),(0,s.jsx)(n.td,{children:"\u5355\u6b21\u89c4\u5212"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u8fed\u4ee3"})}),(0,s.jsx)(n.td,{children:"\u591a\u8f6e\u81f3\u6536\u655b"}),(0,s.jsx)(n.td,{children:"\u5355\u8f6e"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u53ef\u4fe1\u5ea6"})}),(0,s.jsx)(n.td,{children:"\u9ad8\uff08\u5171\u8bc6\u9a71\u52a8\uff09"}),(0,s.jsx)(n.td,{children:"\u4e2d\uff08\u5355\u89c6\u89d2\uff09"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u65f6\u95f4"})}),(0,s.jsx)(n.td,{children:"\u8f83\u957f\uff08\u591a\u8f6e\uff09"}),(0,s.jsx)(n.td,{children:"\u66f4\u5feb"})]})]})]}),"\n",(0,s.jsx)(n.h3,{id:"\u4f7f\u7528\u573a\u666f-2",children:"\u4f7f\u7528\u573a\u666f"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"\u591a\u89c6\u89d2\u5206\u6790"}),"\n",(0,s.jsx)(n.li,{children:"\u6280\u672f\u9009\u578b"}),"\n",(0,s.jsx)(n.li,{children:"\u65b9\u6848\u5bf9\u6bd4"}),"\n",(0,s.jsx)(n.li,{children:"\u67b6\u6784\u51b3\u7b56"}),"\n"]}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"level-2-\u5bf9\u6bd4\u8868",children:"Level 2 \u5bf9\u6bd4\u8868"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"\u65b9\u9762"}),(0,s.jsx)(n.th,{children:"lite-plan"}),(0,s.jsx)(n.th,{children:"lite-fix"}),(0,s.jsx)(n.th,{children:"multi-cli-plan"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u7528\u9014"})}),(0,s.jsx)(n.td,{children:"\u9700\u6c42\u660e\u786e"}),(0,s.jsx)(n.td,{children:"\u6f0f\u6d1e\u8bca\u65ad"}),(0,s.jsx)(n.td,{children:"\u591a\u89c6\u89d2"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u89c4\u5212"})}),(0,s.jsx)(n.td,{children:"\u5185\u5b58\u4e2d"}),(0,s.jsx)(n.td,{children:"\u57fa\u4e8e\u4e25\u91cd\u7a0b\u5ea6"}),(0,s.jsx)(n.td,{children:"\u5171\u8bc6\u9a71\u52a8"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4ea7\u7269"})}),(0,s.jsx)(n.td,{children:"memory://plan"}),(0,s.jsx)(n.td,{children:".lite-fix/"}),(0,s.jsx)(n.td,{children:".multi-cli-plan/"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u4ee3\u7801\u63a2\u7d22"})}),(0,s.jsx)(n.td,{children:"\u53ef\u9009 (-e \u53c2\u6570)"}),(0,s.jsx)(n.td,{children:"\u5185\u7f6e\u8bca\u65ad"}),(0,s.jsx)(n.td,{children:"ACE \u641c\u7d22"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u591aCLI"})}),(0,s.jsx)(n.td,{children:"\u5426"}),(0,s.jsx)(n.td,{children:"\u5426"}),(0,s.jsx)(n.td,{children:"\u662f (Gemini/Codex/Claude)"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.strong,{children:"\u6700\u9002\u5408"})}),(0,s.jsx)(n.td,{children:"\u5355\u6a21\u5757\u529f\u80fd"}),(0,s.jsx)(n.td,{children:"\u6f0f\u6d1e\u4fee\u590d"}),(0,s.jsx)(n.td,{children:"\u6280\u672f\u51b3\u7b56"})]})]})]}),"\n",(0,s.jsx)(n.h2,{id:"\u6267\u884c-lite-execute",children:"\u6267\u884c: lite-execute"}),"\n",(0,s.jsxs)(n.p,{children:["\u6240\u6709 Level 2 \u5de5\u4f5c\u6d41\u901a\u8fc7 ",(0,s.jsx)(n.code,{children:"lite-execute"})," \u6267\u884c:"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:"/workflow:lite-execute --in-memory\n"})}),"\n",(0,s.jsx)(n.h3,{id:"\u6267\u884c\u6d41\u7a0b",children:"\u6267\u884c\u6d41\u7a0b"}),"\n",(0,s.jsx)(d.A,{chart:"\n flowchart TD\n A([\u5f00\u59cb]) --\x3e B[\u521d\u59cb\u5316\u8ffd\u8e2a
previousExecutionResults]\n B --\x3e C[\u4efb\u52a1\u5206\u7ec4
& \u6279\u91cf\u521b\u5efa]\n\n C --\x3e D[\u63d0\u53d6\u663e\u5f0f
depends_on]\n D --\x3e E[\u5206\u7ec4: \u72ec\u7acb
\u4efb\u52a1 -> \u5e76\u884c\u6279\u6b21]\n E --\x3e F[\u5206\u7ec4: \u4f9d\u8d56
\u4efb\u52a1 -> \u987a\u5e8f\u9636\u6bb5]\n\n F --\x3e G[\u521b\u5efa TodoWrite
\u6279\u6b21\u5217\u8868]\n G --\x3e H[\u542f\u52a8\u6267\u884c]\n\n H --\x3e I[\u9636\u6bb5 1: \u6240\u6709\u72ec\u7acb
\u4efb\u52a1 - \u5355\u6279\u6b21]\n I --\x3e J[\u9636\u6bb5 2+: \u4f9d\u8d56\u4efb\u52a1
\u6309\u4f9d\u8d56\u987a\u5e8f]\n\n J --\x3e K[\u8ffd\u8e2a\u8fdb\u5ea6
TodoWrite \u66f4\u65b0]\n K --\x3e L{\u9700\u8981
\u4ee3\u7801\u5ba1\u6838?}\n L --\x3e|\u662f| M[\u5ba1\u6838\u6d41\u7a0b]\n L --\x3e|\u5426| N([\u5b8c\u6210])\n M --\x3e N\n\n classDef startend fill:#c8e6c9,stroke:#388e3c\n classDef action fill:#e3f2fd,stroke:#1976d2\n classDef decision fill:#fff9c4,stroke:#f57c00\n\n class A,N startend,B,D,E,F,G,I,J,K,M action,C,L decision\n"}),"\n",(0,s.jsx)(n.h3,{id:"\u7279\u6027",children:"\u7279\u6027"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u5e76\u884c\u6267\u884c"})," \u72ec\u7acb\u4efb\u52a1"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u987a\u5e8f\u9636\u6bb5"})," \u4f9d\u8d56\u4efb\u52a1"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"\u8fdb\u5ea6\u8ffd\u8e2a"})," \u901a\u8fc7 TodoWrite"]}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.strong,{children:"\u53ef\u9009\u4ee3\u7801\u5ba1\u6838"})}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"\u76f8\u5173\u5de5\u4f5c\u6d41",children:"\u76f8\u5173\u5de5\u4f5c\u6d41"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"/docs/zh/workflows/level-1-ultra-lightweight",children:"Level 1: \u8d85\u8f7b\u91cf\u7ea7"})," - \u66f4\u7b80\u5355\u7684\u5de5\u4f5c\u6d41"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"/docs/zh/workflows/level-3-standard",children:"Level 3: \u6807\u51c6\u7ea7"})," - \u5b8c\u6574\u4f1a\u8bdd\u7ba1\u7406"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"/docs/zh/workflows/level-4-brainstorm",children:"Level 4: \u5934\u8111\u98ce\u66b4"})," - \u591a\u89d2\u8272\u63a2\u7d22"]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"/docs/zh/workflows/faq",children:"\u5e38\u89c1\u95ee\u9898"})," - \u5e38\u89c1\u95ee\u9898\u89e3\u7b54"]}),"\n"]})]})}function o(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(j,{...e})}):j(e)}}}]); \ No newline at end of file diff --git a/ccw/docs-site/docs/workflows/level-2-rapid.mdx b/ccw/docs-site/docs/workflows/level-2-rapid.mdx index 02c89461..df28e7c2 100644 --- a/ccw/docs-site/docs/workflows/level-2-rapid.mdx +++ b/ccw/docs-site/docs/workflows/level-2-rapid.mdx @@ -128,7 +128,7 @@ Level 2 workflows provide lightweight planning or single analysis with fast iter - Medium/High: Use cli-lite-planning-agent **Phase 3: Planning** -- Load plan schema: `~/.claude/workflows/cli-templates/schemas/plan-json-schema.json` +- Load plan schema: `~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json` - Generate plan.json following schema **Phase 4: Confirmation & Selection** diff --git a/ccw/docs-site/i18n/zh/docusaurus-plugin-content-docs/current/workflows/level-2-rapid.mdx b/ccw/docs-site/i18n/zh/docusaurus-plugin-content-docs/current/workflows/level-2-rapid.mdx index c047a0c0..870aa06c 100644 --- a/ccw/docs-site/i18n/zh/docusaurus-plugin-content-docs/current/workflows/level-2-rapid.mdx +++ b/ccw/docs-site/i18n/zh/docusaurus-plugin-content-docs/current/workflows/level-2-rapid.mdx @@ -128,7 +128,7 @@ Level 2 工作流提供轻量级规划或单次分析,支持快速迭代。它 - 中/高: 使用 cli-lite-planning-agent **阶段 3: 规划** -- 加载计划 schema: `~/.claude/workflows/cli-templates/schemas/plan-json-schema.json` +- 加载计划 schema: `~/.ccw/workflows/cli-templates/schemas/plan-json-schema.json` - 按照生成计划 schema 生成 plan.json **阶段 4: 确认与选择** diff --git a/ccw/frontend/src/components/layout/AppShell.tsx b/ccw/frontend/src/components/layout/AppShell.tsx index 607eae3d..b9ebaecb 100644 --- a/ccw/frontend/src/components/layout/AppShell.tsx +++ b/ccw/frontend/src/components/layout/AppShell.tsx @@ -162,7 +162,6 @@ export function AppShell({
{/* Header - fixed at top */}
{ + // Per-location total counts (unfiltered, for tab badges) + const projectCount = allCommands.filter(c => c.location === 'project').length; + const userCount = allCommands.filter(c => c.location === 'user').length; + + // Apply filters (except showDisabled) for counts and grouping + const baseFiltered = (() => { let commands = allCommands; if (filter?.search) { @@ -166,14 +172,15 @@ export function useCommands(options: UseCommandsOptions = {}): UseCommandsReturn commands = commands.filter((c) => c.location === filter.location); } - if (filter?.showDisabled === false) { - commands = commands.filter((c) => c.enabled !== false); - } - return commands; })(); - // Group by category + // Apply showDisabled filter for the returned commands list + const filteredCommands = filter?.showDisabled === false + ? baseFiltered.filter((c) => c.enabled !== false) + : baseFiltered; + + // Group by category (from allCommands for global view) const commandsByCategory: Record = {}; const categories = new Set(); @@ -186,13 +193,13 @@ export function useCommands(options: UseCommandsOptions = {}): UseCommandsReturn commandsByCategory[category].push(command); } - // Group by group + // Group by group (from baseFiltered - respects location filter, includes disabled for accordion) const groupedCommands: Record = {}; const groups = new Set(); - const enabledCount = allCommands.filter(c => c.enabled !== false).length; - const disabledCount = allCommands.length - enabledCount; + const enabledCount = baseFiltered.filter(c => c.enabled !== false).length; + const disabledCount = baseFiltered.length - enabledCount; - for (const command of allCommands) { + for (const command of baseFiltered) { const group = command.group || 'other'; groups.add(group); if (!groupedCommands[group]) { @@ -217,6 +224,8 @@ export function useCommands(options: UseCommandsOptions = {}): UseCommandsReturn groups: Array.from(groups).sort(), enabledCount, disabledCount, + projectCount, + userCount, totalCount: allCommands.length, isLoading: query.isLoading, isFetching: query.isFetching, diff --git a/ccw/frontend/src/pages/CommandsManagerPage.tsx b/ccw/frontend/src/pages/CommandsManagerPage.tsx index bc815a7d..5c3123b5 100644 --- a/ccw/frontend/src/pages/CommandsManagerPage.tsx +++ b/ccw/frontend/src/pages/CommandsManagerPage.tsx @@ -3,7 +3,7 @@ // ======================================== // Manage custom slash commands with search/filter -import { useState, useMemo } from 'react'; +import { useState } from 'react'; import { useIntl } from 'react-intl'; import { Terminal, @@ -46,6 +46,8 @@ export function CommandsManagerPage() { groups, enabledCount, disabledCount, + projectCount, + userCount, isLoading, isFetching, error, @@ -93,16 +95,6 @@ export function CommandsManagerPage() { toggleGroup(groupName, enable, locationFilter); }; - // Calculate command counts per location - const projectCount = useMemo( - () => commands.filter((c) => c.location === 'project').length, - [commands] - ); - const userCount = useMemo( - () => commands.filter((c) => c.location === 'user').length, - [commands] - ); - return (
{/* Page Header */} @@ -159,25 +151,6 @@ export function CommandsManagerPage() { ]} /> - {/* Show Disabled Controls */} -
- -
{/* Summary Stats */} @@ -223,6 +196,22 @@ export function CommandsManagerPage() { />
+ diff --git a/ccw/frontend/src/pages/QueuePage.tsx b/ccw/frontend/src/pages/QueuePage.tsx index b4318a3d..377d1481 100644 --- a/ccw/frontend/src/pages/QueuePage.tsx +++ b/ccw/frontend/src/pages/QueuePage.tsx @@ -167,7 +167,7 @@ export function QueuePage() { {formatMessage({ id: 'issues.queue.pageTitle' })}

- {formatMessage({ id: 'issues.queue.pageDescription' })} + {formatMessage({ id: 'issues.queue.description' })}

diff --git a/ccw/src/core/routes/claude-routes.ts b/ccw/src/core/routes/claude-routes.ts index ad105894..8fdfcfc8 100644 --- a/ccw/src/core/routes/claude-routes.ts +++ b/ccw/src/core/routes/claude-routes.ts @@ -982,10 +982,10 @@ export async function handleClaudeRoutes(ctx: RouteContext): Promise { const userGuidelinesPath = join(homedir(), '.claude', 'workflows', 'chinese-response.md'); if (!existsSync(userGuidelinesPath)) { - return { error: 'Chinese response guidelines file not found at ~/.claude/workflows/chinese-response.md', status: 404 }; + return { error: 'Chinese response guidelines file not found at ~/.ccw/workflows/chinese-response.md', status: 404 }; } - const guidelinesRef = '~/.claude/workflows/chinese-response.md'; + const guidelinesRef = '~/.ccw/workflows/chinese-response.md'; // Configure based on target const isCodex = target === 'codex'; @@ -1177,7 +1177,7 @@ export async function handleClaudeRoutes(ctx: RouteContext): Promise { if (existsSync(cliToolsUsagePath)) { cliToolsUsageContent = readFileSync(cliToolsUsagePath, 'utf8'); } else { - return { error: 'CLI tools usage guidelines file not found at ~/.claude/workflows/cli-tools-usage.md', status: 404 }; + return { error: 'CLI tools usage guidelines file not found at ~/.ccw/workflows/cli-tools-usage.md', status: 404 }; } const cliToolsJsonPath = join(homedir(), '.claude', 'cli-tools.json'); @@ -1213,7 +1213,7 @@ export async function handleClaudeRoutes(ctx: RouteContext): Promise { if (existsSync(cliToolsUsagePath)) { cliToolsUsageContent = readFileSync(cliToolsUsagePath, 'utf8'); } else { - return { error: 'CLI tools usage guidelines file not found at ~/.claude/workflows/cli-tools-usage.md', status: 404 }; + return { error: 'CLI tools usage guidelines file not found at ~/.ccw/workflows/cli-tools-usage.md', status: 404 }; } // Read and format cli-tools.json @@ -1304,10 +1304,10 @@ export async function handleClaudeRoutes(ctx: RouteContext): Promise { const userGuidelinesPath = join(homedir(), '.claude', 'workflows', 'windows-platform.md'); if (!existsSync(userGuidelinesPath)) { - return { error: 'Windows platform guidelines file not found at ~/.claude/workflows/windows-platform.md', status: 404 }; + return { error: 'Windows platform guidelines file not found at ~/.ccw/workflows/windows-platform.md', status: 404 }; } - const guidelinesRef = '~/.claude/workflows/windows-platform.md'; + const guidelinesRef = '~/.ccw/workflows/windows-platform.md'; const windowsRefLine = `- **Windows Platform**: @${guidelinesRef}`; const windowsRefPattern = /^- \*\*Windows Platform\*\*:.*windows-platform\.md.*$/gm; diff --git a/ccw/src/tools/claude-cli-tools.ts b/ccw/src/tools/claude-cli-tools.ts index f38a33ee..e5116b4e 100644 --- a/ccw/src/tools/claude-cli-tools.ts +++ b/ccw/src/tools/claude-cli-tools.ts @@ -955,10 +955,10 @@ export function updateCodeIndexMcp( // Determine target file based on provider const targetFile = provider === 'ace' - ? '@~/.claude/workflows/context-tools-ace.md' + ? '@~/.ccw/workflows/context-tools-ace.md' : provider === 'none' - ? '@~/.claude/workflows/context-tools-none.md' - : '@~/.claude/workflows/context-tools.md'; + ? '@~/.ccw/workflows/context-tools-none.md' + : '@~/.ccw/workflows/context-tools.md'; if (!fs.existsSync(globalClaudeMdPath)) { // If global CLAUDE.md doesn't exist, check project-level diff --git a/ccw/src/tools/template-discovery.ts b/ccw/src/tools/template-discovery.ts index 4e33a92f..5772e988 100644 --- a/ccw/src/tools/template-discovery.ts +++ b/ccw/src/tools/template-discovery.ts @@ -2,7 +2,7 @@ * Template Discovery Module * * Provides auto-discovery and loading of CLI templates from - * ~/.claude/workflows/cli-templates/ + * ~/.ccw/workflows/cli-templates/ * * Features: * - Scan prompts/ directory (flat structure with category-function.txt naming)