Files
Claude-Code-Workflow/.claude/commands/workflow/resume.md
catlog22 967e3805b7 docs: 标准化命令文档格式,移除表情符号并添加命令模板规范
更新所有命令文档以提高可读性和一致性:
- 移除所有表情符号(⚠️, , , ▸等),使用纯文本替代
- 统一标题格式,改进章节结构
- 简化状态指示器和格式标记
- 添加三个新的命令模板规范文档

新增文档:
- COMMAND_FLOW_STANDARD.md - 标准命令流程规范
- COMMAND_TEMPLATE_EXECUTOR.md - 执行器命令模板
- COMMAND_TEMPLATE_ORCHESTRATOR.md - 编排器命令模板

影响范围:
- CLI命令(cli-init, codex-execute, discuss-plan, execute)
- 内存管理命令(skill-memory, tech-research, workflow-skill-memory)
- 任务管理命令(breakdown, create, execute, replan)
- 工作流命令(所有workflow相关命令)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-05 21:48:43 +08:00

3.7 KiB

name, description, argument-hint, allowed-tools
name description argument-hint allowed-tools
resume Intelligent workflow session resumption with automatic progress analysis session-id for workflow session to resume SlashCommand(*), TodoWrite(*), Read(*), Bash(*)

Sequential Workflow Resume Command

Usage

/workflow:resume "<session-id>"

Purpose

Sequential command coordination for workflow resumption by first analyzing current session status, then continuing execution with special resume context. This command orchestrates intelligent session resumption through two-step process.

Command Coordination Workflow

Phase 1: Status Analysis

  1. Call status command: Execute /workflow:status to analyze current session state
  2. Verify session information: Check session ID, progress, and current task status
  3. Identify resume point: Determine where workflow was interrupted

Phase 2: Resume Execution

  1. Call execute with resume flag: Execute /workflow:execute --resume-session="{session-id}"
  2. Pass session context: Provide analyzed session information to execute command
  3. Direct agent execution: Skip discovery phase, directly enter TodoWrite and agent execution

Implementation Protocol

Sequential Command Execution

# Phase 1: Analyze current session status
SlashCommand(command="/workflow:status")

# Phase 2: Resume execution with special flag
SlashCommand(command="/workflow:execute --resume-session=\"{session-id}\"")

Progress Tracking

TodoWrite({
  todos: [
    {
      content: "Analyze current session status and progress",
      status: "in_progress",
      activeForm: "Analyzing session status"
    },
    {
      content: "Resume workflow execution with session context",
      status: "pending",
      activeForm: "Resuming workflow execution"
    }
  ]
});

Resume Information Flow

Status Analysis Results

The /workflow:status command provides:

  • Session ID: Current active session identifier
  • Current Progress: Completed, in-progress, and pending tasks
  • Interruption Point: Last executed task and next pending task
  • Session State: Overall workflow status

Execute Command Context

The special --resume-session flag tells /workflow:execute:

  • Skip Discovery: Don't search for sessions, use provided session ID
  • Direct Execution: Go straight to TodoWrite generation and agent launching
  • Context Restoration: Use existing session state and summaries
  • Resume Point: Continue from identified interruption point

Error Handling

Session Validation Failures

  • Session not found: Report missing session, suggest available sessions
  • Session inactive: Recommend activating session first
  • Status command fails: Retry once, then report analysis failure

Execute Resumption Failures

  • No pending tasks: Report workflow completion status
  • Execute command fails: Report resumption failure, suggest manual intervention

Success Criteria

  1. Status analysis complete: Session state properly analyzed and reported
  2. Execute command launched: Resume execution started with proper context
  3. Agent coordination: TodoWrite and agent execution initiated successfully
  4. Context preservation: Session state and progress properly maintained

Prerequisite Commands:

  • /workflow:plan or /workflow:execute - Workflow must be in progress or paused

Called by This Command (2 phases):

  • /workflow:status - Phase 1: Analyze current session status and identify resume point
  • /workflow:execute - Phase 2: Resume execution with --resume-session flag

Follow-up Commands:

  • None - Workflow continues automatically via /workflow:execute

Sequential command coordination for workflow session resumption