Seedream 4.0 (ByteDance)
Seedream 4.0 in ComfyUI — the only way in, because the weights never shipped
- image_input
- image
- output_url
ByteDance has a very consistent policy: open the components, keep the products closed. Seedream is a product, and it has never had open weights - the whole line, from 4.0 up through 5.0 Pro, is API-only. That's why this node matters. If you want Seedream quality from inside a ComfyUI workflow, this is not one option among many; it's the door. It wraps Replicate's hosted bytedance/seedream-4 model, which is ByteDance's flagship text-to-image with a serious reputation for prompt adherence and clean high-res output. The trade is that every image is a paid API call - there's no local fallback to fall back to, because none exists.
That framing should also set your expectations. This isn't a node that saves you money or VRAM by being clever; it's a convenience wrapper around a commercial API that you could equally hit with a curl. What it saves you is the plumbing: input tensor handling, image-to-image, base64 conversion, and downloading the result back into the graph.
How it works
Standard pack mechanics: your prompt goes to replicate.Client.run("bytedance/seedream-4", ...) with a handful of generation parameters, and the returned URL is downloaded and converted into a ComfyUI tensor. Two things set it apart from the pack's other nodes: it accepts an optional input image for image-to-image work, and it exposes Seedream's multi-image generation settings.
The inputs that matter
- prompt - required, multiline. This model is known for following detailed natural-language descriptions, so be generous with it.
- api_token - required unless
REPLICATE_API_TOKENis set in the environment. - image_input - optional IMAGE. Connect this and you're doing image-to-image (or reference-driven generation) instead of pure text-to-image.
The resolution controls are where people get confused. size offers 1K, 2K, 4K and custom (default 2K). The width and height fields exist, but the code only sends them to the API when size is custom - set a size preset and your custom dimensions are silently ignored. And yes, this node will happily hand you a 4K tensor, so make sure whatever node is downstream can stomach it.
max_images (1–15) and sequential_image_generation (disabled/auto) are the interesting ones - Seedream can generate a sequence of related images rather than independent samples. aspect_ratio defaults to match_input_image, which makes sense when you've fed an input image; from pure text, pick an explicit ratio like 16:9 or 1:1 instead of trusting the default.
Outputs
image - the result as an IMAGE tensor. output_url - the direct Replicate URL as a STRING. Here's the honest gotcha: if you set max_images above 1, the node still returns only the first image. The source grabs output[0] and discards the rest, so the multi-image feature produces one tensor and one URL regardless of your setting. If you need all the generated variants, this node won't give them to you - that's a real limitation, not a tuning issue.
Installing it
Part of the comfyUI_charly_replicate_api pack. ComfyUI Manager, search "ComfyUI Replicate Image Generation & Edit", or:
cd ComfyUI/custom_nodes
git clone https://github.com/charlyad142/comfyUI_charly_replicate_api
Restart ComfyUI, and that's it - dependencies are just the replicate client plus requests and Pillow, no model downloads. You'll need a Replicate account and a token from replicate.com/account/api-tokens. Watch the billing: 2K and 4K generations cost noticeably more than 1K, and max_images multiplies that even though you'll only see the first result back in your graph.
Where people get burned
The pack-wide trap applies: any failure returns a red 512×512 placeholder image with "Error: ..." stuffed into the output_url output. When your preview goes red, read the string, don't stare at the tensor.
Beyond that, the two real surprises are the size/width/height interaction (custom dimensions only apply in custom mode) and the max_images single-output ceiling. Both are quirks of this wrapper rather than the model, so knowing them in advance saves you a confused afternoon.
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | — | |
| api_token | STRING | — | |
| image_inputopt | IMAGE | — | |
| sizeopt | COMBO | 2K | 4 options: 1K, 2K, 4K, custom |
| widthopt | INT | 20481024–4096 | — |
| heightopt | INT | 20481024–4096 | — |
| max_imagesopt | INT | 11–15 | — |
| aspect_ratioopt | COMBO | match_input_image | 6 options: match_input_image, 1:1, 16:9, 9:16, 4:3, 3:4 |
| sequential_image_generationopt | COMBO | disabled | 2 options: disabled, auto |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| output_url | STRING | — |