Preface
As I have already written in some previous articles, there is a problem if the file name without extension is different from the output name in the LoRA file (see Figure 1).
As I could not sleep, I took on this problem and quickly programmed a suitable Extension. First tests looks good. The Extension is working as expected.
What the Extension Does
One can select a LoRA file from a dropdown menu. Sorting is possible in alphabetical forward and backward direction. The selected filename without extension is shown in a textbox on the left side. The filename from the metadata is shown in a textbox on the right side. in parallel the JSON data is shown in textbox underneath. After clicking the Adjust button, the Extension tries to change the metadata tag, which is responsible for the filename. Afterwards one can check clicking on the Update button, if the operation was successful.
Figure 1: Adjust LoRA Filename Extension
The Extension creates a backup copy of the original file with the extension .bak in the LoRA folder.
Installation
The installation link is
https://github.com/zentrocdot/sd-webui-adjust_lora_filename
Known Problem
If the LoRA files have not the right permissions, the Extension is producing in the terminal window an error message. I have to catch this error in a proper way.
To-Do
I have to write a documentation. The Extension has to be tested a little bit more.
Remarks
Please use this Extension carefully at the moment and create in every case a backup file if possible. Use the Extension at your own risk.
Final Word
Have a nice day. Have fun. Be inspired!
Reference
[1] https://github.com/zentrocdot/sd-webui-adjust_lora_filename