Gemini (Soze)
Nano Banana, but inside your ComfyUI graph
- images
- frames
- audio
- text
- image
The headline trick of this node is right in the defaults: drop it in a workflow, leave operation_mode on generate_images and model_name on gemini-3-pro-image-preview, and you're calling Gemini's flagship image model - the one Google rebranded as Nano Banana Pro - from your ComfyUI graph. No GPU, no checkpoint download, nothing local. Just a Google API key and an internet connection.
It's a single-node pack: "Gemini Node", displayed as Gemini (Soze) under the "Soze Nodes" category. SozeInc ported it from the long-running ComfyUI-IF_Gemini to talk to the Gemini 3.0 API, trimmed the Open Router support, and shared it back. The README is upfront that this started as a personal-use port - it's new, lightly tested, and does exactly one job. That job is genuinely handy.
What you'd use it for
Three modes, one node:
generate_images- text-to-image (or reference-image-to-image) with Gemini's native image generation. Wire theimageoutput to a Save Image node and you're done. It also means the output is a real ComfyUI tensor, so you can run it through an upscaler or a detailer the way you would any other generated frame.analysis- feed an image in, get a text description out. The default prompt is literally an image-to-prompt describer ("describe this as a film director would"). Pipe an image in, grab thetextoutput, feed it to a KSampler - that's the classic IF_Gemini workflow, and it's still the best reason to install this.generate_text- plain LLM chat/response mode for a system prompt plus your instruction.
How it works
Under the hood it's the google-genai SDK doing a network call on every queue. The node resolves your API key in order: GEMINI_API_KEY environment variable, then your .zshrc/.bashrc exports, then .env files in a few locations, then whatever you paste into external_api_key. There's a Verify API Key button on the node that hits the pack's /gemini/check_api_key route so you don't discover a bad key mid-run.
The inputs that actually matter
operation_mode-analysis,generate_text, orgenerate_images. Start here.prompt- your instruction. Multiline, and it's pre-filled with the image-description prompt, which trips people up in generate_images mode; replace it.model_name- the six-model list, defaulting togemini-3-pro-image-preview. If you pick a text-only model while in generate_images mode, the code silently swaps you back to the image model - helpful, but don't be surprised when your choice is ignored.thinking_level-minimal/low/medium/highcontrols how much Gemini "thinks" before answering (Gemini 3 only).highis slow and pricier; leave it onminimalunless you want the reasoning depth.images(optional) - reference images for style-based generation or analysis.max_imagescaps how many get sent (default 6).aspect_ratio,media_resolution,batch_count,seed- aspect presets, 1K/2K/4K output, up to 20 images per run, and a seed for repeatability.
Outputs are text (STRING) and image (IMAGE). In analysis/text modes, image is just a placeholder.
Installing it
ComfyUI Manager search "comfyui_soze_gemini" (it's on the Comfy Registry under publisher sozeinc), or:
cd ComfyUI/custom_nodes
git clone https://github.com/SozeInc/ComfyUI_Soze_Gemini
cd ComfyUI_Soze_Gemini
pip install -r requirements.txt
Restart ComfyUI. The dependency list is light - google-genai, google-generativeai, python-dotenv, plus torch/Pillow you already have. No model files. The real prerequisite is a key from aistudio.google.com/apikey.
Where people get burned
- It costs real money. Nano Banana Pro is billed per image - roughly $0.04 up to $0.24 depending on resolution.
batch_countat 4K can eat a couple of dollars in one run. Keep an eye on the meter. - The censorship is server-side. The code sets
BLOCK_NONEon safety categories, but Google still enforces its IMAGE_SAFETY policy on the API; "Powerful, unimaginative, massive hidden biasing" is the community's summary. If a run returns a safety error, reword the prompt - the README says so too. It's not the node being broken. - Every image carries an invisible SynthID watermark. Fine for personal work, worth knowing before you ship something commercial.
- Quota and key errors return as text output. If your
textoutput suddenly says "ERROR: API quota exceeded" or "No Gemini API key found", that's the node talking to you, not a crash. The Verify button sorts out which. - The pack is a young personal port, and exactly one node ships - the prompt-manager helpers that shipped in IF_Gemini are commented out here. Don't expect polish, expect "works".
The name is a mouthful and the pack is barely a week old, but if you want Nano Banana generations or an image-to-prompt step inside ComfyUI without standing up a separate service, this is the node to reach for.
Inputs (24)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | Create a vivid word-picture representation of this image include elements that characterize the subject, costume, prop elemts, the action, the background, layout and composition elements present on the scene, be sure to mention the style and mood of the scene. Like it would a film director or director of photography | — |
| operation_mode | COMBO | generate_images | 3 options: analysis, generate_text, generate_images |
| model_name | COMBO | gemini-3-pro-image-preview | 6 options: gemini-3-pro-image-preview, gemini-3.1-pro-preview, gemini-3.1-flash-image-preview, gemini-3.1-flash-lite-preview, gemini-3-flash-preview, gemini-3-pro-preview |
| temperature | FLOAT | 0.800–1 | — |
| thinking_level | COMBO | minimal | 4 options: minimal, low, medium, high |
| media_resolution | COMBO | 1K | 3 options: 1K, 2K, 4K |
| imagesopt | IMAGE | — | |
| videoopt | STRING | — | |
| framesopt | IMAGE | — | |
| audioopt | AUDIO | — | |
| system_promptopt | STRING | — | |
| seedopt | INT | 00–4294967295 | — |
| sequential_generationopt | BOOLEAN | false | — |
| batch_countopt | INT | 11–20 | — |
| aspect_ratioopt | COMBO | none | 11 options: none, 1:1, 2:3, 3:2, 3:4, 4:3, +5 |
| external_api_keyopt | STRING | — | |
| bypassopt | BOOLEAN | false | — |
| chat_modeopt | BOOLEAN | false | — |
| clear_historyopt | BOOLEAN | false | — |
| structured_outputopt | BOOLEAN | false | — |
| max_imagesopt | INT | 61–16 | — |
| max_output_tokensopt | INT | 81921–32768 | — |
| use_random_seedopt | BOOLEAN | false | — |
| api_call_delayopt | FLOAT | 1.00–60 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| text | STRING | — |
| image | IMAGE | — |