Gemma 4 / Capabilities

Capabilities & Performance

What Gemma 4 can actually do - inputs, thinking, tool calling, vision, audio and long context - and how fast it runs on real hardware, with the settings that change both.

From Google's model card, capability guides and technical report ·

Text Images Audio Video PhoneE2B · offline LaptopE4B · 12B Server26B A4B · 31B Gemma 4 open weights · Apache 2.0
Several kinds of input, one model family, any device.
Inputs

What each model accepts

Every Gemma 4 model reads text and images and writes text. Audio is the dividing line: only the three smaller models take it.

ModelTextImageVideoAudioContextOutput
Gemma 4 31B · dense✓✓✓-256KText
Gemma 4 26B A4B · MoE✓✓✓-256KText
Gemma 4 12B · unified✓✓✓✓256KText
Gemma 4 E4B · edge✓✓✓✓128KText
Gemma 4 E2B · on-device✓✓✓✓128KText

From Google's model card. Video is handled as a sequence of image frames, which is why every size can take it; the card caps it at 60 seconds at one frame per second. If you need audio, the 12B is the ceiling. Sizes and file types are on the models page; full figures in technical specs.

Core capabilities

What it can do

The same interface across all five sizes. The summary is in features; this page goes a level deeper.

🧠

Configurable thinking

Reasons before answering when you want accuracy; switch it off when you want speed.

How it works →

🛠️

Function calling

Built-in tokens for declaring tools, calling them and reading the results.

How it works →

👁️

Vision

OCR, object detection, captioning, visual questions and reasoning over several images.

Details →

🎙️

Audio

Speech recognition and speech translation on E2B, E4B and 12B.

Details →

📜

Long context

256K tokens on the three larger models and 128K on the edge models.

🌍

140+ languages

A 262K-entry vocabulary, with multilingual scores to match - see benchmarks.

🧭

System role

Native support for system prompts, for steadier, more controllable conversations.

✍️

Text out only

It reads images and audio but does not create them. Output is always text.

Thinking

Thinking mode

With thinking on, the model writes out its reasoning before the final answer. It is what drives the strong maths, science and coding scores - and it costs time and tokens, so it is yours to control.

text = processor.apply_chat_template(
    message,
    tokenize=False,
    add_generation_prompt=True,
    enable_thinking=True,   # False for fast replies
)

From Google's thinking guide. On Google's hosted API the equivalent is thinking_level, set to "high" or "minimal" - see the API page.

When to turn it on

Maths, debugging, multi-step planning and anything where a wrong answer is costly.

When to turn it off

Chat, classification, extraction and routing, where latency matters more than depth.

Keep history clean

In multi-turn chats, pass back only the final answers. Earlier reasoning is dropped - except on tool-call turns, where it is kept.

Published benchmark scores assume thinking is on. Prompt-level advice is in prompting.

Function calling

Tools and agents

Gemma 4 has dedicated tokens for tool use, so it can ask your program to look something up, run a calculation or take an action, then use the result. Your program stays in charge of what actually runs.

1 · You aska question 2 · Gemma thinksdecides a tool is needed 3 · Tool callnames a function 4 · Your code runs itand returns the result 5 · Gemma answersusing the result call:get_weather {location: "Kyoto"} The model never runs code itself - it asks, your program acts
One turn of an agent loop.
text = processor.apply_chat_template(
    message,
    tools=[weather_function_schema],
    tokenize=False,
    add_generation_prompt=True,
)
inputs = processor(text=text, return_tensors="pt").to(model.device)
outputs = model.generate(**inputs, max_new_tokens=64)

# The model replies with a tool call for your code to parse and run:
# <|tool_call>call:get_weather{location:<|"|>Kyoto<|"|>}<tool_call|>

It cannot run code itself

Google is explicit: the model only produces the call. Your code must parse it, validate the function name and arguments, and execute it.

Thinking helps it decide

With thinking on, the model reasons about whether a tool is needed and which one before it writes the call.

How reliable is it?

On the Tau2 agent benchmark the 31B scores 76.9 and E2B 24.5. Keep chains short on small models and check each step.

From Google's function-calling guide. The July 2026 weight refresh fixed tool-calling problems without a version bump - re-pull older downloads. For coding agents see the Claude Code guide; known gaps are in limitations.

Vision

Images and documents

All five models read images at their natural shape - no squashing to a square. You choose how much detail each image gets.

Tokens per imageUse it for
70 or 140Classification, captioning, video frames
280The default - general image questions
560 or 1,120OCR, document parsing, small text, dense charts

What it handles

Object detection, OCR, visual question answering, captioning and reasoning across multiple images.

Put the image first

Google recommends placing image content before the text of your prompt.

Counting has limits

For very dense scenes it may estimate. Specific instructions give better results than vague ones.

From Google's vision guide and model card. Benchmark scores quoted for vision use the top budget of 1,120 tokens.

Audio and video

Speech and moving pictures

Audio works on E2B, E4B and 12B. Video works everywhere, as frames.

Audio tasksSpeech recognition, speech translation, general speech understanding
FormatsMP3 or WAV, mono, 16 kHz
LengthUp to 30 seconds per clip
Cost25 tokens per second of audio
PlacementAudio after the text of your prompt
VideoUp to 60 seconds at one frame per second

For longer recordings, split them into segments. Stereo files must be mixed down to one channel.

from transformers import pipeline

pipe = pipeline(
    task="any-to-any",
    model="google/gemma-4-E2B-it",
    device_map="auto",
    dtype="auto"
)

messages = [{
  "role": "user",
  "content": [
    {"type": "text", "text": "Transcribe this audio."},
    {"type": "audio", "audio": "audio_file.wav"},
  ]
}]

outputs = pipe(messages, return_full_text=False)

From Google's audio guide and model card. Running audio models on a phone is covered on the Android page and mobile downloads; the 12B has its own guide.

Under the hood

Four design choices that shape performance

🧩

Mixture of Experts

The 26B A4B activates about 3.8B of its 26B parameters per token, so it runs far faster than its size suggests - though all of it must sit in memory.

🔗

Encoder-free 12B

Image patches and raw audio are projected straight into the model with no separate encoders - fewer parts, less memory.

📐

pp-RoPE positions

The technical report says the positional scheme, with p = 0.25, cuts the global KV-cache footprint by up to 37.5%, which is what makes long context practical.

⚡

Multi-Token Prediction

A 4-layer drafter, from about 76M to 500M parameters, proposes several tokens for the main model to verify at once.

From the technical report and Google's MTP overview. Which files to download for each is on the models page.

Performance

Measured speed

Google's published measurements for the edge models running through LiteRT-LM: 1,024 tokens in, 256 out.

Gemma 4 E2B - writing speed

Tokens per second, GPU backend unless noted
MacBook Pro M4 Max160 t/s
Linux PC, RTX 4090143 t/s
iPhone 17 Pro56 t/s
Galaxy S26 Ultra52 t/s
Raspberry Pi 5 (CPU)8 t/s
DeviceModelWritingFirst word
MacBook Pro M4 MaxE2B160 t/s0.1 s
Linux PC, RTX 4090E2B143 t/s0.1 s
iPhone 17 ProE2B56 t/s0.3 s
Galaxy S26 UltraE2B52 t/s0.3 s
Galaxy S26 UltraE4B22 t/s0.8 s
Raspberry Pi 5 (CPU)E2B8 t/s7.8 s

From Google's LiteRT-LM overview and the LiteRT-LM model cards. On the same phone, switching E2B from CPU to GPU cut the wait for the first word from 1.8 seconds to 0.3 and memory from 1,733 MB to 676 MB. Server throughput for the 26B A4B and 31B depends heavily on hardware and serving stack and is not published by Google in a form this page could confirm - measure on your own setup, starting from self-hosting. Quality scores are on the benchmarks page.

Tuning

Eight ways to make it faster

Use the drafter

Load the matching MTP drafter for faster generation with no quality loss. On the 26B A4B it may not help at batch size 1 on limited hardware.

Use QAT 4-bit

About a quarter of the memory of full precision, with quality close to it. See QAT builds.

Minimise thinking

For classification, routing and extraction, turn thinking down or off.

Lower the vision budget

Going from 1,120 to 280 tokens per image is four times less to read.

Prefer the MoE for volume

The 26B A4B does far less work per token than the dense 31B.

Right-size the model

The 12B gives much of the larger models' quality at a fraction of the memory.

Turn on the GPU

On phones and laptops, the GPU backend is the single biggest speed-up.

Shorten the input

Audio costs 25 tokens a second and each image up to 1,120. Send only what the question needs.

Memory planning is in the VRAM guide; runtime choice in the runtime selector; Apple silicon in Mac setup.

Choose

Which model for which job

WorkloadRecommendedWhy
High-volume serving26B A4BOnly about 3.8B parameters active per token
Hardest reasoning31B, with its drafterBest scores; the drafter recovers some speed
Audio input12BThe largest model that accepts audio
One consumer GPU or a laptop12B QATAbout 6.7 GB of memory at 4-bit, with 256K context
Phone, offline, privateE2B on GPU676 MB and 0.3 s to the first word in Google's test
Long-document retrieval31BHolds accuracy best at 128K and beyond
Multi-step agents31B, current weights, short chainsThe weakest area on small models - verify each step
Search and RAG retrievalEmbeddingGemma 2Purpose-built for embeddings - see the guide

Recommendations are this site's guidance based on the figures above. Get the files from the download hub or follow how to download and install; try before installing in the playground or chat; weigh cost on the pricing page.

FAQ

Capability questions

More answers on the full FAQ page.

Can Gemma 4 generate images or audio?

No. Every model outputs text only. Images, video and audio are inputs on the models that support them.

Which Gemma 4 models understand audio?

E2B, E4B and 12B. The 26B A4B and 31B accept text, images and video frames, but not audio.

Why is the 26B faster than the 31B?

It is a Mixture-of-Experts model: each token is routed through about 3.8B of its 26B parameters, so far fewer weights are read per token than in the dense 31B.

Should I always use the MTP drafter?

For interactive, low-concurrency use it is free speed with no quality loss. Google notes the 26B A4B drafter may give no gain at batch size 1 on hardware with limited parallelism.

Does thinking mode slow it down?

Yes. The reasoning is generated text, so it costs time and tokens. Published accuracy assumes it is on; turning it off trades accuracy for speed.

How much quality is lost at 4-bit?

Less than you might expect with Google's QAT builds, which are trained to tolerate quantisation. Below 4-bit, quality falls quickly.

Is the 256K context really usable?

On the larger models, yes for retrieval: the 31B scores 96.4 on RULER at 128K. On E2B the long window works for lookup but not for reasoning across documents.

How does it compare with other models?

See the model comparison, Gemma 4 vs Qwen 3.5 and, for the previous generation, the Gemma 3 page. Responsible-use notes are under safety.

See what it can do on your own task

Capabilities on paper matter less than results on your prompts.

Top