baidu/ernie-4.5-21b-a3bOpen WeightsOpen ERNIE text MoE with 21B total and 3B active parameters
Benchmark Pricing$0.07 / 1M in$0.28 / 1M out
Context: 131,072 tokens•Max Output: 8,000 tokens•Released: 2025-06-30
TECHNICAL SPECIFICATIONS
Context Window131,072131.1K tokens
Max Output8,0008K tokens
LicenseApache-2.0Self-hostable
Input Modalities
Text
Function / Tool CallingSupported (MCP Ready)
Structured OutputsGuaranteed Schema
MODEL CONTEXT PROTOCOL (MCP) READINESS
✓ ERNIE 4.5 21B A3B natively supports OpenAI / Anthropic format tool calling and is fully compatible with MCP servers and agent loops.
MCP Context Window Recommendations
With a context capacity of 131,072 tokens, this model can handle moderately large MCP tool definitions and multi-turn conversation logs comfortably.
API CALL INVOCATION EXAMPLE
// Example: Calling ERNIE 4.5 21B A3B via OpenAI SDK
import OpenAI from "openai";
const client = new OpenAI({
apiKey: process.env.BAIDU_API_KEY,
});
const response = await client.chat.completions.create({
model: "baidu/ernie-4.5-21b-a3b",
messages: [{ role: "user", content: "Hello! Can you inspect MCP tools?" }],
});
console.log(response.choices[0].message.content);PRICING BY PROVIDER
Novita AIbaidu/ernie-4.5-21B-a3b
$0.07 / $0.28
Heliconeernie-4.5-21b-a3b-thinking
$0.07 / $0.28
Rates in USD per 1M tokens. Rates synchronized from models.dev public catalog.
MODEL RESOURCES
More Models by Baidu
Alternative and family models from the same lab
CoBuddy
baidu/cobuddy•Baidu
Baidu Qianfan model optimized for code generation and tool-using coding agents
65.5K out max
In: $0.28 • Out: $1.13
BaiduERNIE 4.5 300B A47B
baidu/ernie-4.5-300b-a47b•Baidu
Open ERNIE text MoE with 300B total and 47B active parameters
12K out max
In: $0.28 • Out: $1.10
BaiduERNIE 4.5 VL 424B A47B
baidu/ernie-4.5-vl-424b-a47b•Baidu
Multimodal reasoning model for visual analysis, planning, and tool use
16K out maxVision
In: $0.42 • Out: $1.25
Baidu