Claude Code Consulting Tool: Let a cheaper model hire an expensive one as its strategist

Anthropic has launched the Advisor Tool API for Claude Code. The core idea is to have low-cost models like Sonnet perform tasks, while calling on flagship models such as Opus for decision-making advice when encountering difficult problems, thereby achieving an optimal balance between cost and intelligence.
Anthropic did something quite clever this week — they added a new API called the “Advisor Tool” to Claude Code.
In short: let the cheaper models do the heavy lifting, and when they hit a problem they can’t solve, pay the expensive model for advice.
This isn’t just a proof of concept — it’s an officially released API in beta form. It directly changes the cost structure when developers build AI agents.
The problem: flagship models are too expensive; cheaper models aren’t smart enough
Anyone who’s developed AI agents knows the reality — if you want the agent to be reliable, you need to use the strongest model. But those top models charge per token, so running complex tasks can cost several dollars per run, and at scale, the expense becomes unsustainable.
Take Anthropic’s own models as an example: Opus 4’s capabilities are unquestionable, but its price is several times that of Sonnet. In most agent scenarios, 80% of tasks don’t require Opus-level reasoning — reading files, writing boilerplate code, format conversions — Sonnet or even Haiku can handle these. But for the remaining 20% of critical decisions — architecture selection, complex bug root cause analysis, multi-step reasoning — cheaper models will crash and burn.
Previously, developers had three options: use the expensive model throughout (burn money), use the cheap model throughout (crash often), or build their own routing logic (requires time and effort).
Essentially, the Advisor Tool is Anthropic turning this “routing” capability into a native API.

How it works: not nesting, but layered collaboration
The design philosophy of the Advisor Tool is quite clear — Anthropic calls it “layered collaboration.”
In practice, your agent’s main loop runs on a lower-cost model (such as Sonnet), which executes tasks. When it determines that a problem exceeds its own ability, it can call a special tool — the Advisor — to hand the problem off to a stronger model (such as Opus). Opus doesn’t directly perform the task; it only returns suggestions and analysis. Sonnet takes these suggestions and continues execution.
This is different from simple “model nesting.” Nesting means A calls B, B calls C, the chain gets deeper and the context gets messier. The Advisor Tool works more like an organizational hierarchy: a junior engineer (Sonnet) encounters an uncertain technical plan, consults the architect (Opus) for guidance, then goes back to work. The architect doesn’t need every execution detail, and the junior doesn’t have to check in for every small task.
At the API level, Advisor is defined as a new tool type. You declare it in the tools array just like a normal function tool, except the type field is advisor_20260301.
You need to add a beta header when calling:
anthropic-beta: advisor-tool-2026-03-01
Then declare the tool like this:
{
"type": "advisor_20260301",
"name": "opus_advisor",
"model": "claude-opus-4-20260401",
"description": "Consult a senior model for advice when facing complex architectural decisions or multi-step reasoning problems"
}
When the execution model (Sonnet) decides it needs help during a conversation, it calls this advisor just like any other tool, passing along the current context. Opus returns its analysis and suggestions — the whole process is transparent to the developer.
Practical effects: cost savings are real, but not magical
Community testers have already been experimenting. There’s a funny comment on a Linux.do post — someone asked Sonnet to evaluate the feature, and Sonnet replied: “I’m invincible; Opus doesn’t need to trouble itself.”
Joking aside, tests show the results vary by scenario.
For code-generation tasks, the Sonnet + Opus advisor combo can deliver near-Opus quality while cutting costs by 60–70%. The reason is simple: most code generation tasks Sonnet can already handle, and only tasks requiring complex business logic or architectural decisions trigger Opus involvement.
However, for tasks requiring continuous deep reasoning — long-chain mathematical proofs or complex multi-file refactoring — the advisor mode doesn’t work as well. Opus only sees the context snippet that Sonnet passes over, not the complete reasoning chain, so the quality of suggestions suffers.
In other words, the Advisor Tool solves scenarios that “occasionally need advanced intelligence,” rather than those that “need advanced intelligence throughout.” It’s a pragmatic positioning.
Comparison with competitors: the idea isn’t new, but this implementation is cleaner
The concept of multi-model collaboration isn’t unique to Anthropic.
The open-source community has already explored similar approaches. One Zhihu article analyzed several multi-model collaboration schemes within the Claude Code ecosystem — projects like OMO and omc — switching models via the Task tool’s model parameter. Some even used the MCP protocol to integrate Gemini into Claude Code, achieving cross-vendor model collaboration.
But all these methods share a common problem: they’re application-layer patchwork, where developers must handle context passing, error handling, token accounting, and other messy details themselves.
The Advisor Tool’s key advantage is that it’s API-native. Anthropic handles context transmission, token management, and error fallback on the backend. For developers, it’s as simple as declaring an advisor tool — no need to build your own orchestration framework.
As for OpenAI — there’s currently no direct equivalent. GPT’s function calling is mature, but model collaboration still requires developer-side orchestration. Google’s Gemini has an Agent framework, but doesn’t offer native multi-model collaboration at the API level.
So Anthropic’s move puts it about half a step ahead in API design.
What it means for developers
If you’re building AI agents, the Advisor Tool deserves serious attention.
The most direct benefit is cost optimization. Previously, your budget might have forced you to use Sonnet exclusively. Now, you can bring in Opus’s capabilities at key decision points, with only a small increase in total cost but a noticeable boost in reliability.
More fundamentally, it changes the way agents are architected. Before, model choice was a global decision — if you chose Sonnet, it was Sonnet everywhere; if Opus, Opus everywhere. Now, model selection becomes local — the agent can dynamically adjust which model to use based on task difficulty.
It’s a bit like microservice architecture: not every request should hit the most powerful server; most can go to regular instances, with only complex requests routed to high-performance ones.
In practice: calling the Advisor Tool via OpenAI Hub
For developers in mainland China, direct access to Anthropic’s API may not be convenient. OpenAI Hub (openai-hub.com) supports all Claude models through a fully OpenAI-compatible format, letting you test the Advisor Tool directly.
Here’s a complete example showing Sonnet as executor and Opus as advisor for a code review task:
import anthropic
# Call via OpenAI Hub for domestic access
client = anthropic.Anthropic(
base_url="https://openai-hub.com/anthropic",
api_key="your-openai-hub-key",
)
# Define the advisor tool
tools = [
{
"type": "advisor_20260301",
"name": "opus_advisor",
"model": "claude-opus-4-20260401",
"description": "Consult Opus for advice when encountering complex architectural problems or deep code analysis"
}
]
# Use Sonnet as the main execution model
response = client.messages.create(
model="claude-sonnet-4-20250514",
max_tokens=4096,
tools=tools,
extra_headers={
"anthropic-beta": "advisor-tool-2026-03-01"
},
messages=[
{
"role": "user",
"content": "Please review the following code’s architectural design and provide optimization suggestions:\n\n"
"```python\n"
"class OrderService:\n"
" def __init__(self):\n"
" self.db = Database()\n"
" self.cache = Redis()\n"
" self.mq = RabbitMQ()\n"
" self.payment = PaymentGateway()\n"
" self.email = EmailService()\n"
"\n"
" def create_order(self, user_id, items):\n"
" order = self.db.insert(user_id, items)\n"
" self.payment.charge(user_id, order.total)\n"
" self.cache.invalidate(f'user:{user_id}')\n"
" self.mq.publish('order.created', order)\n"
" self.email.send(user_id, 'Order confirmed')\n"
" return order\n"
"```"
}
]
)
print(response.content)
In this example, Sonnet first tries to analyze the code itself. When it detects that issues like service coupling, transaction consistency, or error handling strategies involve architectural-level reasoning, it’s very likely to invoke opus_advisor for deeper analysis. The final result you receive combines Sonnet’s execution abilities with Opus’s analytical judgment.
If you prefer the OpenAI-compatible format, you can also call it through OpenAI Hub’s unified interface:
from openai import OpenAI
client = OpenAI(
base_url="https://openai-hub.com/v1",
api_key="your-openai-hub-key",
)
# Use Claude Sonnet via OpenAI-compatible calls
response = client.chat.completions.create(
model="claude-sonnet-4-20250514",
messages=[
{
"role": "user",
"content": "Analyze the architecture issues in this code and propose a refactoring plan..."
}
],
max_tokens=4096
)
print(response.choices[0].message.content)
One key allows you to call Claude, GPT, Gemini, DeepSeek, etc. — handy for multi-model comparison testing.
A few details worth noting
First, the Advisor Tool is still in beta. The API signature may change later, so prepare for compatibility in production usage.
Second, the advisor model doesn’t have to be Opus. In theory, you could use Haiku as executor and Sonnet as advisor to reduce costs even further. You could even declare multiple advisors of different levels, letting the executor choose which one to consult based on problem complexity.
Third, advisor calls add latency. Each consultation is another API round trip. If your use case is latency-sensitive, this tradeoff matters. Tested average: each advisor call adds about 2–5 seconds, depending on problem complexity and Opus’s response length.
Fourth, context window management. The executor model passes limited context to the advisor — not the full dialog history. This means your agent design must consider what information is essential for the advisor’s judgment and ensure those portions are included during the call.
Looking ahead
The significance of the Advisor Tool goes beyond saving money.
It represents a growing trend: AI systems moving from “one big model does everything” toward “multiple specialized models collaborating.” This mirrors software engineering’s evolution — from monolithic apps to microservices, from single servers to distributed clusters.
In the future, we’ll likely see more such native collaboration APIs — not just between models of the same provider, but cross-vendor collaboration will become common. Imagine an agent that uses Claude for text reasoning, Gemini for multimodal understanding, and DeepSeek for mathematical computation — each model playing its specialty role.
That also creates new opportunities for API aggregation platforms. When developers need to integrate multiple vendors’ models in a single agent, unified API gateways and key management grow more valuable.
The Advisor Tool is still in beta, but it’s clearly on the right track. For teams developing AI agents, it’s recommended to start experimenting now — at least include it in your architectural evaluation. By the time the official release arrives, you’ll already know which scenarios suit it best.
References:
- Claude Code Advisor Tool discussion thread - Linux.do — community discussion and testing feedback on the Advisor Tool
- Claude Code multi-model agent collaboration practices: OMO, omc - Zhihu column — comparative analysis of multi-model collaboration solutions



