ComfyUI Extension: ComfyUI-Mute-Switch

Authored by zhaocaiji

Created

Updated

0 stars

Run ComfyUI workflows without the setup

No installs, no CUDA version roulette, no GPU sitting idle on your bill. Bring a workflow and run it in the browser.

A smart logic switch for ComfyUI that physically mutes upstream nodes to save GPU/CPU resources, featuring dynamic inputs and auto-cleanup.

Looking for a different extension?

Custom Nodes (0)

    README

    ComfyUI Mute Switch (Dynamic)

    A smart logic switch for ComfyUI that physically MUTES upstream nodes to save GPU/CPU resources, featuring dynamic inputs and auto-cleanup.

    Unlike a standard "Bypass" (which passes data through), this node sets the upstream execution mode to Mute (Never). This allows ComfyUI to completely skip processing entire branches of your workflow, saving time and VRAM.

    Features

    • True Resource Saving: Mutes unconnected or disabled branches preventing execution.
    • Dynamic Inputs: Automatically adds new input slots as you connect them.
    • Auto-Cleanup: Automatically removes unused slots and reorders inputs when links are removed.
    • Odd/Even Logic: Controlled by an integer input (1=On, 2=Off).
    • Invert Toggle: Easily flip the logic without changing the input number.
    • Zero-Output: Acts as a workflow sink (Output Node), no extra output sockets needed.

    Installation

    1. Clone this repository into your ComfyUI/custom_nodes/ folder:
      git clone [https://github.com/YOUR_USERNAME/ComfyUI-Mute-Switch.git](https://github.com/YOUR_USERNAME/ComfyUI-Mute-Switch.git)
      
    2. Restart ComfyUI.

    Usage

    1. Add Node: Search for Mute Switch.
    2. Control: Connect an Int or Primitive node to the control_value widget.
      • Odd Numbers (1, 3...): Inputs are Active.
      • Even Numbers (0, 2...): Inputs are Muted.
    3. Invert: Use the invert switch in the node widget to flip the logic (Odd=Mute, Even=Active).
    4. Connect: Drag your workflow branches (e.g., the output of a specialized module) into input_1. A new input_2 will automatically appear.

    Why use this?

    Standard boolean switches in ComfyUI often calculate both branches before discarding one. This node uses frontend JavaScript to act on the graph before execution starts, ensuring the disabled branch never even loads into memory.

    Run ComfyUI workflows without the setup

    No installs, no CUDA version roulette, no GPU sitting idle on your bill. Bring a workflow and run it in the browser.

    Learn more