Skip to content

Latest commit

 

History

History
9 lines (5 loc) · 916 Bytes

File metadata and controls

9 lines (5 loc) · 916 Bytes

preview image

A simple extension for web-ui to generate unique tokens for dreambooth/finetuning which are unlikely to conflict with existing concepts in the stable diffusion model. Should be placed in the extensions folder, e.g. stable-diffusion-webui-master\extensions\webui_finetuning_tokens

It creates a token out of an existing partial word + word in the CLIP vocab

It deprioritizes words with vowels or the letter y, and has a set list of known acronyms to avoid to increase the chances of generating a rare token. It avoids using the same sub-components in multiple tokens when generating a list of tokens.

The final result is printed in a python dictionary format so that it is very easy to slot into any stable diffusion build as a text replacer on a prompt, during training or inference.