@@ -185,7 +185,7 @@ class ChinesePromptTranslate(Transformer):
|
||||
|
||||
|
||||
#定义Prompt文法
|
||||
grammar = """
|
||||
grammar = r"""
|
||||
start: sentence
|
||||
sentence: phrase ("," phrase)*
|
||||
phrase: emphasis | weight | word | lora | embedding | schedule
|
||||
|
||||
@@ -168,7 +168,7 @@ def process(text, seed=None):
|
||||
replacements_found = True
|
||||
string = string.replace(f"__{match}__", replacement, 1)
|
||||
elif '*' in keyword:
|
||||
subpattern = keyword.replace('*', '.*').replace('+','\+')
|
||||
subpattern = keyword.replace('*', '.*').replace('+', r'\+')
|
||||
total_patterns = []
|
||||
found = False
|
||||
for k, v in easy_wildcard_dict.items():
|
||||
|
||||
+1
-1
@@ -1728,7 +1728,7 @@ class saveText:
|
||||
if not os.path.isabs(output_file_path):
|
||||
output_path = os.path.join(self.output_dir, output_path)
|
||||
base_output = os.path.basename(output_path)
|
||||
if output_path.endswith("ComfyUI/output") or output_path.endswith("ComfyUI\output"):
|
||||
if output_path.endswith("ComfyUI/output") or output_path.endswith(r"ComfyUI\output"):
|
||||
base_output = ""
|
||||
|
||||
# Check output destination
|
||||
|
||||
Reference in New Issue
Block a user