ComfyUI Node

Scene-Beat Data

The beat's prompt and timing, pulled into the loop

By wgedeon·Created 12 months ago·Updated 10 months ago· 2
Scene-Beat Data
  • scene_beat
  • title
  • duration_secs
  • positive
  • negative

Scene-Beat Data is the extractor for the pack's leaf level. Wire Play (Start)'s beat_current output into its scene_beat input and it returns the beat's title, duration_secs, positive, and negative - the shot-level prompt and timing that define the chunk currently being rendered.

Of the four Data extractors in this pack, this is the one you're most likely to actually use every iteration, because the beat is where the interesting text lives. The whole point of the layered tree is that acts and scenes set the stage while beats write the shot ("camera tracks left as he walks," "she turns toward the sea"), and those shot prompts need to reach the text encoder. Scene-Beat Data is the conduit: grab positive/negative here and feed them into your CLIP encoder or sampler inside the loop body.

The outputs that matter

  • positive, negative - the beat's shot-level prompt strings. Plain text, not conditioning - this pack stores and passes strings, so the encoding happens downstream, in your graph.
  • duration_secs - the beat's length in seconds. Useful if your sampler or scheduling logic wants to reason about timing rather than frame counts. Note the output type is INT here even though you set a FLOAT on the Scene-Beat node, so expect rounding if you go below a second.
  • title - purely descriptive; wire it to a display node or filename logic if you want beat names in your outputs.

Input is a single optional SCENE_BEAT socket. Leave it empty and you get empties (and, amusingly, the string "Beat is None" in the title output - a debugging crumb the author left in).

Installing

With the pack via ComfyUI Manager (search "comfyui_play_traversal") or:

cd ComfyUI/custom_nodes
git clone https://github.com/wgedeon/comfyui_play_traversal
pip install -r requirements.txt

Restart ComfyUI. Standard heavy install for this pack (diffusers, accelerate, onnxruntime, opencv-python, spandrel, peft, clip_interrogator, sentencepiece, matplotlib, lark); no bundled models.

Where people get burned

  • Wire it from beat_current, not your Scene-Beat node. The static beat you built carries the fields, sure, but inside a loop you always want the current beat - the loop re-injects the new beat_current into Play (Start) on every expansion. Grab it from the wrong place and every chunk uses beat one's prompt.
  • duration_secs is an INT here. Your 1.5-second beat comes out as an integer. If you're doing timing math with it, convert and be aware you've already lost precision.
  • This is the beat layer, not the scene layer. Per-beat shots here; scene flavor from Scene Data; play globals from Play Data. Mix them up and you'll wonder why your "cinematic" tag never shows up - it's two extractors up the tree.
  • Early single-author pack (version "2.0.0-inprogress") - the console traversal prints are your best debugging view.
CategoryFeller of Trees/Play Traversal

Inputs (1)

NameTypeDefaultDescription
scene_beatoptSCENE_BEAT

Outputs (4)

NameTypeDescription
titleSTRING
duration_secsINT
positiveSTRING
negativeSTRING