cmworld
V2EX  ›  Google

Gemini 3 Pro Image(Nano Banana Pro) 的 API 生成大于 4k 参数求教

  •  
  •   cmworld · Nov 22, 2025 · 1770 views
    This topic created in 176 days ago, the information mentioned may be changed or developed.

    文档里 imageSize 可以设置 1K 、2K 、4K 。我自己实测只有 1K 能成功返回图片。model = "gemini-3-pro-image-preview" generation_config = { "responseModalities": ["TEXT", "IMAGE"], "maxOutputTokens…

    看了代码片段,它们更完整的结构。imageSize 并不是直接放在 generationConfig 下面,而是被包裹在一个叫 imageConfig 的对象里。

    最终测试结果也不行,有朋友成功设置成功的吗?

    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   855 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 20:30 · PVG 04:30 · LAX 13:30 · JFK 16:30
    ♥ Do have faith in what you're doing.