Faishme Gemini
Local Images, Google's Brain — VLM Judgement in One Node
- images
- output
Faishme Gemini is the pack's "ask a cloud model what it sees" node. You feed it one or more images, a system prompt, and a question; it sends them to Gemini 2.5 Flash and returns the answer as a string. No local weights, no GPU footprint - just an API key, a network call, and whatever Google's model decides about your image. If you've ever wished you could ask "is the subject centered? what color is the jacket?" mid-workflow, this is that.
How it works
The node builds a google-genai client with your api_key, then sends the incoming IMAGE batch (converted to PIL) plus your user_prompt to the hardcoded model gemini-2.5-flash, with your system_prompt as the system instruction and temperature pinned at 0.0. It also wraps the call in retry logic (exponential backoff with jitter, a couple of attempts) so transient Google API errors don't kill the whole run. The plain text response comes out of output as a STRING.
A few details worth knowing:
- The model name is hardcoded - you can't swap it to Gemini Pro from the widget.
- It expects a 4D image tensor and asserts it. Feed it a normal IMAGE batch and you're fine.
- If Google flags the response as recitation (finish reason 3), the node returns nothing and the run dies rather than emitting a bad string. In practice that's rare for product-photo questions.
- Temperature 0 means you get the same answer for the same input - which is what you want when the output feeds downstream logic.
Inputs that matter
Four inputs, and three of them are the point:
- images - the IMAGE(s) you want judged. This is the input that makes it a vision node.
- system_prompt - how you frame the model. This is where you'd write "You are a fashion QA assistant. Answer in one word: yes or no."
- user_prompt - the actual question, e.g. "Does this model wear the red dress?"
- api_key - your Google AI Studio key. This one deserves caution: it's a plain widget, so don't share a workflow with your real key baked in.
Wiring it up
The output is a STRING, and output is marked as an output node, so you'll typically run it into a Show Text / preview node to read the answer, or - more usefully - into whatever switch or logic node turns its answer into graph decisions. In the Faishme pipeline that's QC: generate, ask, route the result. Keep in mind the images leave your machine; this node is not for private data.
Installing it
Same install as the whole pack - Manager, search "ComfyUI_faishme", or:
cd ComfyUI/custom_nodes
git clone https://github.com/AkashKarnatak/ComfyUI_faishme
Restart, then make sure the API deps are present: google-genai and vertexai are in the pack's requirements.txt, so Manager should install them. You'll also need a Gemini API key from Google AI Studio - the free tier works, and this node only bills you per call.
Where people get burned
The two real failure modes are the key and the context. No key (or a wrong key) → the client throws and the node errors. And forgetting this is a cloud call - Gemini 2.5 Flash has a context window and a knowledge cutoff, so it can't judge things that aren't visible in the pixels you sent. It also can't see the rest of your graph, so any instruction it needs ("judge only the garment region") has to be in the prompts. It's a genuinely handy QC/automation node, but it's not an oracle - it's a well-wrapped API call with retries.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| system_prompt | STRING | — | |
| user_prompt | STRING | — | |
| api_key | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| output | STRING | — |