omc-plan

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese
<Purpose> Plan creates comprehensive, actionable work plans through intelligent interaction. It auto-detects whether to interview the user (broad requests) or plan directly (detailed requests), and supports consensus mode (iterative Planner/Architect/Critic loop with RALPLAN-DR structured deliberation) and review mode (Critic evaluation of existing plans). </Purpose>
<Use_When>
  • User wants to plan before implementing -- "plan this", "plan the", "let's plan"
  • User wants structured requirements gathering for a vague idea
  • User wants an existing plan reviewed -- "review this plan",
    --review
  • User wants multi-perspective consensus on a plan --
    --consensus
    , "ralplan"
  • Task is broad or vague and needs scoping before any code is written </Use_When>
<Do_Not_Use_When>
  • User wants autonomous end-to-end execution -- use
    autopilot
    instead
  • User wants to start coding immediately with a clear task -- use
    ralph
    or delegate to executor
  • User asks a simple question that can be answered directly -- just answer it
  • Task is a single focused fix with obvious scope -- skip planning, just do it </Do_Not_Use_When>
<Why_This_Exists> Jumping into code without understanding requirements leads to rework, scope creep, and missed edge cases. Plan provides structured requirements gathering, expert analysis, and quality-gated plans so that execution starts from a solid foundation. The consensus mode adds multi-perspective validation for high-stakes projects. </Why_This_Exists>
<Execution_Policy>
  • Auto-detect interview vs direct mode based on request specificity
  • Ask one question at a time during interviews -- never batch multiple questions
  • Gather codebase facts via
    explore
    agent before asking the user about them
  • Plans must meet quality standards: 80%+ claims cite file/line, 90%+ criteria are testable
  • Consensus mode runs fully automated by default; add
    --interactive
    to enable user prompts at draft review and final approval steps
  • Consensus mode uses RALPLAN-DR short mode by default; switch to deliberate mode with
    --deliberate
    or when the request explicitly signals high risk (auth/security, data migration, destructive/irreversible changes, production incident, compliance/PII, public API breakage) </Execution_Policy>
<Steps>
<Purpose> Plan通过智能交互创建全面、可执行的工作计划。它会自动检测是否需要与用户进行访谈(针对宽泛请求)或直接制定计划(针对详细请求),并支持共识模式(采用RALPLAN-DR结构化审议的迭代式规划师/架构师/评审师循环)和评审模式(评审师对现有计划进行评估)。 </Purpose>
<Use_When>
  • 用户希望在实施前进行规划——例如“规划这个”、“制定计划”、“我们来做个规划”
  • 用户希望为模糊的想法收集结构化需求
  • 用户希望评审现有计划——例如“评审这个计划”、
    --review
  • 用户希望获得计划的多视角共识——例如
    --consensus
    、“ralplan”
  • 任务宽泛或模糊,需要在编写代码前明确范围 </Use_When>
<Do_Not_Use_When>
  • 用户希望自主端到端执行——请改用
    autopilot
  • 用户希望针对明确任务立即开始编码——请使用
    ralph
    或委托给执行器
  • 用户提出可直接回答的简单问题——直接回答即可
  • 任务是单一明确的修复,范围清晰——跳过规划,直接执行 </Do_Not_Use_When>
<Why_This_Exists> 在不理解需求的情况下直接编写代码会导致返工、范围蔓延和遗漏边缘情况。Plan提供结构化的需求收集、专家分析和质量管控的计划,让执行工作从坚实的基础开始。共识模式为高风险项目增加了多视角验证环节。 </Why_This_Exists>
<Execution_Policy>
  • 根据请求的具体程度自动检测访谈模式与直接模式
  • 访谈时一次只提一个问题——绝不批量提问
  • 在向用户询问代码库相关问题前,先通过
    explore
    agent收集代码库事实
  • 计划必须符合质量标准:80%以上的声明引用文件/行号,90%以上的标准可测试
  • 共识模式默认完全自动化;添加
    --interactive
    可在草案评审和最终批准步骤启用用户提示
  • 共识模式默认使用RALPLAN-DR简短模式;当使用
    --deliberate
    或请求明确涉及高风险(认证/安全、数据迁移、破坏性/不可逆变更、生产事件、合规/PII、公共API中断)时,切换到审慎模式 </Execution_Policy>
<Steps>

Mode Selection

模式选择

ModeTriggerBehavior
InterviewDefault for broad requestsInteractive requirements gathering
Direct
--direct
, or detailed request
Skip interview, generate plan directly
Consensus
--consensus
, "ralplan"
Planner -> Architect -> Critic loop until agreement with RALPLAN-DR structured deliberation (short by default,
--deliberate
for high-risk); add
--interactive
for user prompts at draft and approval steps
Review
--review
, "review this plan"
Critic evaluation of existing plan
模式触发条件行为
访谈模式宽泛请求默认启用交互式需求收集
直接模式
--direct
,或详细请求
跳过访谈,直接生成计划
共识模式
--consensus
、"ralplan"
规划师->架构师->评审师循环,直至达成共识,采用RALPLAN-DR结构化审议(默认简短模式,高风险场景使用
--deliberate
切换为审慎模式);添加
--interactive
可在草案和批准步骤获取用户提示
评审模式
--review
、"评审这个计划"
评审师对现有计划进行评估

Interview Mode (broad/vague requests)

访谈模式(宽泛/模糊请求)

  1. Classify the request: Broad (vague verbs, no specific files, touches 3+ areas) triggers interview mode
  2. Ask one focused question using
    AskUserQuestion
    for preferences, scope, and constraints
  3. Gather codebase facts first: Before asking "what patterns does your code use?", spawn an
    explore
    agent to find out, then ask informed follow-up questions
  4. Build on answers: Each question builds on the previous answer
  5. Consult Analyst (Opus) for hidden requirements, edge cases, and risks
  6. Create plan when the user signals readiness: "create the plan", "I'm ready", "make it a work plan"
  1. 请求分类:宽泛请求(模糊动词、无特定文件、涉及3个以上领域)触发访谈模式
  2. 提出聚焦问题:使用
    AskUserQuestion
    询问偏好、范围和约束条件,一次一个问题
  3. 先收集代码库事实:在询问“你的代码使用了什么模式?”这类问题前,先启动
    explore
    agent查明情况,再提出有依据的后续问题
  4. 基于回答逐步推进:每个问题都建立在上一个回答的基础上
  5. 咨询分析师(Opus):挖掘隐藏需求、边缘情况和风险
  6. 创建计划:当用户表示准备就绪时——例如“创建计划”、“我准备好了”、“制定工作计划”

Direct Mode (detailed requests)

直接模式(详细请求)

  1. Quick Analysis: Optional brief Analyst consultation
  2. Create plan: Generate comprehensive work plan immediately
  3. Review (optional): Critic review if requested
  1. 快速分析:可选的简短分析师咨询
  2. 创建计划:立即生成全面的工作计划
  3. 评审(可选):如果有请求,由评审师进行评审

Consensus Mode (
--consensus
/ "ralplan")

共识模式 (
--consensus
/ "ralplan")

RALPLAN-DR modes: Short (default, bounded structure) and Deliberate (for
--deliberate
or explicit high-risk requests). Both modes keep the same Planner -> Architect -> Critic sequence and the same
AskUserQuestion
gates.
  1. Planner creates initial plan and a compact RALPLAN-DR summary before any Architect review. The summary MUST include:
    • Principles (3-5)
    • Decision Drivers (top 3)
    • Viable Options (>=2) with bounded pros/cons for each option
    • If only one viable option remains, an explicit invalidation rationale for the alternatives that were rejected
    • In deliberate mode: a pre-mortem (3 failure scenarios) and an expanded test plan covering unit / integration / e2e / observability
  2. User feedback (--interactive only): If running with
    --interactive
    , MUST use
    AskUserQuestion
    to present the draft plan plus the RALPLAN-DR Principles / Decision Drivers / Options summary for early direction alignment with these options:
    • Proceed to review — send to Architect and Critic for evaluation
    • Request changes — return to step 1 with user feedback incorporated
    • Skip review — go directly to final approval (step 7) If NOT running with
      --interactive
      , automatically proceed to review (step 3).
  3. Architect reviews for architectural soundness using
    Task(subagent_type="oh-my-claudecode:architect", ...)
    . Architect review MUST include: strongest steelman counterargument (antithesis) against the favored option, at least one meaningful tradeoff tension, and (when possible) a synthesis path. In deliberate mode, Architect should explicitly flag principle violations. Wait for this step to complete before proceeding to step 4. Do NOT run steps 3 and 4 in parallel.
  4. Critic evaluates against quality criteria using
    Task(subagent_type="oh-my-claudecode:critic", ...)
    . Critic MUST verify principle-option consistency, fair alternative exploration, risk mitigation clarity, testable acceptance criteria, and concrete verification steps. Critic MUST explicitly reject shallow alternatives, driver contradictions, vague risks, or weak verification. In deliberate mode, Critic MUST reject missing/weak pre-mortem or missing/weak expanded test plan. Run only after step 3 is complete.
  5. Re-review loop (max 5 iterations): If Critic rejects, execute this closed loop: a. Collect all rejection feedback from Architect + Critic b. Pass feedback to Planner to produce a revised plan c. Return to Step 3 — Architect reviews the revised plan d. Return to Step 4 — Critic evaluates the revised plan e. Repeat until Critic approves OR max 5 iterations reached f. If max iterations reached without approval, present the best version to user via
    AskUserQuestion
    with note that expert consensus was not reached
  6. Apply improvements: When reviewers approve with improvement suggestions, merge all accepted improvements into the plan file before proceeding. Final consensus output MUST include an ADR section with: Decision, Drivers, Alternatives considered, Why chosen, Consequences, Follow-ups. Specifically: a. Collect all improvement suggestions from Architect and Critic responses b. Deduplicate and categorize the suggestions c. Update the plan file in
    .omc/plans/
    with the accepted improvements (add missing details, refine steps, strengthen acceptance criteria, ADR updates, etc.) d. Note which improvements were applied in a brief changelog section at the end of the plan
  7. On Critic approval (with improvements applied): (--interactive only) If running with
    --interactive
    , use
    AskUserQuestion
    to present the plan with these options:
    • Approve and implement via team (Recommended) — proceed to implementation via coordinated parallel team agents (
      /team
      ). Team is the canonical orchestration surface since v4.1.7.
    • Approve and execute via ralph — proceed to implementation via ralph+ultrawork (sequential execution with verification)
    • Clear context and implement — compact the context window first (recommended when context is large after planning), then start fresh implementation via ralph with the saved plan file
    • Request changes — return to step 1 with user feedback
    • Reject — discard the plan entirely If NOT running with
      --interactive
      , output the final approved plan and stop. Do NOT auto-execute.
  8. (--interactive only) User chooses via the structured
    AskUserQuestion
    UI (never ask for approval in plain text)
  9. On user approval (--interactive only):
    • Approve and implement via team: MUST invoke
      Skill("oh-my-claudecode:team")
      with the approved plan path from
      .omc/plans/
      as context. Do NOT implement directly. The team skill coordinates parallel agents across the staged pipeline for faster execution on large tasks. This is the recommended default execution path.
    • Approve and execute via ralph: MUST invoke
      Skill("oh-my-claudecode:ralph")
      with the approved plan path from
      .omc/plans/
      as context. Do NOT implement directly. Do NOT edit source code files in the planning agent. The ralph skill handles execution via ultrawork parallel agents.
    • Clear context and implement: First invoke
      Skill("compact")
      to compress the context window (reduces token usage accumulated during planning), then invoke
      Skill("oh-my-claudecode:ralph")
      with the approved plan path from
      .omc/plans/
      . This path is recommended when the context window is 50%+ full after the planning session.
RALPLAN-DR模式简短模式(默认,结构化边界清晰)和审慎模式(适用于
--deliberate
或明确的高风险请求)。两种模式均保持规划师->架构师->评审师的流程,以及
AskUserQuestion
的反馈环节。
  1. 规划师创建初始计划和简洁的RALPLAN-DR摘要,然后再提交给架构师评审。摘要必须包含:
    • 原则(3-5条)
    • 决策驱动因素(前3项)
    • 可行方案(不少于2个),每个方案需包含明确的优缺点
    • 如果仅剩一个可行方案,需提供明确的备选方案无效理由
    • 审慎模式下:需包含事前分析(3种失败场景)和扩展测试计划,覆盖单元测试/集成测试/e2e测试/可观测性
  2. 用户反馈(仅
    --interactive
    模式):如果启用
    --interactive
    必须使用
    AskUserQuestion
    展示草案计划以及RALPLAN-DR原则/决策驱动因素/方案摘要,用于早期方向对齐,提供以下选项:
    • 进入评审环节——提交给架构师和评审师进行评估
    • 请求修改——结合用户反馈返回步骤1
    • 跳过评审——直接进入最终批准环节(步骤7) 如果未启用
      --interactive
      ,自动进入评审环节(步骤3)。
  3. 架构师评审:通过
    Task(subagent_type="oh-my-claudecode:architect", ...)
    检查架构合理性。架构师评审必须包含:针对首选方案最有力的反驳论点(反题)、至少一个有意义的权衡矛盾,以及(可能的话)一个综合解决方案路径。在审慎模式下,架构师应明确标记违反原则的情况。必须等待此步骤完成后再进入步骤4,不得并行运行步骤3和4。
  4. 评审师评估:通过
    Task(subagent_type="oh-my-claudecode:critic", ...)
    对照质量标准进行评估。评审师必须验证原则与方案的一致性、备选方案的公平性探索、风险缓解的清晰度、可测试的验收标准,以及具体的验证步骤。评审师必须明确拒绝浅层备选方案、驱动因素矛盾、模糊风险或薄弱的验证环节。在审慎模式下,评审师必须拒绝缺失/薄弱的事前分析或缺失/薄弱的扩展测试计划。仅在步骤3完成后运行此步骤。
  5. 重新评审循环(最多5次迭代):如果评审师拒绝,执行以下闭环: a. 收集架构师和评审师的所有拒绝反馈 b. 将反馈传递给规划师以生成修订后的计划 c. 返回步骤3——架构师评审修订后的计划 d. 返回步骤4——评审师评估修订后的计划 e. 重复直至评审师批准或达到最大5次迭代 f. 如果达到最大迭代次数仍未批准,通过
    AskUserQuestion
    向用户展示最佳版本,并说明未达成专家共识
  6. 应用改进:当评审者批准并提出改进建议时,在进入下一步前将所有已接受的改进合并到计划文件中。最终共识输出必须包含ADR部分:决策驱动因素考虑的备选方案选择理由后果后续行动。具体步骤: a. 收集架构师和评审师反馈中的所有改进建议 b. 对建议进行去重和分类 c. 更新
    .omc/plans/
    中的计划文件,融入已接受的改进(补充缺失细节、优化步骤、强化验收标准、更新ADR等) d. 在计划末尾的简短变更日志部分记录已应用的改进
  7. 评审师批准(已应用改进)后:(仅
    --interactive
    模式)如果启用
    --interactive
    ,使用
    AskUserQuestion
    展示计划并提供以下选项:
    • 批准并通过团队实施(推荐)——通过协调并行团队Agent(
      /team
      )进入实施阶段。从v4.1.7版本开始,Team是标准的编排界面。
    • 批准并通过ralph执行——通过ralph+ultrawork进入实施阶段(带验证的顺序执行)
    • 清理上下文并实施——先压缩上下文窗口(规划后上下文较大时推荐),然后使用保存的计划文件通过ralph启动全新实施
    • 请求修改——结合用户反馈返回步骤1
    • 拒绝——完全丢弃计划 如果未启用
      --interactive
      ,输出最终批准的计划并停止,不得自动执行。
  8. (仅
    --interactive
    模式)用户通过结构化的
    AskUserQuestion
    UI进行选择(绝不能用纯文本请求批准)
  9. 用户批准后(仅
    --interactive
    模式):
    • 批准并通过团队实施必须调用
      Skill("oh-my-claudecode:team")
      ,并将
      .omc/plans/
      中的已批准计划路径作为上下文。不得直接实施。Team技能协调分阶段流水线中的并行Agent,以加快大型任务的执行速度。这是推荐的默认执行路径。
    • 批准并通过ralph执行必须调用
      Skill("oh-my-claudecode:ralph")
      ,并将
      .omc/plans/
      中的已批准计划路径作为上下文。不得直接实施。不得在规划Agent中编辑源代码文件。Ralph技能通过ultrawork并行Agent处理执行工作。
    • 清理上下文并实施:首先调用
      Skill("compact")
      压缩上下文窗口(减少规划过程中累积的令牌使用量),然后调用
      Skill("oh-my-claudecode:ralph")
      ,并传入
      .omc/plans/
      中的已批准计划路径。当规划会话后上下文窗口使用率达到50%以上时,推荐使用此路径。

Review Mode (
--review
)

评审模式 (
--review
)

  1. Read plan file from
    .omc/plans/
  2. Evaluate via Critic using
    Task(subagent_type="oh-my-claudecode:critic", ...)
  3. Return verdict: APPROVED, REVISE (with specific feedback), or REJECT (replanning required)
  1. .omc/plans/
    读取计划文件
  2. 通过
    Task(subagent_type="oh-my-claudecode:critic", ...)
    由评审师进行评估
  3. 返回结论:批准、需要修订(附带具体反馈)或拒绝(需要重新规划)

Plan Output Format

计划输出格式

Every plan includes:
  • Requirements Summary
  • Acceptance Criteria (testable)
  • Implementation Steps (with file references)
  • Risks and Mitigations
  • Verification Steps
  • For consensus/ralplan: RALPLAN-DR summary (Principles, Decision Drivers, Options)
  • For consensus/ralplan final output: ADR (Decision, Drivers, Alternatives considered, Why chosen, Consequences, Follow-ups)
  • For deliberate consensus mode: Pre-mortem (3 scenarios) and Expanded Test Plan (unit/integration/e2e/observability)
Plans are saved to
.omc/plans/
. Drafts go to
.omc/drafts/
. </Steps>
<Tool_Usage>
  • Use
    AskUserQuestion
    for preference questions (scope, priority, timeline, risk tolerance) -- provides clickable UI
  • Use plain text for questions needing specific values (port numbers, names, follow-up clarifications)
  • Use
    explore
    agent (Haiku, 30s timeout) to gather codebase facts before asking the user
  • Use
    Task(subagent_type="oh-my-claudecode:planner", ...)
    for planning validation on large-scope plans
  • Use
    Task(subagent_type="oh-my-claudecode:analyst", ...)
    for requirements analysis
  • Use
    Task(subagent_type="oh-my-claudecode:critic", ...)
    for plan review in consensus and review modes
  • CRITICAL — Consensus mode agent calls MUST be sequential, never parallel. Always await the Architect Task result before issuing the Critic Task.
  • In consensus mode, default to RALPLAN-DR short mode; enable deliberate mode on
    --deliberate
    or explicit high-risk signals (auth/security, migrations, destructive changes, production incidents, compliance/PII, public API breakage)
  • In consensus mode with
    --interactive
    : use
    AskUserQuestion
    for the user feedback step (step 2) and the final approval step (step 7) -- never ask for approval in plain text. Without
    --interactive
    , skip both prompts and output the final plan.
  • In consensus mode with
    --interactive
    , on user approval MUST invoke
    Skill("oh-my-claudecode:ralph")
    for execution (step 9) -- never implement directly in the planning agent
  • When user selects "Clear context and implement" in step 7 (--interactive only): invoke
    Skill("compact")
    first to compress the accumulated planning context, then immediately invoke
    Skill("oh-my-claudecode:ralph")
    with the plan path -- the compact step is critical to free up context before the implementation loop begins </Tool_Usage>
<Examples> <Good> Adaptive interview (gathering facts before asking): ``` Planner: [spawns explore agent: "find authentication implementation"] Planner: [receives: "Auth is in src/auth/ using JWT with passport.js"] Planner: "I see you're using JWT authentication with passport.js in src/auth/. For this new feature, should we extend the existing auth or add a separate auth flow?" ``` Why good: Answers its own codebase question first, then asks an informed preference question. </Good> <Good> Single question at a time: ``` Q1: "What's the main goal?" A1: "Improve performance" Q2: "For performance, what matters more -- latency or throughput?" A2: "Latency" Q3: "For latency, are we optimizing for p50 or p99?" ``` Why good: Each question builds on the previous answer. Focused and progressive. </Good> <Bad> Asking about things you could look up: ``` Planner: "Where is authentication implemented in your codebase?" User: "Uh, somewhere in src/auth I think?" ``` Why bad: The planner should spawn an explore agent to find this, not ask the user. </Bad> <Bad> Batching multiple questions: ``` "What's the scope? And the timeline? And who's the audience?" ``` Why bad: Three questions at once causes shallow answers. Ask one at a time. </Bad> <Bad> Presenting all design options at once: ``` "Here are 4 approaches: Option A... Option B... Option C... Option D... Which do you prefer?" ``` Why bad: Decision fatigue. Present one option with trade-offs, get reaction, then present the next. </Bad> </Examples>
<Escalation_And_Stop_Conditions>
  • Stop interviewing when requirements are clear enough to plan -- do not over-interview
  • In consensus mode, stop after 5 Planner/Architect/Critic iterations and present the best version
  • Consensus mode without
    --interactive
    outputs the final plan and stops; with
    --interactive
    , requires explicit user approval before any implementation begins
  • If the user says "just do it" or "skip planning", MUST invoke
    Skill("oh-my-claudecode:ralph")
    to transition to execution mode. Do NOT implement directly in the planning agent.
  • Escalate to the user when there are irreconcilable trade-offs that require a business decision </Escalation_And_Stop_Conditions>
<Final_Checklist>
  • Plan has testable acceptance criteria (90%+ concrete)
  • Plan references specific files/lines where applicable (80%+ claims)
  • All risks have mitigations identified
  • No vague terms without metrics ("fast" -> "p99 < 200ms")
  • Plan saved to
    .omc/plans/
  • In consensus mode: RALPLAN-DR summary includes 3-5 principles, top 3 drivers, and >=2 viable options (or explicit invalidation rationale)
  • In consensus mode final output: ADR section included (Decision / Drivers / Alternatives considered / Why chosen / Consequences / Follow-ups)
  • In deliberate consensus mode: pre-mortem (3 scenarios) + expanded test plan (unit/integration/e2e/observability) included
  • In consensus mode with
    --interactive
    : user explicitly approved before any execution; without
    --interactive
    : plan output only, no auto-execution </Final_Checklist>
<Advanced>
每份计划包含:
  • 需求摘要
  • 验收标准(可测试)
  • 实施步骤(含文件引用)
  • 风险与缓解措施
  • 验证步骤
  • 共识模式/ralplan计划:RALPLAN-DR摘要(原则、决策驱动因素、方案)
  • 共识模式/ralplan最终输出:ADR(决策、驱动因素、考虑的备选方案、选择理由、后果、后续行动)
  • 审慎共识模式:事前分析(3种场景)扩展测试计划(单元测试/集成测试/e2e测试/可观测性)
计划将保存到
.omc/plans/
,草稿保存到
.omc/drafts/
</Steps>
<Tool_Usage>
  • 使用
    AskUserQuestion
    询问偏好类问题(范围、优先级、时间线、风险容忍度)——提供可点击的UI
  • 对于需要具体值的问题(端口号、名称、后续澄清),使用纯文本提问
  • 在询问用户前,使用
    explore
    agent(Haiku,超时时间30秒)收集代码库事实
  • 对于大范围计划,使用
    Task(subagent_type="oh-my-claudecode:planner", ...)
    进行规划验证
  • 使用
    Task(subagent_type="oh-my-claudecode:analyst", ...)
    进行需求分析
  • 在共识模式和评审模式下,使用
    Task(subagent_type="oh-my-claudecode:critic", ...)
    进行计划评审
  • 关键注意事项——共识模式下的Agent调用必须按顺序执行,绝不能并行。必须等待架构师任务结果返回后,再发起评审师任务。
  • 共识模式默认使用RALPLAN-DR简短模式;当使用
    --deliberate
    或明确的高风险信号(认证/安全、迁移、破坏性变更、生产事件、合规/PII、公共API中断)时,启用审慎模式
  • 在启用
    --interactive
    的共识模式下:用户反馈环节(步骤2)和最终批准环节(步骤7)必须使用
    AskUserQuestion
    ——绝不能用纯文本请求批准。未启用
    --interactive
    时,跳过这两个提示并输出最终计划。
  • 在启用
    --interactive
    的共识模式下,用户批准后必须调用
    Skill("oh-my-claudecode:ralph")
    执行(步骤9)——绝不能在规划Agent中直接实施。
  • 当用户在步骤7中选择“清理上下文并实施”时(仅
    --interactive
    模式):先调用
    Skill("compact")
    压缩累积的规划上下文,然后立即调用
    Skill("oh-my-claudecode:ralph")
    并传入计划路径——压缩步骤对于在实施循环开始前释放上下文至关重要 </Tool_Usage>
<Examples> <Good> 自适应访谈(先收集事实再提问): ``` Planner: [启动explore agent: "查找认证实现位置"] Planner: [收到回复: "认证在src/auth/中使用JWT和passport.js实现"] Planner: "我了解到你在src/auth/中使用JWT和passport.js实现认证。 对于这个新功能,我们应该扩展现有认证系统还是添加独立的认证流程?" ``` 优点:先自行查明代码库相关问题,再提出有依据的偏好问题。 </Good> <Good> 一次只提一个问题: ``` Q1: "主要目标是什么?" A1: "提升性能" Q2: "对于性能优化,你更关注延迟还是吞吐量?" A2: "延迟" Q3: "针对延迟优化,我们是优化p50还是p99指标?" ``` 优点:每个问题都基于上一个回答,聚焦且循序渐进。 </Good> <Bad> 询问可自行查找的信息: ``` Planner: "你的代码库中认证功能在哪里实现?" User: "呃,我想是在src/auth的某个地方?" ``` 缺点:规划师应该启动explore agent来查找,而不是询问用户。 </Bad> <Bad> 批量提问: ``` "范围是什么?时间线呢?受众是谁?" ``` 缺点:一次提三个问题会导致回答不够深入,应该一次只提一个。 </Bad> <Bad> 一次性展示所有设计方案: ``` "这里有4种方案:方案A... 方案B... 方案C... 方案D... 你偏好哪一个?" ``` 缺点:会导致决策疲劳。应该一次展示一个方案及其权衡,获取反馈后再展示下一个。 </Bad> </Examples>
<Escalation_And_Stop_Conditions>
  • 当需求足够清晰可制定计划时停止访谈——不要过度访谈
  • 在共识模式下,经过5次规划师/架构师/评审师迭代后停止,展示最佳版本
  • 未启用
    --interactive
    的共识模式输出最终计划后停止;启用
    --interactive
    的模式在任何实施开始前需要明确的用户批准
  • 如果用户说“直接做”或“跳过规划”,必须调用
    Skill("oh-my-claudecode:ralph")
    切换到执行模式,绝不能在规划Agent中直接实施。
  • 当存在无法调和的权衡,需要业务决策时,升级给用户处理 </Escalation_And_Stop_Conditions>
<Final_Checklist>
  • 计划包含可测试的验收标准(90%以上为具体标准)
  • 计划在适用时引用具体的文件/行号(80%以上的声明)
  • 所有风险都已确定缓解措施
  • 没有无度量标准的模糊术语(例如将“快速”改为“p99 < 200ms”)
  • 计划已保存到
    .omc/plans/
  • 共识模式下:RALPLAN-DR摘要包含3-5条原则、前3项驱动因素、不少于2个可行方案(或明确的备选方案无效理由)
  • 共识模式最终输出:包含ADR部分(决策/驱动因素/考虑的备选方案/选择理由/后果/后续行动)
  • 审慎共识模式下:包含事前分析(3种场景)+扩展测试计划(单元测试/集成测试/e2e测试/可观测性)
  • 启用
    --interactive
    的共识模式:任何执行前已获得用户明确批准;未启用
    --interactive
    的模式:仅输出计划,不自动执行 </Final_Checklist>
<Advanced>

Design Option Presentation

设计方案展示

When presenting design choices during interviews, chunk them:
  1. Overview (2-3 sentences)
  2. Option A with trade-offs
  3. [Wait for user reaction]
  4. Option B with trade-offs
  5. [Wait for user reaction]
  6. Recommendation (only after options discussed)
Format for each option:
undefined
在访谈中展示设计方案时,应分块进行:
  1. 概述(2-3句话)
  2. 方案A及其权衡
  3. [等待用户反馈]
  4. 方案B及其权衡
  5. [等待用户反馈]
  6. 推荐方案(仅在讨论完所有方案后)
每个方案的格式:
undefined

Option A: [Name]

方案A: [名称]

Approach: [1 sentence] Pros: [bullets] Cons: [bullets]
What's your reaction to this approach?
undefined
方法: [1句话] 优点: [项目符号] 缺点: [项目符号]
你对这个方法有什么看法?
undefined

Question Classification

问题分类

Before asking any interview question, classify it:
TypeExamplesAction
Codebase Fact"What patterns exist?", "Where is X?"Explore first, do not ask user
User Preference"Priority?", "Timeline?"Ask user via AskUserQuestion
Scope Decision"Include feature Y?"Ask user
Requirement"Performance constraints?"Ask user
在提出任何访谈问题前,先对问题进行分类:
类型示例操作
代码库事实"存在哪些模式?", "X在哪里?"先进行探索,不要询问用户
用户偏好"优先级?", "时间线?"通过AskUserQuestion询问用户
范围决策"是否包含功能Y?"询问用户
需求"性能约束?"询问用户

Review Quality Criteria

评审质量标准

CriterionStandard
Clarity80%+ claims cite file/line
Testability90%+ criteria are concrete
VerificationAll file refs exist
SpecificityNo vague terms
标准要求
清晰度80%以上的声明引用文件/行号
可测试性90%以上的标准为具体可测
验证所有文件引用均存在
具体性无模糊术语

Deprecation Notice

弃用通知

The separate
/planner
,
/ralplan
, and
/review
skills have been merged into
/plan
. All workflows (interview, direct, consensus, review) are available through
/plan
. </Advanced>
独立的
/planner
/ralplan
/review
技能已合并到
/plan
中。所有工作流(访谈、直接、共识、评审)均可通过
/plan
访问。 </Advanced>",