Loading...
Loading...
Compare original and translation side by side
$description$descriptionAskUserQuestionAskUserQuestion.claude/skills/<name>/SKILL.md~/.claude/skills/<name>/SKILL.md.claude/skills/<name>/SKILL.md~/.claude/skills/<name>/SKILL.mdAskUserQuestionAskUserQuestion---
name: {{skill-name}}
description: {{one-line description}}
allowed-tools:
{{list of tool permission patterns observed during session}}
when_to_use: {{detailed description of when Claude should automatically invoke this skill, including trigger phrases and example user messages}}
argument-hint: "{{hint showing argument placeholders}}"
arguments:
{{list of argument names}}
context: {{inline or fork -- omit for inline}}
------
name: {{skill-name}}
description: {{one-line description}}
allowed-tools:
{{list of tool permission patterns observed during session}}
when_to_use: {{detailed description of when Claude should automatically invoke this skill, including trigger phrases and example user messages}}
argument-hint: "{{hint showing argument placeholders}}"
arguments:
{{list of argument names}}
context: {{inline or fork -- omit for inline}}
---$arg_name$arg_name
**Per-step annotations** (include where relevant):
- **Success criteria** is REQUIRED on every step.
- **Execution**: `Direct` (default), `Task agent` (straightforward subagents), `Teammate` (agent with true parallelism and inter-agent communication), or `[human]` (user does it). Only needs specifying if not Direct.
- **Artifacts**: Data this step produces that later steps need (e.g., PR number, commit SHA). Only include if later steps depend on it.
- **Human checkpoint**: When to pause and ask the user before proceeding. Include for irreversible actions (merging, sending messages), error judgment (merge conflicts), or output review.
- **Rules**: Hard rules for the workflow. User corrections during the reference session can be especially useful here.
**Step structure tips:**
- Steps that can run concurrently use sub-numbers: 3a, 3b
- Steps requiring the user to act get `[human]` in the title
- Keep simple skills simple -- a 2-step skill doesn't need annotations on every step
**Frontmatter rules:**
- `allowed-tools`: Minimum permissions needed (use patterns like `Bash(gh:*)` not `Bash`)
- `context`: Only set `context: fork` for self-contained skills that don't need mid-process user input.
- `when_to_use` is CRITICAL -- tells the model when to auto-invoke. Start with "Use when..." and include trigger phrases.
- `arguments` and `argument-hint`: Only include if the skill takes parameters. Use `$name` in the body for substitution.
**Success criteria**: The complete SKILL.md content has been drafted.
**每步注解**(相关场景下需要包含):
- **Success criteria** 是每个步骤的必填项,用于说明步骤已完成可以进入下一步,可以是列表形式。
- **Execution**:`Direct`(默认)、`Task agent`(简单子Agent)、`Teammate`(支持真正并行和Agent间通信的Agent)、或`[human]`(用户手动执行),非Direct模式才需要指定。
- **Artifacts**:该步骤产生的、后续步骤需要依赖的数据(例如PR编号、commit SHA),仅当后续步骤有依赖时需要包含。
- **Human checkpoint**:需要暂停并询问用户确认再继续的节点,不可逆动作(合并、发消息)、错误判断(合并冲突)或输出审核场景需要包含。
- **Rules**:工作流的硬性规则,参考会话过程中用户的纠正内容会非常有用。
**步骤结构提示**:
- 可以并行运行的步骤使用子编号:3a、3b
- 需要用户执行的步骤在标题中添加`[human]`
- 简单技能保持简洁——2步的技能不需要每个步骤都加注解
**前置元数据规则**:
- `allowed-tools`:需要的最小权限(使用类似`Bash(gh:*)`的模式,不要直接写`Bash`)
- `context`:仅当技能是不需要流程中用户输入的独立任务时,才设置`context: fork`
- `when_to_use` 是核心字段——告诉模型什么时候自动调用该技能,以「Use when...」开头,包含触发短语。
- `arguments` 和 `argument-hint`:仅当技能需要接收参数时包含,在正文中使用`$name`进行变量替换。
**成功标准**:完整的SKILL.md内容已起草完成。AskUserQuestion/{{skill-name}} [arguments]AskUserQuestion/{{skill-name}} [arguments]