Skip to content

Conversation

@HenkDz
Copy link

@HenkDz HenkDz commented Sep 11, 2025

Super Power Lora Loader - Enhanced LoRA Management

This PR introduces a new Super Power Lora Loader node that extends the original Power Lora Loader with advanced features while keeping the original implementation completely unchanged.

✨ Features Added

🔗 Trigger Words Integration

  • Individual trigger word fields for each LoRA
  • Automatic combination of trigger words into text output
  • Text input/output for seamless prompt integration
  • Toggle trigger words visibility on/off

📋 Template Management

  • Save Template: Store LoRA configurations as reusable templates
  • Load Template: Quickly apply saved LoRA sets with search functionality
  • Delete Templates: Remove unwanted templates with confirmation
  • Template persistence across sessions

🎨 Enhanced UI

  • Improved header with trigger words toggle
  • Modern template browser with search filtering
  • Professional visual polish and responsive design
  • Minimum width adjustment for trigger word fields

🏗️ Implementation

Clean Separation

  • Original Power Lora Loader: Remains 100% unchanged - matches upstream exactly
  • Super Power Lora Loader: New standalone node with enhanced features
  • No conflicts: Both nodes coexist independently

Backend Architecture

  • RgthreePowerLoraLoader: Original class (pristine)
  • RgthreeSuperPowerLoraLoader: Enhanced class with trigger word functionality
  • Proper inheritance structure with distinct input/output schemas
  • DELETE API endpoint for template management

Frontend Components

  • power_lora_loader.js: Original implementation (untouched)
  • super_power_lora_loader.js: New enhanced implementation
  • Enhanced template chooser with search and delete capabilities
  • Independent registration and node management

📸 Demo

image

Screenshot showing the enhanced interface with trigger words, template buttons, and text output

🔍 Testing

  • Both nodes load correctly in ComfyUI
  • Original Power Lora Loader functionality preserved
  • Super variant trigger words work correctly
  • Template save/load/delete functionality verified
  • Text output properly combines trigger words
  • Search functionality in template browser
  • No conflicts between node variants

💡 Benefits

  1. Backward Compatibility: Existing workflows using Power Lora Loader continue unchanged
  2. Enhanced Workflow: Users can upgrade to Super version for advanced features
  3. Clean Architecture: Proper separation of concerns with no code duplication
  4. Future-Proof: Easy to maintain and extend independently
  5. Professional UX: Modern template management with search and delete

📋 Files Changed

Core Implementation

  • __init__.py - Register both node variants
  • py/power_lora_loader.py - Add Super class with text I/O
  • web/comfyui/super_power_lora_loader.js - Enhanced frontend
  • Super Power Lora Loader.png - Demo screenshot

Supporting Infrastructure

  • web/comfyui/constants.js - Add SUPER_POWER_LORA_LOADER constant
  • web/comfyui/utils_menu.js - Enhanced template chooser
  • web/common/rgthree_api.js - Template deletion API
  • py/server/routes_power_lora.py - DELETE endpoint
  • web/comfyui/power_lora_loader.js - Reverted to original state

This implementation provides users with choice: keep using the reliable original, or upgrade to the enhanced Super version with trigger words and templates.

HenkDz added 9 commits August 21, 2025 19:16
- Add trigger word input field for each lora widget
- Add text input/output to node for prompt integration
- Combine trigger words from enabled loras into text output
- Update UI to show trigger word fields with placeholder text
- Increase minimum node width to accommodate new fields
- Update help text and headers to explain trigger word feature
- Create standalone Super Power Lora Loader with trigger word functionality
- Maintain original Power Lora Loader as pristine basic version
- Add template save/load capabilities for LoRA sets
- Include text input/output for prompt integration with trigger words
- Register both variants independently in node system
- Add showcase image demonstrating enhanced features

Separates functionality while preserving original author's implementation.
… features

Supporting Infrastructure:
- Add SUPER_POWER_LORA_LOADER constant to node registry
- Enhance template chooser with search functionality and delete capability
- Add DELETE API endpoint for template management
- Revert basic Power Lora Loader to pristine original state

Template Management Features:
- Interactive template browser with search filtering
- One-click template deletion with confirmation
- Improved error handling and user feedback
- Modern dialog interface with responsive design

API Enhancements:
- Add deletePowerLoraTemplate() method to rgthree_api
- Implement DELETE /rgthree/api/power_lora/templates endpoint
- Proper error handling and status responses
- Template persistence management

Code Separation:
- Remove all trigger word functionality from basic loader
- Remove template save/load buttons from basic version
- Clean revert to match original rgthree implementation exactly
- Maintain complete separation between basic and super variants

This completes the full implementation with both frontend and backend
support for the enhanced Super Power Lora Loader functionality.
@stef654547
Copy link

extremely useful

@w2253543w
Copy link

非常好,使用起来方便多了

@Galvo87
Copy link

Galvo87 commented Sep 12, 2025

Super useful, thanks!

@Mr-Wojack
Copy link

useful, thanks!

@HenkDz HenkDz changed the title feat: Add Super Power Lora Loader with enhanced featuresfeat: Add Super Power Lora Loader with enhanced features feat: Add Super Power Lora Loader with enhanced features Sep 12, 2025
@rgthree
Copy link
Owner

rgthree commented Sep 13, 2025

Thanks for the PR, this is cool stuff. I can tell you've jumped in here and there's a lot of value you've added and I'm excited to see a contribution like this.

With that said, I don't want to pull this in as-is. Some of it is actually incompatible, but that's just because I never expected to see a PR like that and don't have a formal how-to-contribute doc; perhaps I should.

But the other reason is I've been thinking how to better incorporate some of these features into the regular Power Lora Loader node. The way I see it, there's no reason the normal PLL can't have some of these feature (other than it's easier to an outside contribute to create a new node than hack an existing one, noted). I do like some of the way you've handled trigger words in the node. You can get the trigger words today in rgthree-comfy by using the Power Puter combined with the Power Lora Loader, but I like how you're work here ties it to the workflow node too.

Anyway, if you're interested, we can go back and forth on a design and how to incorporate some of the features within the PLL, including some of the work I've been thinking of incorporating. But I'd want to separate it from this PR and break up the work a bit.

Or I can take some of your ideas here as inspiration and find time to incorporate it myself if you're not interested if fleshing out a proposal and design.

@HenkDz
Copy link
Author

HenkDz commented Sep 14, 2025

But the other reason is I've been thinking how to better incorporate some of these features into the regular Power Lora Loader node. The way I see it, there's no reason the normal PLL can't have some of these feature (other than it's easier to an outside contribute to create a new node than hack an existing one, noted). I do like some of the way you've handled trigger words in the node. You can get the trigger words today in rgthree-comfy by using the Power Puter combined with the Power Lora Loader, but I like how you're work here ties it to the workflow node too.

Well I first started hacking the regular PPL, then I though it might be easier for you to merge if the node is totally separate from yours and doesn't affect anything from your orignal code, other than registering it.

Anyway, if you're interested, we can go back and forth on a design and how to incorporate some of the features within the PLL, including some of the work I've been thinking of incorporating. But I'd want to separate it from this PR and break up the work a bit.

Sure, I am all ears.

Or I can take some of your ideas here as inspiration and find time to incorporate it myself if you're not interested if fleshing out a proposal and design.

image

Yes, this can also help I have shown you what me and many others might really want to see in PLL, however, I am quite confident that it would be very challenging to "find time", I have this same issue. All depends on priorities.

@HenkDz
Copy link
Author

HenkDz commented Sep 14, 2025

Here's current state of the new node, really struggled to add collpasiblity. I have also add a settings to help users only activate what they need.
image

@ThePowerOfMonkeys
Copy link

+1 to something like this - its insanely frustrating to have to trawl the web to find info on a Lora you downloaded ages ago, to find the page down or removed.. when the information is in the metadata for the file!

PowerLoraLoader is a great tool, but being able to pull the trigger data out would be fantastic!

@rgthree
Copy link
Owner

rgthree commented Sep 21, 2025

+1 to something like this - its insanely frustrating to have to trawl the web to find info on a Lora you downloaded ages ago, to find the page down or removed.. when the information is in the metadata for the file!

PowerLoraLoader is a great tool, but being able to pull the trigger data out would be fantastic!

PowerLoraLoader does this already in the Show Info dialog, if possible. AFAICT, this PR doesn’t do anything further.

I do owe a breakdown on how we can get some of these other features into the PLL.

@HenkDz
Copy link
Author

HenkDz commented Sep 21, 2025

Is this considered an upgrade?

image

@ThePowerOfMonkeys
Copy link

+1 to something like this - its insanely frustrating to have to trawl the web to find info on a Lora you downloaded ages ago, to find the page down or removed.. when the information is in the metadata for the file!
PowerLoraLoader is a great tool, but being able to pull the trigger data out would be fantastic!

PowerLoraLoader does this already in the Show Info dialog, if possible. AFAICT, this PR doesn’t do anything further.

I do owe a breakdown on how we can get some of these other features into the PLL.

It does yeah, which is handy to get to the civitai page to see example prompts etc. its just a load more clicks & doesn't go with keyboard shortcuts to open / close dialogs (at least I dont think it does?) .. All I need is to quickly check what a trigger word is to update a complex prompt.. Just having the information in front of us is much more convenient. obviously your call:) & just stating a rationale!

I did try to get the triggers function working in the puter node (that's hugely powerful - nice work there!) but I'm not sure that's working after the latest comfy updates (asyncio error)

@Santodan
Copy link

Is this considered an upgrade?
image

sir, i really need to know how the hell you have made the buttons in a single line... trying to create that also in one of my nodes, and Gemini is not been able to
looking at how they appear, they don't seem to be "normal" buttons

@HenkDz
Copy link
Author

HenkDz commented Sep 26, 2025

Is this considered an upgrade?
image

sir, i really need to know how the hell you have made the buttons in a single line... trying to create that also in one of my nodes, and Gemini is not been able to looking at how they appear, they don't seem to be "normal" buttons

I refactore the whole thing, now you can just build on Vite, TS, Tailwind whatever. I have made an MD Guide for other LLMs to build the same.
image

I built my own ND Super Lora node and it is super handy and with beautiful UIand UX.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants