Closed xedis closed 1 year ago
this used to be a feature of the extension civitai helper, but since about a week and a half ago, there was a commit here that broke it.
Let's not mix things up, this is a valid feature request totally regardless of CivitAi and especially of CivitAi helper extension.
Regarding activation text, I think it might be worth bringing in A1111's recent changes that created a modal popup to view various metadata, including tags listed in the model file.
It allows the user to construct and save what the default activation text will be, either manually typing it or by clicking on the individual tags to build it up.
The current limitation it has is that it only pull tags from the model file's metadata, and doesn't look for civitai.info files (or other sources, to generalize).
Besides the ability to save custom activation text, I think it would be great to add an additional section of tags for each available data source (e.g. Civitai) -- the model file's metadata may not exist (meaning no tags), and the other sources could have useful tags/phrases that work well with the extra network.
The natural drawback of the new A1111 modal interface is that it does require the user to explicitly save the activation text for each model. However, the previous defacto standard of relying on Civitai Helper was very limited anyway (Civitai's 'trainedWords' are prone to all the classic problems of relying on the uploader to fill it out properly, and are still just suggestions).
For reference, here is a screenshot of the popup interface after clicking 'edit metadata': (Edit: Made collapsible)
I really love how you've created the directory list on the left side so far, and I think incorporating the above too would be a huge step in usability. Even before SDNext I was always frustrated at Civitai Helper's limits on the activation text (especially if the model doesn't exist on their site anyway).
i've added basic functionality - name/aliases/tags are displayed as card title and there is one extra button that adds/removes tags to prompt. it could be done much nicer from ui perspective, but don't have time right now. btw, i hate a1111 colorful tag display with counts. not to mention its veeery slow - ask ppl that have few hundred loras.
btw, i hate a1111 colorful tag display with counts. not to mention its veeery slow - ask ppl that have few hundred loras.
Fair enough, I hadn't tested it for performance yet at all. With slowdowns.. I'd pass too.
I just looked again and noticed it also seems to break apart phrases by spaces (in some cases) into individual tags where it doesn't make sense (like separating 'artist style' into two tags).
i'll check on that. problem is that there is no clear tag in safetensors metadata, it involves some string parsing.
Here's an example as a case-study, if it's helpful. It's tricky to come up with an interface that can handle it.
墨心 MoXin 1.0 https://civitai.com/models/12597?modelVersionId=14856
In this case, there are a lot of phrases demonstrating 7 different keywords (at the start of each phrase, for different artists/styles I believe).
SDNext removes the 100_
from "100_shuimosuxiebysim": {
, and gives: shuimosuxiebysim
which happens to match one of the keywords seen in the metadata list.
Side note: I found another model that starts with "8_bmt": {
, but bmt
isn't a keyword actually used in the tags. (See: https://civitai.com/models/20759)
A1111 breaks down all of the phrases by spaces into individual tags:
(notice things like and
and with
)
And since it truncates the tag list by frequency, it cuts out 4 of the 7 keywords!
For completeness, I compared to CivitAI's trainedWords:
CivitAI's trainedWords are almost convinent in this example, but it is missing two keywords from the model metadata ('fubaoshi', 'likuchan'), and one has a typo ('shuimobysim' should be 'shuimosuxiebysim', I assume.. or vise versa?).
Feature description
Many LoRA, LyCORIS, TI have "trigger words" listed in CivitAI's posts Can we modify one of the icons to paste the trigger words? In the API response it should be trainedWords. Confirmed found in civitapi model info https://github.com/civitai/civitai/wiki/REST-API-Reference#response-fields-2
Potential implementations depending on preference and well, complexity:
1 . Take the place of the Description buttons? I don't think they have ever provided any use for me personally. Unsure if others leverage them tho.
Since I myself am useless when it comes to writing fresh chunks of code, I can be of little use in developing this especially js, however this chunk of code from the civitai_helper.js may be of some use https://github.com/butaixianran/Stable-Diffusion-Webui-Civitai-Helper/blob/920ca3267f789a72e3225c99f069bf0be0db795d/javascript/civitai_helper.js#L636
Version Platform Description
No response