Nodes/ComfyUI-JakeUpgrade/Audio Input Switch JK๐Ÿ‰
ComfyUI Node

Audio Input Switch JK๐Ÿ‰

Pick between two audio tracks with a boolean โ€” made for video workflows with soundtracks

By jakechaiยทCreated 2 years agoยทUpdated 3 months agoยท 147
Audio Input Switch JK๐Ÿ‰
  • audio_false
  • audio_true
  • audio_output
  • boolean
โ—„boolean_valuefalseโ–บ

Video generation in ComfyUI doesn't stop at frames - the "Cuts" and talking-head workflows JakeUpgrade ships also carry audio around the graph, and occasionally you want a choice of which track goes where. Audio Input Switch JK๐Ÿ‰ is the switch-family node that does that: two AUDIO wires in, one boolean, the chosen clip flows out.

It landed as part of the pack's audio-aware push - the same v2.0.16 update that added Cut Audio JK, Cut Audio Index JK, and the scene-cut audio tools. If you're assembling a video from scene cuts, "use the voice-over for segment 1, the music bed for segment 2" is a routing problem, and this is a routing node.

How it works

Same core as every JK switch:

if audio_true is not None and boolean_value:
    return (audio_true, boolean_value)
else:
    return (audio_false, boolean_value)
  • boolean_value - True returns the "true" audio, False the "false" one.
  • audio_false - required, used when False.
  • audio_true - optional, used when True; unplugged = pass-through.

Outputs: audio_output (AUDIO) and boolean.

The AUDIO type is the one the video-helper / audio-node ecosystem uses - whatever produces audio in your graph (Video Helper Suite's audio load/save, the pack's own Cut Audio nodes, Qwen-ASR output, etc.) speaks it. This switch just routes the object; it doesn't decode or resample anything, so it's cheap and safe to drop into a video assembly line.

Where you'd use it

  • Toggle between a voice track and a music track for a given segment in a talking-video workflow.
  • A/B two versions of a scene's audio (original vs a cut/processed take) without rebuilding the graph.
  • Choose whether a segment gets audio at all - wire audio_true to a real clip and leave audio_false connected to silence/empty.

It's a niche node, honestly - you only need it if you're doing audio-in-the-graph work. But if you are, it's the difference between one toggle and a pile of cut-and-paste edits.

Install

Ships with ComfyUI-JakeUpgrade. ComfyUI Manager โ†’ search ComfyUI-JakeUpgrade, or:

cd ComfyUI/custom_nodes
git clone https://github.com/jakechai/ComfyUI-JakeUpgrade
cd ComfyUI-JakeUpgrade && pip install -r requirements.txt

No models. Menu: ๐Ÿ‰ JK/๐Ÿ”€ Switch. Same pack-level notes as the other switches: the Manager conflict warning with IPAdapter Plus is replacement-folder noise you can ignore, and if the switch menu is absent, check ENABLED_MODULES in config.ini.

Category๐Ÿ‰ JK/๐Ÿ”€ Switch

Inputs (3)

NameTypeDefaultDescription
boolean_valueBOOLEANfalseCondition to select between inputs (True=audio_true, False=audio_false)
audio_falseAUDIOAudio to return when condition is False
audio_trueoptAUDIOAudio to return when condition is True (optional)

Outputs (2)

NameTypeDescription
audio_outputAUDIOโ€”
booleanBOOLEANโ€”