Nodes/Chat-Image-Bridge-Node/Chat Image Bridge Advanced
ComfyUI Node

Chat Image Bridge Advanced

Raw responses, retries, and 14 reference images

By Marigold1122·Created 3 months ago·Updated 22 days ago· 3
Chat Image Bridge Advanced
  • image_01
  • image_02
  • image_03
  • image_04
  • image_05
  • image_06
  • image_07
  • image_08
  • image_09
  • image_10
  • image_11
  • image_12
  • image_13
  • image_14
  • image
  • response
  • image_refs
api_key
base_url
modelgemini-3-pro-image-preview
prompt
system_prompt
size
extra_body_json
timeout_seconds300
retry_times1
redact_responsetrue

Same engine as the plain ChatImageBridge node, but with the hood up. ChatImageBridgeAdvanced is the debug-and-power variant you pull out when the standard node works for the happy path and you need to know why a relay did something weird, or when a provider needs parameters the standard UI doesn't expose. If the plain node is the daily driver, this one is the diagnostic tool you keep in the drawer - but it's also the only one that'll let you feed 14 reference images to a Gemini-style model, so it's not just for debugging.

What's different

The mechanism is identical under the hood: OpenAI-compatible chat completions (or native Gemini format for Gemini models when resolution/aspect ratio are set), images as base64 PNG data URLs, images recovered from markdown, URLs, b64_json, or inlineData. What Advanced adds is three outputs and a row of request overrides.

The outputs are the headline:

  • image - the IMAGE tensor, same as the plain node.
  • response - the raw JSON response as a string, so you can actually read what the provider sent back. Wire it to a text viewer or just peek at it. By default it's redacted - giant base64 blobs are replaced with <redacted N chars> - and the redact_response toggle controls that.
  • image_refs - a string listing the image references the node decoded, which is gold when a response technically contains an image but the node's parser can't turn it into a tensor.

The inputs worth knowing

Beyond the shared api_key, base_url, model, prompt, resolution, aspect_ratio, and timeout_seconds (default 300, 30–1800), you get:

  • system_prompt - a system message prepended to the conversation, for providers that respect one.
  • size - a free-form string sent as the size field (like 3840x2160). The plain node never lets you touch this directly.
  • extra_body_json - a JSON object that gets merged into the request payload, which is how you pass provider-specific fields no UI could predict.
  • retry_times - 1 to 10. The base node fires once; this one will retry with a short backoff (it sleeps up to a few seconds between attempts).
  • redact_response - boolean, default true. Flip it off and response will contain the full base64 payloads, which you will not enjoy scrolling past, but it's there when you need it.

Image inputs run image_01 through image_14. The README notes the relay can technically accept 20, but 14 is the reliable public limit for these models, so that's the cap.

Install

It's part of the Chat-Image-Bridge-Node pack:

cd ComfyUI/custom_nodes
git clone https://github.com/Marigold1122/Chat-Image-Bridge-Node.git ComfyUI-ChatImageBridge
pip install -r ComfyUI-ChatImageBridge/requirements.txt

Restart, then api -> Chat Image Bridge -> Chat Image Bridge Advanced. Or ComfyUI Manager, search "Chat-Image-Bridge-Node". Dependency is just requests.

Troubleshooting

  • "extra_body_json must be a JSON object" - it's parsed with json.loads and must be an object, not a string or a list. Trailing commas or single quotes will fail.
  • Huge response strings - if you disabled redaction, expect multi-megabyte outputs when an image comes back as b64_json. That's why the default is on.
  • Different-sized outputs - if the provider returns multiple images at different sizes, the node keeps the ones matching the first image's size and warns in the console. Most relays return one consistent image, but it's worth knowing where that console line comes from.
  • When you've confirmed a weird response via response, the fix is usually either a different model string or an extra_body_json field your specific relay needs - which is precisely why this node exists.

Use this one when you're diagnosing or when 14 reference images matter. For everything else, the plain ChatImageBridge is less to look at and does the same job.

Categoryapi/Chat Image Bridge

Inputs (24)

NameTypeDefaultDescription
api_keySTRING
base_urlSTRING
modelSTRINGgemini-3-pro-image-preview
promptSTRING
system_promptSTRING
sizeSTRING
extra_body_jsonSTRING
timeout_secondsINT30030–1800
retry_timesINT11–10
redact_responseBOOLEANtrue
image_01optIMAGE
image_02optIMAGE
image_03optIMAGE
image_04optIMAGE
image_05optIMAGE
image_06optIMAGE
image_07optIMAGE
image_08optIMAGE
image_09optIMAGE
image_10optIMAGE
image_11optIMAGE
image_12optIMAGE
image_13optIMAGE
image_14optIMAGE

Outputs (3)

NameTypeDescription
imageIMAGE
responseSTRING
image_refsSTRING