Google: Gemma 4 31B (batch) vs OpenAI: GPT-5.4 Mini (batch)
Neither wins outright: Google: Gemma 4 31B (batch) is the pick when cost matters at scale, OpenAI: GPT-5.4 Mini (batch) when you need to fit long inputs in one request.
Monthly cost at list price for five common workloads. Token counts per unit are stated so you can scale them to your own traffic. A workload that does not fit a model's context window is marked rather than priced.
Workload (per month)
Google: Gemma 4 31B (batch)
OpenAI: GPT-5.4 Mini (batch)
Difference
Customer-support chatbot
50,000 conversations — each a 6-turn conversation (1,500 in / 400 out tokens)
$48.65
$73.13
Google: Gemma 4 31B (batch) saves $24.48
RAG search over documents
20,000 questions — each a question answered from ~8 retrieved passages (6,000 in / 500 out tokens)
$56.50
$67.50
Google: Gemma 4 31B (batch) saves $11.00
Coding / tool-using agent
2,000 tasks — each a multi-step task with tool calls and file context (60,000 in / 6,000 out tokens)
$58.44
$72.00
Google: Gemma 4 31B (batch) saves $13.56
Batch summarisation
10,000 documents — each a 6,000-word report summarised to a page (8,000 in / 600 out tokens)
$37.02
$43.50
Google: Gemma 4 31B (batch) saves $6.48
Long-document analysis
500 documents — each a 150-page contract or codebase read in one pass (100,000 in / 2,000 out tokens)
$20.47
$21.00
Google: Gemma 4 31B (batch) saves $0.53
Capabilities side by side
Capability
Google: Gemma 4 31B (batch)
OpenAI: GPT-5.4 Mini (batch)
What it lets you do
Tool / function calling
✓ Yes
✓ Yes
call your APIs and run agent loops
Structured output (JSON schema)
✓ Yes
✓ Yes
return JSON that validates against your schema
Reasoning / thinking mode
✓ Yes
✓ Yes
spend extra tokens thinking before answering hard problems
Image input
✓ Yes
✓ Yes
read screenshots, charts and scanned pages
Audio input
—
—
take speech or audio directly
File / PDF input
—
✓ Yes
accept documents without your own parsing step
Image output
—
—
generate images, not just text
Built-in web search
—
✓ Yes
answer from live web results
Seed (reproducible sampling)
—
✓ Yes
repeat a generation for tests and evals
Log-probabilities
—
—
read token confidence for classification and scoring
From each model's published parameters and input/output types. “—” means not advertised, not proven absent.
Price history
Google: Gemma 4 31B (batch): price unchanged since we started tracking it on 2026-08-29.
OpenAI: GPT-5.4 Mini (batch): price unchanged since we started tracking it on 2026-08-07.
Which should you choose?
Choose Google: Gemma 4 31B (batch) if…
cost matters at scale — it is 37% cheaper on a typical 3:1 input/output mix ($48.65 vs $73.13 a month for 50,000 support chats)
you generate long outputs in one go — up to 236K tokens (about 176,900 words) per response
Choose OpenAI: GPT-5.4 Mini (batch) if…
you need to fit long inputs in one request — 400K tokens is roughly 600 pages, against 393
you need file / PDF input — to accept documents without your own parsing step; Google: Gemma 4 31B (batch) does not advertise it
you need built-in web search — to answer from live web results; Google: Gemma 4 31B (batch) does not advertise it
you need seed (reproducible sampling) — to repeat a generation for tests and evals; Google: Gemma 4 31B (batch) does not advertise it
Frequently asked questions
Is Google: Gemma 4 31B (batch) better than OpenAI: GPT-5.4 Mini (batch)?
Neither wins outright: Google: Gemma 4 31B (batch) is the pick when cost matters at scale, OpenAI: GPT-5.4 Mini (batch) when you need to fit long inputs in one request. In short: Google: Gemma 4 31B (batch) when cost matters at scale, you generate long outputs in one go; OpenAI: GPT-5.4 Mini (batch) when you need to fit long inputs in one request, you need file / PDF input, you need built-in web search, you need seed (reproducible sampling).
Which is cheaper, Google: Gemma 4 31B (batch) or OpenAI: GPT-5.4 Mini (batch)?
Google: Gemma 4 31B (batch) is cheaper: $0.53 vs $0.84 per 1M tokens at a typical 3:1 input/output mix, 37% less. For 50,000 support conversations a month that is $48.65 against $73.13.
How much do Google: Gemma 4 31B (batch) and OpenAI: GPT-5.4 Mini (batch) cost per million tokens?
Google: Gemma 4 31B (batch) costs $0.39 per 1M input tokens and $0.97 per 1M output tokens; OpenAI: GPT-5.4 Mini (batch) costs $0.38 input and $2.25 output. Output tokens are billed separately, so long answers shift the gap.
Which has the bigger context window, Google: Gemma 4 31B (batch) or OpenAI: GPT-5.4 Mini (batch)?
OpenAI: GPT-5.4 Mini (batch): 400K tokens, about 600 pages, against 262K (about 393 pages) for Google: Gemma 4 31B (batch).
Do Google: Gemma 4 31B (batch) and OpenAI: GPT-5.4 Mini (batch) support function calling and JSON output?
Can Google: Gemma 4 31B (batch) or OpenAI: GPT-5.4 Mini (batch) read images?
Yes, both accept image input.
Is Google: Gemma 4 31B (batch) or OpenAI: GPT-5.4 Mini (batch) free to use?
No free variant is listed for either; both are pay-per-token.
What is the maximum output length of Google: Gemma 4 31B (batch) and OpenAI: GPT-5.4 Mini (batch)?
Google: Gemma 4 31B (batch) can write up to 236K tokens (about 176,900 words) per response; OpenAI: GPT-5.4 Mini (batch) up to 128K (about 96,000 words).
When were Google: Gemma 4 31B (batch) and OpenAI: GPT-5.4 Mini (batch) released?
Google: Gemma 4 31B (batch) was listed on 2026-04-02; OpenAI: GPT-5.4 Mini (batch) on 2026-03-17.
Gemma 4 31B Instruct is Google DeepMind's 30.7B dense multimodal model supporting text and image input with text output. Features a 256K token context window, configurable thinking/reasoning mode, native function...
GPT-5.4 mini brings the core capabilities of GPT-5.4 to a faster, more efficient model optimized for high-throughput workloads. It supports text and image inputs with strong performance across reasoning, coding,...