Build with AI

How do you use Claude Haiku 5.5 as a fast sub-agent?

· By Robert Scales · 4 min read

Short answer

Let a larger model such as Claude Sonnet 5.5 plan the job and write the final answer, and hand the many small, repetitive pieces in between to Claude Haiku 5.5, each with narrow instructions and a fixed output format. Your code runs the Haiku calls in parallel, collects their short results, and passes only those to the larger model.

A sub-agent is a model call that does one delegated piece of a larger job and reports back. The model that hands out the pieces and assembles the result is often called the lead or orchestrator. Anthropic designed Claude Haiku 5.5, released on October 7, partly for this role: it recommends the model as a helper to Opus 5.5 or Sonnet 5.5 in coding work, and aims it at summaries, classification and other high-volume tasks.

The reason is price and speed. For requests up to 100,000 tokens, Haiku 5.5 costs $0.10 per million input tokens and $0.50 per million output tokens, a tenth of what Haiku 4.5 cost, and Anthropic calls it its fastest model. A token is a small piece of text, about part of a word. When a job breaks into hundreds of small reads, those prices change what is affordable.

The pattern in one picture

StageModelJobOutput
SplitYour codeCut the work into independent piecesA list of inputs
ReadHaiku 5.5, many calls in parallelExtract the same few fields from each pieceShort structured notes
CombineSonnet 5.5, one callReason over all the notes and write the resultThe final answer

The lead never reads the raw material, only Haiku's short notes. That keeps the expensive model's input small and its attention on judgment.

Each worker call should spell out four things: its objective, the exact output format, what it may use, and where its job stops. Vague assignments produce notes that can't be compared or combined, and small models need that discipline more than large ones.

A worked example: 500 customer reviews

A small online shop wants a one-page summary of what 500 customers said this quarter. Each review goes to Haiku 5.5 for a three-line note. Sonnet 5.5 then reads the 500 notes and writes the report.

import anthropic
from concurrent.futures import ThreadPoolExecutor

client = anthropic.Anthropic()  # reads the ANTHROPIC_API_KEY environment variable

WORKER = "claude-haiku-5-5"
LEAD = "claude-sonnet-5-5"

WORKER_RULES = """You read ONE customer review. Reply in exactly three lines:
TOPIC: one of price, quality, delivery, service, other
SENTIMENT: positive, negative or mixed
QUOTE: the single most telling sentence, copied exactly from the review
Do not add anything else. If the review is empty or not a review, write TOPIC: other."""

def read_review(review_text):
    msg = client.messages.create(
        model=WORKER,
        max_tokens=150,
        system=WORKER_RULES,
        messages=[{"role": "user", "content": review_text}],
    )
    return msg.content[0].text

with open("reviews.txt") as f:
    reviews = [r.strip() for r in f.read().split("\n---\n") if r.strip()]

with ThreadPoolExecutor(max_workers=8) as pool:   # several Haiku calls at once
    notes = list(pool.map(read_review, reviews))

report = client.messages.create(
    model=LEAD,
    max_tokens=1500,
    system="You write clear one-page reports for a small shop owner.",
    messages=[{"role": "user", "content":
        "Here are structured notes on this quarter's reviews:\n\n"
        + "\n\n".join(notes)
        + "\n\nWrite: the top three problems with counts, the top three strengths, "
          "and one action to take first. Use the quotes as evidence."}],
)
print(report.content[0].text)

Three details make it work. The worker's rules fix the output to three labeled lines, so the lead gets tidy, comparable notes. The worker gets a tight max_tokens limit, which caps cost and stops rambling. And the parallel pool runs several Haiku calls at the same time, so 500 reviews take minutes rather than an hour.

What does it cost? Using list prices and illustrative sizes, 1,000 tokens per review and 50 tokens per note:

Haiku 5.5 reads, Sonnet 5.5 writesSonnet 5.5 does everything
Reading 500 reviews (0.5 million input tokens)$0.05$1.00
Writing 500 notes (25,000 output tokens)about $0.01$0.25
Final report (about 30,000 in, 1,000 out)about $0.07about $0.07
Totalabout $0.13about $1.32

A tenfold difference on one report is small money. At thousands of documents a day, it decides whether a feature is worth building. Anthropic also notes that Haiku 5.5 uses a new tokenizer that produces slightly more tokens for the same text, so measure real usage rather than relying on estimates.

Try it: Run the worker function on 20 reviews and check every note by hand. Count how many have the right topic and sentiment. If fewer than 18 are right, tighten the rules or add two example reviews with their correct notes before scaling up.

Tuning the worker

Haiku 5.5 is the first Haiku with an adjustable effort setting, a control over how much it thinks before answering. For simple extraction, lower effort keeps it fast and cheap; for pieces that need a little interpretation, raising it can help. Test both on your 20 hand-checked examples and keep the lowest setting that passes.

Which jobs should stay with a bigger model?

Planning and splitting. Deciding how to divide an unfamiliar problem is judgment work. If the pieces are wrong, every sub-agent does the wrong thing quickly. Let Sonnet 5.5 or Opus 5.5 plan, or do the split in your own code when it is obvious, as with one review per call.

The final synthesis. Weighing hundreds of notes, spotting patterns and writing for a reader belongs to the lead. That is why the example keeps the report on Sonnet 5.5.

Complex coding. Anthropic itself says its larger Sonnet and Opus models remain the better choice for complex coding, even though Haiku 5.5 improved sharply on coding tests. Use Haiku for searching a codebase or summarizing files, not for designing a change.

Tightly linked work. Splitting pays off when the pieces are independent, like separate reviews. When every step needs the result of the previous one, or every worker would need the whole background to do its part, one capable model working through the task is usually simpler and more reliable.

A good rule of thumb: give Haiku the work you could hand to a careful assistant with a checklist, and keep for the bigger model anything that needs the checklist to be written first.

Sources

  1. Introducing Claude Haiku 5.5 — Anthropic, October 7, 2026
  2. Introducing Claude Sonnet 5.5 — Anthropic, September 28, 2026
  3. anthropic-sdk-python: README and message_create_params — Anthropic (GitHub), March 1, 2024

Get the free Guide to Artificial Intelligence

Sign up for the weekly newsletter and receive the free guide: what changed in AI this week, one lesson, one prompt to try. Unsubscribe in one click.

How we handle your address

Back to top

Display

Your choices are saved in this browser only. No data is sent.

Text size
100%
Colours
Reading
More settings
Accessibility statement