Repository navigation
feat(vertex_ai): add vertex_ai/gemini-4-hydrogen from the Vertex pricing page - #51432
Conversation
PR overviewNo security issues were found in this pull request. Reviews
|
cceec26 to
0f9d35a
Compare
|
|
|
@BugBot run |
[Medium impact] The change affects pricing and model details for one Vertex AI model. Fix the missing Flex audio price in both catalogs before merging. Findings
SummaryAdds Flex audio pricing is missing in both copies. Audio therefore falls back to the Standard rate instead of receiving the Flex discount.
Reviews (1) · Last reviewed commit: "feat(vertex_ai): add vertex_ai/gemini-4-..." · Reviewed by Greptile |
| "input_cost_per_audio_token": 1.5e-06, | ||
| "input_cost_per_audio_token_batches": 7.5e-07, | ||
| "input_cost_per_audio_token_priority": 2.7e-06, |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 0f9d35a. Configure here.
| "input_cost_per_audio_token_priority": 2.7e-06, | ||
| "input_cost_per_token": 1.5e-06, | ||
| "input_cost_per_token_batches": 7.5e-07, | ||
| "input_cost_per_token_flex": 7.5e-07, |
There was a problem hiding this comment.
Missing flex rate for audio tokens
Medium Severity
The new vertex_ai/gemini-4-hydrogen row prices audio for standard, batches, and priority, and text for flex, but omits input_cost_per_audio_token_flex. Flex and batch Vertex traffic therefore bills audio at the standard input_cost_per_audio_token rate, twice the published flex input price.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 0f9d35a. Configure here.
Merging this PR will not alter performance1 warning
Comparing |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |


Summary
Adds
vertex_ai/gemini-4-hydrogen(kind page). The Vertex pricing page https://cloud.google.com/gemini-enterprise-agent-platform/generative-ai/pricing (now served at https://cloud.google.com/model-garden/pricing) gained a Gemini 4 Hydrogen row in its Gemini 4 Standard, Priority and Flex/Batch tables, and the google-models page lists it under "Generally available Gemini models". The rest of the page re-rendered with identical prices: 190 per-token cells across 29 existing vertex rows were compared against the catalog with 0 mismatches, so no other row changes.Row evidence
Pricing page, Gemini 4 Standard table: "Gemini 4 Hydrogen | Input (text, image, video, audio) | Global | $1.50 | $0.075 | $1.875 ***" and "Text output (response and reasoning) | Global | $7.50". Non-global cells are 1.1x ($1.65 input, $8.25 output), so
regional_endpoint_uplift_multiplier: 1.1like the sibling Gemini 4 rows.Priority table: "Gemini 4 Hydrogen | Input (text, image, video, audio) | Global | $2.70 | $0.135" and "Text output (response and reasoning) | Global | $13.50". Flex/Batch table: "Gemini 4 Hydrogen | Input (text, image, video, audio) | Global | $0.75 | $0.0375" and "Text output (response and reasoning) | Global | $3.75". Written as
_priority,_batchesand_flexfields. One input price covers text, image, video and audio, soinput_cost_per_audio_tokenequals the text input price for each tier.Model page https://docs.cloud.google.com/gemini-enterprise-agent-platform/models/gemini/4-hydrogen: "Model ID gemini-4-hydrogen", "Context window 1,048,576", "Maximum output tokens 1,048,576", modalities Text input and output, Image, Audio and Video input only, "Thinking Supported", "Structured output Supported", "Function calling Supported", "URL context Supported", "Computer use Supported", "Gemini Live API Not supported", "Batch inference Supported", "Standard PayGo with Usage Tiers, Flex PayGo, Priority PayGo Supported", "Hydrogen supports implicit caching only (4,096-token minimum)" (
prompt_cache_min_tokens: 4096), "Setting thinking_budget or thinking_level="MINIMAL" returns an HTTP 400 validation error" (supports_minimal_reasoning_effort: false). Grounding fields copied from the siblingvertex_ai/gemini-4-carbonrow since the Gemini 4 grounding table ("$14 per 1,000 Grounding Queries", "5,000 Grounding Queries per month at no charge, aggregated across all Gemini 3 and Gemini 4 models") is shared.Left out on purpose
Cache write price ($1.875 Global) is footnoted "*** Pricing for cache write effective January 12, 2027" and the model page says explicit context caching is not supported today, so it is not published yet. Gemini 4 Carbon and Gemini 4 Argon still show their promo prices through November 30, 2026 with $4/$20 starting December 1, 2026, kept at the current price per the existing switch-on-the-day rulings (vertex-ai-gemini-4-argon-3-8-tts-promo-switch-on-the-day).
Details
Link to Devin session: https://app.devin.ai/sessions/e66f1c24cf9141999d26e48119200233
Open in Devin Desktop: https://app.devin.ai/desktop/session/e66f1c24cf9141999d26e48119200233?variant=devin
Requested by: @kerry-berri
Note
Low Risk
Data-only addition to the model pricing JSON files; no auth, routing, or billing logic changes beyond enabling accurate cost/context lookup for a new model key.
Overview
Adds a
vertex_ai/gemini-4-hydrogencatalog row tomodel_prices_and_context_window.jsonandlitellm/model_prices_and_context_window_backup.json, mirroring the existinggemini/gemini-4-hydrogenentry but with Vertex pricing (standard, priority, flex/batch tier token costs, audio input pricing, 1.1 regional uplift, 1M context/output limits, modality and capability flags, grounding/search billing, and/v1/batchsupport).No runtime or routing code changes—only the shared model price/context registry is extended so LiteLLM can route and cost Vertex
gemini-4-hydrogencalls consistently with sibling Gemini 4 models.Reviewed by Cursor Bugbot for commit 0f9d35a. Bugbot is set up for automated code reviews on this repo. Configure here.