π Gemini Session (Load)
Picking up an edit conversation exactly where you left it
- session
- last_image
- last_text
- turn_count
The whole point of saving a Gemini conversation is being able to come back to it. π Gemini Session (Load) is the return trip: point it at a saved session by name, and it reconstructs the full conversation - history, turn count, every image - so the next Edit Turn node continues the scene instead of starting from scratch. This is what turns the pack from "fun single-run demo" into something you can actually work with over days.
How it works
The node reads output/gemini_sessions/{session_name}/session.json, which the Save node wrote earlier. That file holds the serialized chat history, the model, and all the per-turn text; the turn images are the PNG files sitting next to it. The load happens on the client side, then - critically - the conversation is not replayed. When you wire this session into an Edit Turn, that node rebuilds the Gemini chat from the stored history and makes one fresh API call for the next edit. Cheaper and faster than re-running every turn.
Inputs that matter
session_name- the folder name underoutput/gemini_sessions/. Must match what was used on Session Start/Save exactly. If you're not sure, look in that folder - only sessions with asession.jsonare loadable.api_key(optional) - here's the trap: the Save node deliberately does not write your API key intosession.json, so the Load node needs it again, and it needs it now, because resuming the conversation means making a live API call. Provide it here, or rely on theGEMINI_API_KEYenv var /gemini_api_key.txtfallback.
Outputs
session (the reconstructed conversation, ready for an Edit Turn or Gallery), last_image (the most recent turn as a regular IMAGE tensor - useful for a quick preview, though it's a 64Γ64 black placeholder if the session somehow has no images), last_text (the last model reply), and turn_count (so you know where you're picking up).
The resume workflow
The canonical pattern, straight from the pack README:
Run 1: [Session Start] β [Edit Turn] β [Session Save]
Run 2: [Session Load] β [Edit Turn] β [Edit Turn] β [Session Save]
Same session name on both runs, and the second run continues the first. Rinse, repeat, and your edit chain survives restarts, ComfyUI updates, even a different machine as long as the output folder travels with you.
Install and gotchas
Same pack, same install - 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. Dependencies are google-genai, filelock, and Pillow - nothing heavy, no model files.
The two things that bite beginners: forgetting the API key on load (the node raises a clear "No API key found" error, and it's not saved in the file on purpose), and mismatching the session name. The name is literally the folder name, so if "My Session" became "My_Session" on the way in, you need the underscore version on the way out. Load a nonexistent session and you'll get a FileNotFoundError telling you exactly what it expected to find.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| session_name | STRING | Name of the saved session to load (folder name under output/gemini_sessions/) | |
| api_keyopt | STRING | Google AI API key (needed to resume the conversation) |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| session | * | β |
| last_image | IMAGE | β |
| last_text | STRING | β |
| turn_count | INT | β |