Kling O3 · Reference to Video
Named subjects with <<<image_1>>> and JSON elements
- reference_image_urls
- reference_video_urls
- video
- task id
Two ways to keep a character consistent, on one node. The simple one: wire up to seven reference images and address them in the prompt as <<<image_1>>>, <<<image_2>>>. The powerful one: build a named entity out of 2–4 images of the same subject in the elements field, then drop @name into the prompt wherever that character or object should appear. It runs from 10.08 credits per second, up to 4K.
How it works
Reference images are uploaded (PNG, JPEG fallback above 10 MiB), a quote is taken, the task goes to Kuaishou, and the finished MP4 comes back as a VIDEO. Standard plumbing for this pack: idempotency key on submit, progress text on the node, download at the end.
reference_image_urls is an autogrow group - connect one and a second socket appears, up to seven. Numbering follows connection order, and that's what <<<image_1>>> refers to, so reorder your connections and your prompt means something different.
elements is a JSON text field, and it's the part that needs care. Each element is an object with a name, a description, and an image_urls list of 2–4 pictures of the same character or object, plus optional per-element audio lists and start/end millisecond windows. Then @name in the prompt pulls that subject in. The tooltip flags it as 4K only, and the image_urls are URLs - this is the one place in the node where you can't just wire an IMAGE in. If your subject is a local file, put it somewhere fetchable first, or use the socket path with <<<image_n>>> instead. Leave the box blank and it simply isn't sent.
The other inputs
prompt - say who and what each reference is, then describe the shot. "@mara walks to the window, <<<image_3>>>'s jacket on, camera pushes in" is the shape that works.
reference_video_urls - optional, one clip, for motion, camera or characters. With a video you can use up to 4 reference images, and the run bills at a higher per-second rate. That last bit is easy to miss.
generate_audio - off by default; not available with a reference video. keep_original_audio - on by default, only relevant when a reference video is connected.
resolution - 720p, 1080p, 4k. aspect_ratio - 16:9, 9:16, 1:1. duration_seconds - 3 to 15.
shot_type and multi_prompt - the same single/multi/customize switch as elsewhere, with a JSON shot list whose durations must sum to duration_seconds.
Outputs
video (VIDEO) and task id (STRING). Save it, or feed another PopNow node. The id is your handle in the API console.
Install
Manager → PopNow → Install → restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/popnow-ai/popnow-comfyui
Key from popnow.ai/api/console/keys into Settings > PopNow or POPNOW_API_KEY, then restart once more. No dependencies, no model files, runs on anything that runs ComfyUI. Kill off custom_nodes/popnow_api.py if it exists.
Where people get burned
JSON. elements and multi_prompt are both text fields parsed as JSON, and a missing quote or a trailing comma turns into a stop before submission with "'elements' must be valid JSON". Build the object in a scratch file, validate it, paste it in.
Reference count limits are enforced server-side and they interact with video: seven images, or four if you connected a reference video. Exceed it and you get a 400 naming the field.
Money: with 4K and audio and a 15-second duration, a single take is not cheap, and the reference video seconds bill on top. Set Settings > PopNow > Max credits per run before experimenting. And remember a cancelled run keeps going on PopNow and is charged if it succeeds - check the API console rather than re-queueing.
Inputs (11)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | Say who and what each reference is (<<<image_1>>>, <<<image_2>>> and so on) and describe the shot they should produce. | |
| reference_image_urls | COMFY_AUTOGROW_V3 | Reference images for characters, objects, outfits or places, up to 7. Refer to them in the prompt as <<<image_1>>>, <<<image_2>>> and so on. | |
| elements | STRING | One named subject built from 2 to 4 images of the same character or object. Write @name in the prompt where it should appear. 4K only. JSON. A list of objects with "description", "end_ms"?, "image_urls", "name", "reference_audio_urls"?, "start_ms"?. | |
| aspect_ratio | COMBO | 16:9 | Output aspect ratio. |
| resolution | COMBO | 720p | Output resolution. Higher tiers cost more per second. |
| generate_audio | BOOLEAN | false | Generate a native soundtrack (voices, effects, ambience) with the picture. Audio costs more per second. Not available with a reference video. |
| keep_original_audio | BOOLEAN | true | Keep the reference video's own sound in the result. Only matters when a reference video is given. |
| duration_seconds | INT | 53–15 | Output length in whole seconds, from 3 to 15. Billed per second. |
| shot_type | COMBO | single | single keeps one continuous shot; multi lets the model cut the prompt into several shots on its own; customize follows the shot list you give in multi_prompt. |
| multi_prompt | STRING | Shot list for shot_type customize: one entry per shot, in order, each with its own prompt and length in seconds. The lengths must add up to duration_seconds. JSON. A list of objects with "duration_seconds", "prompt". | |
| reference_video_urlsopt | COMFY_AUTOGROW_V3 | Optional reference video (one clip) whose motion, camera or characters the new shot should draw on. Refer to it in the prompt as <<<video_1>>>. With a video, use up to 4 reference images. A run with a reference video is billed at a higher per-second rate. |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| video | VIDEO | — |
| task id | STRING | The PopNow task id, for the API console logs or support. |