ApX logoApX logo

Gemma 4 31B

Parameters

30.7B

Context Length

256K

Modality

Multimodal

Architecture

Dense

License

Apache 2.0

Release Date

2 Apr 2026

Knowledge Cutoff

-

System Requirements

VRAM requirements for different quantization methods and context sizes

1,024 tokens

67.03 GB VRAM

Consumer

3x RTX 4090

24GB VRAM

Datacenter

1x NVIDIA A100

80GB VRAM

Apple Silicon

1x Apple M3 Max

128GB VRAM

256,000 tokens

330.21 GB VRAM

Consumer

17x RTX 4090

24GB VRAM

Datacenter

5x NVIDIA A100

80GB VRAM

Apple Silicon

4x Apple M3 Max

128GB VRAM

Architecture Diagram

Input TokensToken EmbeddingPosition: RoPEHidden: 5.4k · Context: 256K · Vocab: 262.1kx 60 layersRMSNormPre-AttentionGrouped-Query Attention32Q / 16KV heads · SW: 1kHead dim: 256+RMSNormPre-FFNFeed-Forward NetworkGELUIntermediate: 21.5k+Final RMSNormOutput Logits

Evaluation Benchmarks

Rank

#23

BenchmarkScoreRank

Agent Arena

Agent Arena

0.20

🥇

1

General Text

Text Arena

1451

45

Web Development

WebDev Arena

1364

62

Rankings

Overall Rank

#23

Coding Rank

#4

About Gemma 4 31B

Gemma 4 31B is the flagship dense model with 30.7B parameters and 256K context window, delivering frontier intelligence for workstations and consumer GPUs. Supports text and image input with state-of-the-art performance on coding, reasoning, and multimodal understanding. Features configurable thinking mode and native function calling for advanced agentic workflows and IDE integration.

Technical Specifications

Attention

Attention Structure

Grouped-Query Attention

Attention Heads

32

Key-Value Heads

16

Attention Head Dimension

256

Position Embedding

ROPE

RoPE Theta

1,000,000

Sliding Window Attention

Yes

Sliding Window Size

1,024

Sliding Window Ratio

83.3%

Linear Attention

No

Linear Attention Ratio

-

Normalization

RMS Normalization

Activation Function

GELU

Dimensions

Hidden Dimension Size

5,376

Number of Layers

60

FFN Intermediate Size (Dense)

21,504

Multi-Token Prediction Heads

-

Tokenizer

Vocabulary Size

262,144

About Gemma 4

Gemma 4 is Google DeepMind's most advanced open model family, built from Gemini 3 research and technology. Featuring both Dense and Mixture-of-Experts (MoE) architectures, these multimodal models handle text, images, and audio (on smaller variants), with context windows up to 256K tokens. Designed for frontier-level performance across reasoning, coding, and agentic workflows, Gemma 4 delivers unprecedented intelligence-per-parameter from mobile devices to enterprise servers. Released under Apache 2.0 license.


Other Gemma 4 Models