The second most-used model on Kyma and the one the vision alias points to — Google's newest open model, with image understanding at cheap-tier pricing.
Modalities
Text+Image → Text
Input
$0.0702 /1M
Output
$0.2006 /1M
Cached input
$0.00702 /1M90% off
Context
128K
Speed
medium
Performance
Live production data from real requests on Kyma — not synthetic benchmarks.
Rank
#2
of 87 active models
Tokens served
391.3M
all-time
Success rate
100%
last 7 days
Top apps using this model
Public apps sending the most traffic to this model — a signal of what real workloads it fits.
Pricing
Pay per token. Cached input is billed at 10% of the input rate.
+ Estimate your workload− Estimate your workload
Estimated monthly cost
$6.08
$0.2028 / day on Gemma 4 31B
Same workload on:
Estimates use list pricing with cached input billed at the 90%-discount rate. Actual bills depend on real token counts — every response includes its exact cost.
When to use Gemma 4 31B
Where this model earns its cost — and where it doesn't.
Gemma 4 31B is Google's newest open model and a cheap-tier model on Kyma that accepts images, not just text. It sits in the strong quality tier and is built for multimodal and general-purpose work: send it screenshots, photos, or document scans alongside your prompt and get text back.
On Kyma it is the platform's second most-used model, serving 18.6% of all production tokens — over 370 million — across agents like OpenClaw, Claude Code, and Hermes Agent. Requests sent with the `vision` alias resolve here. Every call gets automatic failover if a serving path degrades, and prompt caching bills repeated prompt prefixes at 10% of the input rate, which matters for agents that resend the same long system prompt.
The 128K-token context window combines with function calling and structured outputs, so it can read an image and return clean JSON in a single call — a complete loop for vision-driven pipelines.
Image understanding
Describe, classify, or answer questions about screenshots, photos, and charts — the core workload the `vision` alias exists for.
Visual data extraction
Vision input plus structured outputs means it can turn receipts, forms, or UI screenshots into validated JSON in one request.
Agent tool use
It supports function calling and already runs real agent traffic in production, from OpenClaw to Claude Code to Hermes Agent.
High-volume general tasks
Cheap-tier pricing with strong-tier quality fits summarization, classification, and chat workloads where cost per call dominates.
Long-context review
The 128K window fits large documents or long agent histories — with or without images attached.
Not ideal for: Extended reasoning problems (it has no reasoning mode) or very long single generations — output is capped at 8K tokens per request.
How it compares
Against the peers people actually weigh it against.
| Spec | Gemma 4 31B | Gemini 3.5 Flash Lite | Gemini 3.6 Flash |
|---|---|---|---|
| Input /1M | $0.0702 | $0.405 | $2.025 |
| Output /1M | $0.2006 | $3.375 | $10.125 |
| Context | 128K | 1M | 1M |
| Tools | Yes | Yes | Yes |
| Reasoning | Yes | Yes | Yes |
| Speed | medium | fast | fast |
Quick start
Up and running in under two minutes.
- 1
Create an API key
Sign up and grab a key from the dashboard — $0.50 free credit, no card required.
Get API key → - 2
Make your first request
Drop in your key and send a chat completion — fully OpenAI-compatible.
curl https://kymaapi.com/v1/chat/completions \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "gemma-4-31b", "messages": [ {"role": "user", "content": "Explain prompt caching in one paragraph."} ] }' - 3
Stream responses
Add
"stream": trueto receive tokens as they arrive.curl https://kymaapi.com/v1/chat/completions \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "gemma-4-31b", "stream": true, "messages": [{"role": "user", "content": "Hello!"}] }'
FAQ
Common questions about this model.
What is the context window of Gemma 4 31B?
How much does the Gemma 4 31B API cost?
Does Gemma 4 31B support function calling?
How do I use Gemma 4 31B?
Is Gemma 4 31B good for vision tasks?
When should I pick Gemma 4 31B over a bigger model?
Why run Gemma 4 31B through Kyma?
More models by Google
See all 18 →| Model | Context | Input | Output |
|---|---|---|---|
| 1M | $2.025 | $10.125 | |
| 1M | $0.405 | $3.375 | |
| — | $0.0635 / min | ||
| 1M | $2.025 | $12.15 | |
| — | $0.0389 / min | ||
| — | $0.046 / image | ||
| — | $0.0026 / min | ||
| 1M | $0.3375 | $1.35 | |