🍃 ComfyUI-FlowControl

A unified custom node suite for ComfyUI featuring real-time queue controls, mid-generation pausing, queue crash recovery, visual model pickers, live latent canvas previews, folder automation, prompt utilities, and resolution tools.

⚠️ Notice: Fully compatible with both ComfyUI Frontend V2 (Nodes 2.0 / Vue UI) and Classic ComfyUI Frontend (Nodes 1.0 / LiteGraph).


📦 Individual Nodes Reference

Expand any node below to view its description, inputs, outputs, and usage documentation.

🍃 📁 LoRA Loader (Folder) (FolderLoraLoader)

Overview

Loads a LoRA by folder path using raw filename matching or formatted names with customizable output formatting options.

Inputs & Widgets

  • model (MODEL): Input model.
  • clip (CLIP): Input CLIP.
  • folder (STRING): Subfolder filter (e.g. Celebrities, PonyV6, *).
  • lora_name (COMBO): Dropdown listing available LoRA files in the target folder.
  • strength_model (FLOAT): Model weight strength (default 1.0).
  • strength_clip (FLOAT): CLIP weight strength (default 1.0).
  • output_format (COMBO, Advanced): Choose output format (Parsed Name, Filename, Filename without extension, Relative Path, Full Path, Custom Regex).
  • custom_regex (STRING, Advanced): Pattern used when output_format is Custom Regex.

Outputs

  • MODEL: Patched model.
  • CLIP: Patched CLIP.
  • lora_name (STRING): Formatted name or filename of the loaded LoRA.
🍃 ✨ LoRA Loader (Pretty) (FolderLoraLoaderPretty)

Overview

Loads a LoRA using formatted pretty names (e.g. Ana De Armas V1 instead of krea2_Ana-De-Armas_v1.safetensors).

Inputs & Widgets

  • model (MODEL): Input model.
  • clip (CLIP): Input CLIP.
  • folder (STRING): Subfolder filter.
  • lora_name (COMBO): Dropdown listing formatted pretty names.
  • strength_model (FLOAT): Model weight strength.
  • strength_clip (FLOAT): CLIP weight strength.
  • output_format (COMBO, Advanced): Choose output format (Parsed Name, Filename, Filename without extension, Relative Path, Full Path, Custom Regex).
  • custom_regex (STRING, Advanced): Pattern used when output_format is Custom Regex.

Outputs

  • MODEL: Patched model.
  • CLIP: Patched CLIP.
  • lora_name (STRING): Formatted name or filename of the loaded LoRA.
🍃 🖼️ Visual LoRA Loader (VisualLoraLoader / alias FolderLoraLoaderVisualPrettyV2)

Overview

Visual thumbnail LoRA browser with search, multi-selection, ranking badges (🔥, 🥇 Gold, 🥈 Silver, 🥉 Bronze), and automated Civitai SHA256 & TMDB preview image fetching.

Inputs & Widgets

  • model (MODEL): Input model.
  • clip (CLIP): Input CLIP.
  • folder (STRING): Folder filter.
  • strength_model (FLOAT): Model strength.
  • strength_clip (FLOAT): CLIP strength.
  • display_mode (COMBO, Advanced): Choose between Scrollable (fixed height) or Show All (auto-expanding node card).
  • sort_loras_by (COMBO, Advanced): Sort LoRAs inside folders (Name (A-Z), Name (Z-A), Usage (High to Low), Usage (Low to High), Date Modified (Newest First), Date Modified (Oldest First)).
  • sort_folders_by (COMBO, Advanced): Sort folder sections order (Name (A-Z), Name (Z-A), Total Usage (High to Low), Average Usage (High to Low), Total LoRAs (Most First)).
  • folder_position (COMBO, Advanced): Layout position of root LoRAs vs folders (Folders First vs Root LoRAs First).
  • content_alignment (COMBO, Advanced): Align tiles and folder headers to the left or right (Left Aligned vs Right Aligned).
  • output_format (COMBO, Advanced): Choose output format (Parsed Name, Filename, Filename without extension, Relative Path, Full Path, Custom Regex).
  • custom_regex (STRING, Advanced): Pattern used when output_format is Custom Regex.

Outputs

  • MODEL: Sequentially patched model with all active LoRAs loaded.
  • CLIP: Sequentially patched CLIP with all active LoRAs loaded.
  • lora_name (STRING): Comma-separated list of active LoRA names.
🍃 📷 Visual Image Loader (VisualImageLoader / alias ImageLoaderVisualPrettyV2)

Overview

Visual thumbnail browser for image folders with instant preview selection and EXIF positive prompt metadata extraction.

Inputs & Widgets

  • folder (STRING): Folder path to load images from.
  • display_mode (COMBO, Advanced): Scrollable vs Show All.
  • sort_images_by (COMBO, Advanced): Name (A-Z), Name (Z-A), Date Modified (Newest First), Date Modified (Oldest First).

Outputs

  • IMAGE: Selected image tensor.
  • positive_prompt (STRING): Extracted prompt metadata.
  • width (INT): Image width.
  • height (INT): Image height.
🍃 ↩️ Back To Placeholder (BackToPlaceholder)

Overview

Execution anchor node that undoes placing content into a placeholder slot by scanning text for LoRA pretty names matching a folder and restoring placeholder tokens (e.g. %celeb%).

Inputs & Widgets

  • text (STRING, Forced Input): Input prompt text.
  • lora_folder (STRING): Target LoRA folder filter.
  • placeholder (STRING): Token to restore (default %celeb%).

Outputs

  • text (STRING): Processed prompt text with restored placeholder tokens.
🍃 📂 Load Image From Folder (LoadImageFromFolder)

Overview

Monitors a folder for incoming images, loads the target image into a PyTorch tensor, and removes processed files.

Inputs & Widgets

  • folder (STRING): Watch directory path (default input/watch).
  • wait_if_folder_is_empty (BOOLEAN): Poll until image arrives vs return dummy tensor immediately.
  • rescan_interval (INT): Polling frequency in seconds.
  • sort_by (COMBO): Sort by date_modified, date_created, or name.
  • regex_filter (STRING): Regex pattern to filter filenames.

Outputs

  • image (IMAGE): Loaded image tensor.
  • has_image (BOOLEAN): True if image loaded, False if folder empty.
🍃 ⏱️ Recent Outputs (LoadRecentOutputs)

Overview

Chronologically cycles through recently generated output images from ComfyUI's output directory.

Inputs & Widgets

  • output_folder (STRING): Target output directory.
  • amount (INT): Number of newest images to pool (1-100).
  • index (INT): Step index selection.

Outputs

  • IMAGE: Output image tensor.
🍃 👁️ Live Latent Preview (PreviewLatentLiveNode)

Overview

Canvas rendering node that listens to sampler WebSocket latent binary streams and displays real-time live previews on the canvas during generation.

Inputs & Outputs

  • Category: FlowControl/Previews
  • Output Node: True
🍃 ⏸️ FlowControl Decision (FlowControlDecision)

Overview

Pauses workflow execution at a specific step and displays an inline UI popup with Continue, Cancel, or Stop Workflow actions, plus optional native OS desktop notifications.

Inputs & Widgets

  • disable (BOOLEAN): Bypass decision gate.
  • send_os_notification (BOOLEAN): Trigger native OS desktop toast on pause.
  • timeout (INT): Auto-continue timeout in seconds (-1 = infinite).

Outputs

  • cancel (BOOLEAN): False on Continue, True on Cancel (for branch routing).
🍃 ⭐ Favorite Prompts (FavoritePromptLoader)

Overview

Visually browse saved favorite images and prompts from your favorites folder.

Inputs & Widgets

  • display_mode (COMBO, Advanced): Scrollable vs Show All.
  • sort_images_by (COMBO, Advanced): Name (A-Z), Name (Z-A), Date Modified (Newest First), Date Modified (Oldest First).

Outputs

  • IMAGE: Favorite image tensor.
  • positive_prompt (STRING): Favorited prompt text.
  • MASK: Mask tensor.
  • width (INT): Image width.
  • height (INT): Image height.
🍃 💾 Save Favorite Preview (SaveFavoritePreview)

Overview

Preview image node equipped with a native "Save Active to Favorites" button widget.

Inputs & Outputs

  • images (IMAGE): Input images to preview and save.
🍃 📐 Text Aspect Ratio Finder (TextAspectRatioFinder / alias AspectRatioFinder)

Overview

Parses input text for aspect ratios (e.g. 16:9, 2.35:1), syntax-checks them, and calculates pixel resolution for a target megapixel target.

Inputs & Widgets

  • aspect_ratios (STRING): Allowed ratio list.
  • search_mode (COMBO): First match (Front) vs Last match (Back).
  • target_mp (FLOAT): Target megapixels (e.g. 1.0 MP).
  • default_aspect_ratio (COMBO): Fallback ratio if none found.
  • multiple_of (INT, Advanced): Dimension step multiple (default 8).
  • min_mp (FLOAT, Advanced): Minimum megapixel limit.
  • max_mp (FLOAT, Advanced): Maximum megapixel limit.
  • text (STRING, Optional Input): Input text to search.

Outputs

  • width (INT): Calculated width.
  • height (INT): Calculated height.
  • aspect_ratio (STRING): Matched ratio string.
🍃 📐 Preview Image Size & Aspect Ratio (PreviewImageSizeAspectRatio)

Overview

Visual display node that draws a scaled outline box preview of the image aspect ratio and dimension summary (W x H).

Inputs & Widgets

  • width (INT, Optional Input): Image width in pixels.
  • height (INT, Optional Input): Image height in pixels.
  • aspect_ratio (STRING, Optional Input): Aspect ratio string (e.g. 16:9 or 2:3).
  • ratio_float (FLOAT, Optional Input): Aspect ratio float value (e.g. 1.777).

Outputs

  • (None - Visual Display Node Only)
🍃 🔎 Text LoRA Finder & Loader (TextLoraFinder / alias LoraTextFinder)

Overview

Scans text prompts for LoRA names or custom patterns, automatically loads matched LoRAs into MODEL and CLIP, and outputs the formatted LoRA list.

Inputs & Widgets

  • model (MODEL): Input model.
  • clip (CLIP): Input CLIP.
  • folder (STRING): LoRA folder filter.
  • search_for (COMBO): Search by Parsed Name, Filename, Filename without extension, or Custom Regex.
  • custom_regex (STRING, Advanced): Pattern for custom regex search mode or output formatting.
  • search_mode (COMBO): First match (Front) vs Last match (Back) match priority.
  • find_amount (INT): Maximum number of LoRAs to find and load.
  • strength_model (FLOAT): Model strength.
  • strength_clip (FLOAT): CLIP strength.
  • output_format (COMBO, Advanced): Output format (Parsed Name, Filename, Filename without extension, Relative Path, Full Path, Custom Regex).
  • text (STRING, Optional Input): Text string to scan.

Outputs

  • MODEL: Model patched with matched LoRAs.
  • CLIP: CLIP patched with matched LoRAs.
  • loras (STRING): Comma-separated list of loaded LoRA names.
🍃 🔄 Prompt Queue Iterator (PromptQueueIterator)

Overview

Parses multiline prompt text blocks, popping/selecting prompts per batch queue iteration with persistent queue state saved to disk across restarts.

Inputs & Widgets

  • pop_mode (COMBO): Pop Top & Delete, Cycle / Loop, Random (Delete), Random (Keep).
  • separator (COMBO): >1 Empty Line, Newline, >2 Empty Lines.
  • text (STRING, Multiline Input): Multiline text input.

Outputs

  • prompt (STRING): Current popped prompt for the batch step.
  • remaining_text (STRING): Remaining multiline prompt text.
  • remaining_count (INT): Count of remaining prompts.
🍃 🔤 Multi Text Replacer (MultiTextReplacer)

Overview

Searches input text for multiple search targets specified in a comma-separated list or regex pattern and replaces all matches with a replacement string in a single-pass loop-safe execution.

Inputs & Widgets

  • find (STRING): Search targets list (e.g. %celeb%, %model%, %character% or "18 year old", "teen").
  • replace (STRING): Replacement string.
  • case_sensitive (BOOLEAN, Advanced): Case sensitivity toggle.
  • search_mode (COMBO, Advanced): Comma Separated List vs Regex Pattern.
  • text (STRING, Optional Input): Text string to process.

Outputs

  • text (STRING): Text after replacements.
  • replaced_count (INT): Total replacements executed.

⚙️ ComfyUI Settings Menu Reference

Configure options directly under ComfyUI Settings (⚙ gear icon):

⚙️ FlowControl Settings
  • 🍃 FlowControl: Favorites Folder: Path to store and load favorite prompts/images (default output/favorites).
  • 🍃 FlowControl: Enable LoRA Usage Tracking: Toggle LoRA usage counting and visual rank badges (🔥, Gold, Silver, Bronze) ON/OFF.
  • 🍃 FlowControl: Enable Civitai Auto-Scraping: Automatically download model preview images from Civitai via SHA256 file hashes.
  • 🍃 FlowControl: Civitai API Key: Optional key for Civitai SHA256 model preview search (Authorization: Bearer <key>).
  • 🍃 FlowControl: Enable TMDB Auto-Scraping: Automatically download celebrity preview images from TMDB.
  • 🍃 FlowControl: TMDB API Key: Optional key or Read Access Token (eyJ...) for celebrity preview search.
  • 🍃 FlowControl: Default Pause Queue State on Launch: Sets whether the queue should start Unpaused or Paused on boot.
  • 🍃 FlowControl: Default Pause Queue Mode on Launch: Sets the default pause behavior (Finish Active Prompt vs Instant Resume Node).
  • 🍃 FlowControl: Persistent Queue Restored Launch State: Controls what happens to crash-recovered queue items (Start Paused or Start Unpaused).
  • 🍃 FlowControl: Pause Button Unpaused Color: Customizable hex color for the toolbar unpaused state.
  • 🍃 FlowControl: Enable Pause Queue Toolbar Button: Toggle top action bar Pause & Continue button ON/OFF.
  • 🍃 FlowControl: Enable Persistent Queue (Auto-Recovery): Toggle the real-time crash recovery queue saving on or off.
  • 🍃 FlowControl: Enable System Tray Icon: Enables an OS notification area / system tray icon to view queue status with matching colors and trigger Pause (Finish/Instant) or Continue/Resume without opening the browser.
  • 🍃 FlowControl: Restore Assets on Launch: Automatically restores your latest generated images into the Assets / History pane when ComfyUI starts up.
  • 🍃 FlowControl: Restored Assets Count: The number of newest images from the output folder to populate into the Assets / History pane on launch (default 64).

🔒 Security & Privacy

  • All API keys and settings are stored locally in .env (excluded from git commits via .gitignore).
  • No hardcoded personal paths, keys, or credentials.
  • Atomic file writes (.tmp + os.replace) prevent JSON corruption during sudden crashes.

🚀 Installation & Setup

  1. Open your terminal and navigate to your ComfyUI custom_nodes directory:
    cd ComfyUI/custom_nodes
    git clone https://github.com/KOFiblto/ComfyUI-FlowControl.git
    
  2. Restart ComfyUI.
  3. Open ComfyUI Settings (⚙ gear menu) to configure API keys or feature toggles if desired.

📜 License

Distributed under the MIT License.

S
Description
No description provided
Readme MIT
3.3 MiB
Languages
JavaScript 50.9%
Python 48.7%
CSS 0.4%