Skip to content

Conversation

@dingyi222666
Copy link
Member

@dingyi222666 dingyi222666 commented Nov 20, 2025

This PR adds support for Gemini 3.0 image generation capabilities.

New Features

  • Add support for Gemini 3.0 Pro Image Preview model's image generation feature
  • Improve image generation model detection logic using generic 'image' keyword matching for better compatibility and future-proofing

Other Changes

  • Update documentation in both English and Chinese to reflect Gemini 3.0 support
  • Bump package version to 1.3.8

- Update image generation feature detection to support all image-capable models
- Broaden model compatibility check from specific model names to generic 'image' keyword
- Update documentation to reflect Gemini 3.0 Pro Image Preview support
- Bump package version to 1.3.8

This change makes the image generation feature more flexible and future-proof
by detecting any model with 'image' in its name, rather than maintaining a
hardcoded list of specific model versions.
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 20, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

在Gemini适配器中调整了图像生成功能的启用条件。将imageGeneration的触发条件从精确匹配"gemini-2.5-flash-image"改为模糊匹配任何包含"image"子字符串的模型标识符。

Changes

聚合 / 文件 变更摘要
Gemini适配器模型配置更新
packages/adapter-gemini/src/utils.ts
扩展prepareModelConfig函数中imageGeneration的启用条件,从精确检查"gemini-2.5-flash-image"改为模式检查任何包含"image"子字符串的模型名称

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 分钟

  • 单个文件中的条件判断逻辑修改
  • 变更范围局限于字符串匹配规则的调整
  • 无新增函数签名或复杂逻辑

Possibly related PRs

Poem

🐰 一根胡萝卜牵出千般景,
image字符启新梦,
模型识别更聪慧,
图像生成展身手,
条件宽松多包容。

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/gemini-3-image

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 76f150e and c0d9c97.

⛔ Files ignored due to path filters (3)
  • packages/adapter-gemini/package.json is excluded by !**/*.json
  • packages/adapter-gemini/src/locales/en-US.schema.yml is excluded by !**/*.yml
  • packages/adapter-gemini/src/locales/zh-CN.schema.yml is excluded by !**/*.yml
📒 Files selected for processing (1)
  • packages/adapter-gemini/src/utils.ts (1 hunks)

Tip

📝 Customizable high-level summaries are now available in beta!

You can now customize how CodeRabbit generates the high-level summary in your pull requests — including its content, structure, tone, and formatting.

  • Provide your own instructions using the high_level_summary_instructions setting.
  • Format the summary however you like (bullet lists, tables, multi-section layouts, contributor stats, etc.).
  • Use high_level_summary_in_walkthrough to move the summary from the description to the walkthrough section.

Example instruction:

"Divide the high-level summary into five sections:

  1. 📝 Description — Summarize the main change in 50–60 words, explaining what was done.
  2. 📓 References — List relevant issues, discussions, documentation, or related PRs.
  3. 📦 Dependencies & Requirements — Mention any new/updated dependencies, environment variable changes, or configuration updates.
  4. 📊 Contributor Summary — Include a Markdown table showing contributions:
    | Contributor | Lines Added | Lines Removed | Files Changed |
  5. ✔️ Additional Notes — Add any extra reviewer context.
    Keep each section concise (under 200 words) and use bullet or numbered lists for clarity."

Note: This feature is currently in beta for Pro-tier users, and pricing will be announced later.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @dingyi222666, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

此拉取请求旨在通过引入对 Gemini 3.0 图像生成功能的支持来增强系统的能力。它还通过采用更通用的匹配策略来改进图像生成模型的识别机制,确保了更好的可扩展性。此外,相关的文档和版本号也已更新,以反映这些新功能。

Highlights

  • 支持 Gemini 3.0 图像生成: 此 PR 增加了对 Gemini 3.0 Pro Image Preview 模型的图像生成功能支持。
  • 改进图像生成模型检测逻辑: 图像生成模型的检测逻辑已优化,现在使用通用的 'image' 关键字进行匹配,提高了未来模型的兼容性。
  • 文档更新: 更新了中英文文档说明,以反映对 Gemini 3.0 图像生成功能的支持。
  • 版本升级: 项目版本已从 1.3.7 升级到 1.3.8。
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@dingyi222666 dingyi222666 changed the title [Feature] 支持 Gemini 3.0 图像生成 [Feature] Add Gemini 3.0 image generation support Nov 20, 2025
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

本次 PR 主要添加了对 Gemini 3.0 图像生成的支持,并改进了模型检测逻辑。代码变更清晰,目的明确。我对图像生成模型的检测逻辑提出了一点建议,以使其更加健壮,避免未来可能出现的问题。其他部分的修改,如版本号和文档更新,看起来都是正确的。

@dingyi222666 dingyi222666 merged commit ffcd501 into v1-dev Nov 20, 2025
2 of 3 checks passed
@dingyi222666 dingyi222666 deleted the feat/gemini-3-image branch November 20, 2025 14:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants