opencode-controller

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Opencode Controller

Opencode 控制器

Core rule

核心规则

Clawdbot does not write code. All planning and coding happens inside Opencode.
Clawdbot 不编写代码。 所有规划和编码工作都在 Opencode 内部完成。

Pre-flight

准备步骤

  • Ask the user which AI provider to use.
  • Ask how the provider should be authenticated.
  • Do not proceed without confirmation.
  • 询问用户要使用哪个AI提供商。
  • 询问提供商的认证方式。
  • 未获得确认前不得继续操作。

Session management

会话管理

  • Start Opencode.
  • Open session selector using: /sessions
  • If the current project already exists:
    • Select the existing session.
  • Never create a new session without user approval.
  • 启动Opencode。
  • 使用以下命令打开会话选择器: /sessions
  • 如果当前项目已存在:
    • 选择现有会话。
  • 未获得用户批准,绝不能创建新会话。

Agent (mode) control

Agent(模式)控制

  • Open agent selector using: /agents
  • Available agents:
    • Plan
    • Build
  • Always select Plan first.
  • Switch agents whenever required using
    /agents
    .
  • 使用以下命令打开Agent选择器: /agents
  • 可用的Agent:
    • Plan(规划)
    • Build(构建)
  • 始终先选择Plan模式。
  • 必要时使用
    /agents
    切换Agent。

Model selection

模型选择

  • Open model selector using: /models
  • Select the user-requested provider.
  • If authentication is required:
    • Copy the login link provided by Opencode.
    • Send it to the user.
    • Wait for confirmation before continuing.
  • 使用以下命令打开模型选择器: /models
  • 选择用户指定的提供商。
  • 如果需要认证:
    • 复制Opencode提供的登录链接。
    • 将链接发送给用户。
    • 等待用户确认后再继续。

Plan agent behavior

Plan Agent 行为规范

  • Ask Opencode to analyze the task.
  • Request a clear step-by-step plan.
  • Allow Opencode to ask clarification questions.
  • Review the plan carefully.
  • If the plan is incorrect or incomplete:
    • Ask Opencode to revise it.
  • Do not allow code generation in Plan.
  • 让Opencode分析任务。
  • 请求清晰的分步规划。
  • 允许Opencode提出澄清问题。
  • 仔细审核规划。
  • 如果规划不正确或不完整:
    • 要求Opencode修改规划。
  • 禁止在Plan模式下生成代码。

Build agent behavior

Build Agent 行为规范

  • Switch to Build using
    /agents
    .
  • Ask Opencode to implement the approved plan.
  • If Opencode asks any question:
    • Immediately switch back to Plan.
    • Answer and confirm the plan.
    • Switch back to Build.
  • 使用
    /agents
    切换到Build模式。
  • 让Opencode执行已获批的规划。
  • 如果Opencode提出问题:
    • 立即切换回Plan模式。
    • 回答问题并确认规划。
    • 切换回Build模式。

Completion

完成标准

  • Repeat the Plan → Build loop until all user requirements are satisfied.
  • Never skip Plan.
  • Never answer questions in Build.
  • 重复“规划→构建”循环,直到满足所有用户需求。
  • 绝不能跳过规划步骤。
  • 绝不能在Build模式下回答问题。

Output format

输出格式

  • Show all slash commands explicitly.
  • State which option is selected.
  • Provide login links verbatim.
  • 明确显示所有斜杠命令。
  • 说明选择的选项。
  • 原样提供登录链接。