mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-14 02:42:04 +08:00
refactor: Convert skill-generator from Chinese to English and remove emoji icons
- Convert all markdown files from Chinese to English - Remove all emoji/icon decorations (🔧📋⚙️✅🏁🔍📚⛔⭐) - Update all section headers, descriptions, and documentation - Keep all content logic, structure, code examples unchanged - Maintain template variables and file paths as-is Files converted (9 files total): - SKILL.md: Output structure comments - templates/skill-md.md: All Chinese descriptions and comments - specs/reference-docs-spec.md: All section headers and explanations - phases/01-requirements-discovery.md through 05-validation.md (5 files) - specs/execution-modes.md, skill-requirements.md, cli-integration.md, scripting-integration.md (4 files) - templates/sequential-phase.md, autonomous-orchestrator.md, autonomous-action.md, code-analysis-action.md, llm-action.md, script-template.md (6 files) All 16 files in skill-generator are now fully in English.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
---
|
||||
name: skill-generator
|
||||
description: Meta-skill for creating new Claude Code skills with configurable execution modes. Supports sequential (fixed order) and autonomous (stateless) phase patterns. Use for skill scaffolding, skill creation, or building new workflows. Triggers on "create skill", "new skill", "skill generator", "生成技能", "创建技能".
|
||||
description: Meta-skill for creating new Claude Code skills with configurable execution modes. Supports sequential (fixed order) and autonomous (stateless) phase patterns. Use for skill scaffolding, skill creation, or building new workflows. Triggers on "create skill", "new skill", "skill generator".
|
||||
allowed-tools: Task, AskUserQuestion, Read, Bash, Glob, Grep, Write
|
||||
---
|
||||
|
||||
@@ -36,96 +36,94 @@ Meta-skill for creating new Claude Code skills with configurable execution modes
|
||||
|
||||
## Execution Modes
|
||||
|
||||
### Mode 1: Sequential (固定顺序)
|
||||
### Mode 1: Sequential (Fixed Order)
|
||||
|
||||
传统线性执行模式,阶段按数字前缀顺序执行。
|
||||
Traditional linear execution model, phases execute in numeric prefix order.
|
||||
|
||||
```
|
||||
Phase 01 → Phase 02 → Phase 03 → ... → Phase N
|
||||
Phase 01 -> Phase 02 -> Phase 03 -> ... -> Phase N
|
||||
```
|
||||
|
||||
**适用场景**:
|
||||
- 流水线式任务(收集 → 分析 → 生成)
|
||||
- 阶段间有强依赖关系
|
||||
- 输出结构固定
|
||||
**Use Cases**:
|
||||
- Pipeline tasks (collect -> analyze -> generate)
|
||||
- Strong dependencies between phases
|
||||
- Fixed output structure
|
||||
|
||||
**示例**: `software-manual`, `copyright-docs`
|
||||
**Examples**: `software-manual`, `copyright-docs`
|
||||
|
||||
### Mode 2: Autonomous (无状态自主选择)
|
||||
### Mode 2: Autonomous (Stateless Auto-Select)
|
||||
|
||||
智能路由模式,根据上下文动态选择执行路径。
|
||||
Intelligent routing model, dynamically selects execution path based on context.
|
||||
|
||||
```
|
||||
┌─────────────────────────────────────────┐
|
||||
│ Orchestrator Agent │
|
||||
│ (读取状态 → 选择 Phase → 执行 → 更新) │
|
||||
└───────────────┬─────────────────────────┘
|
||||
│
|
||||
┌───────────┼───────────┐
|
||||
↓ ↓ ↓
|
||||
┌───────┐ ┌───────┐ ┌───────┐
|
||||
│Phase A│ │Phase B│ │Phase C│
|
||||
│(独立) │ │(独立) │ │(独立) │
|
||||
└───────┘ └───────┘ └───────┘
|
||||
---------------------------------------------------
|
||||
Orchestrator Agent
|
||||
(Read state -> Select Phase -> Execute -> Update)
|
||||
---------------------------------------------------
|
||||
|
|
||||
---------+----------+----------
|
||||
| | |
|
||||
Phase A Phase B Phase C
|
||||
(standalone) (standalone) (standalone)
|
||||
```
|
||||
|
||||
**适用场景**:
|
||||
- 交互式任务(对话、问答)
|
||||
- 阶段间无强依赖
|
||||
- 需要动态响应用户意图
|
||||
**Use Cases**:
|
||||
- Interactive tasks (chat, Q&A)
|
||||
- No strong dependencies between phases
|
||||
- Dynamic user intent response required
|
||||
|
||||
**示例**: `issue-manage`, `workflow-debug`
|
||||
**Examples**: `issue-manage`, `workflow-debug`
|
||||
|
||||
## Key Design Principles
|
||||
|
||||
1. **模式感知**: 根据任务特性自动推荐执行模式
|
||||
2. **骨架生成**: 生成完整目录结构和文件骨架
|
||||
3. **规范遵循**: 严格遵循 `_shared/SKILL-DESIGN-SPEC.md`
|
||||
4. **可扩展性**: 生成的 Skill 易于扩展和修改
|
||||
1. **Mode Awareness**: Automatically recommend execution mode based on task characteristics
|
||||
2. **Skeleton Generation**: Generate complete directory structure and file skeletons
|
||||
3. **Standards Compliance**: Strictly follow `_shared/SKILL-DESIGN-SPEC.md`
|
||||
4. **Extensibility**: Generated Skills are easy to extend and modify
|
||||
|
||||
---
|
||||
|
||||
## ⚠️ Mandatory Prerequisites (强制前置条件)
|
||||
## Required Prerequisites
|
||||
|
||||
> **⛔ 禁止跳过**: 在执行任何生成操作之前,**必须**完整阅读以下文档。未阅读规范直接生成将导致输出不符合质量标准。
|
||||
IMPORTANT: Before any generation operation, read the following specification documents. Generating without understanding these standards will result in non-conforming output.
|
||||
|
||||
### 核心规范 (必读)
|
||||
### Core Specifications (Mandatory Read)
|
||||
|
||||
| Document | Purpose | Priority |
|
||||
|----------|---------|----------|
|
||||
| [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) | 通用设计规范 - 定义所有 Skill 的结构、命名、质量标准 | **P0 - 最高** |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | **参考文档生成规范** - 确保生成的skill中Reference Documents部分有正确的分阶段组织和使用时机指引 | **P0 - 最高** |
|
||||
| [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) | Universal design spec - defines structure, naming, quality standards for all Skills | **P0 - Critical** |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | Reference document generation spec - ensures generated Skills have proper phase-based Reference Documents with usage timing guidance | **P0 - Critical** |
|
||||
|
||||
### 模板文件 (生成前必读)
|
||||
### Template Files (Read Before Generation)
|
||||
|
||||
| Document | Purpose |
|
||||
|----------|---------|
|
||||
| [templates/skill-md.md](templates/skill-md.md) | SKILL.md 入口文件模板 |
|
||||
| [templates/sequential-phase.md](templates/sequential-phase.md) | Sequential Phase 模板 |
|
||||
| [templates/autonomous-orchestrator.md](templates/autonomous-orchestrator.md) | Autonomous 编排器模板 |
|
||||
| [templates/autonomous-action.md](templates/autonomous-action.md) | Autonomous Action 模板 |
|
||||
| [templates/code-analysis-action.md](templates/code-analysis-action.md) | 代码分析 Action 模板 |
|
||||
| [templates/llm-action.md](templates/llm-action.md) | LLM Action 模板 |
|
||||
| [templates/script-template.md](templates/script-template.md) | 统一脚本模板 (Bash + Python) |
|
||||
| [templates/skill-md.md](templates/skill-md.md) | SKILL.md entry file template |
|
||||
| [templates/sequential-phase.md](templates/sequential-phase.md) | Sequential Phase template |
|
||||
| [templates/autonomous-orchestrator.md](templates/autonomous-orchestrator.md) | Autonomous Orchestrator template |
|
||||
| [templates/autonomous-action.md](templates/autonomous-action.md) | Autonomous Action template |
|
||||
| [templates/code-analysis-action.md](templates/code-analysis-action.md) | Code Analysis Action template |
|
||||
| [templates/llm-action.md](templates/llm-action.md) | LLM Action template |
|
||||
| [templates/script-template.md](templates/script-template.md) | Unified Script Template (Bash + Python) |
|
||||
|
||||
### 规范文档 (按需阅读)
|
||||
### Specification Documents (Read as Needed)
|
||||
|
||||
| Document | Purpose |
|
||||
|----------|---------|
|
||||
| [specs/execution-modes.md](specs/execution-modes.md) | 执行模式规范 |
|
||||
| [specs/skill-requirements.md](specs/skill-requirements.md) | Skill 需求规范 |
|
||||
| [specs/cli-integration.md](specs/cli-integration.md) | CLI 集成规范 |
|
||||
| [specs/scripting-integration.md](specs/scripting-integration.md) | 脚本集成规范 |
|
||||
| [specs/execution-modes.md](specs/execution-modes.md) | Execution Modes Specification |
|
||||
| [specs/skill-requirements.md](specs/skill-requirements.md) | Skill Requirements Specification |
|
||||
| [specs/cli-integration.md](specs/cli-integration.md) | CLI Integration Specification |
|
||||
| [specs/scripting-integration.md](specs/scripting-integration.md) | Script Integration Specification |
|
||||
|
||||
### Phase 执行指南 (执行时参考)
|
||||
### Phase Execution Guides (Reference During Execution)
|
||||
|
||||
| Document | Purpose |
|
||||
|----------|---------|
|
||||
| [phases/01-requirements-discovery.md](phases/01-requirements-discovery.md) | 收集 Skill 需求 |
|
||||
| [phases/02-structure-generation.md](phases/02-structure-generation.md) | 生成目录结构 |
|
||||
| [phases/03-phase-generation.md](phases/03-phase-generation.md) | 生成 Phase 文件 |
|
||||
| [phases/04-specs-templates.md](phases/04-specs-templates.md) | 生成规范和模板 |
|
||||
| [phases/05-validation.md](phases/05-validation.md) | 验证和文档 |
|
||||
| [phases/01-requirements-discovery.md](phases/01-requirements-discovery.md) | Collect Skill Requirements |
|
||||
| [phases/02-structure-generation.md](phases/02-structure-generation.md) | Generate Directory Structure |
|
||||
| [phases/03-phase-generation.md](phases/03-phase-generation.md) | Generate Phase Files |
|
||||
| [phases/04-specs-templates.md](phases/04-specs-templates.md) | Generate Specs and Templates |
|
||||
| [phases/05-validation.md](phases/05-validation.md) | Validation and Documentation |
|
||||
|
||||
---
|
||||
|
||||
@@ -135,92 +133,73 @@ Phase 01 → Phase 02 → Phase 03 → ... → Phase N
|
||||
Input Parsing:
|
||||
└─ Convert user request to structured format (skill-name/purpose/mode)
|
||||
|
||||
Phase 0: Specification Study (⚠️ MANDATORY - 禁止跳过)
|
||||
└─ Read specification documents
|
||||
├─ Load: ../_shared/SKILL-DESIGN-SPEC.md
|
||||
├─ Load: All templates/*.md files
|
||||
├─ Understand: Structure rules, naming conventions, quality standards
|
||||
└─ Output: Internalized requirements (in-memory, no file output)
|
||||
└─ Validation: ⛔ MUST complete before Phase 1
|
||||
Phase 0: Specification Study (MANDATORY - Must complete before proceeding)
|
||||
- Read specification documents
|
||||
- Load: ../_shared/SKILL-DESIGN-SPEC.md
|
||||
- Load: All templates/*.md files
|
||||
- Understand: Structure rules, naming conventions, quality standards
|
||||
- Output: Internalized requirements (in-memory, no file output)
|
||||
- Validation: MUST complete before Phase 1
|
||||
|
||||
Phase 1: Requirements Discovery
|
||||
└─ Gather skill requirements via user interaction
|
||||
├─ Tool: AskUserQuestion
|
||||
│ ├─ Prompt: Skill name, purpose, execution mode
|
||||
│ ├─ Prompt: Phase/Action definition
|
||||
│ └─ Prompt: Tool dependencies, output format
|
||||
├─ Process: Generate configuration object
|
||||
└─ Output: skill-config.json → ${workDir}/
|
||||
├─ skill_name: string
|
||||
├─ execution_mode: "sequential" | "autonomous"
|
||||
├─ phases/actions: array
|
||||
└─ allowed_tools: array
|
||||
- Gather skill requirements via user interaction
|
||||
- Tool: AskUserQuestion
|
||||
- Collect: Skill name, purpose, execution mode
|
||||
- Collect: Phase/Action definition
|
||||
- Collect: Tool dependencies, output format
|
||||
- Process: Generate configuration object
|
||||
- Output: skill-config.json
|
||||
- Contains: skill_name, execution_mode, phases/actions, allowed_tools
|
||||
|
||||
Phase 2: Structure Generation
|
||||
└─ Create directory structure and entry file
|
||||
├─ Input: skill-config.json (from Phase 1)
|
||||
├─ Tool: Bash
|
||||
│ └─ Execute: mkdir -p .claude/skills/{skill-name}/{phases,specs,templates,scripts}
|
||||
├─ Tool: Write
|
||||
│ └─ Generate: SKILL.md (entry point with architecture diagram)
|
||||
└─ Output: Complete directory structure
|
||||
├─ .claude/skills/{skill-name}/SKILL.md
|
||||
├─ .claude/skills/{skill-name}/phases/
|
||||
├─ .claude/skills/{skill-name}/specs/
|
||||
├─ .claude/skills/{skill-name}/templates/
|
||||
└─ .claude/skills/{skill-name}/scripts/
|
||||
- Create directory structure and entry file
|
||||
- Input: skill-config.json (from Phase 1)
|
||||
- Tool: Bash
|
||||
- Execute: mkdir -p .claude/skills/{skill-name}/{phases,specs,templates,scripts}
|
||||
- Tool: Write
|
||||
- Generate: SKILL.md (entry point with architecture diagram)
|
||||
- Output: Complete directory structure
|
||||
|
||||
Phase 3: Phase/Action Generation
|
||||
└─ Decision (execution_mode check):
|
||||
├─ execution_mode === "sequential" → Generate Sequential Phases
|
||||
│ ├─ Tool: Read (template: templates/sequential-phase.md)
|
||||
│ ├─ Loop: For each phase in config.sequential_config.phases
|
||||
│ │ ├─ Generate: phases/{phase-id}.md
|
||||
│ │ └─ Link: Previous phase output → Current phase input
|
||||
│ ├─ Tool: Write (orchestrator: phases/_orchestrator.md)
|
||||
│ ├─ Tool: Write (workflow definition: workflow.json)
|
||||
│ └─ Output: phases/01-{name}.md, phases/02-{name}.md, ...
|
||||
│
|
||||
└─ execution_mode === "autonomous" → Generate Orchestrator + Actions
|
||||
├─ Tool: Read (template: templates/autonomous-orchestrator.md)
|
||||
├─ Tool: Write (state schema: phases/state-schema.md)
|
||||
├─ Tool: Write (orchestrator: phases/orchestrator.md)
|
||||
├─ Tool: Write (action catalog: specs/action-catalog.md)
|
||||
├─ Loop: For each action in config.autonomous_config.actions
|
||||
│ ├─ Tool: Read (template: templates/autonomous-action.md)
|
||||
│ └─ Generate: phases/actions/{action-id}.md
|
||||
└─ Output: phases/orchestrator.md, phases/actions/*.md
|
||||
- Decision (execution_mode check):
|
||||
- IF execution_mode === "sequential": Generate Sequential Phases
|
||||
- Read template: templates/sequential-phase.md
|
||||
- Loop: For each phase in config.sequential_config.phases
|
||||
- Generate: phases/{phase-id}.md
|
||||
- Link: Previous phase output -> Current phase input
|
||||
- Write: phases/_orchestrator.md
|
||||
- Write: workflow.json
|
||||
- Output: phases/01-{name}.md, phases/02-{name}.md, ...
|
||||
|
||||
- ELSE IF execution_mode === "autonomous": Generate Orchestrator + Actions
|
||||
- Read template: templates/autonomous-orchestrator.md
|
||||
- Write: phases/state-schema.md
|
||||
- Write: phases/orchestrator.md
|
||||
- Write: specs/action-catalog.md
|
||||
- Loop: For each action in config.autonomous_config.actions
|
||||
- Read template: templates/autonomous-action.md
|
||||
- Generate: phases/actions/{action-id}.md
|
||||
- Output: phases/orchestrator.md, phases/actions/*.md
|
||||
|
||||
Phase 4: Specs & Templates
|
||||
└─ Generate domain specifications and templates
|
||||
├─ Input: skill-config.json (domain context)
|
||||
├─ ⚠️ 参考规范: [specs/reference-docs-spec.md](specs/reference-docs-spec.md) - 确保生成的参考文档有正确的分阶段组织
|
||||
├─ Tool: Write
|
||||
│ ├─ Generate: specs/{domain}-requirements.md
|
||||
│ ├─ Generate: specs/quality-standards.md
|
||||
│ └─ Generate: templates/agent-base.md (if needed)
|
||||
└─ Output: Domain-specific documentation
|
||||
├─ specs/{skill-name}-requirements.md
|
||||
├─ specs/quality-standards.md
|
||||
└─ templates/agent-base.md
|
||||
- Generate domain specifications and templates
|
||||
- Input: skill-config.json (domain context)
|
||||
- Reference: [specs/reference-docs-spec.md](specs/reference-docs-spec.md) for document organization
|
||||
- Tool: Write
|
||||
- Generate: specs/{domain}-requirements.md
|
||||
- Generate: specs/quality-standards.md
|
||||
- Generate: templates/agent-base.md (if needed)
|
||||
- Output: Domain-specific documentation
|
||||
|
||||
Phase 5: Validation & Documentation
|
||||
└─ Verify completeness and generate usage guide
|
||||
├─ Input: All generated files from previous phases
|
||||
├─ Tool: Glob + Read
|
||||
│ └─ Check: Required files exist and contain proper structure
|
||||
├─ Tool: Write
|
||||
│ ├─ Generate: README.md (usage instructions)
|
||||
│ └─ Generate: validation-report.json (completeness check)
|
||||
└─ Output: Final documentation
|
||||
├─ README.md (how to use this skill)
|
||||
└─ validation-report.json (quality gate results)
|
||||
|
||||
Return:
|
||||
└─ Summary with skill location and next steps
|
||||
├─ Skill path: .claude/skills/{skill-name}/
|
||||
├─ Status: ✅ All phases completed
|
||||
└─ Suggestion: "Review SKILL.md and customize phase files as needed"
|
||||
- Verify completeness and generate usage guide
|
||||
- Input: All generated files from previous phases
|
||||
- Tool: Glob + Read
|
||||
- Check: Required files exist and contain proper structure
|
||||
- Tool: Write
|
||||
- Generate: README.md (usage instructions)
|
||||
- Generate: validation-report.json (completeness check)
|
||||
- Output: Final documentation
|
||||
```
|
||||
|
||||
**Execution Protocol**:
|
||||
@@ -278,83 +257,83 @@ Write(`${skillDir}/README.md`, generateReadme(config, validation));
|
||||
|
||||
## Reference Documents by Phase
|
||||
|
||||
> **重要**: 本部分展示skill-generator如何组织自己的参考文档,这是生成的skill应该模仿的示例。详见 [specs/reference-docs-spec.md](specs/reference-docs-spec.md)
|
||||
IMPORTANT: This section demonstrates how skill-generator organizes its own reference documentation. This is the pattern that all generated Skills should emulate. See [specs/reference-docs-spec.md](specs/reference-docs-spec.md) for details.
|
||||
|
||||
### 🔧 Phase 0: Specification Study (强制前置)
|
||||
### Phase 0: Specification Study (Mandatory Prerequisites)
|
||||
|
||||
所有生成操作前必须阅读的规范
|
||||
Specification documents that must be read before any generation operation
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) | Skill设计通用规范 | 理解Skill结构和命名规范 ✅ **必读** |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | 参考文档生成规范 | 确保Reference Documents有正确的组织方式 ✅ **必读** |
|
||||
| [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) | Universal Skill design specification | Understand Skill structure and naming conventions - **REQUIRED** |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | Reference document generation specification | Ensure Reference Documents have proper phase-based organization - **REQUIRED** |
|
||||
|
||||
### 📋 Phase 1: Requirements Discovery
|
||||
### Phase 1: Requirements Discovery
|
||||
|
||||
收集Skill需求和配置
|
||||
Collect Skill requirements and configuration
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/01-requirements-discovery.md](phases/01-requirements-discovery.md) | Phase 1执行指南 | 理解如何收集用户需求和生成配置 |
|
||||
| [specs/skill-requirements.md](specs/skill-requirements.md) | Skill需求规范 | 理解Skill应包含哪些信息 |
|
||||
| [phases/01-requirements-discovery.md](phases/01-requirements-discovery.md) | Phase 1 execution guide | Understand how to collect user requirements and generate configuration |
|
||||
| [specs/skill-requirements.md](specs/skill-requirements.md) | Skill requirements specification | Understand what information a Skill should contain |
|
||||
|
||||
### 🔧 Phase 2: Structure Generation
|
||||
### Phase 2: Structure Generation
|
||||
|
||||
生成目录结构和入口文件
|
||||
Generate directory structure and entry file
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/02-structure-generation.md](phases/02-structure-generation.md) | Phase 2执行指南 | 理解如何生成目录结构 |
|
||||
| [templates/skill-md.md](templates/skill-md.md) | SKILL.md模板 | 了解如何生成入口文件 |
|
||||
| [phases/02-structure-generation.md](phases/02-structure-generation.md) | Phase 2 execution guide | Understand how to generate directory structure |
|
||||
| [templates/skill-md.md](templates/skill-md.md) | SKILL.md template | Learn how to generate the entry file |
|
||||
|
||||
### ⚙️ Phase 3: Phase/Action Generation
|
||||
### Phase 3: Phase/Action Generation
|
||||
|
||||
根据执行模式生成具体的phase或action文件
|
||||
Generate specific phase or action files based on execution mode
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/03-phase-generation.md](phases/03-phase-generation.md) | Phase 3执行指南 | 理解Sequential vs Autonomous生成逻辑 |
|
||||
| [templates/sequential-phase.md](templates/sequential-phase.md) | Sequential Phase模板 | 生成Sequential模式的phase文件 |
|
||||
| [templates/autonomous-orchestrator.md](templates/autonomous-orchestrator.md) | Orchestrator模板 | 生成Autonomous模式的编排器 |
|
||||
| [templates/autonomous-action.md](templates/autonomous-action.md) | Action模板 | 生成Autonomous模式的action |
|
||||
| [phases/03-phase-generation.md](phases/03-phase-generation.md) | Phase 3 execution guide | Understand Sequential vs Autonomous generation logic |
|
||||
| [templates/sequential-phase.md](templates/sequential-phase.md) | Sequential Phase template | Generate phase files for Sequential mode |
|
||||
| [templates/autonomous-orchestrator.md](templates/autonomous-orchestrator.md) | Orchestrator template | Generate orchestrator for Autonomous mode |
|
||||
| [templates/autonomous-action.md](templates/autonomous-action.md) | Action template | Generate action files for Autonomous mode |
|
||||
|
||||
### ✅ Phase 4: Specs & Templates
|
||||
### Phase 4: Specs & Templates
|
||||
|
||||
生成领域特定的规范和模板
|
||||
Generate domain-specific specifications and templates
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/04-specs-templates.md](phases/04-specs-templates.md) | Phase 4执行指南 | 理解如何生成domain-specific文档 |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | 参考文档规范 | ⭐ 生成Specs时要遵循的规范 |
|
||||
| [phases/04-specs-templates.md](phases/04-specs-templates.md) | Phase 4 execution guide | Understand how to generate domain-specific documentation |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | Reference document specification | IMPORTANT: Follow this spec when generating Specs |
|
||||
|
||||
### 🏁 Phase 5: Validation & Documentation
|
||||
### Phase 5: Validation & Documentation
|
||||
|
||||
验证生成结果并生成最终文档
|
||||
Verify results and generate final documentation
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/05-validation.md](phases/05-validation.md) | Phase 5执行指南 | 理解如何验证生成的skill完整性 |
|
||||
| [phases/05-validation.md](phases/05-validation.md) | Phase 5 execution guide | Understand how to verify generated Skill completeness |
|
||||
|
||||
### 🔍 Debugging & Troubleshooting
|
||||
### Debugging & Troubleshooting
|
||||
|
||||
遇到问题时查阅
|
||||
Reference documents when encountering issues
|
||||
|
||||
| Issue | Solution Document |
|
||||
|-------|------------------|
|
||||
| 生成的Skill缺少Reference Documents | [specs/reference-docs-spec.md](specs/reference-docs-spec.md) - 检查是否遵循分阶段组织 |
|
||||
| 参考文档组织混乱 | [specs/reference-docs-spec.md](specs/reference-docs-spec.md) - 核心原则部分 |
|
||||
| 生成的文档不符合质量标准 | [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) |
|
||||
| Generated Skill missing Reference Documents | [specs/reference-docs-spec.md](specs/reference-docs-spec.md) - verify phase-based organization is followed |
|
||||
| Reference document organization unclear | [specs/reference-docs-spec.md](specs/reference-docs-spec.md) - Core Principles section |
|
||||
| Generated documentation does not meet quality standards | [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) |
|
||||
|
||||
### 📚 Reference & Background
|
||||
### Reference & Background
|
||||
|
||||
用于深度学习和设计决策
|
||||
Documents for deep learning and design decisions
|
||||
|
||||
| Document | Purpose | Notes |
|
||||
|----------|---------|-------|
|
||||
| [specs/execution-modes.md](specs/execution-modes.md) | 执行模式详细规范 | Sequential vs Autonomous的对比和适用场景 |
|
||||
| [specs/cli-integration.md](specs/cli-integration.md) | CLI集成规范 | 生成的Skill如何与CLI集成 |
|
||||
| [specs/scripting-integration.md](specs/scripting-integration.md) | 脚本集成规范 | Phase中如何使用脚本 |
|
||||
| [templates/script-template.md](templates/script-template.md) | 脚本模板 | Bash + Python统一模板 |
|
||||
| [specs/execution-modes.md](specs/execution-modes.md) | Detailed execution modes specification | Comparison and use cases for Sequential vs Autonomous |
|
||||
| [specs/cli-integration.md](specs/cli-integration.md) | CLI integration specification | How generated Skills integrate with CLI |
|
||||
| [specs/scripting-integration.md](specs/scripting-integration.md) | Script integration specification | How to use scripts in Phases |
|
||||
| [templates/script-template.md](templates/script-template.md) | Script template | Unified Bash + Python template |
|
||||
|
||||
---
|
||||
|
||||
@@ -364,13 +343,13 @@ Write(`${skillDir}/README.md`, generateReadme(config, validation));
|
||||
|
||||
```
|
||||
.claude/skills/{skill-name}/
|
||||
├── SKILL.md # 入口文件
|
||||
├── SKILL.md # Entry file
|
||||
├── phases/
|
||||
│ ├── _orchestrator.md # 声明式编排器
|
||||
│ ├── workflow.json # 工作流定义
|
||||
│ ├── 01-{step-one}.md # 阶段 1
|
||||
│ ├── 02-{step-two}.md # 阶段 2
|
||||
│ └── 03-{step-three}.md # 阶段 3
|
||||
│ ├── _orchestrator.md # Declarative orchestrator
|
||||
│ ├── workflow.json # Workflow definition
|
||||
│ ├── 01-{step-one}.md # Phase 1
|
||||
│ ├── 02-{step-two}.md # Phase 2
|
||||
│ └── 03-{step-three}.md # Phase 3
|
||||
├── specs/
|
||||
│ ├── {skill-name}-requirements.md
|
||||
│ └── quality-standards.md
|
||||
@@ -384,10 +363,10 @@ Write(`${skillDir}/README.md`, generateReadme(config, validation));
|
||||
|
||||
```
|
||||
.claude/skills/{skill-name}/
|
||||
├── SKILL.md # 入口文件
|
||||
├── SKILL.md # Entry file
|
||||
├── phases/
|
||||
│ ├── orchestrator.md # 编排器 (状态驱动)
|
||||
│ ├── state-schema.md # 状态结构定义
|
||||
│ ├── orchestrator.md # Orchestrator (state-driven)
|
||||
│ ├── state-schema.md # State schema definition
|
||||
│ └── actions/
|
||||
│ ├── action-init.md
|
||||
│ ├── action-create.md
|
||||
@@ -407,80 +386,80 @@ Write(`${skillDir}/README.md`, generateReadme(config, validation));
|
||||
|
||||
## Reference Documents by Phase
|
||||
|
||||
> **重要**: 本部分展示skill-generator如何组织自己的参考文档,这是生成的skill应该模仿的示例。详见 [specs/reference-docs-spec.md](specs/reference-docs-spec.md)
|
||||
IMPORTANT: This section demonstrates how skill-generator organizes its own reference documentation. This is the pattern that all generated Skills should emulate. See [specs/reference-docs-spec.md](specs/reference-docs-spec.md) for details.
|
||||
|
||||
### 🔧 Phase 0: Specification Study (强制前置)
|
||||
### Phase 0: Specification Study (Mandatory Prerequisites)
|
||||
|
||||
所有生成操作前必须阅读的规范
|
||||
Specification documents that must be read before any generation operation
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) | Skill设计通用规范 | 理解Skill结构和命名规范 ✅ **必读** |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | 参考文档生成规范 | 确保Reference Documents有正确的组织方式 ✅ **必读** |
|
||||
| [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) | Universal Skill design specification | Understand Skill structure and naming conventions - **REQUIRED** |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | Reference document generation specification | Ensure Reference Documents have proper phase-based organization - **REQUIRED** |
|
||||
|
||||
### 📋 Phase 1: Requirements Discovery
|
||||
### Phase 1: Requirements Discovery
|
||||
|
||||
收集Skill需求和配置
|
||||
Collect Skill requirements and configuration
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/01-requirements-discovery.md](phases/01-requirements-discovery.md) | Phase 1执行指南 | 理解如何收集用户需求和生成配置 |
|
||||
| [specs/skill-requirements.md](specs/skill-requirements.md) | Skill需求规范 | 理解Skill应包含哪些信息 |
|
||||
| [phases/01-requirements-discovery.md](phases/01-requirements-discovery.md) | Phase 1 execution guide | Understand how to collect user requirements and generate configuration |
|
||||
| [specs/skill-requirements.md](specs/skill-requirements.md) | Skill requirements specification | Understand what information a Skill should contain |
|
||||
|
||||
### 🔧 Phase 2: Structure Generation
|
||||
### Phase 2: Structure Generation
|
||||
|
||||
生成目录结构和入口文件
|
||||
Generate directory structure and entry file
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/02-structure-generation.md](phases/02-structure-generation.md) | Phase 2执行指南 | 理解如何生成目录结构 |
|
||||
| [templates/skill-md.md](templates/skill-md.md) | SKILL.md模板 | 了解如何生成入口文件 |
|
||||
| [phases/02-structure-generation.md](phases/02-structure-generation.md) | Phase 2 execution guide | Understand how to generate directory structure |
|
||||
| [templates/skill-md.md](templates/skill-md.md) | SKILL.md template | Learn how to generate the entry file |
|
||||
|
||||
### ⚙️ Phase 3: Phase/Action Generation
|
||||
### Phase 3: Phase/Action Generation
|
||||
|
||||
根据执行模式生成具体的phase或action文件
|
||||
Generate specific phase or action files based on execution mode
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/03-phase-generation.md](phases/03-phase-generation.md) | Phase 3执行指南 | 理解Sequential vs Autonomous生成逻辑 |
|
||||
| [templates/sequential-phase.md](templates/sequential-phase.md) | Sequential Phase模板 | 生成Sequential模式的phase文件 |
|
||||
| [templates/autonomous-orchestrator.md](templates/autonomous-orchestrator.md) | Orchestrator模板 | 生成Autonomous模式的编排器 |
|
||||
| [templates/autonomous-action.md](templates/autonomous-action.md) | Action模板 | 生成Autonomous模式的action |
|
||||
| [phases/03-phase-generation.md](phases/03-phase-generation.md) | Phase 3 execution guide | Understand Sequential vs Autonomous generation logic |
|
||||
| [templates/sequential-phase.md](templates/sequential-phase.md) | Sequential Phase template | Generate phase files for Sequential mode |
|
||||
| [templates/autonomous-orchestrator.md](templates/autonomous-orchestrator.md) | Orchestrator template | Generate orchestrator for Autonomous mode |
|
||||
| [templates/autonomous-action.md](templates/autonomous-action.md) | Action template | Generate action files for Autonomous mode |
|
||||
|
||||
### ✅ Phase 4: Specs & Templates
|
||||
### Phase 4: Specs & Templates
|
||||
|
||||
生成领域特定的规范和模板
|
||||
Generate domain-specific specifications and templates
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/04-specs-templates.md](phases/04-specs-templates.md) | Phase 4执行指南 | 理解如何生成domain-specific文档 |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | 参考文档规范 | ⭐ 生成Specs时要遵循的规范 |
|
||||
| [phases/04-specs-templates.md](phases/04-specs-templates.md) | Phase 4 execution guide | Understand how to generate domain-specific documentation |
|
||||
| [specs/reference-docs-spec.md](specs/reference-docs-spec.md) | Reference document specification | IMPORTANT: Follow this spec when generating Specs |
|
||||
|
||||
### 🏁 Phase 5: Validation & Documentation
|
||||
### Phase 5: Validation & Documentation
|
||||
|
||||
验证生成结果并生成最终文档
|
||||
Verify results and generate final documentation
|
||||
|
||||
| Document | Purpose | When to Use |
|
||||
|----------|---------|-------------|
|
||||
| [phases/05-validation.md](phases/05-validation.md) | Phase 5执行指南 | 理解如何验证生成的skill完整性 |
|
||||
| [phases/05-validation.md](phases/05-validation.md) | Phase 5 execution guide | Understand how to verify generated Skill completeness |
|
||||
|
||||
### 🔍 Debugging & Troubleshooting
|
||||
### Debugging & Troubleshooting
|
||||
|
||||
遇到问题时查阅
|
||||
Reference documents when encountering issues
|
||||
|
||||
| Issue | Solution Document |
|
||||
|-------|------------------|
|
||||
| 生成的Skill缺少Reference Documents | [specs/reference-docs-spec.md](specs/reference-docs-spec.md) - 检查是否遵循分阶段组织 |
|
||||
| 参考文档组织混乱 | [specs/reference-docs-spec.md](specs/reference-docs-spec.md) - 核心原则部分 |
|
||||
| 生成的文档不符合质量标准 | [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) |
|
||||
| Generated Skill missing Reference Documents | [specs/reference-docs-spec.md](specs/reference-docs-spec.md) - verify phase-based organization is followed |
|
||||
| Reference document organization unclear | [specs/reference-docs-spec.md](specs/reference-docs-spec.md) - Core Principles section |
|
||||
| Generated documentation does not meet quality standards | [../_shared/SKILL-DESIGN-SPEC.md](../_shared/SKILL-DESIGN-SPEC.md) |
|
||||
|
||||
### 📚 Reference & Background
|
||||
### Reference & Background
|
||||
|
||||
用于深度学习和设计决策
|
||||
Documents for deep learning and design decisions
|
||||
|
||||
| Document | Purpose | Notes |
|
||||
|----------|---------|-------|
|
||||
| [specs/execution-modes.md](specs/execution-modes.md) | 执行模式详细规范 | Sequential vs Autonomous的对比和适用场景 |
|
||||
| [specs/cli-integration.md](specs/cli-integration.md) | CLI集成规范 | 生成的Skill如何与CLI集成 |
|
||||
| [specs/scripting-integration.md](specs/scripting-integration.md) | 脚本集成规范 | Phase中如何使用脚本 |
|
||||
| [templates/script-template.md](templates/script-template.md) | 脚本模板 | Bash + Python统一模板 |
|
||||
| [specs/execution-modes.md](specs/execution-modes.md) | Detailed execution modes specification | Comparison and use cases for Sequential vs Autonomous |
|
||||
| [specs/cli-integration.md](specs/cli-integration.md) | CLI integration specification | How generated Skills integrate with CLI |
|
||||
| [specs/scripting-integration.md](specs/scripting-integration.md) | Script integration specification | How to use scripts in Phases |
|
||||
| [templates/script-template.md](templates/script-template.md) | Script template | Unified Bash + Python template |
|
||||
Reference in New Issue
Block a user