yangdx commited on
Commit
b0b8d3e
·
1 Parent(s): 64c403b

Remove the single quotation marks that enclose the names of the entities

Browse files
Files changed (1) hide show
  1. lightrag/utils.py +2 -0
lightrag/utils.py CHANGED
@@ -1428,6 +1428,8 @@ def normalize_extracted_info(name: str, is_entity=False) -> str:
1428
  # Remove English quotation marks from the beginning and end
1429
  if len(name) >= 2 and name.startswith('"') and name.endswith('"'):
1430
  name = name[1:-1]
 
 
1431
 
1432
  if is_entity:
1433
  # remove Chinese quotes
 
1428
  # Remove English quotation marks from the beginning and end
1429
  if len(name) >= 2 and name.startswith('"') and name.endswith('"'):
1430
  name = name[1:-1]
1431
+ if len(name) >= 2 and name.startswith("'") and name.endswith("'"):
1432
+ name = name[1:-1]
1433
 
1434
  if is_entity:
1435
  # remove Chinese quotes