Overview
This tutorial shows how to run Claude Fable 5 — Anthropic’s most capable model, positioned above the Opus family — on the Swarms API. Fable 5 is built for the hardest reasoning and long-horizon agentic work: multi-step analysis, deep synthesis, and debates where agents must genuinely engage with each other’s arguments. Using it requires exactly two things in your agent config: setmodel_name to anthropic/claude-fable-5, and leave temperature as None (the model rejects numeric sampling parameters). Everything else about your existing agents and swarms stays the same. The examples below walk through the full range of agent types — a standalone single agent, a sequential pipeline, a concurrent specialist fan-out, a director-led hierarchical swarm, a multi-agent group chat, and a cost-efficient mixed-model pattern that reserves Fable 5 for the synthesis step.
What This Example Shows
- The correct model name to use (
anthropic/claude-fable-5) - Why
temperaturemust beNonefor this model — never a number - A single agent on Claude Fable 5
- A
SequentialWorkflowresearch pipeline - A
ConcurrentWorkflowfan-out across specialist agents - A
HierarchicalSwarmwith an auto-generated director - A
GroupChatdebate between opposing analysts - A mixed-model pattern: Fable 5 as the aggregator, cheaper models as workers
Claude Fable 5 is Anthropic’s most capable generally available model, sitting above the Opus family. It is built for the hardest reasoning and long-horizon agentic work, and it is wired into every multi-agent primitive on the Swarms platform. Switching an existing agent to Fable 5 is a one-line change in your agent config.
Step 1: Get Your API Key
- Visit https://swarms.world/platform/api-keys
- Sign in or create an account
- Generate a new API key
- Set it as an environment variable:
Step 2: Install the Swarms Python Client
Step 3: Create the Client
Every example below reuses this client:Fable 5 reasons deeply before answering, so individual calls can take noticeably longer than smaller models — especially on hard tasks. Keep the client
timeout generous.Single Agent on Claude Fable 5
The minimal case. Note thattemperature is explicitly None — this is the only sampling configuration Fable 5 accepts.
SequentialWorkflow: Research → Analysis → Report
Agents run one after another; each receives the previous agent’s output. Fable 5’s long-horizon reasoning makes it a strong fit for every stage of a pipeline like this.ConcurrentWorkflow: Specialist Fan-Out
All agents receive the same task in parallel and answer independently — ideal when you want several expert perspectives at once.HierarchicalSwarm: Director + Workers
You define only the workers — the framework auto-generates a director that decomposes the task, routes subtasks to each worker, and synthesizes the final answer.GroupChat: Opposing Analysts Debate
Agents discuss the task together and can respond to each other’s arguments. Fable 5 is notably strong at pushing back on weak reasoning, which makes debates substantive rather than agreeable.Cost Pattern: Fable 5 Aggregator, Cheaper Workers
Fable 5 is priced above the Opus tier, so a common production pattern isMixtureOfAgents with inexpensive workers doing the breadth work and Fable 5 doing the final synthesis, where its reasoning matters most.
Using Fable 5 in Other Swarm Types
Every other swarm architecture takes the samemodel_name. Drop "model_name": "anthropic/claude-fable-5" (with temperature left as None) into any agent inside any of these swarm configs:
SequentialWorkflowConcurrentWorkflowAgentRearrangeMixtureOfAgentsGroupChatMajorityVotingCouncilAsAJudgeMultiAgentRouterHeavySwarmLLMCouncilDebateWithJudgeBatchedGridWorkflowRoundRobinPlannerWorkerSwarmauto
Common Pitfalls
400 error mentioning temperature, top_p, or top_k
400 error mentioning temperature, top_p, or top_k
You passed a numeric sampling parameter. Fable 5 removed
temperature, top_p, and top_k entirely. Set temperature to None (or delete the field) in every agent config that uses anthropic/claude-fable-5 — the Swarms API strips None fields before calling Anthropic.Requests take longer than with other models
Requests take longer than with other models
Expected. Fable 5 always reasons before answering and hard tasks can run for several minutes. Raise your client
timeout, and prefer swarm architectures that parallelize independent work (ConcurrentWorkflow, MixtureOfAgents) over long sequential chains when latency matters.A request returns empty content with a refusal stop reason
A request returns empty content with a refusal stop reason
Fable 5 ships with additional safety classifiers and may decline certain requests (notably deep cybersecurity and research-biology content) that other models answer. If your workload lives near those domains, route it to
anthropic/claude-opus-4-8 instead.Where do I find pricing?
Where do I find pricing?
Fable 5 pricing follows Anthropic’s published rates (50 per million input/output tokens) and is reflected in the Swarms cost-tracking endpoints. See the pricing page for current rates.
Next Steps
- Browse the Multi-Agent Architectures catalog for more swarm types
- Read the Single Agent Overview for the full agent config surface
- See the Claude Opus 4.8 example for the lower-cost Anthropic tier with the same no-temperature rule
- See Streaming to stream Fable 5 tokens to your client in real time