skill-pipeline
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseSkill Pipeline
技能Pipeline
The conductor, not a player. This skill classifies tasks, selects the pipeline variant, calibrates depth, and orchestrates handoffs between skills. It produces no artifacts of its own — its output is routing decisions that activate other skills.
它是指挥者,而非执行者。该技能负责对任务分类、选择Pipeline变体、校准执行深度,并且协调各个技能之间的交接。它本身不会生成任何产物——输出内容是用于激活其他技能的路由决策。
Task Classification
任务分类
On every coding task, classify before acting. Evaluate scope signals and map to a task class.
Input signals: file count, task description, existing plan/handoff files, batch indicators, CI environment.
Task received
│
├─ Trivial (typo, rename, version bump)
│ → No skills. Just do it.
│
├─ Small (isolated fix, single-file, <10 logic lines)
│ → simplify-and-harden only (post-completion)
│
├─ Medium (feature in known area, 2-5 files)
│ → intent-framed-agent + simplify-and-harden
│
├─ Large (complex refactor, new architecture, unfamiliar codebase, high-risk logic)
│ → Full standard pipeline
│ → Recommend /plan-interview before starting
│
├─ Long-running (multi-session, high context pressure, prior handoff exists)
│ → Full standard pipeline with context-surfing as critical skill
│
└─ Batch (multiple features from spec, 5+ discrete tasks, issue triage)
→ Team-based pipeline (agent-teams-simplify-and-harden)When uncertain, start with Medium. Add skills if drift or quality issues appear mid-task.
For detailed heuristics, edge cases, and examples: read .
references/classification-rules.md处理任何编码任务时,都要先分类再执行。评估范围信号并映射到对应的任务类别。
输入信号: 文件数量、任务描述、已有的计划/交接文件、批量标识、CI环境。
Task received
│
├─ Trivial (typo, rename, version bump)
│ → No skills. Just do it.
│
├─ Small (isolated fix, single-file, <10 logic lines)
│ → simplify-and-harden only (post-completion)
│
├─ Medium (feature in known area, 2-5 files)
│ → intent-framed-agent + simplify-and-harden
│
├─ Large (complex refactor, new architecture, unfamiliar codebase, high-risk logic)
│ → Full standard pipeline
│ → Recommend /plan-interview before starting
│
├─ Long-running (multi-session, high context pressure, prior handoff exists)
│ → Full standard pipeline with context-surfing as critical skill
│
└─ Batch (multiple features from spec, 5+ discrete tasks, issue triage)
→ Team-based pipeline (agent-teams-simplify-and-harden)如果无法确定分类,先按中等任务处理。如果任务执行过程中出现范围偏移或质量问题,可补充对应技能。
如需了解详细的启发式规则、边界场景和示例,请阅读。
references/classification-rules.mdPipeline Selection
Pipeline选择
Route task class to the right variant:
| Task Class | Variant | Rationale |
|---|---|---|
| Trivial | None | No overhead needed |
| Small | Standard (minimal) | S&H only |
| Medium | Standard (partial) | Scope monitoring + review |
| Large | Standard (full) | Full depth with planning |
| Long-running | Standard (full) | Context-surfing is critical |
| Batch | Team-based | Breadth over depth |
| CI environment | CI | Headless review |
Heuristic: Standard pipeline for depth (single complex feature). Team-based pipeline for breadth (batch of tasks). CI pipeline when or .
CI=trueGITHUB_ACTIONS=true将任务类别匹配到合适的变体:
| 任务类别 | 变体 | 设计逻辑 |
|---|---|---|
| 琐碎任务 | 无 | 不需要额外开销 |
| 小任务 | 标准型(最小配置) | 仅启用S&H |
| 中等任务 | 标准型(部分配置) | 范围监控 + 评审 |
| 大型任务 | 标准型(全量配置) | 带规划的全深度执行 |
| 长周期任务 | 标准型(全量配置) | context-surfing为核心能力 |
| 批量任务 | 团队协作型 | 优先覆盖广度而非深度 |
| CI环境 | CI型 | 无界面评审 |
启发式规则: 标准Pipeline适用于要求「深度」的场景(单个复杂功能),团队协作型Pipeline适用于要求「广度」的场景(批量任务),当环境变量或时使用CI Pipeline。
CI=trueGITHUB_ACTIONS=trueActivation Sequences
激活顺序
Standard Pipeline
标准Pipeline
classify
→ (recommend /plan-interview if Large or Long-running)
→ intent-framed-agent (at planning-to-execution transition)
→ context-surfing (auto-activates when intent frame + plan exist; concurrent with intent monitoring)
→ [IMPLEMENTATION]
→ simplify-and-harden (post-completion, if non-trivial diff)
→ self-improvement (on errors, corrections, or S&H learning candidates)Skill-by-class activation:
| Skill | Trivial | Small | Medium | Large | Long-running |
|---|---|---|---|---|---|
| plan-interview | - | - | - | Recommend | Recommend |
| intent-framed-agent | - | - | Activate | Activate | Activate |
| context-surfing | - | - | - | Activate | Critical |
| simplify-and-harden | - | If non-trivial | If non-trivial | If non-trivial | If non-trivial |
| self-improvement | On error only | On error only | On error/completion | On error/completion | On error/completion |
classify
→ (recommend /plan-interview if Large or Long-running)
→ intent-framed-agent (at planning-to-execution transition)
→ context-surfing (auto-activates when intent frame + plan exist; concurrent with intent monitoring)
→ [IMPLEMENTATION]
→ simplify-and-harden (post-completion, if non-trivial diff)
→ self-improvement (on errors, corrections, or S&H learning candidates)按任务类别的技能激活规则:
| 技能 | 琐碎任务 | 小任务 | 中等任务 | 大型任务 | 长周期任务 |
|---|---|---|---|---|---|
| plan-interview | - | - | - | 推荐 | 推荐 |
| intent-framed-agent | - | - | 激活 | 激活 | 激活 |
| context-surfing | - | - | - | 激活 | 核心必备 |
| simplify-and-harden | - | 非平凡变更时启用 | 非平凡变更时启用 | 非平凡变更时启用 | 非平凡变更时启用 |
| self-improvement | 仅出错时启用 | 仅出错时启用 | 出错/完成时启用 | 出错/完成时启用 | 出错/完成时启用 |
Team-Based Pipeline
团队协作型Pipeline
classify (Batch)
→ (recommend /plan-interview if no spec exists)
→ agent-teams-simplify-and-harden
├─ Team lead emits Intent Frame #1
├─ Phase 1: parallel implementation agents
├─ Compile + test verification
├─ Phase 2: parallel audit agents (simplify, harden, spec)
├─ Fix loop (up to 3 audit rounds)
└─ Learning loop output
→ self-improvementclassify (Batch)
→ (recommend /plan-interview if no spec exists)
→ agent-teams-simplify-and-harden
├─ Team lead emits Intent Frame #1
├─ Phase 1: parallel implementation agents
├─ Compile + test verification
├─ Phase 2: parallel audit agents (simplify, harden, spec)
├─ Fix loop (up to 3 audit rounds)
└─ Learning loop output
→ self-improvementCI Pipeline
CI Pipeline
classify (CI detected)
→ simplify-and-harden-ci (headless scan, PR changed files only)
→ self-improvement-ci (pattern aggregation, promotion recommendations)classify (CI detected)
→ simplify-and-harden-ci (headless scan, PR changed files only)
→ self-improvement-ci (pattern aggregation, promotion recommendations)Depth Calibration
深度校准
Not just which skills — how deep each goes:
| Dimension | Small | Medium | Large | Long-running | Batch |
|---|---|---|---|---|---|
| Planning passes | 0 | 0-1 | 1-2 | Deep iterative | Per-task or umbrella |
| Intent frame | - | Single frame | Full frame + monitoring | Full + handoff | Team lead frame |
| Context-surfing | - | - | Active | Critical (exit protocol ready) | Lightweight drift checks |
| S&H budget | 20% diff, 60s | 20% diff, 60s | 20% diff, 60s | 20% diff, 60s | 30% team growth cap |
| Audit rounds (teams) | - | - | - | - | Up to 3 |
| Self-improvement | Error-triggered | Error-triggered | Error + S&H feed | Error + S&H feed | Error + teams feed |
不仅要确定使用哪些技能,还要校准每个技能的执行深度:
| 维度 | 小任务 | 中等任务 | 大型任务 | 长周期任务 | 批量任务 |
|---|---|---|---|---|---|
| 规划迭代次数 | 0 | 0-1 | 1-2 | 深度迭代 | 按任务或统一规划 |
| 意图框架 | - | 单框架 | 完整框架 + 监控 | 完整框架 + 交接 | 团队负责人输出框架 |
| context-surfing | - | - | 活跃 | 核心(已准备退出协议) | 轻量偏移检查 |
| S&H预算 | 20% diff, 60s | 20% diff, 60s | 20% diff, 60s | 20% diff, 60s | 30%团队成长上限 |
| (团队)审核轮次 | - | - | - | - | 最多3轮 |
| self-improvement | 错误触发 | 错误触发 | 错误 + S&H反馈 | 错误 + S&H反馈 | 错误 + 团队反馈 |
Handoff Rules
交接规则
Artifacts flow between skills. The orchestrator ensures each skill receives what it needs.
Key handoffs:
-
Plan file () — produced by
docs/plans/plan-NNN-<slug>.md, consumed byplan-interview(context),intent-framed-agent(wave anchor),context-surfing(task extraction).agent-teams -
Intent Frame — produced by, consumed by
intent-framed-agent(wave anchor strengthening). Copied into handoff files on drift exit.context-surfing -
Handoff file () — produced by
.context-surfing/handoff-[slug]-[timestamp].mdon drift exit, consumed by next session for resume.context-surfing -
Learning candidates () — produced by
learning_loop.candidatesandsimplify-and-harden, consumed byagent-teamsfor pattern tracking.self-improvement
Precedence: If and both fire simultaneously, context-surfing's exit takes precedence. Degraded context makes scope checks unreliable.
context-surfingintent-framed-agentFor the full artifact/signal/budget table: read .
references/handoff-matrix.md产物在技能之间流转,编排器会确保每个技能收到所需的输入。
核心交接项:
-
计划文件 () — 由
docs/plans/plan-NNN-<slug>.md生成,供plan-interview(上下文)、intent-framed-agent(波动锚点)、context-surfing(任务提取)使用。agent-teams -
意图框架 — 由生成,供
intent-framed-agent(强化波动锚点)使用。发生范围偏移退出时会复制到交接文件中。context-surfing -
交接文件 () — 发生范围偏移退出时由
.context-surfing/handoff-[slug]-[timestamp].md生成,供下一次会话恢复上下文使用。context-surfing -
学习候选集 () — 由
learning_loop.candidates和simplify-and-harden生成,供agent-teams做模式追踪使用。self-improvement
优先级规则: 如果和同时触发,context-surfing的退出请求优先级更高。上下文降级会导致范围检查不可靠。
context-surfingintent-framed-agent如需查看完整的产物/信号/预算表,请阅读。
references/handoff-matrix.mdDecision Points
决策节点
The orchestrator intervenes at these moments:
编排器会在以下节点介入:
Task Arrival
任务接收时
Classify the task. Select pipeline variant and depth. Emit routing decision. If Large/Long-running, recommend . If Batch, recommend team-based variant.
/plan-interview对任务分类,选择Pipeline变体和深度,输出路由决策。如果是大型/长周期任务,推荐使用。如果是批量任务,推荐使用团队协作型变体。
/plan-interviewPlan Approval
计划获批时
When user approves a plan from , flow directly into the execution stage — no separate "should I proceed?" prompt. This means activating to emit an Intent Frame. The intent frame itself still requires user confirmation before coding begins (that confirmation is part of , not an extra gate). Populate task tracking with checklist items.
plan-interviewintent-framed-agentintent-framed-agent当用户批准输出的计划后,直接进入执行阶段——不需要额外的「是否继续」确认。这意味着会激活生成意图框架,编码开始前仍然需要用户确认意图框架(该确认是的内置流程,不是额外关卡)。同时填充任务跟踪的检查清单项。
plan-interviewintent-framed-agentintent-framed-agentPlanning-to-Execution Transition
规划转执行阶段
When no plan-interview was used and the user signals readiness ("go ahead", "implement this", "let's start"), activate . Emit Intent Frame. Wait for user confirmation of the frame before coding.
intent-framed-agent如果没有使用plan-interview,且用户发出就绪信号(「继续」、「实现这个需求」、「开始吧」),则激活生成意图框架,等待用户确认框架后再开始编码。
intent-framed-agentImplementation Complete
实现完成时
Check if diff meets the non-trivial threshold (see ). If yes, activate . If no, signal completion directly.
references/classification-rules.mdsimplify-and-harden检查diff是否达到非平凡变更阈值(参考)。如果是,激活;如果否,直接发出完成信号。
references/classification-rules.mdsimplify-and-hardenDrift Detected
检测到范围偏移时
If fires a drift exit, stop execution. Write handoff file. If the task was classified below Large, consider re-classifying upward for the next session.
context-surfing如果触发范围偏移退出,停止执行,写入交接文件。如果原任务分类低于大型任务,可考虑在下一次会话升级分类。
context-surfingSession Resume
会话恢复时
Check for handoff files in . If found, read completely. Re-establish context from handoff. Re-classify if needed. Resume from recommended re-entry point.
.context-surfing/检查目录下是否有交接文件。如果有,完整读取文件内容,从交接信息中重建上下文,必要时重新分类,从推荐的重入节点恢复执行。
.context-surfing/Overrides
手动覆盖规则
Users can override any routing decision:
- Force depth: /
depth=small— override classificationdepth=large - Force variant: /
variant=teams— override pipeline selectionvariant=standard - Skip review: — skip
--no-reviewsimplify-and-harden - Force planning: invoke on any task regardless of classification
/plan-interview - Skip all skills: user says "just do it" on a non-trivial task — respect the override
用户可以覆盖任何路由决策:
- 强制指定深度: /
depth=small— 覆盖分类结果depth=large - 强制指定变体: /
variant=teams— 覆盖Pipeline选择结果variant=standard - 跳过评审: — 跳过
--no-review步骤simplify-and-harden - 强制规划: 任意任务都可以调用,不受分类限制
/plan-interview - 跳过所有技能: 用户对非平凡任务下达「直接执行」指令时,尊重该覆盖规则
Re-classification
重分类规则
Tasks can change class mid-execution. Watch for:
- Escalation signals: scope expanded beyond original estimate, many more files affected than expected, drift exit,
context-surfingdetects significant scope changeintent-framed-agent - De-escalation signals: task turns out simpler than planned, plan reveals minimal changes needed
When re-classification is warranted:
- Note the signal that triggered re-classification
- Adjust active skills (add or remove pipeline stages)
- If escalating to Large: recommend if no plan exists
/plan-interview - If de-escalating: drop unnecessary stages, proceed with lighter pipeline
任务执行过程中可能变更类别,需要关注以下信号:
- 升级信号: 范围超出初始预估、受影响文件远超预期、触发范围偏移退出、
context-surfing检测到重大范围变更intent-framed-agent - 降级信号: 任务实际复杂度低于预期、规划显示只需要极小改动
当需要重分类时:
- 记录触发重分类的信号
- 调整活跃技能(新增或移除Pipeline阶段)
- 如果升级为大型任务且无现成计划,推荐使用
/plan-interview - 如果降级,移除不必要的阶段,使用更轻量的Pipeline继续执行
Anti-Patterns
反模式
- Do NOT re-implement skill logic. This skill classifies and dispatches. Each individual skill owns its own procedure.
- Do NOT auto-invoke plan-interview. It is a human gate. Recommend it; let the user decide.
- Do NOT create a third monitoring layer. During execution, monitors scope and
intent-framed-agentmonitors quality. The orchestrator dispatches at decision points, then gets out of the way.context-surfing - Do NOT override individual skill guardrails. If has a 20% budget cap, the orchestrator respects it.
simplify-and-harden - Do NOT force skills on trivial tasks. The pipeline exists to help, not to slow down simple work.
- 不要重复实现技能逻辑: 该技能仅负责分类和调度,每个独立技能自行管理内部流程
- 不要自动调用plan-interview: 它是人工管控节点,仅做推荐,由用户决定是否使用
- 不要创建第三层监控: 执行阶段由监控范围,
intent-framed-agent监控质量,编排器仅在决策节点调度,之后不介入执行context-surfing - 不要覆盖单个技能的防护规则: 如果设置了20%的预算上限,编排器需要遵守该限制
simplify-and-harden - 不要强制给琐碎任务挂载技能: Pipeline的作用是提效,而非拖慢简单任务的执行速度
Pipeline Variant Details
Pipeline变体详情
For complete step-by-step walkthroughs of each variant including hybrid scenarios and session resume: read .
references/pipeline-variants.md如需查看每个变体的完整分步流程,包括混合场景和会话恢复的说明,请阅读。
references/pipeline-variants.md