Save 4 hours! We auto-setup your workflow! Free!

Drop your workflow.json — we handle every dependency, custom node, and model. Just open the link and run.

Auto-Setup Workflow Json (Free) Now!
ComfyUI > Nodes > ComfyUI-BFSNodes > BFS Shot Planner

ComfyUI Node: BFS Shot Planner

Class Name

BFSShotPlanner

Category
BFS/shot loop
Author
alisson-anjos (Account age: 1474days)
Extension
ComfyUI-BFSNodes
Latest Updated
2026-11-14
Github Stars
0.14K

How to Install ComfyUI-BFSNodes

Install this extension via the ComfyUI Manager by searching for ComfyUI-BFSNodes
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter ComfyUI-BFSNodes in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • 16GB VRAM to 80GB VRAM GPU machines
  • 400+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 200+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

BFS Shot Planner Description

Splits video into planned shots with prompts, references, and timing for downstream assembly.

BFS Shot Planner:

BFSShotPlanner turns a source video into a sequence of shorter shots that can be processed individually and assembled afterward. It can divide footage at detected camera cuts, at fixed lengths, or at boundaries you set by hand. For each shot, it prepares the source frames, applies the shot’s prompt and reference-picture choices, and carries timing and continuity information forward to the rest of the workflow. This makes longer video projects easier to manage: you can work shot by shot while retaining a timeline that tells BFS Shot Join where every segment belongs, including segments you chose not to generate.

BFS Shot Planner Input Parameters:

plan

Required STRING containing the planner’s JSON configuration. The planner panel normally writes this value; it identifies the video and stores settings such as the planned range, splitting method, shot boundaries, prompts, references, and run behavior. Changing it can alter the number of shots, their frames, and the results passed downstream. Its source-defined default is json.dumps(DEFAULT_PLAN), but the contents of DEFAULT_PLAN are not provided here, so no exact default JSON or setting ranges can be stated. No minimum or maximum string length is declared. The JSON must be valid, and the referenced video must be available in the input folder.

prompt

Optional STRING supplied through a connection. It provides the default prompt for shots that do not have their own prompt, overriding the panel’s global prompt. A shot-specific prompt still takes precedence. When Auto prompt is enabled, the connected text instead serves as its template, so its role depends on that panel setting. No default text, minimum length, maximum length, or fixed options are declared; leaving it unconnected lets the planner use the prompt information in plan.

mask

Optional MASK,IMAGE connection representing a mask for the whole source video. White marks the subject. It can supply externally prepared segmentation for shots that do not have their own mask video, text selection, or points, replacing that selection step for those shots. The tooltip specifies one mask per source frame and says that a different mask count is spread across the video. No numeric minimum, maximum, or default value is declared; leaving it unconnected means the planner does not supply this whole-video mask.

vlm

Optional CLIP vision-language model connection. With the relevant panel settings enabled, it can examine shots, suggest what to segment, describe a shot for the {shot} prompt placeholder, and help generate written prompts or missing picture and target descriptions. Connecting a model alone does not mean every feature is active: shot analysis also depends on the panel’s VLM configuration. The source identifies compatible loading examples as qwen3vl_4b and qwen3vl_8b. No numeric range or default model is declared; its default state is unconnected.

point_model

Optional MOLMO_POINT_MODEL connection for MolmoPoint-8B. When connected, a text selection such as “the red car” can be converted into points for SAM 3 to track, instead of asking SAM 3 to interpret that selection text directly. This affects how text-based subject selections are located, rather than setting the shot prompt. The source names “Auto Download & Load MolmoPoint-8B” as a loading example. No numeric range or default model is declared; its default state is unconnected.

BFS Shot Planner Output Parameters:

shots

A BFS_SHOT list containing one item for each shot handed to downstream processing. Each item carries its frames and shot-specific information, including timing, prompt, references, and applicable mask or continuity data. Connect it to compatible shot-processing nodes, then send the decoded results to BFS Shot Join. In a stored queue run, the planner may hand out only the next pending shot, or an assembly placeholder when every shot is already stored; therefore, the number of items handed out in that execution need not equal count.

count

An INT giving the number of enabled shots selected to run in the plan. It excludes disabled or otherwise skipped shots, which remain represented in timeline. In stored queue mode, this is the total number of selected shots, not necessarily the number generated during the current execution.

fps

A FLOAT giving the planned timeline’s frames per second. Use it to interpret frame counts as durations and to keep downstream video settings aligned with the planned timing; it is the planner’s working frame rate, which may differ from the source video’s frame rate.

width

An INT giving the planned generation width. It is calculated from the plan’s generation-size settings and the source dimensions. A shot processed as a crop can carry its own frame dimensions, so inspect the individual shot when working with cropped shots.

height

An INT giving the planned generation height. Together with width, it describes the main generation size and the starting dimensions for second-pass size calculations. Cropped shots can carry different frame dimensions.

audio

An AUDIO track covering the shots selected to run, trimmed to their planned duration. If the source has no usable soundtrack, or the plan selects silent audio, the planner supplies a silent track so downstream video creation still receives audio data. When skipped shots are retained in the final video, use the timeline-aware assembly path: this output is marked as audio for running shots only, while timeline carries audio aligned to the full planned sequence when source audio is available.

summary

A STRING containing a readable account of the plan. It reports information such as the selected shot count, frame total, duration, frame rate, generation size, skipped shots, and per-shot frame ranges. Depending on the run, it can also report second-pass dimensions, queue status, and VLM suggestions. Read it to check that the proposed split matches your intended edit before evaluating the finished video.

timeline

A BFS_SHOT_TIMELINE value containing every planned shot in order, including those that will not run. It records each segment’s boundaries and run status alongside source-video and timing information. Pass it to BFS Shot Join so the join can place generated shots correctly and handle skipped segments according to the plan’s fill setting.

refs

An IMAGE list of the distinct reference pictures used by the shots selected to run, without duplicates and in first-used order. It lets compatible downstream nodes access the pictures used across the plan. When no reference picture is used, the planner emits a grey placeholder image rather than an empty image output; check ref_count to distinguish that placeholder from a real reference.

ref_count

An INT giving the number of distinct, successfully loaded reference pictures in refs. A value of 0 means the accompanying grey image is only a placeholder, not a picture selected for a shot.

second_pass

A BOOLEAN indicating whether the plan’s Run-tab second pass is enabled. Use it to switch an upscale and second-sampling branch on or off. It describes the plan setting; it does not perform the second pass by itself.

upscale_width

An INT giving the calculated second-pass width. It is based on the planned generation size and the second-pass size settings, then aligned to the required image and latent grids. It is available as a planned dimension even when second_pass is off.

upscale_height

An INT giving the calculated second-pass height. Use it with upscale_width to configure the second-pass branch consistently; like the width, it is a calculated target, not an indication that upscaling has already happened.

BFS Shot Planner Usage Tips:

  • Set the video, working frame rate, planned range, and split method in the planner panel, then read summary to confirm the shot count and frame ranges before running an expensive generation graph.
  • Use cut-based splitting when camera changes should define shots; use fixed lengths for more uniform work units, or manual boundaries when a particular edit needs precise shot divisions. Keep each planned shot within the length supported by your generation model.
  • Put a prompt on a particular shot when it needs different treatment. Use the connected prompt for a shared fallback, and check the Auto prompt setting before assuming that connection will be used as the final wording.
  • Connect timeline to BFS Shot Join even when some shots are disabled. It preserves their positions and gives the join the information needed to fill or drop them according to the plan.
  • If you have a prepared whole-video subject mask, connect it to mask and check its alignment with the source footage. Shot-specific mask selections can take precedence, so review those shots separately.
  • Connect a compatible vlm when you want enabled VLM analysis or automatic descriptions. For text-based subject selections that need point guidance, connect point_model and inspect the resulting selection preview.
  • Use second_pass to control whether the upscale branch runs, and upscale_width and upscale_height for its target size. Do not infer that a second pass occurred merely because target dimensions are present.

BFS Shot Planner Common Errors and Solutions:

BFS Shot Planner: the plan is not valid JSON (...)

  • Explanation: The plan text could not be parsed as JSON, often because of a missing quote, comma, or closing bracket.
  • Solution: Reopen and save the plan through the planner panel, or validate any JSON you edited manually before running again.

BFS Shot Loop: file not found in the input folder: '...'

  • Explanation: The video named in plan does not resolve to an existing input file.
  • Solution: Check the video selection in the panel and confirm that the file still exists in the expected input location.

BFS Shot Loop: no frames decoded from ...

  • Explanation: The video file was found, but the decoder could not read any requested frames from it.
  • Solution: Confirm that the video plays normally, then try a supported, readable copy of the file and check that the planned range falls within the footage.

BFS Shot Planner: no shot is left to run (all disabled).

  • Explanation: The resolved plan contains no shots marked to run.
  • Solution: Enable at least one shot in the panel and review any settings that skip or filter shots.

Shot N: written prompt is outdated after changes to request/pictures/marks or writer rules. Use Write again in the panel, or connect the Planner VLM to regenerate it. The old prompt was not sent to generation.

  • Explanation: Auto prompt detected that a previously written prompt no longer matches the current shot settings, and no VLM was connected to rewrite it.
  • Solution: Use the panel’s Write action again after your changes, or connect the Planner VLM so the prompt can be regenerated.

ref_image / ref_image_2 are no longer planner inputs: the connected images are ignored.

  • Explanation: An older saved workflow still has legacy reference-image connections. This is a warning rather than a failure, but those pictures will not affect the planner.
  • Solution: Set reference pictures in the planner panel’s Prompts & refs tab and remove the obsolete connections from the old workflow.

shot N: head needs the queue loop ... generated without it

  • Explanation: A shot requests continuity from the previous shot’s generated ending, but the current automatic run does not have that previous result available.
  • Solution: Use the stored queue loop when that continuity is important, or choose a shot-continuity setting that does not depend on the previous generated ending.

BFS Shot Planner Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI-BFSNodes
RunComfy
Copyright 2025 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Models, enabling artists to harness the latest AI tools to create incredible art.

BFS Shot Planner