Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Way to get tags from metadata of lora without needing to load a model #9

Open
ewebgh33 opened this issue Sep 7, 2024 · 1 comment

Comments

@ewebgh33
Copy link

ewebgh33 commented Sep 7, 2024

As title says, is there a way to get tags out, without having to load a model into VRAM?

Setting up a workflow
Tried these nodes
Tried to queue a text dispay to show the tags from metadata
Error: connect model and clip
Why?

Why is the model needed to queue to the output of the lora's metadata tags?
Loading models is slow - reading metadata should be fast and have nothing to do with what model I have loaded (or not).

It would be really great if tags could be output without having to process the whole chain up to the lora loader.

I was looking at your nodes because I want an integrated lora loader / tag reader to get the trigger words out of loras.
With other nodes, the loader is one node, and the metadata reader is a separate node (so I have to choose the lora in two places).

Also
Is there a way to get out JUST the keywords / trigger words, not a list of prompts etc?
I have folders of loras, and all of them have been processed with the CivitAI Lora Helper extension, which adds json for each Lora containing the trigger words, prompt examples, etc.
I guess your node is pulling from two locations - civit, and lora metadata. And I guess lora metadata is NOT the same as the data in the JSON which lists trigger words.
As I have already queried Civit for all loras, and now have the data locally, I don't want to have a connection to civit each time I load a lora. While this is good functionality (and I like that I can set to false so it won't connect to internet), it would also be good to check the json that is on the drive with each lora, and pull trigger words from that.

Interested in your thoughts.

@Extraltodeus
Copy link
Owner

Extraltodeus commented Sep 7, 2024

Hello! The node is pretty simple. It gets tags from Civitai and save them in the root of your ComfyUI folder in a file named loratags.json

Check the forks of this project, somebody made a version with added functionnalities which may suit your needs better. I don't intend to modify this one much as I am not too big on loras. I was just annoyed at not remembering the tags.

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

No branches or pull requests

2 participants