ComfyUI Extension: LoRA Range Loader
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.
ComfyUI custom node: load a LoRA from current selection and automatically advance current within a first/last filename range.
README
comfyui-lora-range-loader (ComfyUI)
![]()
Custom node for ComfyUI that loads a LoRA like the core LoraLoaderModelOnly, but adds a filename range sweep workflow for testing many LoRA checkpoints from the same training run.
What this node does
- Adds the node Load LoRA Range (Model Only).
- Loads the LoRA selected in
currentexactly like the core model-only LoRA loader. - Adds
firstandlastfields to define an allowed filename range. - Adds
modeto control howcurrentchanges after each queued run. - Supports these modes:
fixed: keepcurrentunchangedincrement: move to the next filename in the sortedfirst..lastrange and wrap tofirstdecrement: move backward in the sortedfirst..lastrange and wrap tolastrandom: pick a random filename from the sortedfirst..lastrange
How it works
The node is split into two parts:
- Backend Python loads only the LoRA selected in
current. - Frontend JavaScript updates
currentafter the workflow is queued.
This means the LoRA used for the current execution is always the value visible in current at queue time, and the next value is prepared for the following run.
Range rules
- The list of LoRAs is sorted by filename in ascending order.
firstmust come before or equal tolastin that sorted list.- If
firstcomes afterlast, automatic switching is disabled. - If
currentis outside thefirst..lastrange, the node still loads that LoRA, butincrement,decrement, andrandomdo not change it.
LoRA loading behavior
- The node reuses the core
LoraLoaderimplementation. - It does not load
firstorlastinto memory. - It only loads
current. - It inherits the same single-entry cache as the core loader, so repeating the same
currentvalue does not reload the LoRA file unnecessarily.
Compatibility
Backend compatibility:
- The Python node is lightweight and relies only on ComfyUI core APIs.
- No extra Python packages are required.
Frontend compatibility:
- Full automatic switching of
currentrequires a modern ComfyUI frontend that supports widget queue lifecycle hooks. - If the frontend extension does not run, the backend node still works as a manual
currentLoRA loader.
How to use
- Add Load LoRA Range (Model Only) to the graph.
- Connect your
MODELinput. - Choose
first,last, andcurrentfrom the LoRA dropdowns. - Choose
mode. - Run the workflow repeatedly.
- Observe
currentadvancing for the next run according tomode.
Install via ComfyUI-Manager
- Open Manager in ComfyUI.
- Install this node from the list or by repository URL.
- Restart ComfyUI or refresh node definitions.
Manual install
- Clone or copy this repository into
ComfyUI/custom_nodes/. - Restart ComfyUI.
No additional Python dependencies are needed.
Included files
__init__.py- backend node definition- web/lora_range_loader.js - frontend logic that advances
current
Notes for publishing
- The Registry package name in
pyproject.tomlis intended to be stable and should be treated as immutable after publishing. - If you want a different final GitHub repository URL or package name, change it before the first Registry publish.
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.