Skip to content

Which Claude Model to Build With: Fable, Opus, Sonnet, Haiku

Selecting the right Claude model to build with: comparing Opus 5.5, Sonnet 5.5, Haiku 5.5, and Fable 5.2 across SWE-bench task costs and latency.

Tuan Tran Van
10 min read
Updated 24/11/2026
Contents (7 sections)
  1. The current Claude model lineup: From Haiku to Fable
  2. Picking a model by task: Why Opus 5.5 is the default starting point
  3. The Effort dial: Tuning reasoning depth before jumping tiers
  4. Context cost vs latency trade-offs: Caching, Fast Mode, and prompt tiers
  5. Mixing models: Multi-model architectures in production
  6. The verdict: Start with Opus 5.5 and optimize against real benchmarks
  7. References

When you design agentic workflows and production software engineering systems, selecting the right Claude model to build with requires evaluating model tiers based on the cost per completed task rather than isolated pricing.

Balancing raw model capability against effort parameter tuning, lifetimes, and context window management dictates your real-world operational spend.

For most agentic and production software engineering workloads, you should select Claude Opus 5.5 operating at its default medium effort setting as your initial baseline. It delivers high-tier task execution at a fraction of the cost per completed attempt compared to scaling to higher pricing tiers or relying on unoptimized fallback strategies.

Selecting lower per-token rates on lighter models often increases your net spend if lower pass rates trigger repeated agent loops and expensive error cascades.

The four Claude model tiers: Haiku, Sonnet, Opus, and Fable balancing speed, reasoning depth, and token cost

The current Claude model lineup: From Haiku to Fable

When you map out the current Claude model lineup, your choices span from lightweight execution models to high-capability frontier reasoning engines.

Claude Haiku 5.5 serves high-volume, latency-sensitive tasks where you can check outputs algorithmically or programmatically.

Operating at its default medium effort setting, Haiku 5.5 scores 85% on GPQA Diamond and achieves a $0.011 cost per passed attempt on Managed Agents workflows. On the Messages API, however, Haiku 5.5 applies a 5x token pricing penalty whenever your request context exceeds 100,000 tokens, requiring you to implement proactive conversation compaction to keep operational costs low. Next in line, Claude Sonnet 5.5 acts as your balanced workhorse, priced at $2.00 per million tokens (MTok) input, $10.00 per MTok output, and $0.10 per MTok cache reads. On the SWE-bench Pro benchmark, Sonnet 5.5 solves 80.3% of tasks at medium effort for $0.07 per solved task, and 87.6% of tasks at its default high effort setting for $0.11 per solved task.

Claude Opus 5.5 serves as your primary baseline for complex agentic workloads, priced at $4.00 per MTok input, $20.00 per MTok output, and $0.20 per MTok cache reads. When you analyze SWE-bench Pro evaluation metrics across effort tiers, Opus 5.5 demonstrates clear scaling performance: low effort solves 87.4% of tasks at $0.12 per solved task; default medium effort solves 92.8% at $0.22 per solved task; high effort solves 95.3% at $0.31 per solved task; and xhigh effort reaches 96.7% at $0.74 per solved task.

At the top tier, Claude Fable 5.2, Fable 5.1, and Mythos 5.2 define the frontier tier for long-horizon reasoning and complex problem-solving. Fable 5.2 solves 96.3% of SWE-bench Pro tasks at high effort (its Messages API default) for $1.39 per solved task, and scores 57.7% on DeepResearch Bench II at high effort for $4.82 per task. The Fable tier features a reduced cache read multiplier of 0.025x the input rate. This yields a cache read cost of $0.25 per MTok on Fable 5.1 (based on its $10.00 per MTok input price) and $0.40 per MTok on Fable 5.2 (based on its $16.00 per MTok input price).

Picking a model by task: Why Opus 5.5 is the default starting point

If you evaluate model performance solely on per-token rate cards, you will make suboptimal architectural decisions. A model with a higher per-token price often completes complex tasks in far fewer agent turns and tool calls, yielding a significantly lower net cost per completed task.

For example, when you run Claude Opus 5.5 at default medium effort, it matches the task completion performance of Claude Fable 5.1 at default high effort on SWE-bench Pro (92.8% versus 92.3%) while cutting your cost per solved task by roughly 80% ($0.22 versus $1.19). Similarly, running Opus 5.5 at low effort matches Sonnet 5.5's default high effort accuracy (87.4% versus 87.6%) while adding only a ~7% cost premium per solved task ($0.12 versus $0.11).

Production spend in autonomous workloads concentrates heavily within a long tail of complex inputs. Data from the WideSearch benchmark demonstrates this distribution clearly: across a 20-problem evaluation run, just two tail problems (10% of the workload) generated 43% of total token spend, with a single problem accounting for 30% of the entire bill.

When an under-powered model fails on difficult edge cases, your system incurs full token charges for the failed initial attempts, followed by compounding spend on retries and downstream error recovery. By establishing Opus 5.5 as your starting baseline—and configuring high effort or fallbacks on failed tail tasks—you ensure your system possesses sufficient baseline reasoning depth to resolve tail problems cleanly before expensive retry cascades compound your bill.

Comparison spectrum of Claude model tiers across task complexity and SWE-bench completion cost

The Effort dial: Tuning reasoning depth before jumping tiers

You can use the effort parameter to control reasoning depth, tool usage, and internal thoroughness without changing your underlying model tier.

On the Messages API, high effort is the default setting for Sonnet 5.5 and Fable 5.2, whereas medium effort is the default for Opus 5.5 and Haiku 5.5. Tuning effort down reduces output generation latency and token volume, while raising effort allows models to run extended self-review loops and execute additional tool iterations.

Re-running failures policy

For workloads with checkable output conditions, such as unit test suites or deterministic verifiers, you should implement a dynamic effort policy rather than a fixed static setting. By running all initial execution attempts at low effort and automatically re-running failing attempts at high effort, you optimize both cost and pass rates. On SWE-bench Pro using Opus 5.5, a low-then-high failure re-run policy achieves a ~97% task resolution rate at an average cost of $0.17 per task. This matches or exceeds the pass rate of running every task at fixed high effort ($0.29 per task) while achieving a ~40% reduction in overall system spend.

Latency vs. time awareness

In long-horizon agent execution, you can inject explicit temporal constraints to cut latency and compute spend without dropping model tiers. When you explicitly prompt the model that execution speed matters while supplying the exact elapsed time on every request, you cut Opus 5.5 single-agent execution time by 47% and reduce task cost by 60% on median DRACO research benchmarks. This optimization requires only a minor score trade-off of 4.1 points, giving you a direct mechanism to bound cost and execution time on complex research tasks.

The Effort dial optimization strategy: low-effort runs with high-effort retries on failure

Context cost vs latency trade-offs: Caching, Fast Mode, and prompt tiers

Prompt caching is your primary lever for reducing operational spend in multi-turn agent loops.

Because agent conversations re-send accumulated historical context on every turn, prompt caching charges a write premium (1.25x input price for 5-minute lifetimes, 2.0x for 1-hour lifetimes) on new tokens, but re-reads cached context at steep discounts (0.05x on Opus 5.5 and Sonnet 5.5; 0.025x on Fable 5.2).

On DeepResearch Bench II agent runs, prompt caching reduces net task costs by 4.8x to 7.2x.

As a practical rule of thumb, migrate from the default 5-minute cache to the 1-hour cache duration when more than 1 in 20 requests follows a pause between 5 and 60 minutes.

To prevent cache expiration without paying the 1-hour cache write multiplier on models like Opus 5.5 or Sonnet 5.5, you can issue keep-alive requests every 4 minutes. Sending a keep-alive request every 4 minutes with max_tokens: 0 refreshes the 5-minute cache lifetime without generating output tokens or incurring output charges. You must preserve original request headers (such as anthropic-beta) during keep-alive calls; otherwise, beta-gated fields in the replayed body will be rejected. Note that max_tokens: 0 keep-alive requests return an API error if your request has thinking.type: "enabled", , or forced tool choices active, so you must select the 1-hour cache duration for those specific workloads instead.

python
import anthropic
 
client = anthropic.Anthropic()
 
def send_keep_alive(last_request_params: dict, headers: dict = None):
    keep_alive_params = last_request_params.copy()
    keep_alive_params["max_tokens"] = 0
    keep_alive_params.pop("stream", None)
 
    extra_headers = headers if headers else {}
 
    response = client.messages.create(
        extra_headers=extra_headers,
        **keep_alive_params
    )
    return response.usage

When your system requires accelerated output delivery, Fast Mode increases generation throughput up to 2.5x higher output tokens per second (OTPS) on Opus 5.5, Fable 5.2, and Mythos 5.2. Fast Mode applies a 2x price multiplier ($8 input / $40 output per MTok on Opus 5.5; $16 input / $80 output on Fable 5.2). It does not improve time to first token (TTFT), and toggling Fast Mode mid-conversation triggers a prompt cache miss because requests operating at different speeds do not share cached prefixes.

python
import anthropic
 
client = anthropic.Anthropic()
 
response = client.messages.create(
    model="claude-opus-5-5",
    max_tokens=4096,
    speed="fast",
    messages=[
        {"role": "user", "content": "Refactor this module to use dependency injection"}
    ]
)

Maintain strict context hygiene by setting max_tokens appropriately across your agent fleet. Setting max_tokens to 64,000 prevents truncated turns without increasing average cost per solved task. Furthermore, when you audit your system prompts to eliminate legacy instructions written for older model generations (such as "verify twice before submitting"), you can achieve up to a 14% net spend reduction during model upgrades by preventing redundant tool calls and excessive generation.

Mixing models: Multi-model architectures in production

Advisor strategy

In advanced production setups, you can deploy multi-model patterns to balance intelligence against execution cost. The Advisor architecture uses a lower-cost primary executor (such as Opus 5.5 or Sonnet 5.5) that consults a frontier advisor model (such as Fable 5.1) on-demand via the advisor tool for difficult reasoning steps. On internal agentic-coding benchmarks, pairing an Opus 5.5 executor at high effort with a Fable 5.1 advisor increased task accuracy to 90.1% ($2.92 per attempt) compared to 88.4% for Opus 5.5 high operating alone ($1.38 per attempt). However, if your executor rarely consults the advisor, the attached tool definition (roughly 1,000 tokens per request) introduces prompt token overhead across short requests that you must monitor.

Orchestrator strategy

The Orchestrator pattern allows you to delegate bulk parallel execution across files or context boundaries larger than a single request window. In a 22-million-token Python defect-search benchmark spanning 201 code repositories, an Orchestrator model (Opus 5.5 at high effort) assigned subtasks to lower-cost workers (Sonnet 5.5 at default effort). This delegated configuration achieved an F1 score of 0.831, matching the accuracy of Opus 5.5 running alone at medium effort (0.827) while cutting your total spend by 31% ($139 versus $200–$236 per full run).

Multi-model production architectures: the Advisor and Orchestrator patterns

The verdict: Start with Opus 5.5 and optimize against real benchmarks

Start your production development with Claude Opus 5.5 configured at its default medium effort level.

This baseline balances task completion capability against token spend, providing optimal cost-per-completed-task performance across software engineering and agentic workloads.

Follow a strict sequential optimization order before modifying your model tiers: first, enable prompt caching across all multi-turn interactions; second, audit system prompts to remove legacy verbose instructions; third, sweep effort parameters and implement low-effort initial runs with high-effort retries on failure; finally, introduce Fast Mode or multi-model architectures (Advisor or Orchestrator) only when empirical benchmarks on your target workload validate the added architectural complexity.

References

Check yourself

Three quick questions to see whether the main ideas stuck.

  1. Which Claude model should serve as your baseline starting point for engineering workloads?
  2. When a model fails on a task with checkable tests, what is the most cost-effective first step?
  3. What risk occurs if you modify the top-level system prompt mid-conversation with thinking blocks?

Oral exam

Questions that test whether you understand how it works, not just what it is. Answer each one in your own words before you open the model answer.

  1. 1The selection metric: cost per completed task

    Why can't a team simply pick the strongest Claude model, or the cheapest one, for everything? And what does "cost per completed task" measure that per-token price does not?

    Model X costs $0.04 per attempt and passes 50% of bug-fix tasks; when it fails, it loops and spends about 3× as much before giving up. Model Y costs $0.10 per attempt and passes 95%. Which is cheaper per completed task, and what happens to X's failures if there is no automated test suite to catch them?

    Show the answer

    Near the top of the range, quality grows much more slowly than cost: Fable 5.2 at high effort solves 96.3% of the SWE-bench Pro subset at $1.39 per task, while Opus 5.5 at medium solves 92.8% at $0.22, so 3.5 extra points cost about six times more. At the bottom, a cheap model that fails often pays for its failures. And you rarely know a task's difficulty in advance, so the framework is a default plus measured escalation, not a lookup table.

    Cost per completed task is total spend across all attempts, failed ones included, divided by the number of tasks that actually pass. Several mechanisms push a cheap model's number up:

    • more attempts per success, because each failure needs a retry;
    • failed attempts often cost more than successful ones, because the model loops or reasons in circles;
    • runs cut off by max_tokens are billed in full and produce nothing usable.

    For X, an average attempt costs 0.5 × $0.04 + 0.5 × $0.12 = $0.08, and a 50% pass rate means two attempts per success: about $0.16 per completed task. Y needs about 1.05 attempts at $0.10: about $0.105. X is 2.5× cheaper per attempt and roughly 1.5× more expensive per finished task.

    Without a verifier, nothing triggers a retry, so X's bad fixes are merged and shipped. The cost does not disappear; it moves off the API bill onto reviewers, users and incident time. Cost per completed task is only measurable, and retry strategies only work, when something can automatically tell a pass from a fail.

  2. 2The four tiers and the job each fits

    Pick a starting tier (Haiku, Sonnet, Opus or Fable) for each workload, and name the one property of the workload that decides it:

    • classifying 2 million support tickets a day into 12 categories, with a labelled sample that scores accuracy automatically;
    • writing unit tests for a medium-sized module as part of a developer's daily work;
    • a multi-day autonomous agent migrating a monolith into services, where one wrong architecture decision costs the team weeks.
    Show the answer

    Ask three questions of each workload: how often does it run, can a machine check the output, and what does one wrong answer cost? The tier follows from those, not from how hard the task sounds.

    Tickets: Haiku. Volume makes unit price dominate, but what makes Haiku safe is the labelled sample. You can measure its accuracy; if it is good enough you stop at the cheapest tier, and if not the numbers tell you to move up. Cheap, high volume and verifiable together is the full reason.

    Unit tests: Sonnet is reasonable, and so is the article's general default, Opus at medium effort. Sonnet at high effort and Opus at low cost about the same ($0.11 versus $0.12 per task). The tests can be run, but a passing test is not a good test: one with no real assertions always passes, so this verifier checks that the code runs, not that it is correct.

    Migration agent: Fable, or Opus as the executor with Fable as an advisor at architecture decision points. The deciding facts are the long horizon, where errors compound over many steps; the cost of one error, where weeks of team time dwarf the gap between $0.22 and $1.39 per task; and the fact that no test suite can check an architecture decision, so cheap-run-then-retry is unavailable. "It is a big task" decides nothing, because Opus is already the default for agents.

  3. 3The effort knob

    Keep the model fixed at Opus 5.5. What does effort actually change about how the model works on a request?

    You run a trivial task, renaming one variable across a 3-file project, once at low and once at high. Predict what happens to the success rate, the cost and the latency, and explain each.

    Show the answer

    effort sets how much computation the model spends searching: how many thinking tokens it generates, how deep its tool-calling goes, and how many self-check passes it makes before the final output. Two points follow:

    • The weights do not change. More effort helps when the answer is reachable with more search; it cannot supply knowledge or skill the model lacks. When raising effort stops helping, that is the signal to change tier.
    • Effort is a budget, not a fixed bill. The model adapts to the task, so the gap between low and high is widest on hard tasks.

    On the rename, success stays the same: low already solves it, and a correct rename has no extra depth left to find. Cost rises at high, because extra thinking tokens and verification tool calls are output tokens (about 5× the input price) and each tool call resends the context. Latency rises too, because tokens are generated one after another, thinking comes before the answer, and each tool call is another sequential round trip. high can also over-engineer, editing files nobody asked it to touch. Trivial work belongs at low.

  4. 4Escalation: low first, re-run failures at high

    On 100 coding tasks with Opus 5.5, running everything at low costs about $0.11 per task with a 13% failure rate; running everything at high costs about $0.29 per task and solves 95.3%. The strategy: run every task at low, let a test suite flag the failures, and re-run only those at high.

    Roughly what does a task cost under this strategy, and why? In practice it reaches about 97% success, higher than high everywhere: what is the mechanism? And what happens if the test suite is weak, so that one in four bad outputs passes anyway?

    Show the answer

    Every task pays the low price once. Only the roughly 13% that fail pay again at high, adding about 0.13 × $0.29 ≈ $0.04, so around $0.15. The measured figure is $0.17 because the tasks that fail are the hard ones and cost more than average at high. Either way, 87% of tasks never pay the high price, which makes the strategy about 41% cheaper than high everywhere.

    It beats high everywhere through retry plus selection, not because low is smarter. A task that fails at low gets two independent attempts, and the second takes a different path. In the high-everywhere run each task gets one attempt, and the ones that fail have no second chance. The tests aim the second attempt exactly at the tasks that need it.

    With a weak suite, about a quarter of the 13 failures pass while wrong. Nothing re-runs them, so roughly three bugs ship and the real success rate falls to about 94%. The reported figure stays at 97%, because the same weak tests produce it: the dashboard says things are better than they are. The strategy, and the success metric, are only as good as the verifier.

  5. 5Prompt caching and preserved thinking

    A long coding-agent session runs on Opus 5.5 with extended thinking and prompt caching on. Forty turns in, the cache is warm, and the agent must follow a new rule for the rest of the session: never touch files under /migrations. What is the best way to add the rule?

    1. A.Append the rule to the top-level system prompt; prompt caching adapts to small changes automatically
    2. B.Send the rule as a new mid-conversation instruction at the end, leaving the system prompt and tool definitions unchanged
    3. C.Delete the earlier thinking blocks from the history first, then edit the system prompt so nothing stale conflicts
    4. D.Switch to the 1-hour cache duration so the edited system prompt is kept longer
    Show the answer

    B. The cache is keyed on the exact prefix of the request, and a change invalidates everything after the changed token. The system prompt sits at the very start, so editing it invalidates all forty turns, and the next request rewrites the whole history at the cache-write price instead of reading it cheaply. Adding the rule at the end leaves the cached prefix intact.

    A also hits a second, worse failure. On Opus 5.5, Sonnet 5.5 and Fable 5.2, earlier thinking blocks are preserved in the history and tied to the context that produced them. Editing the system prompt or tool definitions mid-session invalidates them, which leads to a 400 Bad Request or a forced cache rewrite costing 20 to 50 times more.

    C changes the prefix too, so it breaks the cache as well, and it throws away the agent's earlier reasoning. D misreads the mechanism: cache duration controls how long an entry lives, not what it matches, so an edited prefix misses whether the entry lasts five minutes or an hour.

  6. 6Output-side failures: max_tokens and Fast mode

    To save money, a team lowers max_tokens on a Fable 5.2 coding agent from 64,000 to 16,384. A week later the cost per completed task is up and the success rate is down. Why, and why does the same change hurt Fable much more than Opus?

    The team also turns on Fast mode for its user-facing chat. During a traffic spike users see errors, although the team's normal rate limits are far from exhausted. What is going on, and what should the code do?

    Show the answer

    max_tokens is a hard cut-off, not a target the model plans around. Every token generated up to the cut-off is billed, and those are output and thinking tokens, the expensive kind. Thinking comes first, so a turn cut off mid-thinking often has not started writing the patch at all: you pay for 16k tokens and get nothing usable. That attempt counts as a failure, and a retry pays again from scratch. A lower ceiling does not shrink what a successful task needs; it makes more attempts die with a bill attached. Fable thinks longer on hard tasks, so a 16k ceiling truncates about 85% of its turns against about 25% for Opus.

    Fast mode requests draw on a separate rate-limit pool. A spike can exhaust that pool and return 429 while the standard quota sits mostly unused, which is why "our normal limits are fine" is the clue. The code should catch the 429 and fall back to a standard-speed request, and it should turn off the SDK's automatic retries on the fast call. Otherwise the SDK keeps retrying with backoff against the same exhausted pool, and the user waits longer than standard speed would have taken.

  7. 7Multi-model: Advisor versus Orchestrator

    Team 1 has Fable plan and split the work while Haiku subagents do the pieces in parallel, and uses it to fix a bug in a 30k-token service. Cost and reliability both end up worse than plain Opus.

    Team 2 runs Opus as the executor with an advisor tool that consults Fable at hard decisions. Logs show the executor almost never calls the advisor, yet costs went up compared with plain Opus.

    Explain the mechanism behind each backfire. What property of a workload makes the Orchestrator pattern pay off?

    Show the answer

    Team 1 pays for orchestration it does not need. The task fits in one context window, so one model could see everything. Instead they pay for Fable's planning tokens and for the context passed to every subagent. Reliability drops because each Haiku sees only a slice of the service, while a bug usually spans a caller, a callee and shared state; every handoff compresses context, and what the orchestrator leaves out the subagent never learns. Debugging is also mostly a sequential chain of reasoning, so there is no parallel speed-up to pay for the coordination.

    Team 2 pays for a tool definition it never uses. The advisor definition adds about 1,000 prompt tokens to every request on every turn, whether or not it is called. Everything else matches plain Opus, so with a consult rate near zero the only difference is overhead that grows each turn. Measure the consult rate before keeping an Advisor setup.

    The Orchestrator pattern pays off when the workload exceeds a single context window and splits into fairly independent pieces, such as hunting bugs across a 22-million-token codebase, which came out 31% cheaper than Opus alone. A huge task that is one long chain of dependent steps still will not benefit.

  8. 8Design problem: one system, three workloads

    You are building an AI system for a bank's customer support, with three workloads:

    • live customer chat, where customers leave if the first response takes more than 3 seconds, traffic spikes sharply at month-end, and every conversation starts with the same 8k-token policy document;
    • nightly tagging of 50,000 chat transcripts by complaint type, with 2,000 human-labelled transcripts available;
    • drafting refund decisions over $5,000, a few a day, approved by a busy human who tends to rubber-stamp, where a wrong approval is a regulatory problem.

    For each, which tier and effort level would you start with, what property decided it, and what safeguard covers its most likely failure?

    Show the answer

    Live chat: a fast tier such as Haiku or Sonnet at low effort. Latency decides it, because thinking happens before the first token and every extra second of it loses customers. Put the 8k-token policy at the start of the prompt and never edit it mid-conversation, so prompt caching serves it cheaply on every turn. If you add Fast mode for the spikes, handle the 429 that comes when its separate capacity pool runs out: fall back to standard speed with the SDK's automatic retries off, rather than letting customers wait on retries.

    Nightly tagging: Haiku. It runs at volume, latency does not matter overnight, and a machine can check the output. The 2,000 labelled transcripts are the safeguard: score Haiku on them before trusting it and after every prompt or model change, and escalate only the categories where it falls short. Without that eval set, picking Haiku would be a gamble.

    Refund decisions: Opus at high effort, or Fable. The volume is tiny and the cost of one wrong answer is huge, so the price per task barely matters. A human who rubber-stamps is not a real verifier, so the safeguard has to make the check real: rule-based checks against policy that block before approval, the model citing the exact policy clauses and transaction facts it relied on so the reviewer has something concrete to check, and routing any low-confidence or disputed case for a full review instead of a signature.

Share this article

AI glossary