Key Limitation: No Effort/Thinking Parameter Access

Critical finding: Claude Code custom commands and Task subagents support model selection but NOT effort/thinking parameters.

FeatureDirect APIClaude Code
Model selection
Opus effort parameter
Haiku thinking budget

What This Means

  • Opus 4.5 in Claude Code runs at default (high) effort
  • Haiku 4.5 in Claude Code runs with thinking OFF (default)
  • Cannot access the 39% cost savings from effort: medium
  • Cannot enable Haiku extended thinking for complex tasks

Claude Code-Specific Pricing

Since we can’t use Opus medium effort, the cost comparison changes:

ModelConfig in Claude CodeCost/10K taskQuality
Haiku 4.5thinking: OFF (default)$0.060~70%
Sonnet 4.5standard$0.18077.2%
Opus 4.5effort: HIGH (default)$0.18080.9%

Key insight: Opus high = Sonnet cost, but Opus has better quality!

Revised Strategy for Claude Code

┌─────────────────────────────────────────────────────────────┐
│ MAIN CONVERSATION: Opus 4.5 (high effort - default) │
│ Or: Sonnet 4.5 for cost-conscious users │
└─────────────────────────────────────────────────────────────┘
Task Subagents
┌───────────────────┴───────────────────┐
▼ ▼
┌─────────────────┐ ┌─────────────────┐
│ HAIKU 4.5 │ │ OPUS 4.5 │
│ (Simple) │ │ (Complex) │
├─────────────────┤ ├─────────────────┤
│ Cost: $6/M │ │ Cost: $18/M │
│ Quality: ~70% │ │ Quality: 80.9% │
│ Speed: Fastest │ │ Speed: Fast │
├─────────────────┤ ├─────────────────┤
│ • Install deps │ │ • Schema design │
│ • Run tests │ │ • Refactoring │
│ • File ops │ │ • Architecture │
│ • Verification │ │ • Integration │
│ • Simple docs │ │ • Critical code │
└─────────────────┘ └─────────────────┘

Why Sonnet is Now Obsolete in Claude Code

Since Opus high effort = Sonnet cost ($18/M):

ComparisonSonnet 4.5Opus 4.5 (high)Winner
Cost$18/M$18/MTie
Quality77.2%80.9%Opus (+3.7pp)
Long tasksBaseline+29%Opus
Code quality1/8 langs7/8 langsOpus

Verdict: For complex tasks in Claude Code, always use Opus 4.5 - same cost, better quality.

Custom Command Configuration

Simple Task Command (Haiku)

---
model: claude-haiku-4-5-20251015
description: Run tests and report results
allowed-tools: Bash(bun test:*), Read
---
Run the test suite and provide a summary of results.

Complex Task Command (Opus)

---
model: claude-opus-4-5-20251101
description: Architectural analysis and refactoring
allowed-tools: Read, Write, Edit, Glob, Grep
---
Analyze the codebase architecture and propose improvements.

Planning Command (Opus)

---
model: claude-opus-4-5-20251101
description: Create detailed implementation plan
allowed-tools: Read, Glob, Grep, Write
---
Create a comprehensive plan for the requested feature.

Task Subagent Model Selection

In the Task tool, specify the model:

// Simple task → Haiku
Task(
subagent_type: "general-purpose",
model: "haiku",
prompt: "Install dependencies and verify setup"
)
// Complex task → Opus (NOT Sonnet)
Task(
subagent_type: "general-purpose",
model: "opus",
prompt: "Design the Zod schema with .passthrough() for flexibility"
)

Cost Comparison: Claude Code vs Direct API

For Complex Tasks (18 tasks like frontmatter-improvement)

Claude Code (no effort parameter):

Planning: 1 × Opus high = $18/M
Simple (11 tasks): 11 × Haiku = $66/M
Complex (7 tasks): 7 × Opus high = $126/M
Total: $210/M

Direct API (with effort parameter):

Planning: 1 × Opus high = $18/M
Simple (11 tasks): 11 × Haiku = $66/M
Complex (7 tasks): 7 × Opus MEDIUM = $77/M
Total: $161/M
Savings: 23% cheaper with direct API

When to Use Direct API Instead

Consider direct API calls when:

  1. Running high-volume batch operations
  2. Need the 39% cost savings from Opus medium
  3. Building custom tooling outside Claude Code
  4. Cost optimization is critical

Updated Execution Pattern

For the /execute Slash Command

---
model: claude-opus-4-5-20251101
description: Execute a plan with optimal model routing
allowed-tools: Task, Read, Write, Bash, Glob, Grep
---
Execute the plan at .claude/plans/$ARGUMENTS.md
Task routing:
- Simple/mechanical tasks → model: haiku
- Complex reasoning tasks → model: opus
- All tasks → NO Sonnet (Opus same cost, better quality)

Example Task Classification

Task TypeModelRationale
bun installHaikuCommand execution, no reasoning
bun testHaikuCommand execution, report results
Verify TypeScriptHaikuSimple check, pass/fail
Create Zod schemaOpusRequires design reasoning
Replace parserOpusComplex refactoring
Update functionsHaiku or OpusDepends on complexity
DocumentationHaikuStraightforward writing

Speed Considerations

Haiku advantages:

  • 3-5x faster than Opus for simple tasks
  • Lower latency for quick operations
  • Ideal for parallel execution of many simple tasks

Opus advantages:

  • Better first-attempt success (fewer retries)
  • Token efficient (generates less verbose output)
  • Better for sequential complex reasoning

Monitoring and Optimization

Track These Metrics

  1. Task success rate by model

    • Haiku failures on “simple” tasks → reclassify as complex
    • Opus overkill on tasks → downgrade to Haiku
  2. Cost per successful task

    • Haiku: Should be ~$0.06 per task
    • Opus: Should be ~$0.18 per task
    • Watch for retry overhead
  3. Total execution time

    • Haiku parallelization benefits
    • Opus single-attempt efficiency

Adjustment Triggers

  • Haiku failure rate >10%: Reclassify tasks or use Opus
  • Opus tasks too simple: Downgrade to Haiku
  • Cost exceeds budget: Review task classification

Summary: Claude Code Optimal Strategy

RoleModelWhy
Main conversationOpus 4.5 or Sonnet 4.5User preference/budget
PlanningOpus 4.5Best reasoning
Simple executionHaiku 4.5Fastest, cheapest
Complex executionOpus 4.5Same cost as Sonnet, better quality
Sonnet 4.5Skip itNo advantage in Claude Code

Future Considerations

If Claude Code Adds Effort Parameter Support

The strategy would change to:

  • Simple tasks: Haiku (unchanged)
  • Complex tasks: Opus medium (39% cheaper than current)
  • Critical tasks: Opus high (unchanged)

Potential savings: ~23% reduction in complex task costs

Feature Request

Consider requesting Anthropic add effort/thinking parameters to:

  • Custom slash command YAML frontmatter
  • Task subagent configuration
  • Claude Code settings

Last updated: 2025-11-24 Key insight: In Claude Code, Opus 4.5 (high effort) costs the same as Sonnet 4.5 but delivers +3.7pp better quality. Always prefer Opus over Sonnet for complex tasks.