head-to-head
Google: Gemma 4 31B vs OpenAI: GPT-5.4 Nano
Side-by-side comparison of specs, pricing, benchmark scores, and task rankings. Updated 2026-06-20.
| Google: Gemma 4 31B | OpenAI: GPT-5.4 Nano | |
|---|---|---|
| Vendor | openai | |
| Quality Score | 100 | 100 |
| Benchmark Score | 56.4 | 68.0 |
| Input Price | $0.12/M | $0.20/M |
| Output Price | $0.35/M | $1.25/M |
| Context Window | 262,144 | 400,000 |
| Max Output | 262,144 | 128,000 |
| Tool Calling | ✓ | ✓ |
| Structured Output | ✓ | ✓ |
| Reasoning Mode | ✓ | ✓ |
| Vision | ✓ | ✓ |
| Audio | - | - |
| Benchmark Scores | ||
| ai_index | 48.4 | 63.1 |
| ai_index_agentic | 23.8 | 45.4 |
| ai_index_coding | 71.7 | 92.5 |
| eqbench | 70.8 | - |
Who wins by task?
| Task | Google: Gemma 4 31B | OpenAI: GPT-5.4 Nano |
|---|---|---|
| SQL Generation | 157 | 163 |
| Code Review | 154 | 158 |
| Code Completion | 132 | 133 |
| Code Refactoring | 152 | 157 |
| Bug Fixing | 161 | 168 |
| Unit Test Generation | 143 | 148 |
| Code Documentation | 138 | 140 |
| Regex Writing | 131 | 132 |
| CI/CD Pipelines | 136 | 139 |
| Frontend Component Design | 138 | 141 |
| Data Analysis | 152 | 159 |
| CSV / Spreadsheet Cleanup | 146 | 151 |
| ETL Scripting | 144 | 148 |
| JSON Extraction | 143 | 146 |
| Bulk Data Labeling | 133 | 134 |
| OCR / Document Parsing | 140 | 144 |
| Table Extraction from PDFs | 140 | 144 |
| Long-Document Summarization | 150 | 154 |
| Short-Form Summarization | 129 | 130 |
| Blog Post Writing | 134 | 135 |
Scores reflect capability match + benchmark data + pricing for each task. Methodology →
Related comparisons
MoonshotAI: Kimi K2.7 Code vs Google: Gemma 4 31B
MoonshotAI: Kimi K2.7 Code vs OpenAI: GPT-5.4 Nano
Qwen: Qwen3.7 Plus vs Google: Gemma 4 31B
Qwen: Qwen3.7 Plus vs OpenAI: GPT-5.4 Nano
MiniMax: MiniMax M3 vs Google: Gemma 4 31B
MiniMax: MiniMax M3 vs OpenAI: GPT-5.4 Nano
StepFun: Step 3.7 Flash vs Google: Gemma 4 31B
StepFun: Step 3.7 Flash vs OpenAI: GPT-5.4 Nano