GPT5 Image & Text
An OpenAI vision call you can drop straight into your graph
- image
- response
The name is a lie, in the best way: this node doesn't run anything locally. GPT5 Image & Text is a thin OpenAI API client that takes your image, your text, and a model name, mails them to OpenAI's chat completions endpoint, and hands the reply back as a plain text string. No model download, no VRAM, no gpt-5.2 weights squatting on your disk - the only real dependency is the openai Python package. What you're paying for is a frontier multimodal model that can see, and that you can wire into a workflow as casually as any local node.
Why would you reach for it? The honest answer is one-off or small-batch jobs: "describe this image so I can build a better prompt," "check whether this generation matches the requested composition," "caption 50 images as a sanity check." OpenAI's vision models are genuinely good at this - GPT-5 and the 4.1 series read photographs, screenshots, and rendered art with real accuracy. If you're captioning thousands of images for LoRA training, though, stop: a local VLM (Qwen-VL, Janus Pro, via CaptionThis or similar) will be dramatically cheaper. This node is for when you want an answer now and don't want to babysit a local model.
How it works
Right-click → openai → analysis → GPT5 Image & Text, and you've got a terminal node that takes an optional IMAGE and returns a single STRING output named response. That string is whatever the model said - pipe it into a text display, a Save Text node, or back into a prompt encoder if you're feeling adventurous.
Under the hood it's exactly what you'd hope: the image tensor gets converted to PIL, saved as a PNG, base64-encoded, and attached as an image_url content block. If you feed it a batch (a video's frames, say), it sends up to 10 of them in one request - handy, and also how you accidentally spend money. The one genuinely thoughtful bit is reasoning-model handling: the node detects gpt-5* and o1-* models and automatically switches to max_completion_tokens while silently dropping temperature, because the API rejects temperature on reasoning models. The README claims this so you don't have to remember it, and the source actually does it.
The inputs that matter
You'll set maybe three of these. The rest have sane defaults.
- openai_key - paste your API key. The default is the placeholder
your_openai_key_here, and the node hard-fails on it, so don't skip this. - model - 11 choices:
gpt-5.2,gpt-5.2-pro,gpt-5,gpt-5-mini,gpt-5-nano,gpt-4.1,gpt-4o,gpt-4o-mini,gpt-4-turbo,o1-preview,o1-mini. Mini and Nano are the cheap/fast reasoning tiers; Pro is the wallet-burner. - prompt - the actual instruction ("Describe this image"). system_prompt sets assistant behavior. Both are multiline.
The rest: temperature (0–2, default 0.7) only affects non-reasoning models; max_tokens (default 4096) is for those same standard models; max_completion_tokens (default 10000) applies to reasoning models. image is optional - you can use the node as a plain text LLM call if you want.
Install
Two routes, both quick:
- ComfyUI Manager - search "ComfyUI-gpt5_image_text" and install, or
- the manual way:
cd ComfyUI/custom_nodes/
git clone https://github.com/comrender/ComfyUI-gpt5_image_text
cd ComfyUI-gpt5_image_text
pip install -r requirements.txt
Then restart ComfyUI. requirements.txt is a single line - openai>=1.0.0 - so there's no heavy dependency dance and no model files to fetch. This is about the easiest custom node install there is.
Where people get burned
- Forgotten API key. The placeholder default means the node runs, fails with "Please set your OpenAI API key in the node," and you stare at it wondering why. Set the key.
- Cut-off or "empty" output on reasoning models. If a GPT-5 call returns nothing, check whether it hit the token ceiling - the node raises a clear "Model ran out of tokens" error telling you which limit to raise. Crank
max_completion_tokens. - Temperature mysteriously doing nothing. Not a bug. Reasoning models don't accept it, so the node ignores your 0.7. If you need sampling control, you need a non-reasoning model.
- Your key leaking into a shared workflow. The key lives in the node widget, which means it's in the workflow JSON. Never upload a workflow containing a real key; use an env-var or a secrets manager once you're past playing around.
- Cost creep.
gpt-5.2-proplus a 10-image batch can eat real money in one execution. Use Mini/Nano for bulk work and keep an eye on the API dashboard.
It's a small, single-purpose pack from a small author, so don't expect a roadmap - but for dropping a frontier vision model into a ComfyUI graph without leaving the canvas, it does exactly one thing and does it correctly.
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | Analyze this image and text. | — |
| system_prompt | STRING | You are a helpful assistant. | — |
| model | COMBO | 11 options: gpt-5.2, gpt-5.2-pro, gpt-5, gpt-5-mini, gpt-5-nano, gpt-4.1, +5 | |
| openai_key | STRING | your_openai_key_here | — |
| temperature | FLOAT | 0.70–2 | — |
| max_tokens | INT | 40961–32768 | — |
| max_completion_tokens | INT | 100001–65536 | — |
| imageopt | IMAGE | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| response | STRING | — |