Nodes/VRGameDevGirl Video Enhancement Nodes/VRGDG_IndexedPromptChunkerV2
ComfyUI Node

VRGDG_IndexedPromptChunkerV2

Same Prompt Splitter, But Now It Knows When to Re-Run

By vrgamegirl19·Created about a year ago·Updated about 7 hours ago· 718
VRGDG_IndexedPromptChunkerV2
  • any
  • text_output_1
  • text_output_2
  • text_output_3
  • text_output_4
  • text_output_5
  • text_output_6
  • text_output_7
  • text_output_8
  • text_output_9
  • text_output_10
  • text_output_11
  • text_output_12
  • text_output_13
  • text_output_14
  • text_output_15
  • text_output_16
  • text_output_17
  • text_output_18
  • text_output_19
  • text_output_20
  • text_output_21
  • text_output_22
  • text_output_23
  • text_output_24
  • text_output_25
  • text_output_26
  • text_output_27
  • text_output_28
  • text_output_29
  • text_output_30
  • text_output_31
  • text_output_32
  • text_output_33
  • text_output_34
  • text_output_35
  • text_output_36
  • text_output_37
  • text_output_38
  • text_output_39
  • text_output_40
  • text_output_41
  • text_output_42
  • text_output_43
  • text_output_44
  • text_output_45
  • text_output_46
  • text_output_47
  • text_output_48
  • text_output_49
  • text_output_50
prompt_text
scene_count16
index0
total_sets1

VRGDG_IndexedPromptChunkerV2 is the same scene-splitting utility as the original VRGDG_IndexedPromptChunker - one big prompt in, up to 50 scene-sized chunks out, with index and total_sets for multi-run batches - plus one new input that changes how you use it: an any wildcard socket.

That any input is the entire upgrade, so let's talk about it. The V1 node only re-evaluates when its own widgets change. But in a chunky workflow where the chunker sits downstream of an LLM or a text picker, upstream values change while the chunker's widgets stay identical - and in V1 that meant stale chunks unless you nudged it. V2 accepts any data type on any, so you can wire in a signal (a scene index, a trigger, anything) and the chunker re-splits whenever that input changes. It's dependency awareness grafted onto a string splitter.

Inputs worth knowing

The four from V1 carry over unchanged:

  • prompt_text - the full multi-scene prompt.
  • scene_count - chunks to produce (1–50, default 16).
  • index and total_sets - which batch this run handles out of how many total. Three runs of 16 from a 48-scene video means total_sets = 3 and index walking 0→1→2.

And the new one: any - the wildcard trigger. Feed it anything and the node re-splits on change.

Outputs are the same 50 text_output_1text_output_50 sockets, filled up to scene_count, each ready to wire into a per-scene CLIP encoder or conditioning group.

When V2 is the right choice

If your prompt text is generated by another node in the same graph - an LLM prompt creator, a cycling text picker, a file reader - V2 saves you from a class of "why is it still showing the old scenes" bugs. Every time the upstream text changes, the chunks refresh and the whole pipeline follows. If you're typing the prompt by hand and only changing it occasionally, V1 is fine and you don't need the extra socket. It's a quality-of-life fix aimed at the fully-automated workflow this pack is trying to build, and in that workflow it earns its place.

Install

Same pack, same install:

cd ComfyUI/custom_nodes
git clone https://github.com/vrgamegirl19/comfyui-vrgamedevgirl

Restart ComfyUI, look under VRGDG. Manager users search vrgamedev. No extra downloads.

Honest note

"V2" is a modest upgrade - don't expect a rewrite. If you already wired V1 into a working graph and it's behaving, there's no pressing reason to swap. But if you've ever stared at a chunker that refused to update, you already know why the wildcard input is the one you'd rather have.

CategoryVRGDG

Inputs (5)

NameTypeDefaultDescription
prompt_textSTRING
scene_countINT161–50
indexINT00–999
total_setsINT11–999
any*

Outputs (50)

NameTypeDescription
text_output_1STRING
text_output_2STRING
text_output_3STRING
text_output_4STRING
text_output_5STRING
text_output_6STRING
text_output_7STRING
text_output_8STRING
text_output_9STRING
text_output_10STRING
text_output_11STRING
text_output_12STRING
text_output_13STRING
text_output_14STRING
text_output_15STRING
text_output_16STRING
text_output_17STRING
text_output_18STRING
text_output_19STRING
text_output_20STRING
text_output_21STRING
text_output_22STRING
text_output_23STRING
text_output_24STRING
text_output_25STRING
text_output_26STRING
text_output_27STRING
text_output_28STRING
text_output_29STRING
text_output_30STRING
text_output_31STRING
text_output_32STRING
text_output_33STRING
text_output_34STRING
text_output_35STRING
text_output_36STRING
text_output_37STRING
text_output_38STRING
text_output_39STRING
text_output_40STRING
text_output_41STRING
text_output_42STRING
text_output_43STRING
text_output_44STRING
text_output_45STRING
text_output_46STRING
text_output_47STRING
text_output_48STRING
text_output_49STRING
text_output_50STRING