在预览版中使用 Gemini 2.0 创建和编辑图片
-
Develop
-
Grow
-
Earn
Solutions Events Learn Community
-
Groups
-
Programs
-
Stories
Developer Program Blog Search English
-
- More
-
- More
-
Develop
-
Grow
-
Earn
-
Groups
-
Programs
-
Stories
English Español (Latam) Bahasa Indonesia 日本語 한국어 Português (Brasil) 简体中文 Gemini / Google AI Studio
Create and edit images with Gemini 2.0 in preview
MAY 7, 2025 Kat Kampf Product Manager Google AI Studio Share
鉴于开发者们的热情,我们很高兴地宣布 图像生成 功能现已在 Gemini 2.0 Flash 预览版中提供。
开发者现在可以使用模型名称“gemini-2.0-flash-preview-image-generation”,通过 Google AI Studio 和 Vertex AI 中的 Gemini API,集成具有更高速率限制的会话式图像生成和编辑功能。
Gemini 2.0 Flash 图像生成的新特性
除了启用更高的速率限制和定价之外,我们还改进了模型,使其具有:
-
更好的视觉质量(相对于实验版本)
-
更准确的文本渲染(相对于实验版本)
-
显著降低的过滤拦截率(相对于实验版本)
Gemini 2.0 Flash 图像生成实战
我们非常高兴看到社区对 Gemini 图像生成功能的接受程度。以下是开发者们最感兴趣的一些关键功能的详细介绍:
1) 在新环境中重新构建产品。
2) 实时协作编辑图像。
立即在 AI Studio 中使用 Gemini Co-Drawing Sample App 尝试一下。
Sorry, your browser doesn't support playback for this video
3) 以对话方式编辑图像的特定部分,而不会更改其他任何内容。
4) 使用文本渲染和图像动态创建新的产品 SKU。
5) 将 Gemini 2.0 Flash 作为合作伙伴进行构思:
Sorry, your browser doesn't support playback for this video (右键单击并在新标签页中打开以查看)
立即开始使用 Gemini 的原生图像功能构建
from google import genai
from google.genai import types
client = genai.Client(api_key="GEMINI_API_KEY")
response = client.models.generate_content(
model="gemini-2.0-flash-preview-image-generation",
contents=(
"Show me how to bake a macaron with images."
),
config=types.GenerateContentConfig(
response_modalities=["TEXT", "IMAGE"]
),
)
Copied
您可以在我们的 API 文档 中阅读有关图像生成的更多信息。 此预览版可供开发人员通过 Google AI Studio 和 Vertex AI 开始构建。
我们期待很快带来进一步的质量改进、新功能和扩展的速率限制。 我们迫不及待地想看看您使用 Gemini 2.0 Flash Image Generation 构建了什么。
发布在:
- Gemini
- Google AI Studio
- Web
- AI
- Announcements
- Documentation
- [Vertex AI](https://developers.googleblog.com/en/generate-images-gemini-2-0-flash-preview/</en/search/?tag=Vertex AI>)
- [image generation](https://developers.googleblog.com/en/generate-images-gemini-2-0-flash-preview/</en/search/?tag=image generation>)
- [Developer Tools](https://developers.googleblog.com/en/generate-images-gemini-2-0-flash-preview/</en/search/?tag=Developer Tools>)
- [Gemini 2.0 Flash](https://developers.googleblog.com/en/generate-images-gemini-2-0-flash-preview/</en/search/?tag=Gemini 2.0 Flash>)
Previous
Next
Related Posts
Gemini AI Announcements Industry Trends Gemini 2.5 Pro Preview: even better coding performance MAY 6, 2025
Mobile Web Best Practices Documentation Usability and safety updates to Google Auth Platform APRIL 28, 2025
Cloud How-To Guides Announcements Announcing the general availability of Llama 4 MaaS on Vertex AI APRIL 29, 2025
Gemini Web Case Studies How It’s Made: Little Language Lessons uses Gemini’s multilingual capabilities to personalize language learning APRIL 29, 2025
- Connect
- Programs
- Developer consoles
-
Manage cookies
English
- English
- Español (Latam)
- Bahasa Indonesia
- 日本語
- [ 한국어 ](https://developers.googleblog.com/en/generate-images-gemini-2-0-flash-