Back to Skills

odin-executor

verified

执行 ODIN 计划中的具体任务。负责读取下一个待执行任务、阅读文档并执行代码实现、更新任务状态。 由 odin-task-executor skill 调用,用户不应直接使用。

View on GitHub

Marketplace

cc-plugins

GmwEnterprise/cc-plugins

Plugin

odin

Repository

GmwEnterprise/cc-plugins

plugins/odin/skills/odin-executor/SKILL.md

Last Verified

January 23, 2026

Install Skill

Select agents to install to:

Scope:
npx add-skill https://github.com/GmwEnterprise/cc-plugins/blob/main/plugins/odin/skills/odin-executor/SKILL.md -a claude-code --skill odin-executor

Installation paths:

Claude
.claude/skills/odin-executor/
Powered by add-skill CLI

Instructions

## 职责

执行 odin-plan 创建的具体开发任务。

## 输入参数

- **plan.yml 路径**:odin-plan 生成的计划文件路径

## 工作流程

### 1. 读取下一个任务

使用 `scripts/read-odin-task.py` 脚本读取下一个待执行的任务。

**执行脚本**:
```bash
python3 scripts/read-odin-task.py <plan.yml>
```

脚本返回的任务信息包括:
- `plan_dir`: 计划目录路径
- `description_path`: description.md 路径
- `task_id`: 任务 ID(如 01-create-model)
- `task_detail_path`: 任务详细文档路径
- `files`: 涉及的文件变更信息(add/modify/delete)

**如果没有待执行的任务**:
- 输出提示信息:所有任务已完成
- 结束流程

### 2. 阅读任务文档

先读取 `description.md` 了解整体目标和背景,然后读取任务详细文档了解具体要求:

使用 Read 工具读取文档:
```
Read <description_path>
Read <task_detail_path>
```

### 3. 执行任务步骤

按照任务详细文档中的步骤执行任务。

**执行原则**:
- 遵循项目现有的代码风格和架构模式
- 严格按照任务文档中的步骤执行
- 完成后根据验证标准确认任务完成

**注意事项**:
- 只执行当前任务,不要跳到其他任务
- 如果需求不够清晰,向用户询问
- 确保代码可以正常工作

### 4. 更新任务状态

任务执行完成后,使用 `scripts/update-odin-task.py` 脚本更新状态:

```bash
python3 scripts/update-odin-task.py <plan.yml> <task-id>
```

### 5. 返回执行结果

向调用方返回执行结果摘要,包括:
- 任务 ID
- 完成的具体工作
- 遇到的问题(如有)
- 相关文件变更

## 任务状态说明

- **finished: false**: 未完成的任务
- **finished: true**: 已完成的任务

## 注意事项

- **按序执行**:按序号从上往下依次执行任务
- **状态一致**:执行前先读取任务,执行后立即更新状态
- **验证完成**:根据任务文档中的验证标准确认任务已完成
- **及时报告**:执行过程中及时报告进度和遇到的问题

## 可用脚本

该 skill 提供以下 Python 脚本,通过 Bash 工具调用:

- **scripts/read-odin-task.py**: 读取下一个待执行任务
- **scripts/update-odin-task.py**: 更新任务完成状态
- **scripts/odin_common.py**: 共享工具模块(YAML 处理、任务查找等)

Validation Details

Front Matter
Required Fields
Valid Name Format
Valid Description
Has Sections
Allowed Tools
Instruction Length:
1303 chars