orient

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese
Phase gate: EXPLORE checkpoint. This skill MUST complete all steps before proceeding to Isolate.
阶段门控:EXPLORE检查点。本技能必须完成所有步骤后才能进入Isolate阶段。

Steps

步骤

  1. Fetch issue context (if issue number provided):
    bash
    gh issue view <number> --json title,body,labels,assignees
    If no issue number provided, ask the user to describe the task. If
    gh
    is not available (remote session without GH_TOKEN), skip issue fetch and proceed with manual description.
  2. Auto-detect task type from labels or description:
    Label / keywordTypeBranch prefix
    bug
    , error, crash, broken, fix
    Bugfix
    fix/
    enhancement
    ,
    feature
    , add, want, should, new
    Feature
    feat/
    chore
    ,
    config
    , deps, ci, tooling
    Chore
    chore/
    docs
    , documentation, readme
    Docs
    docs/
    DefaultFeature
    feat/
  3. Scan for relevant ADRs:
    bash
    ls ai-workspace/decisions/*.md 2>/dev/null | head -20
    Check ADR titles/filenames for keywords matching the issue title/body. If matches found, read the relevant ADR and surface it. If ADR scan finds contradictions, surface explicitly: "This task may conflict with ADR-NNN"
  4. Check for interrupted work: If
    .branch-context.md
    exists, read it and include in the brief (resuming work).
  5. Read recent memory:
    bash
    tail -20 ai-workspace/MEMORY.md 2>/dev/null
  6. Present brief:
    ## Orient Brief
    **Task**: [title or description]
    **Type**: [bugfix/feature/chore/docs] → branch prefix: [fix/feat/chore/docs]/
    **Suggested branch**: [prefix]/[kebab-case-name]
    **Relevant ADRs**: [list or "none found"]
    **Resuming?**: [yes — from .branch-context.md / no]
    **Files likely affected**: [educated guess from issue description + ADR context]
  7. Auto-route using the one-sentence rule:
    • Can the entire diff for this task be described in ONE sentence? → Direct to Isolate (skip Design/Review)
    • Otherwise → Plan first (proceed to Design after Isolate)
    Present the routing decision. The agent auto-decides — no human input required. If human is present, they can override.
  1. 获取issue上下文(如果提供了issue编号):
    bash
    gh issue view <number> --json title,body,labels,assignees
    如果未提供issue编号,请用户描述任务。 如果
    gh
    不可用(无GH_TOKEN的远程会话),跳过issue获取,继续使用手动描述。
  2. 从标签或描述中自动检测任务类型
    标签/关键词类型分支前缀
    bug
    , error, crash, broken, fix
    Bugfix
    fix/
    enhancement
    ,
    feature
    , add, want, should, new
    Feature
    feat/
    chore
    ,
    config
    , deps, ci, tooling
    Chore
    chore/
    docs
    , documentation, readme
    Docs
    docs/
    默认Feature
    feat/
  3. 扫描相关ADR
    bash
    ls ai-workspace/decisions/*.md 2>/dev/null | head -20
    检查ADR标题/文件名中是否有与issue标题/内容匹配的关键词。如果找到匹配项,读取相关ADR并展示。 如果ADR扫描发现冲突,明确提示:"本任务可能与ADR-NNN冲突"
  4. 检查中断的工作: 如果存在
    .branch-context.md
    ,读取该文件并纳入概览(恢复工作)。
  5. 读取近期记忆
    bash
    tail -20 ai-workspace/MEMORY.md 2>/dev/null
  6. 输出概览
    ## 定向概览
    **任务**: [标题或描述]
    **类型**: [bugfix/feature/chore/docs] → 分支前缀: [fix/feat/chore/docs]/
    **建议分支**: [prefix]/[kebab-case-name]
    **相关ADR**: [列表或"未找到"]
    **是否恢复工作?**: [是 — 从.branch-context.md恢复 / 否]
    **可能受影响的文件**: [根据issue描述+ADR上下文合理猜测]
  7. 使用单句规则自动路由
    • 该任务的所有代码变更是否能用一句话描述清楚?→ 直接进入Isolate阶段(跳过设计/评审)
    • 否则 → 先制定计划(Isolate阶段后进入设计阶段)
    给出路由决策。由Agent自动决定——无需人工输入。如果有人类在场,可以覆盖该决策。

Edge Cases

边缘案例

  • No issue number + no user description → ask for a description
  • gh
    not available → skip issue fetch, proceed with manual description
  • No ADRs directory → skip ADR scan
  • 无issue编号 + 无用户描述 → 要求用户提供描述
  • gh
    不可用 → 跳过issue获取,继续使用手动描述
  • 无ADRs目录 → 跳过ADR扫描