Fmt only (maybe)

This commit is contained in:
litagin02
2024-05-25 18:15:36 +09:00
parent acf93b80ce
commit 2274087da4
33 changed files with 216 additions and 166 deletions

View File

@@ -51,7 +51,7 @@ def normalize_text(text: str) -> str:
def replace_punctuation(text: str) -> str:
text = text.replace("", "").replace("", "")
pattern = re.compile("|".join(re.escape(p) for p in __REPLACE_MAP.keys()))
pattern = re.compile("|".join(re.escape(p) for p in __REPLACE_MAP))
replaced_text = pattern.sub(lambda x: __REPLACE_MAP[x.group()], text)