@@ -82,10 +82,10 @@ def parse_prompt_attention(text):
8282 (abc) - increases attention to abc by a multiplier of 1.1
8383 (abc:3.12) - increases attention to abc by a multiplier of 3.12
8484 [abc] - decreases attention to abc by a multiplier of 1.1
85- \( - literal character '('
86- \[ - literal character '['
87- \) - literal character ')'
88- \] - literal character ']'
85+ \\ ( - literal character '('
86+ \\ [ - literal character '['
87+ \\ ) - literal character ')'
88+ \\ ] - literal character ']'
8989 \\ - literal character '\'
9090 anything else - just text
9191 >>> parse_prompt_attention('normal text')
@@ -94,7 +94,7 @@ def parse_prompt_attention(text):
9494 [['an ', 1.0], ['important', 1.1], [' word', 1.0]]
9595 >>> parse_prompt_attention('(unbalanced')
9696 [['unbalanced', 1.1]]
97- >>> parse_prompt_attention('\(literal\]')
97+ >>> parse_prompt_attention('\\ (literal\ \ ]')
9898 [['(literal]', 1.0]]
9999 >>> parse_prompt_attention('(unnecessary)(parens)')
100100 [['unnecessaryparens', 1.1]]
@@ -433,6 +433,7 @@ class OnnxStableDiffusionLongPromptWeightingPipeline(OnnxStableDiffusionPipeline
433433 This model inherits from [`DiffusionPipeline`]. Check the superclass documentation for the generic methods the
434434 library implements for all the pipelines (such as downloading or saving, running on a particular device, etc.)
435435 """
436+
436437 if version .parse (version .parse (diffusers .__version__ ).base_version ) >= version .parse ("0.9.0" ):
437438
438439 def __init__ (
0 commit comments