AgentSkillsCN

task-protocol

为 Open Artel 项目制定标准化的任务简报格式与生命周期。明确必填字段、生命周期状态、验收标准规则,以及命名规范。

SKILL.md
--- frontmatter
name: task-protocol
description: Standard task brief format and lifecycle for Open Artel projects. Defines required fields, lifecycle states, acceptance criteria rules, and naming conventions.

Task Brief Format

Every task brief is a markdown file in .ai/tasks/ following this structure:

markdown
## TASK-XXX: [Short descriptive name]

- **Status**: [PENDING | IN_PROGRESS | REVIEW | DONE | BLOCKED]
- **Priority**: [P0-Critical | P1-High | P2-Medium | P3-Low]
- **Type**: [Create | Improve | Fix | Research]
- **Depends on**: [TASK-XXX | none]
- **Blocks**: [TASK-XXX | none]

### Context
[What exists currently, what prompted this task, relevant files]

### Objective
[Specific measurable goal — what "done" looks like]

### Scope
- [File or template area affected]
- [What's in bounds]
- [What's explicitly out of bounds]

### Acceptance Criteria
- [ ] [Testable criterion 1]
- [ ] [Testable criterion 2]
- [ ] Changes are consistent with existing conventions
- [ ] No regressions in other templates

### Notes
[Design decisions, alternatives considered, open questions]

The template is at .ai/templates/task.md.

Required Fields

FieldValuesRequired
StatusPENDING, IN_PROGRESS, REVIEW, DONE, BLOCKEDYes
PriorityP0-Critical, P1-High, P2-Medium, P3-LowYes
TypeCreate, Improve, Fix, ResearchYes
Depends onTASK-XXX or noneYes
BlocksTASK-XXX or noneYes
ContextFree textYes
ObjectiveFree textYes
ScopeBullet listYes
Acceptance CriteriaCheckbox listYes

Task Lifecycle

code
PENDING → IN_PROGRESS → REVIEW → DONE
    ↓                      ↓
  BLOCKED              BLOCKED
    ↓                      ↓
(unblocked)         (feedback addressed)
    ↓                      ↓
IN_PROGRESS            REVIEW → DONE

State Transitions

FromToTrigger
PENDINGIN_PROGRESSAgent begins work
PENDINGBLOCKEDDependency not met
IN_PROGRESSREVIEWAgent commits [ACTION:submit]
IN_PROGRESSBLOCKEDUnexpected blocker discovered
REVIEWDONEReviewer commits [ACTION:approve]
REVIEWIN_PROGRESSReviewer commits [ACTION:reject] — agent addresses feedback
BLOCKEDPENDINGBlocker resolved
BLOCKEDIN_PROGRESSBlocker resolved and agent resumes

Task Naming Convention

PatternExample
TASK-XXX (numeric)TASK-001, TASK-002
TASK-DESCRIPTIVE-NAME (named)TASK-GATEWAY-CLIENT
TASK-<PHASE>-<NUMBER> (phased)TASK-P4-01, TASK-P4-02
TASK-<AGENT>-<NUMBER> (agent-scoped)TASK-LOVABLE-001

File naming: TASK-XXX.md in .ai/tasks/.

Acceptance Criteria Rules

  1. Every criterion must be independently testable — no vague "works correctly"
  2. "Build passes" is always included — for projects with a build step
  3. Boundary compliance is always checked — agent must not modify files outside their domain
  4. Commit format compliance — commits must use [AGENT:x] [ACTION:y] [TASK:z] format
  5. No regressions — existing functionality must not break
  6. Criteria are checkboxes — use - [ ] format for tracking

Priority Definitions

PriorityMeaningResponse Time
P0-CriticalSystem broken, blocking all workImmediate
P1-HighImportant feature or fix, current sprintSame sprint
P2-MediumImprovement, next sprint candidateNext sprint
P3-LowNice to have, backlogWhen capacity allows

Task Decomposition Guidelines

When breaking down work into tasks:

  1. One task per agent — avoid tasks that require multiple agents
  2. Clear boundaries — specify exactly which files are in scope
  3. Testable outcomes — every task has measurable acceptance criteria
  4. Dependency chains — document what blocks what
  5. Size limit — a task should be completable in one work session
  6. Context included — provide enough context that the agent can work independently