惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

V
V2EX
人人都是产品经理
人人都是产品经理
WordPress大学
WordPress大学
博客园 - Franky
小众软件
小众软件
酷 壳 – CoolShell
酷 壳 – CoolShell
Apple Machine Learning Research
Apple Machine Learning Research
爱范儿
爱范儿
IT之家
IT之家
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
V
Visual Studio Blog
S
SegmentFault 最新的问题
美团技术团队
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
有赞技术团队
有赞技术团队
B
Blog RSS Feed
Last Week in AI
Last Week in AI
Jina AI
Jina AI
博客园 - 司徒正美
The Cloudflare Blog
博客园_首页
博客园 - 聂微东
宝玉的分享
宝玉的分享
大猫的无限游戏
大猫的无限游戏

AI

Making global data easier to explore AI for Societal Impact Building AI to accelerate science and improve lives AI for everyone in every language New insights from Google’s AI & Economy ATLAS Watch astronaut Christina Koch and Google’s James Manyika discuss space, technology, and discovery. DevFest is back 3 ways to prep for your next big race with Search Get ready for the game with new football features in Search Recreating a 70-year love story frame by frame Proactive cyber defense for governments and enterprises The latest AI news we announced in August 2026 Try Google Pics: Easy image creation and editing in Google Workspace 3 new ways to plan and book travel in Search 5 ways to upgrade your home decor with Google Search 5 new ways to level up your learning with Search Get closer to the game with Gemini and Pixel Bring your spreadsheet data to life with Sheets canvas AMIE, our research medical AI system, demonstrates real-time clinical video consultation capabilities in a first-of-its-kind study. Evolve your marketing with new AI tools The latest AI news we announced in July 2026 Inside our 353,000-person vibe coding course Gemini API Managed Agents: 3.6 Flash, hooks, and more 5 ways AI Mode in Search helps you enjoy the real world 5 ways to host the ultimate dinner party with Google Search 3 Google updates from Galaxy Unpacked 2026 Connect more of your apps to Search Create, edit and star in videos with two Google Vids updates Celebrating 25 years of visual search innovation Expanding Managed Agents in Gemini API: background tasks, remote MCP and more
New ways to balance cost and reliability in the Gemini API
Lucia Loher Product Manager, Gemini API · 2026-04-02 · via AI

Introducing Flex and Priority inference: advanced controls for developers to optimize costs and reliability through a single, unified interface.

Hussein Hassan Harrirou

Engineering, Gemini API

Your browser does not support the audio element.

Listen to article

This content is generated by Google AI. Generative AI is experimental

[[duration]] minutes

Today, we are adding two new service tiers to the Gemini API: Flex and Priority. These new options give you granular control over cost and reliability through a single, unified interface.

As AI evolves from simple chat into complex, autonomous agents, developers typically have to manage two distinct types of logic:

  • Background tasks: High-volume workflows like data enrichment or "thinking" processes that don't need instant responses.
  • Interactive tasks: User-facing features like chatbots and copilots where high reliability is needed.

Until now, supporting both meant splitting your architecture between standard synchronous serving and the asynchronous Batch API. Flex and Priority help to bridge this gap. You can now route background jobs to Flex and interactive jobs to Priority, both using standard synchronous endpoints. This eliminates the complexity of async job management while giving you the economic and performance benefits of specialized tiers.

Flex Inference: scale innovation for 50% less

Flex Inference is our new cost-optimized tier, designed for latency-tolerant workloads without the overhead of batch processing.

  • 50% price savings: Pay half the price of the Standard API by downgrading criticality of your request (making them less reliable, and adding latency).
  • Synchronous simplicity: Unlike the Batch API, Flex is a synchronous interface. You use the same familiar endpoints without managing input/output files or polling for job completion.
  • Ideal use cases: Background CRM updates, large-scale research simulations, and agentic workflows where the model "browses" or "thinks" in the background.

Get started fast by simply configuring the service_tier parameter in your request:

Flex tier will be available for all paid tiers and is available for GenerateContent and Interactions API requests.

Priority Inference: Highest reliability for critical apps

The new Priority Inference tier offers our highest level of assurance at a premium price point. This helps to ensure your most important traffic is not preempted, even during peak platform usage.

  • Highest criticality: Priority requests get highest criticality leading to higher reliability, even during peak load.
  • Graceful downgrade: If your traffic exceeds your Priority limits, overflow requests are automatically served at the Standard tier instead of failing. This keeps your application online and helps to ensure business continuity.
  • Transparent response: The API response indicates which tier served your request, giving you full visibility into your performance and billing.
  • Ideal use cases: Real-time customer support bots, live content moderation pipelines, and time-sensitive requests.

To use Priority Inference, simply set the service_tier parameter accordingly:

Priority inference will be available to users with Tier 2 / 3 paid projects across the `GenerateContent` API and Interactions API endpoints.

Visit the Gemini API documentation to see the full pricing breakdown and start optimizing your production tiers today. To see it in action, check out the cookbook for runnable code examples.

Related stories