docs: add VitePress documentation site

- Add docs directory with VitePress configuration
- Add GitHub Actions workflow for docs build and deploy
- Support bilingual (English/Chinese) documentation
- Include search, custom theme, and responsive design
This commit is contained in:
catlog22
2026-02-28 16:14:09 +08:00
parent ab65caec45
commit c3ddf7e322
136 changed files with 34486 additions and 0 deletions

152
docs/commands/claude/cli.md Normal file
View File

@@ -0,0 +1,152 @@
# CLI Tool Commands
## One-Liner
**CLI tool commands are the bridge to external model invocation** — integrating Gemini, Qwen, Codex and other multi-model capabilities into workflows.
## Core Concepts
| Concept | Description | Configuration |
|----------|-------------|---------------|
| **CLI Tool** | External AI model invocation interface | `cli-tools.json` |
| **Endpoint** | Available model services | gemini, qwen, codex, claude |
| **Mode** | analysis / write / review | Permission level |
## Command List
| Command | Function | Syntax |
|---------|----------|--------|
| [`cli-init`](#cli-init) | Generate configuration directory and settings files | `/cli:cli-init [--tool gemini\|qwen\|all] [--output path] [--preview]` |
| [`codex-review`](#codex-review) | Interactive code review using Codex CLI | `/cli:codex-review [--uncommitted\|--base <branch>\|--commit <sha>] [prompt]` |
## Command Details
### cli-init
**Function**: Generate `.gemini/` and `.qwen/` configuration directories based on workspace tech detection, including settings.json and ignore files.
**Syntax**:
```
/cli:cli-init [--tool gemini|qwen|all] [--output path] [--preview]
```
**Options**:
- `--tool=tool`: gemini, qwen or all
- `--output=path`: Output directory
- `--preview`: Preview mode (don't actually create)
**Generated File Structure**:
```
.gemini/
├── settings.json # Gemini configuration
└── ignore # Ignore patterns
.qwen/
├── settings.json # Qwen configuration
└── ignore # Ignore patterns
```
**Tech Detection**:
| Detection Item | Generated Config |
|----------------|------------------|
| TypeScript | tsconfig-related config |
| React | React-specific config |
| Vue | Vue-specific config |
| Python | Python-specific config |
**Examples**:
```bash
# Initialize all tools
/cli:cli-init --tool all
# Initialize specific tool
/cli:cli-init --tool gemini
# Specify output directory
/cli:cli-init --output ./configs
# Preview mode
/cli:cli-init --preview
```
### codex-review
**Function**: Interactive code review using Codex CLI via ccw endpoint, supporting configurable review targets, models, and custom instructions.
**Syntax**:
```
/cli:codex-review [--uncommitted|--base <branch>|--commit <sha>] [--model <model>] [--title <title>] [prompt]
```
**Options**:
- `--uncommitted`: Review uncommitted changes
- `--base <branch>`: Compare with branch
- `--commit <sha>`: Review specific commit
- `--model <model>`: Specify model
- `--title <title>`: Review title
**Note**: Target flags and prompt are mutually exclusive
**Examples**:
```bash
# Review uncommitted changes
/cli:codex-review --uncommitted
# Compare with main branch
/cli:codex-review --base main
# Review specific commit
/cli:codex-review --commit abc123
# With custom instructions
/cli:codex-review --uncommitted "focus on security issues"
# Specify model and title
/cli:codex-review --model gpt-5.2 --title "Authentication module review"
```
## CLI Tool Configuration
### cli-tools.json Structure
```json
{
"version": "3.3.0",
"tools": {
"gemini": {
"enabled": true,
"primaryModel": "gemini-2.5-flash",
"secondaryModel": "gemini-2.5-flash",
"tags": ["analysis", "Debug"],
"type": "builtin"
},
"qwen": {
"enabled": true,
"primaryModel": "coder-model",
"tags": [],
"type": "builtin"
},
"codex": {
"enabled": true,
"primaryModel": "gpt-5.2",
"tags": [],
"type": "builtin"
}
}
}
```
### Mode Descriptions
| Mode | Permission | Use Cases |
|------|------------|-----------|
| `analysis` | Read-only | Code review, architecture analysis, pattern discovery |
| `write` | Create/modify/delete | Feature implementation, bug fixes, documentation creation |
| `review` | Git-aware code review | Review uncommitted changes, branch diffs, specific commits |
## Related Documentation
- [CLI Invocation System](../../features/cli.md)
- [Core Orchestration](./core-orchestration.md)
- [Workflow Commands](./workflow.md)

View File

@@ -0,0 +1,166 @@
# Core Orchestration Commands
## One-Liner
**Core orchestration commands are the workflow brain of Claude_dms3** — analyzing task intent, selecting appropriate workflows, and automatically executing command chains.
## Command List
| Command | Function | Syntax |
|---------|----------|--------|
| [`/ccw`](#ccw) | Main workflow orchestrator - intent analysis -> workflow selection -> command chain execution | `/ccw "task description"` |
| [`/ccw-coordinator`](#ccw-coordinator) | Command orchestration tool - chained command execution and state persistence | `/ccw-coordinator "task description"` |
## Command Details
### /ccw
**Function**: Main workflow orchestrator - intent analysis -> workflow selection -> command chain execution
**Syntax**:
```
/ccw "task description"
```
**Options**:
- `--yes` / `-y`: Auto mode, skip confirmation steps
**Workflow**:
```mermaid
graph TD
A[User Input] --> B[Analyze Intent]
B --> C{Clarity Score}
C -->|>=2| D[Select Workflow Directly]
C -->|<2| E[Clarify Requirements]
E --> D
D --> F[Build Command Chain]
F --> G{User Confirm?}
G -->|Yes| H[Execute Command Chain]
G -->|Cancel| I[End]
H --> J{More Steps?}
J -->|Yes| F
J -->|No| K[Complete]
```
**Task Type Detection**:
| Type | Trigger Keywords | Workflow |
|------|------------------|----------|
| **Bug Fix** | urgent, production, critical + fix, bug | lite-fix |
| **Brainstorming** | brainstorm, ideation | brainstorm-with-file |
| **Debug Document** | debug document, hypothesis | debug-with-file |
| **Collaborative Analysis** | analyze document | analyze-with-file |
| **Collaborative Planning** | collaborative plan | collaborative-plan-with-file |
| **Requirements Roadmap** | roadmap | req-plan-with-file |
| **Integration Test** | integration test | integration-test-cycle |
| **Refactoring** | refactor | refactor-cycle |
| **Team Workflow** | team + keywords | corresponding team workflow |
| **TDD** | tdd, test-first | tdd-plan -> execute |
| **Test Fix** | test fix, failing test | test-fix-gen -> test-cycle-execute |
**Examples**:
```bash
# Basic usage - auto-select workflow
/ccw "implement user authentication"
# Bug fix
/ccw "fix login failure bug"
# TDD development
/ccw "implement payment using TDD"
# Team collaboration
/ccw "team-planex implement user notification system"
```
### /ccw-coordinator
**Function**: Command orchestration tool - analyze tasks, recommend command chains, sequential execution, state persistence
**Syntax**:
```
/ccw-coordinator "task description"
```
**Minimal Execution Units**:
| Unit Name | Command Chain | Output |
|-----------|---------------|--------|
| **Quick Implementation** | lite-plan -> lite-execute | Working code |
| **Multi-CLI Planning** | multi-cli-plan -> lite-execute | Working code |
| **Bug Fix** | lite-plan (--bugfix) -> lite-execute | Fixed code |
| **Full Plan+Execute** | plan -> execute | Working code |
| **Verified Plan+Execute** | plan -> plan-verify -> execute | Working code |
| **TDD Plan+Execute** | tdd-plan -> execute | Working code |
| **Test Gen+Execute** | test-gen -> execute | Generated tests |
| **Review Cycle** | review-session-cycle -> review-cycle-fix | Fixed code |
| **Issue Workflow** | discover -> plan -> queue -> execute | Completed issue |
**Workflow**:
```mermaid
graph TD
A[Task Analysis] --> B[Discover Commands]
B --> C[Recommend Command Chain]
C --> D{User Confirm?}
D -->|Yes| E[Sequential Execute]
D -->|Modify| F[Adjust Command Chain]
F --> D
E --> G[Persist State]
G --> H{More Steps?}
H -->|Yes| B
H -->|No| I[Complete]
```
**Examples**:
```bash
# Auto-orchestrate bug fix
/ccw-coordinator "production login failure"
# Auto-orchestrate feature implementation
/ccw-coordinator "add user avatar upload"
```
## Auto Mode
Both commands support the `--yes` flag for auto mode:
```bash
# Auto mode - skip all confirmations
/ccw "implement user authentication" --yes
/ccw-coordinator "fix login bug" --yes
```
**Auto mode behavior**:
- Skip requirement clarification
- Skip user confirmation
- Execute command chain directly
## Related Skills
| Skill | Function |
|-------|----------|
| `workflow-lite-plan` | Lightweight planning workflow |
| `workflow-plan` | Full planning workflow |
| `workflow-execute` | Execution workflow |
| `workflow-tdd` | TDD workflow |
| `review-cycle` | Code review cycle |
## Comparison
| Feature | /ccw | /ccw-coordinator |
|---------|------|------------------|
| **Execution Location** | Main process | External CLI + background tasks |
| **State Persistence** | No | Yes |
| **Hook Callbacks** | Not supported | Supported |
| **Complex Workflows** | Simple chains | Supports parallel, dependencies |
| **Use Cases** | Daily development | Complex projects, team collaboration |
## Related Documentation
- [Workflow Commands](./workflow.md)
- [Session Management](./session.md)
- [CLI Invocation System](../features/cli.md)

View File

@@ -0,0 +1,118 @@
# Claude Commands
## One-Liner
**Claude Commands is the core command system of Claude_dms3** — invoking various workflows, tools, and collaboration features through slash commands.
## Core Concepts
| Category | Command Count | Description |
|----------|---------------|-------------|
| **Core Orchestration** | 2 | Main workflow orchestrators (ccw, ccw-coordinator) |
| **Workflow** | 20+ | Planning, execution, review, TDD, testing workflows |
| **Session Management** | 6 | Session creation, listing, resuming, completion |
| **Issue Workflow** | 7 | Issue discovery, planning, queue, execution |
| **Memory** | 8 | Memory capture, update, document generation |
| **CLI Tools** | 2 | CLI initialization, Codex review |
| **UI Design** | 10 | UI design prototype generation, style extraction |
## Command Categories
### 1. Core Orchestration Commands
| Command | Function | Difficulty |
|---------|----------|------------|
| [`/ccw`](./core-orchestration.md#ccw) | Main workflow orchestrator - intent analysis -> workflow selection -> command chain execution | Intermediate |
| [`/ccw-coordinator`](./core-orchestration.md#ccw-coordinator) | Command orchestration tool - chained command execution and state persistence | Intermediate |
### 2. Workflow Commands
| Command | Function | Difficulty |
|---------|----------|------------|
| [`/workflow:lite-lite-lite`](./workflow.md#lite-lite-lite) | Ultra-lightweight multi-tool analysis and direct execution | Intermediate |
| [`/workflow:lite-plan`](./workflow.md#lite-plan) | Lightweight interactive planning workflow | Intermediate |
| [`/workflow:lite-execute`](./workflow.md#lite-execute) | Execute tasks based on in-memory plan | Intermediate |
| [`/workflow:lite-fix`](./workflow.md#lite-fix) | Lightweight bug diagnosis and fix | Intermediate |
| [`/workflow:plan`](./workflow.md#plan) | 5-phase planning workflow | Intermediate |
| [`/workflow:execute`](./workflow.md#execute) | Coordinate agent execution of workflow tasks | Intermediate |
| [`/workflow:replan`](./workflow.md#replan) | Interactive workflow replanning | Intermediate |
| [`/workflow:multi-cli-plan`](./workflow.md#multi-cli-plan) | Multi-CLI collaborative planning | Intermediate |
| [`/workflow:review`](./workflow.md#review) | Post-implementation review | Intermediate |
| [`/workflow:clean`](./workflow.md#clean) | Smart code cleanup | Intermediate |
| [`/workflow:init`](./workflow.md#init) | Initialize project state | Intermediate |
| [`/workflow:brainstorm-with-file`](./workflow.md#brainstorm-with-file) | Interactive brainstorming | Intermediate |
| [`/workflow:analyze-with-file`](./workflow.md#analyze-with-file) | Interactive collaborative analysis | Beginner |
| [`/workflow:debug-with-file`](./workflow.md#debug-with-file) | Interactive hypothesis-driven debugging | Intermediate |
| [`/workflow:unified-execute-with-file`](./workflow.md#unified-execute-with-file) | Universal execution engine | Intermediate |
### 3. Session Management Commands
| Command | Function | Difficulty |
|---------|----------|------------|
| [`/workflow:session:start`](./session.md#start) | Discover existing sessions or start new workflow session | Intermediate |
| [`/workflow:session:list`](./session.md#list) | List all workflow sessions | Beginner |
| [`/workflow:session:resume`](./session.md#resume) | Resume most recently paused workflow session | Intermediate |
| [`/workflow:session:complete`](./session.md#complete) | Mark active workflow session as completed | Intermediate |
| [`/workflow:session:solidify`](./session.md#solidify) | Crystallize session learnings into project guidelines | Intermediate |
### 4. Issue Workflow Commands
| Command | Function | Difficulty |
|---------|----------|------------|
| [`/issue:new`](./issue.md#new) | Create structured issue from GitHub URL or text description | Intermediate |
| [`/issue:discover`](./issue.md#discover) | Discover potential issues from multiple perspectives | Intermediate |
| [`/issue:discover-by-prompt`](./issue.md#discover-by-prompt) | Discover issues via user prompt | Intermediate |
| [`/issue:plan`](./issue.md#plan) | Batch plan issue solutions | Intermediate |
| [`/issue:queue`](./issue.md#queue) | Form execution queue | Intermediate |
| [`/issue:execute`](./issue.md#execute) | Execute queue | Intermediate |
| [`/issue:convert-to-plan`](./issue.md#convert-to-plan) | Convert planning artifact to issue solution | Intermediate |
### 5. Memory Commands
| Command | Function | Difficulty |
|---------|----------|------------|
| [`/memory:compact`](./memory.md#compact) | Compress current session memory to structured text | Intermediate |
| [`/memory:tips`](./memory.md#tips) | Quick note-taking | Beginner |
| [`/memory:load`](./memory.md#load) | Load task context via CLI project analysis | Intermediate |
| [`/memory:update-full`](./memory.md#update-full) | Update all CLAUDE.md files | Intermediate |
| [`/memory:update-related`](./memory.md#update-related) | Update CLAUDE.md for git-changed modules | Intermediate |
| [`/memory:docs-full-cli`](./memory.md#docs-full-cli) | Generate full project documentation using CLI | Intermediate |
| [`/memory:docs-related-cli`](./memory.md#docs-related-cli) | Generate documentation for git-changed modules | Intermediate |
| [`/memory:style-skill-memory`](./memory.md#style-skill-memory) | Generate SKILL memory package from style reference | Intermediate |
### 6. CLI Tool Commands
| Command | Function | Difficulty |
|---------|----------|------------|
| [`/cli:cli-init`](./cli.md#cli-init) | Generate configuration directory and settings files | Intermediate |
| [`/cli:codex-review`](./cli.md#codex-review) | Interactive code review using Codex CLI | Intermediate |
### 7. UI Design Commands
| Command | Function | Difficulty |
|---------|----------|------------|
| [`/workflow:ui-design:explore-auto`](./ui-design.md#explore-auto) | Interactive exploratory UI design workflow | Intermediate |
| [`/workflow:ui-design:imitate-auto`](./ui-design.md#imitate-auto) | Direct code/image input UI design | Intermediate |
| [`/workflow:ui-design:style-extract`](./ui-design.md#style-extract) | Extract design styles from reference images or prompts | Intermediate |
| [`/workflow:ui-design:layout-extract`](./ui-design.md#layout-extract) | Extract layout information from reference images | Intermediate |
| [`/workflow:ui-design:animation-extract`](./ui-design.md#animation-extract) | Extract animation and transition patterns | Intermediate |
| [`/workflow:ui-design:codify-style`](./ui-design.md#codify-style) | Extract styles from code and generate shareable reference package | Intermediate |
| [`/workflow:ui-design:generate`](./ui-design.md#generate) | Combine layout templates with design tokens to generate prototypes | Intermediate |
## Auto Mode
Most commands support the `--yes` or `-y` flag to enable auto mode and skip confirmation steps.
```bash
# Standard mode - requires confirmation
/ccw "implement user authentication"
# Auto mode - execute directly without confirmation
/ccw "implement user authentication" --yes
```
## Related Documentation
- [Skills Reference](../skills/)
- [CLI Invocation System](../features/cli.md)
- [Workflow Guide](../guide/ch04-workflow-basics.md)

View File

@@ -0,0 +1,294 @@
# Issue Workflow Commands
## One-Liner
**Issue workflow commands are the closed-loop system for issue management** — from discovery, planning to execution, fully tracking the issue resolution process.
## Core Concepts
| Concept | Description | Location |
|---------|-------------|----------|
| **Issue** | Structured issue definition | `.workflow/issues/ISS-*.json` |
| **Solution** | Execution plan | `.workflow/solutions/SOL-*.json` |
| **Queue** | Execution queue | `.workflow/queues/QUE-*.json` |
| **Execution State** | Progress tracking | State within queue |
## Command List
| Command | Function | Syntax |
|---------|----------|--------|
| [`new`](#new) | Create structured issue from GitHub URL or text description | `/issue:new [-y] <github-url \| description> [--priority 1-5]` |
| [`discover`](#discover) | Discover potential issues from multiple perspectives | `/issue:discover [-y] <path pattern> [--perspectives=dimensions] [--external]` |
| [`discover-by-prompt`](#discover-by-prompt) | Discover issues via user prompt | `/issue:discover-by-prompt [-y] <prompt> [--scope=src/**]` |
| [`plan`](#plan) | Batch plan issue solutions | `/issue:plan [-y] --all-pending <issue-id>[,...] [--batch-size 3]` |
| [`queue`](#queue) | Form execution queue | `/issue:queue [-y] [--queues N] [--issue id]` |
| [`execute`](#execute) | Execute queue | `/issue:execute [-y] --queue <queue-id> [--worktree [path]]` |
| [`convert-to-plan`](#convert-to-plan) | Convert planning artifact to issue solution | `/issue:convert-to-plan [-y] [--issue id] [--supplement] <source>` |
## Command Details
### new
**Function**: Create structured issue from GitHub URL or text description, supporting requirement clarity detection.
**Syntax**:
```
/issue:new [-y|--yes] <github-url | text description> [--priority 1-5]
```
**Options**:
- `--priority 1-5`: Priority (1=critical, 5=low)
**Clarity Detection**:
| Input Type | Clarity | Behavior |
|------------|---------|----------|
| GitHub URL | 3 | Direct creation |
| Structured text | 2 | Direct creation |
| Long text | 1 | Partial clarification |
| Short text | 0 | Full clarification |
**Issue Structure**:
```typescript
interface Issue {
id: string; // GH-123 or ISS-YYYYMMDD-HHMMSS
title: string;
status: 'registered' | 'planned' | 'queued' | 'in_progress' | 'completed' | 'failed';
priority: number; // 1-5
context: string; // Issue description (single source of truth)
source: 'github' | 'text' | 'discovery';
source_url?: string;
// Binding
bound_solution_id: string | null;
// Feedback history
feedback?: Array<{
type: 'failure' | 'clarification' | 'rejection';
stage: string;
content: string;
created_at: string;
}>;
}
```
**Examples**:
```bash
# Create from GitHub
/issue:new https://github.com/owner/repo/issues/123
# Create from text (structured)
/issue:new "login failed: expected success, actual 500 error"
# Create from text (vague - will ask)
/issue:new "auth has problems"
# Specify priority
/issue:new --priority 2 "payment timeout issue"
```
### discover
**Function**: Discover potential issues from multiple perspectives (Bug, UX, Test, Quality, Security, Performance, Maintainability, Best Practices).
**Syntax**:
```
/issue:discover [-y|--yes] <path pattern> [--perspectives=bug,ux,...] [--external]
```
**Options**:
- `--perspectives=dimensions`: Analysis dimensions
- `bug`: Potential bugs
- `ux`: UX issues
- `test`: Test coverage
- `quality`: Code quality
- `security`: Security issues
- `performance`: Performance issues
- `maintainability`: Maintainability
- `best-practices`: Best practices
- `--external`: Use Exa external research (security, best practices)
**Examples**:
```bash
# Comprehensive scan
/issue:discover src/
# Specific dimensions
/issue:discover src/auth/ --perspectives=security,bug
# With external research
/issue:discover src/payment/ --perspectives=security --external
```
### discover-by-prompt
**Function**: Discover issues via user prompt, using Gemini-planned iterative multi-agent exploration, supporting cross-module comparison.
**Syntax**:
```
/issue:discover-by-prompt [-y|--yes] <prompt> [--scope=src/**] [--depth=standard|deep] [--max-iterations=5]
```
**Options**:
- `--scope=path`: Scan scope
- `--depth=depth`: standard or deep
- `--max-iterations=N`: Maximum iteration count
**Examples**:
```bash
# Standard scan
/issue:discover-by-prompt "find auth module issues"
# Deep scan
/issue:discover-by-prompt "analyze API performance bottlenecks" --depth=deep
# Specify scope
/issue:discover-by-prompt "check database query optimization" --scope=src/db/
```
### plan
**Function**: Batch plan issue solutions, using issue-plan-agent (explore + plan closed loop).
**Syntax**:
```
/issue:plan [-y|--yes] --all-pending <issue-id>[,<issue-id>,...] [--batch-size 3]
```
**Options**:
- `--all-pending`: Plan all pending issues
- `--batch-size=N`: Issues per batch
**Examples**:
```bash
# Plan specific issues
/issue:plan ISS-20240115-001,ISS-20240115-002
# Plan all pending issues
/issue:plan --all-pending
# Specify batch size
/issue:plan --all-pending --batch-size 5
```
### queue
**Function**: Form execution queue from bound solutions, using issue-queue-agent (solution level).
**Syntax**:
```
/issue:queue [-y|--yes] [--queues <n>] [--issue <id>]
```
**Options**:
- `--queues N`: Number of queues to create
- `--issue id`: Specific issue
**Examples**:
```bash
# Form queue
/issue:queue
# Create multiple queues
/issue:queue --queues 3
# Specific issue
/issue:queue --issue ISS-20240115-001
```
### execute
**Function**: Execute queue, using DAG parallel orchestration (one commit per solution).
**Syntax**:
```
/issue:execute [-y|--yes] --queue <queue-id> [--worktree [<existing-path>]]
```
**Options**:
- `--queue id`: Queue ID
- `--worktree [path]`: Optional worktree path
**Examples**:
```bash
# Execute queue
/issue:execute --queue QUE-20240115-001
# Use worktree
/issue:execute --queue QUE-20240115-001 --worktree ../feature-branch
```
### convert-to-plan
**Function**: Convert planning artifact (lite-plan, workflow session, markdown) to issue solution.
**Syntax**:
```
/issue:convert-to-plan [-y|--yes] [--issue <id>] [--supplement] <source>
```
**Options**:
- `--issue id`: Bind to existing issue
- `--supplement`: Supplement mode (add to existing solution)
**Source Types**:
- lite-plan artifact
- workflow session
- Markdown file
**Examples**:
```bash
# Convert from lite-plan
/issue:convert-to-plan .workflow/sessions/WFS-xxx/artifacts/lite-plan.md
# Bind to issue
/issue:convert-to-plan --issue ISS-20240115-001 plan.md
# Supplement mode
/issue:convert-to-plan --supplement additional-plan.md
```
### from-brainstorm
**Function**: Convert brainstorm session ideas to issues and generate executable solutions.
**Syntax**:
```
/issue:from-brainstorm SESSION="session-id" [--idea=<index>] [--auto] [-y|--yes]
```
**Options**:
- `--idea=index`: Specific idea index
- `--auto`: Auto mode
**Examples**:
```bash
# Convert all ideas
/issue:from-brainstorm SESSION="WFS-brainstorm-2024-01-15"
# Convert specific idea
/issue:from-brainstorm SESSION="WFS-brainstorm-2024-01-15" --idea=3
# Auto mode
/issue:from-brainstorm --auto SESSION="WFS-brainstorm-2024-01-15"
```
## Issue Workflow
```mermaid
graph TD
A[Discover Issue] --> B[Create Issue]
B --> C[Plan Solution]
C --> D[Form Execution Queue]
D --> E[Execute Queue]
E --> F{Success?}
F -->|Yes| G[Complete]
F -->|No| H[Feedback Learning]
H --> C
```
## Related Documentation
- [Workflow Commands](./workflow.md)
- [Core Orchestration](./core-orchestration.md)
- [Team System](../../features/)

View File

@@ -0,0 +1,262 @@
# Memory Commands
## One-Liner
**Memory commands are the cross-session knowledge persistence system** — capturing context, updating memory, generating documentation, making AI remember the project.
## Core Concepts
| Concept | Description | Location |
|---------|-------------|----------|
| **Memory Package** | Structured project context | MCP core_memory |
| **CLAUDE.md** | Module-level project guide | Each module/directory |
| **Tips** | Quick notes | `MEMORY.md` |
| **Project Documentation** | Generated documentation | `docs/` directory |
## Command List
| Command | Function | Syntax |
|---------|----------|--------|
| [`compact`](#compact) | Compress current session memory to structured text | `/memory:compact [optional: session description]` |
| [`tips`](#tips) | Quick note-taking | `/memory:tips <note content> [--tag tags] [--context context]` |
| [`load`](#load) | Load task context via CLI project analysis | `/memory:load [--tool gemini\|qwen] "task context description"` |
| [`update-full`](#update-full) | Update all CLAUDE.md files | `/memory:update-full [--tool gemini\|qwen\|codex] [--path directory]` |
| [`update-related`](#update-related) | Update CLAUDE.md for git-changed modules | `/memory:update-related [--tool gemini\|qwen\|codex]` |
| [`docs-full-cli`](#docs-full-cli) | Generate full project documentation using CLI | `/memory:docs-full-cli [path] [--tool tool]` |
| [`docs-related-cli`](#docs-related-cli) | Generate documentation for git-changed modules | `/memory:docs-related-cli [--tool tool]` |
| [`style-skill-memory`](#style-skill-memory) | Generate SKILL memory package from style reference | `/memory:style-skill-memory [package-name] [--regenerate]` |
## Command Details
### compact
**Function**: Compress current session memory to structured text, extracting objectives, plans, files, decisions, constraints, and state, saving via MCP core_memory tool.
**Syntax**:
```
/memory:compact [optional: session description]
```
**Extracted Content**:
- Objectives
- Plans
- Files
- Decisions
- Constraints
- State
**Examples**:
```bash
# Basic compression
/memory:compact
# With description
/memory:compact "user authentication implementation session"
```
### tips
**Function**: Quick note-taking command, capturing thoughts, snippets, reminders, and insights for future reference.
**Syntax**:
```
/memory:tips <note content> [--tag <tag1,tag2>] [--context <context>]
```
**Options**:
- `--tag=tags`: Tags (comma-separated)
- `--context=context`: Context information
**Examples**:
```bash
# Basic note
/memory:tips "remember to use rate limiting for API calls"
# With tags
/memory:tips "auth middleware needs to handle token expiry" --tag auth,api
# With context
/memory:tips "use Redis to cache user sessions" --context "login optimization"
```
### load
**Function**: Delegate to universal-executor agent, analyzing project via Gemini/Qwen CLI and returning JSON core content package for task context.
**Syntax**:
```
/memory:load [--tool gemini|qwen] "task context description"
```
**Options**:
- `--tool=tool`: CLI tool to use
**Output**: JSON format project context package
**Examples**:
```bash
# Use default tool
/memory:load "user authentication module"
# Specify tool
/memory:load --tool gemini "payment system architecture"
```
### update-full
**Function**: Update all CLAUDE.md files, using layer-based execution (Layer 3->1), batch agent processing (4 modules/agent), and gemini->qwen->codex fallback.
**Syntax**:
```
/memory:update-full [--tool gemini|qwen|codex] [--path <directory>]
```
**Options**:
- `--tool=tool`: CLI tool to use
- `--path=directory`: Specific directory
**Layer Structure**:
- Layer 3: Project-level analysis
- Layer 2: Module-level analysis
- Layer 1: File-level analysis
**Examples**:
```bash
# Update entire project
/memory:update-full
# Update specific directory
/memory:update-full --path src/auth/
# Specify tool
/memory:update-full --tool qwen
```
### update-related
**Function**: Update CLAUDE.md files for git-changed modules, using batch agent execution (4 modules/agent) and gemini->qwen->codex fallback.
**Syntax**:
```
/memory:update-related [--tool gemini|qwen|codex]
```
**Options**:
- `--tool=tool`: CLI tool to use
**Examples**:
```bash
# Default update
/memory:update-related
# Specify tool
/memory:update-related --tool gemini
```
### docs-full-cli
**Function**: Generate full project documentation using CLI (Layer 3->1), batch agent processing (4 modules/agent), gemini->qwen->codex fallback, direct parallel for <20 modules.
**Syntax**:
```
/memory:docs-full-cli [path] [--tool <gemini|qwen|codex>]
```
**Examples**:
```bash
# Generate entire project documentation
/memory:docs-full-cli
# Generate specific directory documentation
/memory:docs-full-cli src/
# Specify tool
/memory:docs-full-cli --tool gemini
```
### docs-related-cli
**Function**: Generate documentation for git-changed modules using CLI, batch agent processing (4 modules/agent), gemini->qwen->codex fallback, direct execution for <15 modules.
**Syntax**:
```
/memory:docs-related-cli [--tool <gemini|qwen|codex>]
```
**Examples**:
```bash
# Default generation
/memory:docs-related-cli
# Specify tool
/memory:docs-related-cli --tool qwen
```
### style-skill-memory
**Function**: Generate SKILL memory package from style reference, facilitating loading and consistent design system usage.
**Syntax**:
```
/memory:style-skill-memory [package-name] [--regenerate]
```
**Options**:
- `--regenerate`: Regenerate
**Examples**:
```bash
# Generate style memory package
/memory:style-skill-memory my-design-system
# Regenerate
/memory:style-skill-memory my-design-system --regenerate
```
## Memory System Workflow
```mermaid
graph TD
A[In Session] --> B[Capture Context]
B --> C{Session Complete?}
C -->|Yes| D[Compress Memory]
C -->|No| E[Continue Work]
D --> F[Save to core_memory]
F --> G[Update CLAUDE.md]
G --> H[Generate Documentation]
H --> I[New Session Starts]
I --> J[Load Memory Package]
J --> K[Restore Context]
K --> A
```
## CLAUDE.md Structure
```markdown
# Module Name
## One-Liner
Core value description of the module
## Tech Stack
- Framework/library
- Main dependencies
## Key Files
- File path: Description
## Code Conventions
- Naming conventions
- Architecture patterns
- Best practices
## TODO
- Planned features
- Known issues
```
## Related Documentation
- [Memory System](../../features/memory.md)
- [Core Orchestration](./core-orchestration.md)
- [Core Concepts Guide](../../guide/ch03-core-concepts.md)

View File

@@ -0,0 +1,256 @@
# Session Management Commands
## One-Liner
**Session management commands are the workflow state managers** — creating, tracking, resuming, and completing workflow sessions.
## Core Concepts
| Concept | Description | Location |
|---------|-------------|----------|
| **Session ID** | Unique identifier (WFS-YYYY-MM-DD) | `.workflow/active/WFS-xxx/` |
| **Session Type** | workflow, review, tdd, test, docs | Session metadata |
| **Session State** | active, paused, completed | workflow-session.json |
| **Artifacts** | Plans, tasks, TODOs, etc. | Session directory |
## Command List
| Command | Function | Syntax |
|---------|----------|--------|
| [`start`](#start) | Discover existing sessions or start new workflow session | `/workflow:session:start [--type type] [--auto\|--new] [description]` |
| [`list`](#list) | List all workflow sessions | `/workflow:session:list` |
| [`resume`](#resume) | Resume most recently paused workflow session | `/workflow:session:resume` |
| [`complete`](#complete) | Mark active workflow session as completed | `/workflow:session:complete [-y] [--detailed]` |
| [`solidify`](#solidify) | Crystallize session learnings into project guidelines | `/workflow:session:solidify [-y] [--type type] [--category category] "rule"` |
## Command Details
### start
**Function**: Discover existing sessions or start new workflow session, supporting intelligent session management and conflict detection.
**Syntax**:
```
/workflow:session:start [--type <workflow|review|tdd|test|docs>] [--auto|--new] [optional: task description]
```
**Options**:
- `--type=type`: Session type
- `workflow`: Standard implementation (default)
- `review`: Code review
- `tdd`: TDD development
- `test`: Test generation/fix
- `docs`: Documentation session
- `--auto`: Smart mode (auto detect/create)
- `--new`: Force create new session
**Session Types**:
| Type | Description | Default Source |
|------|-------------|----------------|
| `workflow` | Standard implementation | workflow-plan skill |
| `review` | Code review | review-cycle skill |
| `tdd` | TDD development | workflow-tdd skill |
| `test` | Test generation/fix | workflow-test-fix skill |
| `docs` | Documentation session | memory-manage skill |
**Workflow**:
```mermaid
graph TD
A[Start] --> B{Project State Exists?}
B -->|No| C[Call workflow:init]
C --> D
B -->|Yes| D{Mode}
D -->|Default| E[List Active Sessions]
D -->|auto| F{Active Sessions Count?}
D -->|new| G[Create New Session]
F -->|0| G
F -->|1| H[Use Existing Session]
F -->|>1| I[User Selects]
E --> J{User Selects}
J -->|Existing| K[Return Session ID]
J -->|New| G
G --> L[Generate Session ID]
L --> M[Create Directory Structure]
M --> N[Initialize Metadata]
N --> O[Return Session ID]
```
**Examples**:
```bash
# Discovery mode - list active sessions
/workflow:session:start
# Auto mode - smart select/create
/workflow:session:start --auto "implement user authentication"
# New mode - force create new session
/workflow:session:start --new "refactor payment module"
# Specify type
/workflow:session:start --type review "review auth code"
/workflow:session:start --type tdd --auto "implement login feature"
```
### list
**Function**: List all workflow sessions, supporting state filtering, displaying session metadata and progress information.
**Syntax**:
```
/workflow:session:list
```
**Output Format**:
| Session ID | Type | State | Description | Progress |
|------------|------|-------|-------------|----------|
| WFS-2024-01-15 | workflow | active | User authentication | 5/10 |
| WFS-2024-01-14 | review | paused | Code review | 8/8 |
| WFS-2024-01-13 | tdd | completed | TDD development | 12/12 |
**Examples**:
```bash
# List all sessions
/workflow:session:list
```
### resume
**Function**: Resume most recently paused workflow session, supporting automatic session discovery and state update.
**Syntax**:
```
/workflow:session:resume
```
**Workflow**:
```mermaid
graph TD
A[Start] --> B[Find Paused Sessions]
B --> C{Found Paused Session?}
C -->|Yes| D[Load Session]
C -->|No| E[Error Message]
D --> F[Update State to Active]
F --> G[Return Session ID]
```
**Examples**:
```bash
# Resume most recently paused session
/workflow:session:resume
```
### complete
**Function**: Mark active workflow session as completed, archive and learn from experience, update checklist and remove active flag.
**Syntax**:
```
/workflow:session:complete [-y|--yes] [--detailed]
```
**Options**:
- `--detailed`: Detailed mode, collect more learnings
**Workflow**:
```mermaid
graph TD
A[Start] --> B[Confirm Completion]
B --> C{Detailed Mode?}
C -->|Yes| D[Collect Detailed Feedback]
C -->|No| E[Collect Basic Feedback]
D --> F[Generate Learning Document]
E --> F
F --> G[Archive Session]
G --> H[Update Checklist]
H --> I[Remove Active Flag]
I --> J[Complete]
```
**Examples**:
```bash
# Standard completion
/workflow:session:complete
# Detailed completion
/workflow:session:complete --detailed
# Auto mode
/workflow:session:complete -y
```
### solidify
**Function**: Crystallize session learnings and user-defined constraints into permanent project guidelines.
**Syntax**:
```
/workflow:session:solidify [-y|--yes] [--type <convention|constraint|learning>] [--category <category>] "rule or insight"
```
**Options**:
- `--type=type`:
- `convention`: Code convention
- `constraint`: Constraint condition
- `learning`: Experience learning
- `--category=category`: Category name (e.g., `authentication`, `testing`)
**Output Locations**:
- Conventions: `.workflow/specs/conventions/<category>.md`
- Constraints: `.workflow/specs/constraints/<category>.md`
- Learnings: `.workflow/specs/learnings/<category>.md`
**Examples**:
```bash
# Add code convention
/workflow:session:solidify --type=convention --category=auth "all auth functions must use rate limiting"
# Add constraint
/workflow:session:solidify --type=constraint --category=database "no N+1 queries"
# Add learning
/workflow:session:solidify --type=learning --category=api "REST API design lessons learned"
```
## Session Directory Structure
```
.workflow/
├── active/ # Active sessions
│ └── WFS-2024-01-15/ # Session directory
│ ├── workflow-session.json # Session metadata
│ ├── tasks/ # Task definitions
│ ├── artifacts/ # Artifact files
│ └── context/ # Context files
└── archived/ # Archived sessions
└── WFS-2024-01-14/
```
## Session Metadata
```json
{
"session_id": "WFS-2024-01-15",
"type": "workflow",
"status": "active",
"created_at": "2024-01-15T10:00:00Z",
"updated_at": "2024-01-15T14:30:00Z",
"description": "User authentication feature implementation",
"progress": {
"total": 10,
"completed": 5,
"percentage": 50
}
}
```
## Related Documentation
- [Workflow Commands](./workflow.md)
- [Core Orchestration](./core-orchestration.md)
- [Workflow Basics](../../guide/ch04-workflow-basics.md)

View File

@@ -0,0 +1,307 @@
# UI Design Commands
## One-Liner
**UI design commands are the interface prototype generation system** — from style extraction, layout analysis to prototype assembly, fully covering the UI design workflow.
## Core Concepts
| Concept | Description | Storage Location |
|----------|-------------|------------------|
| **Design Run** | Design session directory | `.workflow/ui-design-runs/<run-id>/` |
| **Design Tokens** | Style variables | `design-tokens.json` |
| **Layout Templates** | Structure definitions | `layouts/` |
| **Prototypes** | Generated components | `prototypes/` |
## Command List
### Discovery and Extraction
| Command | Function | Syntax |
|---------|----------|--------|
| [`explore-auto`](#explore-auto) | Interactive exploratory UI design workflow | `/workflow:ui-design:explore-auto [--input "value"] [--targets "list"]` |
| [`imitate-auto`](#imitate-auto) | Direct code/image input UI design | `/workflow:ui-design:imitate-auto [--input "value"] [--session id]` |
| [`style-extract`](#style-extract) | Extract design styles from reference images or prompts | `/workflow:ui-design:style-extract [-y] [--design-id id]` |
| [`layout-extract`](#layout-extract) | Extract layout information from reference images | `/workflow:ui-design:layout-extract [-y] [--design-id id]` |
| [`animation-extract`](#animation-extract) | Extract animation and transition patterns | `/workflow:ui-design:animation-extract [-y] [--design-id id]` |
### Import and Export
| Command | Function | Syntax |
|---------|----------|--------|
| [`import-from-code`](#import-from-code) | Import design system from code files | `/workflow:ui-design:import-from-code [--design-id id] [--session id] [--source path]` |
| [`codify-style`](#codify-style) | Extract styles from code and generate shareable reference package | `/workflow:ui-design:codify-style <path> [--package-name name]` |
| [`reference-page-generator`](#reference-page-generator) | Generate multi-component reference page from design run | `/workflow:ui-design:reference-page-generator [--design-run path]` |
### Generation and Sync
| Command | Function | Syntax |
|---------|----------|--------|
| [`generate`](#generate) | Combine layout templates with design tokens to generate prototypes | `/workflow:ui-design:generate [--design-id id] [--session id]` |
| [`design-sync`](#design-sync) | Sync final design system reference to brainstorm artifacts | `/workflow:ui-design:design-sync --session <session_id>` |
## Command Details
### explore-auto
**Function**: Interactive exploratory UI design workflow, style-centric batch generation, creating design variants from prompts/images, supporting parallel execution and user selection.
**Syntax**:
```
/workflow:ui-design:explore-auto [--input "<value>"] [--targets "<list>"] [--target-type "page|component"] [--session <id>] [--style-variants <count>] [--layout-variants <count>]
```
**Options**:
- `--input=value`: Input prompt or image path
- `--targets=list`: Target component list (comma-separated)
- `--target-type=type`: page or component
- `--session=id`: Session ID
- `--style-variants=N`: Number of style variants
- `--layout-variants=N`: Number of layout variants
**Examples**:
```bash
# Page design exploration
/workflow:ui-design:explore-auto --input "modern e-commerce homepage" --target-type page --style-variants 3
# Component design exploration
/workflow:ui-design:explore-auto --input "user card component" --target-type component --layout-variants 5
# Multi-target design
/workflow:ui-design:explore-auto --targets "header,sidebar,footer" --style-variants 2
```
### imitate-auto
**Function**: UI design workflow supporting direct code/image input for design token extraction and prototype generation.
**Syntax**:
```
/workflow:ui-design:imitate-auto [--input "<value>"] [--session <id>]
```
**Options**:
- `--input=value`: Code file path or image path
- `--session=id`: Session ID
**Examples**:
```bash
# Imitate from code
/workflow:ui-design:imitate-auto --input "./src/components/Button.tsx"
# Imitate from image
/workflow:ui-design:imitate-auto --input "./designs/mockup.png"
```
### style-extract
**Function**: Extract design styles using Claude analysis from reference images or text prompts, supporting variant generation or refine mode.
**Syntax**:
```
/workflow:ui-design:style-extract [-y|--yes] [--design-id <id>] [--session <id>] [--images "<glob>"] [--prompt "<description>"] [--variants <count>] [--interactive] [--refine]
```
**Options**:
- `--images=glob`: Image glob pattern
- `--prompt=description`: Text description
- `--variants=N`: Number of variants
- `--interactive`: Interactive mode
- `--refine`: Refine mode
**Examples**:
```bash
# Extract styles from images
/workflow:ui-design:style-extract --images "./designs/*.png" --variants 3
# Extract from prompt
/workflow:ui-design:style-extract --prompt "dark theme, blue primary, rounded corners"
# Interactive refine
/workflow:ui-design:style-extract --images "reference.png" --refine --interactive
```
### layout-extract
**Function**: Extract structural layout information using Claude analysis from reference images or text prompts, supporting variant generation or refine mode.
**Syntax**:
```
/workflow:ui-design:layout-extract [-y|--yes] [--design-id <id>] [--session <id>] [--images "<glob>"] [--prompt "<description>"] [--targets "<list>"] [--variants <count>] [--device-type <desktop|mobile|tablet|responsive>] [--interactive] [--refine]
```
**Options**:
- `--device-type=type`: desktop, mobile, tablet or responsive
- Other options same as style-extract
**Examples**:
```bash
# Extract desktop layout
/workflow:ui-design:layout-extract --images "desktop-mockup.png" --device-type desktop
# Extract responsive layout
/workflow:ui-design:layout-extract --prompt "three-column layout, responsive design" --device-type responsive
# Multiple variants
/workflow:ui-design:layout-extract --images "layout.png" --variants 5
```
### animation-extract
**Function**: Extract animation and transition patterns from prompts inference and image references for design system documentation.
**Syntax**:
```
/workflow:ui-design:animation-extract [-y|--yes] [--design-id <id>] [--session <id>] [--images "<glob>"] [--focus "<type>"] [--interactive] [--refine]
```
**Options**:
- `--focus=type`: Specific animation type (e.g., fade, slide, scale)
**Examples**:
```bash
# Extract all animations
/workflow:ui-design:animation-extract --images "./animations/*.gif"
# Extract specific type
/workflow:ui-design:animation-extract --focus "fade,slide" --interactive
```
### import-from-code
**Function**: Import design system from code files (CSS/JS/HTML/SCSS), using automatic file discovery and parallel agent analysis.
**Syntax**:
```
/workflow:ui-design:import-from-code [--design-id <id>] [--session <id>] [--source <path>]
```
**Options**:
- `--source=path`: Source code directory
**Examples**:
```bash
# Import from project
/workflow:ui-design:import-from-code --source "./src/styles/"
# Specify design ID
/workflow:ui-design:import-from-code --design-id my-design --source "./theme/"
```
### codify-style
**Function**: Orchestrator extracts styles from code and generates shareable reference package, supporting preview (automatic file discovery).
**Syntax**:
```
/workflow:ui-design:codify-style <path> [--package-name <name>] [--output-dir <path>] [--overwrite]
```
**Options**:
- `--package-name=name`: Package name
- `--output-dir=path`: Output directory
- `--overwrite`: Overwrite existing files
**Examples**:
```bash
# Generate style package
/workflow:ui-design:codify-style ./src/styles/ --package-name my-design-system
# Specify output directory
/workflow:ui-design:codify-style ./theme/ --output-dir ./design-packages/
```
### reference-page-generator
**Function**: Extract and generate multi-component reference pages and documentation from design run.
**Syntax**:
```
/workflow:ui-design:reference-page-generator [--design-run <path>] [--package-name <name>] [--output-dir <path>]
```
**Examples**:
```bash
# Generate reference page
/workflow:ui-design:reference-page-generator --design-run .workflow/ui-design-runs/latest/
# Specify package name
/workflow:ui-design:reference-page-generator --package-name component-library
```
### generate
**Function**: Assemble UI prototypes, combining layout templates with design tokens (default animation support), pure assembler with no new content generation.
**Syntax**:
```
/workflow:ui-design:generate [--design-id <id>] [--session <id>]
```
**Examples**:
```bash
# Generate prototypes
/workflow:ui-design:generate
# Use specific design
/workflow:ui-design:generate --design-id my-design
```
### design-sync
**Function**: Sync final design system reference to brainstorm artifacts, preparing for consumption by `/workflow:plan`.
**Syntax**:
```
/workflow:ui-design:design-sync --session <session_id> [--selected-prototypes "<list>"]
```
**Options**:
- `--selected-prototypes=list`: List of selected prototypes
**Examples**:
```bash
# Sync all prototypes
/workflow:ui-design:design-sync --session WFS-design-2024-01-15
# Sync selected prototypes
/workflow:ui-design:design-sync --session WFS-design-2024-01-15 --selected-prototypes "header,button,card"
```
## UI Design Workflow
```mermaid
graph TD
A[Input] --> B{Input Type}
B -->|Image/Prompt| C[Extract Styles]
B -->|Code| D[Import Styles]
C --> E[Extract Layouts]
D --> E
E --> F[Extract Animations]
F --> G[Design Run]
G --> H[Generate Prototypes]
H --> I[Sync to Brainstorm]
I --> J[Planning Workflow]
```
## Design Run Structure
```
.workflow/ui-design-runs/<run-id>/
├── design-tokens.json # Design tokens
├── layouts/ # Layout templates
│ ├── header.json
│ ├── footer.json
│ └── ...
├── prototypes/ # Generated prototypes
│ ├── header/
│ ├── button/
│ └── ...
└── reference-pages/ # Reference pages
```
## Related Documentation
- [Core Orchestration](./core-orchestration.md)
- [Workflow Commands](./workflow.md)
- [Brainstorming](../../features/)

View File

@@ -0,0 +1,338 @@
# Workflow Commands
## One-Liner
**Workflow commands are the execution engine of Claude_dms3** — providing complete workflow support from lightweight tasks to complex projects.
## Command List
### Lightweight Workflows
| Command | Function | Syntax |
|---------|----------|--------|
| [`lite-lite-lite`](#lite-lite-lite) | Ultra-lightweight multi-tool analysis and direct execution | `/workflow:lite-lite-lite [-y] <task>` |
| [`lite-plan`](#lite-plan) | Lightweight interactive planning workflow | `/workflow:lite-plan [-y] [-e] "task"` |
| [`lite-execute`](#lite-execute) | Execute tasks based on in-memory plan | `/workflow:lite-execute [-y] [--in-memory] [task]` |
| [`lite-fix`](#lite-fix) | Lightweight bug diagnosis and fix | `/workflow:lite-fix [-y] [--hotfix] "bug description"` |
### Standard Workflows
| Command | Function | Syntax |
|---------|----------|--------|
| [`plan`](#plan) | 5-phase planning workflow | `/workflow:plan [-y] "description"\|file.md` |
| [`execute`](#execute) | Coordinate agent execution of workflow tasks | `/workflow:execute [-y] [--resume-session=ID]` |
| [`replan`](#replan) | Interactive workflow replanning | `/workflow:replan [-y] [--session ID] [task-id] "requirement"` |
### Collaborative Workflows
| Command | Function | Syntax |
|---------|----------|--------|
| [`multi-cli-plan`](#multi-cli-plan) | Multi-CLI collaborative planning | `/workflow:multi-cli-plan [-y] <task> [--max-rounds=N]` |
| [`brainstorm-with-file`](#brainstorm-with-file) | Interactive brainstorming | `/workflow:brainstorm-with-file [-y] [-c] "idea"` |
| [`analyze-with-file`](#analyze-with-file) | Interactive collaborative analysis | `/workflow:analyze-with-file [-y] [-c] "topic"` |
| [`debug-with-file`](#debug-with-file) | Interactive hypothesis-driven debugging | `/workflow:debug-with-file [-y] "bug description"` |
| [`unified-execute-with-file`](#unified-execute-with-file) | Universal execution engine | `/workflow:unified-execute-with-file [-y] [-p path] [context]` |
### TDD Workflows
| Command | Function | Syntax |
|---------|----------|--------|
| [`tdd-plan`](#tdd-plan) | TDD planning workflow | `/workflow:tdd-plan "feature description"` |
| [`tdd-verify`](#tdd-verify) | Verify TDD workflow compliance | `/workflow:tdd-verify [--session ID]` |
### Test Workflows
| Command | Function | Syntax |
|---------|----------|--------|
| [`test-fix-gen`](#test-fix-gen) | Create test-fix workflow session | `/workflow:test-fix-gen (session-id\|"description"\|file.md)` |
| [`test-gen`](#test-gen) | Create test session from implementation session | `/workflow:test-gen source-session-id` |
| [`test-cycle-execute`](#test-cycle-execute) | Execute test-fix workflow | `/workflow:test-cycle-execute [--resume-session=ID]` |
### Review Workflows
| Command | Function | Syntax |
|---------|----------|--------|
| [`review`](#review) | Post-implementation review | `/workflow:review [--type=type] [--archived] [session-id]` |
| [`review-module-cycle`](#review-module-cycle) | Standalone multi-dimensional code review | `/workflow:review-module-cycle <path> [--dimensions=dimensions]` |
| [`review-session-cycle`](#review-session-cycle) | Session-based review | `/workflow:review-session-cycle [session-id] [--dimensions=dimensions]` |
| [`review-cycle-fix`](#review-cycle-fix) | Auto-fix review findings | `/workflow:review-cycle-fix <export-file\|review-dir>` |
### Specialized Workflows
| Command | Function | Syntax |
|---------|----------|--------|
| [`clean`](#clean) | Smart code cleanup | `/workflow:clean [-y] [--dry-run] ["focus area"]` |
| [`init`](#init) | Initialize project state | `/workflow:init [--regenerate]` |
| [`plan-verify`](#plan-verify) | Verify planning consistency | `/workflow:plan-verify [--session session-id]` |
## Command Details
### lite-lite-lite
**Function**: Ultra-lightweight multi-tool analysis and direct execution. Simple tasks have no artifacts, complex tasks automatically create planning documents in `.workflow/.scratchpad/`.
**Syntax**:
```
/workflow:lite-lite-lite [-y|--yes] <task description>
```
**Use Cases**:
- Ultra-simple quick tasks
- Code modifications not needing planning documents
- Automatic tool selection
**Examples**:
```bash
# Ultra-simple task
/workflow:lite-lite-lite "fix header styles"
# Auto mode
/workflow:lite-lite-lite -y "update README links"
```
### lite-plan
**Function**: Lightweight interactive planning workflow, supporting in-memory planning, code exploration, and execution to lite-execute.
**Syntax**:
```
/workflow:lite-plan [-y|--yes] [-e|--explore] "task description" | file.md
```
**Options**:
- `-e, --explore`: Execute code exploration first
**Examples**:
```bash
# Basic planning
/workflow:lite-plan "add user avatar feature"
# With exploration
/workflow:lite-plan -e "refactor authentication module"
```
### lite-execute
**Function**: Execute tasks based on in-memory plan, prompt description, or file content.
**Syntax**:
```
/workflow:lite-execute [-y|--yes] [--in-memory] ["task description" | file-path]
```
**Options**:
- `--in-memory`: Use in-memory plan
**Examples**:
```bash
# Execute task
/workflow:lite-execute "implement avatar upload API"
# Use in-memory plan
/workflow:lite-execute --in-memory
```
### lite-fix
**Function**: Lightweight bug diagnosis and fix workflow, supporting intelligent severity assessment and optional hotfix mode.
**Syntax**:
```
/workflow:lite-fix [-y|--yes] [--hotfix] "bug description or issue reference"
```
**Options**:
- `--hotfix`: Hotfix mode (quick fix for production incidents)
**Examples**:
```bash
# Bug fix
/workflow:lite-fix "login returns 500 error"
# Hotfix
/workflow:lite-fix --hotfix "payment gateway timeout"
```
### plan
**Function**: 5-phase planning workflow, outputting IMPL_PLAN.md and task JSON.
**Syntax**:
```
/workflow:plan [-y|--yes] "text description" | file.md
```
**Phases**:
1. Session initialization
2. Context collection
3. Specification loading
4. Task generation
5. Verification/replanning
**Examples**:
```bash
# Plan from description
/workflow:plan "implement user notification system"
# Plan from file
/workflow:plan requirements.md
```
### execute
**Function**: Coordinate agent execution of workflow tasks, supporting automatic session discovery, parallel task processing, and state tracking.
**Syntax**:
```
/workflow:execute [-y|--yes] [--resume-session="session-id"]
```
**Examples**:
```bash
# Execute current session
/workflow:execute
# Resume and execute session
/workflow:execute --resume-session=WFS-2024-01-15
```
### replan
**Function**: Interactive workflow replanning, supporting session-level artifact updates and scope clarification.
**Syntax**:
```
/workflow:replan [-y|--yes] [--session session-id] [task-id] "requirement" | file.md [--interactive]
```
**Examples**:
```bash
# Replan entire session
/workflow:replan --session=WFS-xxx "add user permission checks"
# Replan specific task
/workflow:replan TASK-001 "change to use RBAC"
```
### multi-cli-plan
**Function**: Multi-CLI collaborative planning workflow, using ACE context collection and iterative cross-validation.
**Syntax**:
```
/workflow:multi-cli-plan [-y|--yes] <task description> [--max-rounds=3] [--tools=gemini,codex] [--mode=parallel|serial]
```
**Options**:
- `--max-rounds=N`: Maximum discussion rounds
- `--tools=tools`: CLI tools to use
- `--mode=mode`: Parallel or serial mode
**Examples**:
```bash
# Multi-CLI planning
/workflow:multi-cli-plan "design microservice architecture"
# Specify tools and rounds
/workflow:multi-cli-plan --tools=gemini,codex --max-rounds=5 "database migration plan"
```
### brainstorm-with-file
**Function**: Interactive brainstorming, multi-CLI collaboration, idea expansion, and documented thinking evolution.
**Syntax**:
```
/workflow:brainstorm-with-file [-y|--yes] [-c|--continue] [-m|--mode creative|structured] "idea or topic"
```
**Options**:
- `-c, --continue`: Continue existing session
- `-m, --mode=mode`: creative or structured
**Examples**:
```bash
# Creative brainstorming
/workflow:brainstorm-with-file --mode creative "user growth strategies"
# Structured brainstorming
/workflow:brainstorm-with-file --mode structured "API versioning approach"
```
### analyze-with-file
**Function**: Interactive collaborative analysis with documented discussion, CLI-assisted exploration, and evolving understanding.
**Syntax**:
```
/workflow:analyze-with-file [-y|--yes] [-c|--continue] "topic or question"
```
**Examples**:
```bash
# Analyze topic
/workflow:analyze-with-file "authentication architecture design"
# Continue discussion
/workflow:analyze-with-file -c
```
### debug-with-file
**Function**: Interactive hypothesis-driven debugging with documented exploration, understanding evolution, and Gemini-assisted correction.
**Syntax**:
```
/workflow:debug-with-file [-y|--yes] "bug description or error message"
```
**Examples**:
```bash
# Debug bug
/workflow:debug-with-file "WebSocket connection randomly disconnects"
# Debug error
/workflow:debug-with-file "TypeError: Cannot read property 'id'"
```
### unified-execute-with-file
**Function**: Universal execution engine consuming any planning/brainstorming/analysis output, supporting minimal progress tracking, multi-agent coordination, and incremental execution.
**Syntax**:
```
/workflow:unified-execute-with-file [-y|--yes] [-p|--plan <path>] [-m|--mode sequential|parallel] ["execution context"]
```
**Examples**:
```bash
# Execute plan
/workflow:unified-execute-with-file -p plan.md
# Parallel execution
/workflow:unified-execute-with-file -m parallel
```
## Workflow Diagram
```mermaid
graph TD
A[Task Input] --> B{Task Complexity}
B -->|Simple| C[Lite Workflow]
B -->|Standard| D[Plan Workflow]
B -->|Complex| E[Multi-CLI Workflow]
C --> F[Direct Execution]
D --> G[Plan] --> H[Execute]
E --> I[Multi-CLI Discussion] --> G
F --> J[Complete]
H --> J
I --> J
```
## Related Documentation
- [Session Management](./session.md)
- [Core Orchestration](./core-orchestration.md)
- [Workflow Guide](../../guide/ch04-workflow-basics.md)