Add support for Chinese book title marks in normalize_extracted_info

This commit is contained in:
yangdx 2025-09-04 18:51:57 +08:00
parent ae65676b4e
commit 2c551cb5db

View file

@ -1896,6 +1896,12 @@ def normalize_extracted_info(name: str, remove_inner_quotes=False) -> str:
if "" not in inner_content and "" not in inner_content:
name = inner_content
# Handle Chinese-style book title mark
if name.startswith("") and name.endswith(""):
inner_content = name[1:-1]
if "" not in inner_content and "" not in inner_content:
name = inner_content
if remove_inner_quotes:
# Remove Chinese quotes
name = name.replace("", "").replace("", "").replace("", "").replace("", "")