# vLLM-Omni vLLM-Omni offers a ComfyUI integration on top of its online serving API. It can send model inference requests to either a locally running vLLM-Omni service or a remote one. ## Requirement - Python 3.12 or above - [ComfyUI installed](https://docs.comfy.org/installation/system_requirements) - [vLLM-Omni installed](https://docs.vllm.ai/projects/vllm-omni/en/latest/getting_started/installation/) on either the same device or another device discoverable via the internet. - No need to install additional packages apart from those already required by ComfyUI. > [!TIP] > If you run both ComfyUI and vLLM-Omni on the same device, you can create separate virtual environments and use different Python versions for them. ## Installation Copy this folder to the `custom_nodes` subfolder of your ComfyUI installation. Your directory should look like `ComfyUI/custom_nodes/ComfyUI-vLLM-Omni`. If you are running ComfyUI during copying, you should restart ComfyUI to load this extension. > [!TIP] > You can use utility websites such as to download a subdirectory of a repo. Also checkout community discussions (e.g., ) for more info. On the device and virtual environment you run ComfyUI, launch ComfyUI with ```bash cd ComfyUI # The regular way python main.py # If you are mainly using this node, launch it faster with python main.py --cpu ``` On the device and virtual environment you run vLLM-Omni, start a model service with ```bash vllm serve The_Model_ID_to_Serve --omni --port 8000 ``` Check **ComfyUI's sidebar -> Node Library**. There should be a new folder named **vLLM-Omni**. If no, check your shell running the ComfyUI process. There may be some error messages before the line `Import times for custom nodes:` and the line `To see the GUI go to: http://127.0.0.1:8188`. ## Quickstart This extension offers the following nodes based on the output modalities (at **ComfyUI sidebar -> Node Library**): - **Generate Image** for text-to-image and image-to-image tasks - **Generate Video** for text-to-video, first-frame/image-to-video, and reference-conditioned video - **Latent Mask Editing** for MiniMax-H3 latent-mask editing (source media plus video/audio noise masks) - **FastH3 Deployment** for routing text-to-video requests to a MiniMax-H3 server with FastH3 fused at startup - **Multimodality Understanding** for multimodality-to-text and multimodality-to-audio tasks - **TTS** and **TTS Voice Clone** for TTS tasks - **Generate Music** for lyrics-and-description-to-music generation This extension also offers example workflows (at **ComfyUI sidebar -> Templates -> vLLM-Omni**) > [!NOTE] > The node UI and feature designs are intended to match vLLM-Omni online serving interfaces. It cannot offer more than what the interfaces support. Every node carries the vLLM-Omni mark in its title bar and is tinted by what it outputs, so a graph is readable at a glance: | Colour | Nodes | What they produce | | --- | --- | --- | | Blue | Generate Image, Generate Video, Multimodality Understanding, TTS, TTS Voice Clone | A generated image, video, audio, or text. These are the only nodes that reach a server. | | Amber | AR / Diffusion / Multi-Stage Sampling Params | Sampling parameters that apply to any model | | Purple | Qwen TTS Params, Wan Video Params, MiniMax-H3 Video Params | Parameters that only one model family accepts | | Red | LoRA, FastH3 Deployment | Which weights the server is expected to have loaded | | Teal | Video References, Latent Mask Editing | Reference media | Recolouring a node by hand (right click -> Colors) overrides its tint, and the choice is kept. **Generate Video** takes a clip length in seconds (`duration`), not a frame count. Frames stay the wire unit and are derived with the node's `fps`, so the length is always measured against the rate that is actually served; models that accept only certain frame counts still round to their own lattice server-side. Graphs saved before this widget existed stored `num_frames` in its place and are converted on load, using the fps recorded alongside it -- the browser console names every node it rewrites. To build a simple workflow yourself, - Drag a generation node onto the canvas. - Depending on your need, grab built-in multimedia file loader nodes, such as **image->Load Image**, **image->video->Load Video**, **audio->Load Audio** - Depending on your need, grab built-in multimedia file preview nodes, such as **image->Preview Image**, **image->video->Save Video**, **audio->Preview Audio**, **utils->Preview as Text**. - If you want to tune sampling parameters, grab corresponding nodes from **vLLM-Omni-> Sampling Params**. - For multi-stage models, you can connect multiple **AR Sampling Params** and **Diffusion Sampling Params** nodes to a **Multi-Stage Sampling Params List** node, and connect this node to the generation node. - For some multi-stage models like BAGEL, [only one stage's sampling parameters are exposed and tunable via vLLM-Omni's online serving API](https://docs.vllm.ai/projects/vllm-omni/en/latest/user_guide/examples/online_serving/bagel/). Thus, these models are treated as single-stage ones. Please check the vLLM-Omni documentation on how to correctly set each model's sampling parameters. - For multi-stage models where all stages are either autoregression or diffusion, you can also connect only a single Sampling Params node, indicating that this set of sampling parameters will be used for all stages. ## Screenshots and Examples ### Multimodal understanding (e.g., Qwen Omni series, BAGEL) (Also available at **ComfyUI sidebar->Template->vLLM-Omni->vLLM-Omni Multimodal Understanding**)

vLLM-Omni multimodal understanding

> [!TIP] > Although this node enables all-modality input, you should check whether the specific model you host and request for supports the modalities you connect to the node. You can configure per-stage sampling parameters for multi-stage models.

vLLM-Omni multiple stages

### Text-to-image and image-to-image generation (e.g., Z-Image-Turbo, Qwen-Image-Edit, BAGEL) (Also available at **ComfyUI sidebar->Template->vLLM-Omni->vLLM-Omni Image Generation**)

vLLM-Omni image generation

> [!TIP] > The node automatically choose text-to-image or image-to-image API endpoints depending on whether you connect an image input or not. ### Text-to-video and image-to-video generation (e.g., Wan, MiniMax-H3) (Also available at **ComfyUI sidebar->Template->vLLM-Omni->vLLM-Omni Video Generation**)

vLLM-Omni video generation

> [!TIP] > Connect **frame** for backward-compatible first-frame / image-to-video behavior. For MiniMax-H3 FL2VA, > connect **first_frame**, **last_frame**, or both to condition the start frame, end frame, or both. > > For reference-conditioned generation (MiniMax-H3 Ref2VA), connect a **Video References** node instead. > > Do not combine `frame` with `first_frame` or `last_frame`, and do not combine any frame input with > `references`. Task routing is automatic from which inputs you connect. For MiniMax-H3 Ref2VA, **Video References** accepts up to 9 images (`image_1`–`image_9`), 3 videos (`video_1`–`video_3`), and 3 audio clips (`audio_1`–`audio_3`), with at most 12 connected inputs in total. Any mixture containing at least one image or video is supported; empty and audio-only references are rejected. For example, you can combine 6 images, 3 videos, and 3 audio clips in one request. Within each media type, references follow slot-number order, skipping unconnected slots. For example, connecting `image_2` and `image_9` sends `image_2` as the first image and `image_9` as the second. Each image slot uses the first image in its batch. Existing connections to `image_1`, `image_2`, `audio_1`, `audio_2`, `video_1`, and `video_2` remain valid in saved workflows. #### MiniMax-H3 Reference to Video Load [MiniMax-H3 Reference to Video](example_workflows/vLLM-Omni%20MiniMax-H3%20Reference%20to%20Video.json) from **Templates → ComfyUI-vLLM-Omni**, or drag the JSON onto the canvas. It adapts the [official ComfyUI R2V workflow](https://github.com/Comfy-Org/workflow_templates/blob/main/templates/video_minimax_h3_r2v.json) to remote vLLM-Omni execution. Model loading, sampling, and VAE decoding run on the server; ComfyUI loads references and saves the returned video. Use an extension version containing the audio-preserving output fix from [#7456](https://github.com/vllm-project/vllm-omni/pull/7456). Older versions can drop the server's audio while decoding the response. 1. Start a Ref2VA-capable service using the [MiniMax-H3 recipe](../../recipes/MiniMaxAI/MiniMax-H3.md). Set **Generate Video** to its `/v1` URL and served model name. 2. Select your own image in **Load Image**. The template's filenames are placeholders relative to ComfyUI's input directory; no sample assets or model weights are bundled. 3. Connect **Load Video** and **Load Audio** when needed. Duplicate the loaders to fill more reference slots, or disconnect the image when using video-only input. Keep the references connected to **Generate Video** and leave `frame` disconnected. 4. Match prompt tags such as ``, `