ComfyUI
ComfyUI copied to clipboard
Add docstring to token_weights() and related functions in sd1_clip
Here's my attempt at adding some documentation for the behavior seen in #4610. Hopefully the explanation I gave in the docstring makes sense :)
I got a little carried away and also added a docstring for escape_important() and unescape_important(); documenting those two functions isn't all that helpful to explaining how nesting works in token_weights(), but I'm figuring that there's no harm in adding a little extra documentation.
Oh... there are indentation issues.
Oh... there are indentation issues.
Looks like I forgot to set my editor to use spaces instead of tabs, should be fixed now :)