Baidu

ernie-5.1

Model IDernie-5.1

Integration docsMarkdown

Model introduction

ernie-5.1 is a Baidu model available through MoleAPI with openai access. It fits OpenAI compatible workflows, with pricing synced from the MoleAPI console.

Model capabilities

Specifications come from the cited model material. Catalog tags help identify access features; use the source documentation for exact limits.

OpenAI compatible

Verified specifications

Catalog status
Currently available on MoleAPI
Compatible protocols
openai
Available billing groups
Standard

Sources: MoleAPI console pricing catalog

Model pricing and access

Prices are read directly from the MoleAPI console catalog and shown by current billing group and context tier.

Your final charge follows the account group shown in the console.
Live pricing source

Pricing table

USD / 1M tokens
Standardx1defaultInput $0.6 · Output $2.65

Input

$0.6 / 1M tokens

Output

$2.65 / 1M tokens

Access protocols

Available billing groups: Standard

openai
POST
/v1/chat/completions

Complete model guide

Prepared from vendor sources and independently reviewed. · 2026-07-28

ERNIE 5.1 model guide

ERNIE 5.1 is Baidu’s flagship text and reasoning model, positioned for agentic reasoning, knowledge-intensive tasks, and creative writing. Baidu AI Studio documents web-search enhancement, function calling, and structured output support for the model. [3][4]

Positioning and core capabilities

Baidu released ERNIE 5.1 on May 9, 2026, describing it as a compressed successor to ERNIE 5.0 that retains its predecessor’s pre-training foundation. [4] Baidu positions the model around reasoning, knowledge, agent workflows, and creative-writing performance. [4]

The AI Studio service classifies ERNIE 5.1 for text-to-text generation and thinking workloads. It supports web-search enhancement, function calling, and structured output for tool-using and schema-constrained applications. [3]

Capabilities and specs

ERNIE 5.1 has a documented context window of 128K tokens and accepts up to 119K input tokens. [3] Its standard text listing supports configurable outputs from 2 to 65,536 tokens, with a default output setting of 2K tokens. [3]

SpecificationDocumented value
Release dateMay 9, 2026 [4]
Context window128K tokens [3]
Maximum input119K tokens [3]
Standard output range2–65,536 tokens [3]
Default output setting2K tokens [3]
Thinking Preview chain-of-thought allowanceUp to 60K tokens [3]
Documented featuresWeb-search enhancement, function calling, structured output [3]

Baidu states that ERNIE 5.1 reduces total parameters to approximately one-third and active parameters to approximately one-half of ERNIE 5.0. [4] Baidu also reports pre-training costs of about 6% of comparable models at the same scale; this is a vendor-reported cost claim. [4]

Use cases

ERNIE 5.1 is suited to agent workflows that combine model reasoning with external tools through function calling. [3][4] Web-search enhancement supports search-assisted responses for knowledge-intensive tasks. [3]

Structured output support makes the model applicable to systems that require reliably formatted responses, including automated extraction, routing, and downstream application workflows. [3] Baidu also positions the model for creative-writing tasks alongside reasoning and knowledge work. [4]

Material limitations

The standard ERNIE 5.1 listing and the ERNIE 5.1 Thinking Preview listing have different documented minimum output settings: 2 tokens for the standard listing and 1 token for Thinking Preview. [3] The Thinking Preview listing documents a chain-of-thought allowance of up to 60K tokens. [3]

Baidu’s parameter-reduction and training-cost statements are vendor claims rather than independently reported measurements. [4]

Sources

Code examples

These examples use MoleAPI's OpenAI-compatible endpoint and run after you replace the API key.

curl https://api.moleapi.com/v1/chat/completions \
  -H "Authorization: Bearer $MOLEAPI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "ernie-5.1",
    "messages": [{"role": "user", "content": "Hello"}]
  }'

Frequently asked questions

How is ernie-5.1 priced?

This page reads prices from the MoleAPI console API and updates with model prices, context tiers, and account groups.

How can I access ernie-5.1?

Protocols and endpoints come from the supported_endpoint_types field in the MoleAPI model catalog.

How do I switch an existing project to ernie-5.1?

Keep the MoleAPI API address and key, replace the model parameter with the model ID on this page, then check protocol-specific parameter differences.

Where do the ernie-5.1 model details come from?

Only availability, billing, and protocol facts from the MoleAPI catalog are currently verified, so unconfirmed model specifications are not added.