Agent selecting models

From diegosouzapw/awesome-omni-skill · View interactive version

Agent selecting models is an AI agent skill from the GitHub repository diegosouzapw/awesome-omni-skill. Guidance for selecting appropriate AI model (sonnet vs haiku) based on task complexity, reasoning requirements, and performance needs. Use when implementing agents or justifying model selection.

How to use this skill

Skill file

Selecting AI Models for Agents

Guidelines for choosing between sonnet and haiku models based on agent capabilities and task requirements.

When This Skill Loads

This Skill auto-loads when implementing agents or documenting model selection rationale.

Available Models

Sonnet (claude-sonnet-4-5)

Characteristics:

Use for: Complex, reasoning-intensive tasks

Haiku (claude-haiku-3-5)

Characteristics:

Use for: Simple, well-defined tasks

Decision Framework

Use Sonnet When Task Requires

✅ Advanced Reasoning

✅ Complex Pattern Recognition

✅ Sophisticated Analysis

✅ Multi-Step Orchestration

✅ Deep Web Research

Use Haiku When Task Is

✅ Pattern Matching

✅ Sequential Execution

✅ Straightforward Validation

✅ No Complex Reasoning

✅ High-Volume Processing

Model Selection Matrix

| Task Type | Complexity | Reasoning Required | Recommended Model |

| ------------------ | ----------- | --------------------------- | ----------------- |

| Content creation | High | Yes (narrative, structure) | Sonnet |

| Factual validation | High | Yes (source evaluation) | Sonnet |

| Quality assessment | High | Yes (subjective judgment) | Sonnet |

| Fix application | Medium-High | Yes (confidence assessment) | Sonnet |

| Link checking | Low | No (exists/accessible) | Haiku |

| File operations | Low | No (read/write/move) | Haiku |

| Pattern extraction | Low | No (regex matching) | Haiku |

| Cache management | Low | No (read/write/compare) | Haiku |

Agent-Specific Examples

Sonnet Examples

docs-checker (Complex validation):

model: sonnet

Reasoning:

docs-fixer (Sophisticated analysis):

model: sonnet

Reasoning:

docs-tutorial-checker (Pedagogical analysis):

model: sonnet

Reasoning:

Haiku Examples

docs-link-general-checker (Straightforward validation):

model: haiku

Reasoning:

docs-file-manager (File operations):

model: haiku

Reasoning:

Documenting Model Selection

Model Selection Justification Pattern

Include in agent documentation to explain model choice:

For Sonnet Agents:

**Model Selection Justification**: This agent uses `model: sonnet` because it requires:

- [Reasoning capability 1 - e.g., "Advanced reasoning to analyze technical claims"]
- [Reasoning capability 2 - e.g., "Deep web research to verify facts"]
- [Reasoning capability 3 - e.g., "Pattern recognition across multiple files"]
- [Decision-making type - e.g., "Complex decision-making for criticality levels"]
- [Orchestration need - e.g., "Multi-step validation workflow orchestration"]

For Haiku Agents:

**Model Selection Justification**: This agent uses `model: haiku` because it performs straightforward tasks:

- [Simple task 1 - e.g., "Pattern matching to extract URLs"]
- [Simple task 2 - e.g., "Sequential URL validation via web requests"]
- [Simple task 3 - e.g., "File existence checks"]
- [Simple task 4 - e.g., "Cache management (read/write/compare)"]
- [Simple task 5 - e.g., "Simple status reporting"]
- No complex reasoning or content generation required

Placement in Agent Files

Add justification near the top of agent file, after agent description:

---
name: example-agent
description: Agent description here
model: sonnet
---

# Agent Name

**Model Selection Justification**: [justification here]

[Rest of agent documentation]

Cost and Performance Considerations

Sonnet Trade-offs

Costs:

Benefits:

Use when: Quality and accuracy more important than cost/speed

Haiku Trade-offs

Benefits:

Limitations:

Use when: Cost and speed more important than complex reasoning

Decision Checklist

Before selecting a model, ask:

  1. Does the task require judgment calls?
  1. Are there multiple valid interpretations?
  1. Does it need deep analysis of context?
  1. Will it make complex decisions?
  1. Is it high-volume, low-complexity?
  1. Does cost matter more than quality?

Common Mistakes

❌ Using Sonnet for Simple Tasks:

# Overkill - use haiku
model: sonnet # Just checking if files exist

❌ Using Haiku for Complex Analysis:

# Insufficient - use sonnet
model: haiku # Analyzing code quality and architecture

✅ Match Model to Task Complexity:

# Simple pattern matching
model: haiku

# Complex reasoning
model: sonnet

Key Takeaways

Proper model selection ensures optimal performance, cost-effectiveness, and task completion quality.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.