ecomode

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Ecomode Skill

Ecomode Skill

Token-efficient model routing. This is a MODIFIER, not a standalone execution mode.
Token高效的模型路由。这是一个MODIFIER,而非独立的执行模式。

What Ecomode Does

Ecomode的功能

Overrides default model selection to prefer cheaper tiers:
Default TierEcomode Override
HIGH (opus)MEDIUM (sonnet), HIGH only if essential
MEDIUM (sonnet)LOW (haiku) first, MEDIUM if fails
LOW (haiku)LOW (haiku) - no change
覆盖默认模型选择逻辑,优先选用更经济的模型层级:
默认层级Ecomode替代方案
高级(opus)中级(sonnet),仅在必要时使用高级
中级(sonnet)优先使用低级(haiku),失败时再切换到中级
低级(haiku)低级(haiku)- 无变化

What Ecomode Does NOT Do

Ecomode不具备的功能

  • Persistence: Use
    ralph
    for "don't stop until done"
  • Parallel Execution: Use
    ultrawork
    for parallel agents
  • Delegation Enforcement: Always active via core orchestration
  • 持久执行:如需“任务完成前持续执行”,请使用
    ralph
  • 并行执行:如需多Agent并行执行,请使用
    ultrawork
  • 委托强制:始终通过核心编排生效

Combining Ecomode with Other Modes

Ecomode与其他模式的组合

Ecomode is a modifier that combines with execution modes:
CombinationEffect
eco ralph
Ralph loop with cheaper agents
eco ultrawork
Parallel execution with cheaper agents
eco autopilot
Full autonomous with cost optimization
Ecomode是可与执行模式结合使用的修改器:
组合方式效果
eco ralph
采用更经济Agent的Ralph循环执行
eco ultrawork
采用更经济Agent的并行执行
eco autopilot
结合成本优化的全自主执行

Ecomode Routing Rules

Ecomode路由规则

ALWAYS prefer lower tiers. Only escalate when task genuinely requires it.
DecisionRule
DEFAULTStart with LOW tier (Haiku) for most tasks
UPGRADEEscalate to MEDIUM (Sonnet) when LOW tier fails or task requires multi-file reasoning
AVOIDHIGH tier (Opus) - only for planning/critique if essential
始终优先选用低级模型。仅当任务确实需要时才升级模型层级。
决策规则
默认大多数任务从低级模型(Haiku)开始
升级当低级模型执行失败或任务需要多文件推理时,升级到中级模型(Sonnet)
避免高级模型(Opus)- 仅在必要时用于规划/评审

Agent Selection in Ecomode

Ecomode中的Agent选择

FIRST ACTION: Before delegating any work, read the agent reference file:
Read file: docs/shared/agent-tiers.md
This provides the complete agent tier matrix, MCP tool assignments, and selection guidance.
Ecomode preference order:
// PREFERRED - Use for most tasks
Task(subagent_type="oh-my-claudecode:executor-low", model="haiku", prompt="...")
Task(subagent_type="oh-my-claudecode:explore", model="haiku", prompt="...")
Task(subagent_type="oh-my-claudecode:architect-low", model="haiku", prompt="...")

// FALLBACK - Only if LOW fails
Task(subagent_type="oh-my-claudecode:executor", model="sonnet", prompt="...")
Task(subagent_type="oh-my-claudecode:architect-medium", model="sonnet", prompt="...")

// AVOID - Only for planning/critique if essential
Task(subagent_type="oh-my-claudecode:planner", model="opus", prompt="...")
**首要操作:**在委托任何工作前,请阅读Agent参考文件:
Read file: docs/shared/agent-tiers.md
该文件包含完整的Agent层级矩阵、MCP工具分配及选择指南。
Ecomode优先级顺序:
// PREFERRED - Use for most tasks
Task(subagent_type="oh-my-claudecode:executor-low", model="haiku", prompt="...")
Task(subagent_type="oh-my-claudecode:explore", model="haiku", prompt="...")
Task(subagent_type="oh-my-claudecode:architect-low", model="haiku", prompt="...")

// FALLBACK - Only if LOW fails
Task(subagent_type="oh-my-claudecode:executor", model="sonnet", prompt="...")
Task(subagent_type="oh-my-claudecode:architect-medium", model="sonnet", prompt="...")

// AVOID - Only for planning/critique if essential
Task(subagent_type="oh-my-claudecode:planner", model="opus", prompt="...")

Delegation Enforcement

委托规则执行

Ecomode maintains all delegation rules from core protocol with cost-optimized routing:
ActionDelegate ToModel
Code changesexecutor-low / executorhaiku / sonnet
Analysisarchitect-lowhaiku
Searchexplorehaiku
Documentationwriterhaiku
Ecomode遵循核心协议的所有委托规则,并结合成本优化的路由逻辑:
操作委托对象模型
代码修改executor-low / executorhaiku / sonnet
分析architect-lowhaiku
搜索explorehaiku
文档编写writerhaiku

Background Execution

后台执行

Long-running commands (install, build, test) run in background. Maximum 20 concurrent.
长时间运行的命令(安装、构建、测试)将在后台执行。最大并发数为20。

Token Savings Tips

Token节省技巧

  1. Batch similar tasks to one agent instead of spawning many
  2. Use explore (haiku) for file discovery, not architect
  3. Prefer executor-low for simple changes - only upgrade if it fails
  4. Use writer (haiku) for all documentation tasks
  5. Avoid opus agents unless the task genuinely requires deep reasoning
  1. 批量处理相似任务:将相似任务批量交给一个Agent处理,而非创建多个Agent
  2. **使用explore(haiku)**进行文件发现,而非architect
  3. 优先使用executor-low处理简单修改 - 仅在执行失败时升级
  4. **使用writer(haiku)**处理所有文档编写任务
  5. 避免使用opus Agent,除非任务确实需要深度推理

Disabling Ecomode

禁用Ecomode

Ecomode can be completely disabled via config. When disabled, all ecomode keywords are ignored.
Set in
~/.claude/.omc-config.json
:
json
{
  "ecomode": {
    "enabled": false
  }
}
可通过配置完全禁用Ecomode。禁用后,所有ecomode关键字将被忽略。
~/.claude/.omc-config.json
中设置:
json
{
  "ecomode": {
    "enabled": false
  }
}

State Management

状态管理

Ecomode state is tracked in
.omc/state/ecomode-state.json
.
When work is complete, run
/oh-my-claudecode:cancel
for clean state cleanup.
Ecomode状态记录在
.omc/state/ecomode-state.json
文件中。
工作完成后,运行
/oh-my-claudecode:cancel
以清理状态。