π¬ Gemini Session (Start)
Make an image the model actually remembers
- input_image
- session
- image
- text
- turn_count
Most image models are fire-and-forget. You type a prompt, you get an image, and the model has already forgotten you existed by the time the pixels land. Google's Gemini image models (the "Nano Banana" line, if you follow the rebrand drama) are different - image generation is native to the language model, so it can carry a scene, a character, a whole conversation across multiple generations. This node is the door into that conversation. Everything else in the ComfyUI-Gemini-Conversation-Canvas pack hangs off it.
π¬ Gemini Session (Start) creates a new conversation and generates the first image. The session output is the important thing: it's a dict that carries the full chat history, and every later node in the pack reads and writes to it. Chain an Edit Turn node onto that session wire and you've got "make the car blue" β "now add rain" β "make it evening," each edit coherently changing the same scene. That's the entire pitch of this pack, and it's genuinely something local Stable Diffusion/Flux workflows do poorly without a pile of ControlNet and inpainting scaffolding.
The honest part: this is a cloud API
Before you get excited about a new local model - there is no local model. There's no checkpoint to download, no GPU requirement, no LoRA support. This node calls Google's Gemini API through the google-genai SDK. Every turn is a real API call, billed per image, and the image itself is produced at Google's end. If you need fully offline or fully private generation, walk away now; this pack is for people who want Gemini's conversational editing inside their ComfyUI graph.
You also need an API key. Resolution order (checked by the node itself): the api_key field on the node, then a GEMINI_API_KEY environment variable, then a gemini_api_key.txt file in your ComfyUI root directory. A free key is a couple of clicks away at Google AI Studio - put it in the node field when you're testing and move on.
Inputs that matter
prompt- the initial image description. Be specific; Gemini responds well to concrete detail.session_name- the folder name underoutput/gemini_sessions/where this session lives. Pick something unique per workflow; two Start nodes with the same name will fight over the same folder.model- defaults togemini-3-pro-image-preview(Nano Banana Pro), withgemini-3.1-flash-image-preview(Nano Banana 2) andgemini-2.5-flash-image(Nano Banana) also available. Note the pack's README still lists older2.5-flash-previewIDs - the dropdown in the node is the up-to-date list.aspect_ratio- 1:1 default, or 16:9, 9:16, 21:9 and friends.autolets the model decide.resolution- 1K / 2K / 4K, 2K default.input_image(optional) - connect an IMAGE and the node sends it along with your prompt for image-to-image work ("remove the background and replace it with a beach").api_key(optional) - as above.
Outputs
session (the conversation state - wire it forward), image (the generated image as a normal ComfyUI IMAGE tensor, so you can preview/save/upscale it), text (the model's textual reply, often a short caption), and turn_count (always 1 after the first generation).
Install and gotchas
Install via ComfyUI Manager (search "Gemini Conversation Canvas") or:
cd ComfyUI/custom_nodes/
git clone https://github.com/jeremieLouvaert/ComfyUI-Gemini-Conversation-Canvas
pip install -r ComfyUI-Gemini-Conversation-Canvas/requirements.txt
Restart ComfyUI. Dependencies are light - google-genai, filelock, Pillow - and there are no model downloads at all.
Two things will bite you. First, Gemini is aggressively content-filtered - the community's own summary of ImageFX was "powerful, unimaginative, massive hidden biasing." When a prompt trips a filter you'll get a RuntimeError telling you no image came back; rephrase rather than retry. Second, remember this is per-turn billing - a 10-edit chain is 10 API calls, so don't treat it like local inference.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | Text prompt for the initial image generation | |
| session_name | STRING | my_session | Name for saving/loading this session |
| model | COMBO | gemini-3-pro-image-preview | Gemini model to use for image generation |
| aspect_ratio | COMBO | 1:1 | Aspect ratio for generated images |
| resolution | COMBO | 2K | Output resolution (1K, 2K, 4K) |
| input_imageopt | IMAGE | Optional input image for image-to-image editing | |
| api_keyopt | STRING | Google AI API key. Falls back to GEMINI_API_KEY env var or gemini_api_key.txt |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| session | * | β |
| image | IMAGE | β |
| text | STRING | β |
| turn_count | INT | β |