ComfyUI Extension: Santodan Random LoRA Node

Authored by Santodan

Created

Updated

0 stars

Randomizes selected LoRAs and strengths. Includes trigger word output and support for exclusive/random selection.

Custom Nodes (0)

    README

    Santodan Custom Nodes for ComfyUI

    This is a standalone ComfyUI custom node for randomizing LoRAs with adjustable strength and support for automatic trigger word injection.

    ✅ Compatible with comfyui_image_metadata_extension by using the 💊 CR Apply LoRA Stack from Suzie1 / Comfyroll_CustomNodes


    🎲 Randomize LoRAs Node

    The Randomize LoRAs node lets you experiment by randomly selecting LoRAs from a list and assigning randomized strengths. You can enable exclusive selection (just one LoRA) or allow multiple LoRAs to be mixed.

    Additionally, if the LoRA includes trigger words (via lora-info), these are extracted and returned for use in prompts.


    🔧 Node Inputs

    • lora_name_X: Up to 10 LoRAs to pick from (slots 1–10)
    • min_strength_X: Minimum strength when a LoRA is selected
    • max_strength_X: Maximum strength
    • exclusive_mode:
      • On – choose 1 LoRA only
      • Off – choose a random number from the list
    • stride: Number of runs before re-randomizing (not currently enforced)
    • force_randomize_after_stride: Avoids repeating same LoRA set (partially supported)
    • refresh_loras: Dummy input to trigger updates in the UI
    • lora_stack: (Optional) Input for chaining or merging with existing LoRA stack

    📤 Node Outputs

    • LORA_STACK: A list of (name, min_strength, max_strength) tuples
    • Trigger Words: Comma-separated string of trigger words for selected LoRAs
    • Help Text: Describes the meaning of each setting for reference

    📥 Installation

    Option 1: ComfyUI-Manager (recommended)

    1. Open ComfyUI
    2. Open ComfyUI-Manager
    3. Search for Santodan or Randomize LoRAs
    4. Click Install

    Option 2: Manual Install

    cd ComfyUI/custom_nodes
    git clone https://github.com/Santodan/ComfyUI_santodan_custom_nodes
    

    Then restart ComfyUI.


    🔁 Updating

    cd ComfyUI/custom_nodes/ComfyUI_santodan_custom_nodes
    git pull
    

    Restart ComfyUI to apply the update.


    ❌ Uninstallation

    cd ComfyUI/custom_nodes
    rm -rf ComfyUI_santodan_custom_nodes
    

    Restart ComfyUI.


    🧠 Credits


    📸 Screenshot / Demo

    preview