ApX logoApX logo

ERNIE-4.5-21B-A3B-Base

Active Parameters

21B

Context Length

131K

Modality

Text

Architecture

Mixture of Experts

KV Cache Rate

56 KB/tok

License

Apache 2.0

Release Date

30 Jun 2025

Knowledge Cutoff

Dec 2024

API Pricing (per 1M)

Self-hosted only

Hardware & System Requirements

Precision

Native

Context

Workload Memory: 14.11 GB

INT4 · 8K context

Base Weights: 11.18 GB

KV Cache: 0.44 GB

Runtime & Graphs: 2.50 GB

Minimum Required Hardware

1x NVIDIA L4 24GB

14.1 / 21.6 GB usable

1x RTX 4060 Ti 16GB

14.1 / 14.4 GB usable

Apple M4 24GB

14.1 / 18.0 GB usable

Determine requirements for your specific workload:

Open in VRAM Calculator

Runtime requirements

Checkpoint format

FP16

CUDA

>= 11.8

PyTorch

>= 2.1

Transformers

>= 4.54.0.dev0

ArchitecturePrecisionAttention kernel

Blackwell, Hopper

Native FP16

FlashAttention-3

Ada Lovelace, Ampere

Native FP16

FlashAttention-2

Architecture Diagram

Input TokensToken EmbeddingPosition: AbsoluteHidden: 2.6k · Context: 131K · Vocab: 103.4kx 28 layersRMSNormPre-AttentionGrouped-Query Attention20Q / 4KV headsHead dim: 128+RMSNormPre-FFNSparse MoE FFN (6/64 experts)SwiGLUIntermediate: 1.5k+Final RMSNormOutput Logits

Evaluation Benchmarks

No evaluation benchmarks for ERNIE-4.5-21B-A3B-Base available.

Rankings

Overall Rank

-

Coding Rank

-

About ERNIE-4.5-21B-A3B-Base

ERNIE-4.5-21B-Base is an open-weights Mixture-of-Experts text model by Baidu activating 3B parameters per token for efficient NLP applications. It utilizes modality-isolated routing and progressive RoPE scaling across a 131K context window.

Specifications

Attention

Attention Structure

Grouped-Query Attention

Attention Heads

20

Key-Value Heads

4

Attention Head Dimension

128

Position Embedding

Absolute Position Embedding

RoPE Theta

500,000

Normalization

RMS Normalization

Activation Function

SwigLU

Dimensions

Base Precision

FP16

Hidden Dimension Size

2,560

Number of Layers

28

FFN Intermediate Size (Dense)

1,536

Tokenizer

Vocabulary Size

103,424

Mixture of Experts

Total Expert Parameters

3.0B

Number of Experts

64

Active Experts

6

Shared Experts

2

FFN Intermediate Size (per Expert)

1,536

Dense Layers Before MoE

1

About ERNIE 4.5

The Baidu ERNIE 4.5 family consists of ten large-scale multimodal models. They utilize a heterogeneous Mixture-of-Experts (MoE) architecture, which enables parameter sharing across modalities while also employing dedicated parameters for specific modalities, supporting efficient language and multimodal processing.


Other ERNIE 4.5 Models