npx skills add https://github.com/aaaaqwq/agi-super-skills --skill model-hierarchy将任务路由到能够处理它们的最便宜模型。大多数智能体工作是常规性的。
80% 的智能体任务是日常维护性的。 文件读取、状态检查、格式化、简单的问答。这些不需要昂贵的模型。将高级模型留给真正需要深度推理的问题。
| 模型 | 输入 | 输出 | 最佳用途 |
|---|---|---|---|
| DeepSeek V3 | $0.14 | $0.28 | 常规通用工作 |
| GPT-4o-mini | $0.15 | $0.60 | 快速响应 |
| Claude Haiku | $0.25 | $1.25 | 快速工具使用 |
| Gemini Flash | $0.075 | $0.30 | 高吞吐量 |
| GLM 5 (智谱) | (OpenRouter Z.AI) | (OpenRouter Z.AI) | 常规 + 中等文本;200K 上下文; — 不要用于图像/视觉任务 |
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
| Kimi K2.5 (月之暗面) | $0.45 | $2.25 | 常规 + 中等;262K 上下文;多模态 (文本 + 图像 + 视频) |
仅文本模型 (例如 GLM 5): 不要用于任何需要图像输入或视觉的任务 — 包括照片分析、截图、图像生成工具或文档/图表视觉识别。应路由到具备视觉能力的模型 (例如 Kimi K2.5, GPT-4o, Gemini, 具备视觉的 Claude, GLM-4.5V/4.6V)。
具备视觉能力的第 1/2 层模型 (例如 Kimi K2.5): 用于可能涉及图像的常规或中等任务 — 截图、照片分析、文档、图像生成编排 — 而无需升级到高级视觉模型。
| 模型 | 输入 | 输出 | 最佳用途 |
|---|---|---|---|
| Claude Sonnet | $3.00 | $15.00 | 平衡性能 |
| GPT-4o | $2.50 | $10.00 | 多模态任务 |
| Gemini Pro | $1.25 | $5.00 | 长上下文 |
| 模型 | 输入 | 输出 | 最佳用途 |
|---|---|---|---|
| Claude Opus | $15.00 | $75.00 | 复杂推理 |
| GPT-4.5 | $75.00 | $150.00 | 前沿任务 |
| o1 | $15.00 | $60.00 | 多步推理 |
| o3-mini | $1.10 | $4.40 | 经济型推理 |
价格截至 2026 年 2 月。请查阅供应商文档获取当前费率。
在执行任何任务之前,先进行分类:
需要图像/视觉 → 不要分配给仅文本模型 (GLM 5 等)。使用来自第 1/2 层或第 3 层的具备视觉能力的模型 (例如 Kimi K2.5, GPT-4o, Gemini, Claude, GLM-4.5V)。
特征:
示例:
特征:
示例:
特征:
示例:
function selectModel(task):
# 规则 1: 视觉覆盖 (第 1/2 层包含仅文本模型)
if task.requiresImageInput or task.requiresVision:
return VISION_CAPABLE_MODEL # 例如 Kimi K2.5, GPT-4o, Gemini, Claude; 不要使用 GLM 5 或其他仅文本模型
# 规则 2: 升级覆盖
if task.previousAttemptFailed:
return nextTierUp(task.previousModel)
# 规则 3: 明确的复杂度信号
if task.hasSignal("debug", "architect", "design", "security"):
return TIER_3
if task.hasSignal("write", "code", "summarize", "analyze"):
return TIER_2
# 规则 4: 默认分类
complexity = classifyTask(task)
if complexity == ROUTINE:
return TIER_1
elif complexity == MODERATE:
return TIER_2
else:
return TIER_3
建议模型变更时,使用清晰的语言:
降级建议:
"这看起来是常规的文件工作。需要我生成一个在 DeepSeek 上运行的子智能体来处理吗?结果相同,成本却低得多。"
升级请求:
"我在这里遇到了能力极限。这需要 Opus 级别的推理能力。正在切换升级。"
解释层级结构:
"我让 Sonnet 运行繁重的分析,同时让子智能体在 DeepSeek 上获取数据。这样可以在关键之处不牺牲质量的同时降低成本。"
假设平均每天使用 100K 令牌:
| 策略 | 月度成本 | 备注 |
|---|---|---|
| 纯 Opus | ~$225 | 能力最强,花费最高 |
| 纯 Sonnet | ~$45 | 适用于大多数工作的良好默认选择 |
| 纯 DeepSeek | ~$8 | 便宜但处理难题能力有限 |
| 层级结构 (80/15/5) | ~$19 | 集所有优点于一身 |
80/15/5 分配比例:
结果:与纯高级模型相比,成本降低 10 倍,同时在复杂任务上保持同等质量。
# config.yml - 设置默认模型
model: anthropic/claude-sonnet-4
# 在会话中切换模型
/model opus # 为复杂任务升级
/model deepseek # 为常规任务降级
# 在廉价模型上生成子智能体
sessions_spawn:
task: "抓取并解析这 50 个 URL"
model: deepseek
OpenRouter (第 1 层,具备视觉或仅文本):
# 第 1 层,具备视觉 — Kimi K2.5 (多模态)
model: openrouter/moonshotai/kimi-k2.5
# 心跳、定时任务、涉及图像的任务:K2.5 处理文本和视觉。
# 第 1 层,仅文本 — GLM 5 (无视觉)
# model: openrouter/z-ai/glm-5 # 确切的 OpenRouter Z.AI ID 待定
# 仅用于常规文本任务;对于图像任务,请使用 Kimi K2.5 或其他具备视觉能力的模型。
# 在 CLAUDE.md 或项目说明中
当生成后台智能体时,使用 claude-3-haiku 处理:
- 文件操作
- 简单搜索
- 状态检查
保留 claude-sonnet-4 用于:
- 代码生成
- 分析任务
def get_model_for_task(task_description: str) -> str:
routine_signals = ['read', 'fetch', 'check', 'list', 'format', 'status']
complex_signals = ['debug', 'architect', 'design', 'security', 'why']
desc_lower = task_description.lower()
if any(signal in desc_lower for signal in complex_signals):
return "claude-opus-4"
elif any(signal in desc_lower for signal in routine_signals):
return "deepseek-v3"
else:
return "claude-sonnet-4"
不要:
应该:
为您的用例进行自定义:
每周安装数
1
代码仓库
GitHub 星标数
11
首次出现
1 天前
安全审计
安装于
zencoder1
amp1
cline1
openclaw1
opencode1
cursor1
Route tasks to the cheapest model that can handle them. Most agent work is routine.
80% of agent tasks are janitorial. File reads, status checks, formatting, simple Q&A. These don't need expensive models. Reserve premium models for problems that actually require deep reasoning.
| Model | Input | Output | Best For |
|---|---|---|---|
| DeepSeek V3 | $0.14 | $0.28 | General routine work |
| GPT-4o-mini | $0.15 | $0.60 | Quick responses |
| Claude Haiku | $0.25 | $1.25 | Fast tool use |
| Gemini Flash | $0.075 | $0.30 | High volume |
| GLM 5 (Zhipu) | (OpenRouter Z.AI) | (OpenRouter Z.AI) | Routine + moderate text; 200K context; text-only — do not use for image/vision |
| Kimi K2.5 (Moonshot) | $0.45 | $2.25 | Routine + moderate; 262K context; multimodal (text + image + video) |
Text-only models (e.g. GLM 5): Do not use for any task that requires image input or vision — no photo analysis, screenshots, image-generation tools, or document/chart vision. Route to a vision-capable model (e.g. Kimi K2.5, GPT-4o, Gemini, Claude with vision, GLM-4.5V/4.6V).
Vision-capable Tier 1/2 (e.g. Kimi K2.5): Use for routine or moderate tasks that may involve images — screenshots, photo analysis, docs, image-generation orchestration — without moving to premium vision models.
| Model | Input | Output | Best For |
|---|---|---|---|
| Claude Sonnet | $3.00 | $15.00 | Balanced performance |
| GPT-4o | $2.50 | $10.00 | Multimodal tasks |
| Gemini Pro | $1.25 | $5.00 | Long context |
| Model | Input | Output | Best For |
|---|---|---|---|
| Claude Opus | $15.00 | $75.00 | Complex reasoning |
| GPT-4.5 | $75.00 | $150.00 | Frontier tasks |
| o1 | $15.00 | $60.00 | Multi-step reasoning |
| o3-mini | $1.10 | $4.40 | Reasoning on budget |
Prices as of Feb 2026. Check provider docs for current rates.
Before executing any task, classify it:
Requires image/vision → Do not assign to text-only models (GLM 5, etc.). Use a vision-capable model from Tier 1/2 or 3 (e.g. Kimi K2.5, GPT-4o, Gemini, Claude, GLM-4.5V).
Characteristics:
Examples:
Characteristics:
Examples:
Characteristics:
Examples:
function selectModel(task):
# Rule 1: Vision override (Tier 1/2 includes text-only models)
if task.requiresImageInput or task.requiresVision:
return VISION_CAPABLE_MODEL # e.g. Kimi K2.5, GPT-4o, Gemini, Claude; do not use GLM 5 or other text-only
# Rule 2: Escalation override
if task.previousAttemptFailed:
return nextTierUp(task.previousModel)
# Rule 3: Explicit complexity signals
if task.hasSignal("debug", "architect", "design", "security"):
return TIER_3
if task.hasSignal("write", "code", "summarize", "analyze"):
return TIER_2
# Rule 4: Default classification
complexity = classifyTask(task)
if complexity == ROUTINE:
return TIER_1
elif complexity == MODERATE:
return TIER_2
else:
return TIER_3
When suggesting model changes, use clear language:
Downgrade suggestion:
"This looks like routine file work. Want me to spawn a sub-agent on DeepSeek for this? Same result, fraction of the cost."
Upgrade request:
"I'm hitting the limits of what I can figure out here. This needs Opus-level reasoning. Switching up."
Explaining hierarchy:
"I'm running the heavy analysis on Sonnet while sub-agents fetch the data on DeepSeek. Keeps costs down without sacrificing quality where it matters."
Assuming 100K tokens/day average usage:
| Strategy | Monthly Cost | Notes |
|---|---|---|
| Pure Opus | ~$225 | Maximum capability, maximum spend |
| Pure Sonnet | ~$45 | Good default for most work |
| Pure DeepSeek | ~$8 | Cheap but limited on hard problems |
| Hierarchy (80/15/5) | ~$19 | Best of all worlds |
The 80/15/5 split:
Result: 10x cost reduction vs pure premium, with equivalent quality on complex tasks.
# config.yml - set default model
model: anthropic/claude-sonnet-4
# In session, switch models
/model opus # upgrade for complex task
/model deepseek # downgrade for routine
# Spawn sub-agent on cheap model
sessions_spawn:
task: "Fetch and parse these 50 URLs"
model: deepseek
OpenRouter (Tier 1 with vision or text-only):
# Tier 1 with vision — Kimi K2.5 (multimodal)
model: openrouter/moonshotai/kimi-k2.5
# Heartbeats, cron, image-involving tasks: K2.5 handles text and vision.
# Tier 1 text-only — GLM 5 (no vision)
# model: openrouter/z-ai/glm-5 # exact ID TBD on OpenRouter Z.AI
# Routine text-only only; for image tasks use Kimi K2.5 or another vision-capable model.
# In CLAUDE.md or project instructions
When spawning background agents, use claude-3-haiku for:
- File operations
- Simple searches
- Status checks
Reserve claude-sonnet-4 for:
- Code generation
- Analysis tasks
def get_model_for_task(task_description: str) -> str:
routine_signals = ['read', 'fetch', 'check', 'list', 'format', 'status']
complex_signals = ['debug', 'architect', 'design', 'security', 'why']
desc_lower = task_description.lower()
if any(signal in desc_lower for signal in complex_signals):
return "claude-opus-4"
elif any(signal in desc_lower for signal in routine_signals):
return "deepseek-v3"
else:
return "claude-sonnet-4"
DON'T:
DO:
To customize for your use case:
Weekly Installs
1
Repository
GitHub Stars
11
First Seen
1 day ago
Security Audits
Gen Agent Trust HubPassSocketPassSnykWarn
Installed on
zencoder1
amp1
cline1
openclaw1
opencode1
cursor1
AI Elements:基于shadcn/ui的AI原生应用组件库,快速构建对话界面
60,400 周安装