Straive-Kripa commited on
Commit
43f4975
·
verified ·
1 Parent(s): a1d685e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -52,7 +52,7 @@ def anonymize_text_including_proper_nouns_and_addresses(text):
52
  # For recognized named entities
53
  label = ent_or_token.label_
54
 
55
- if label in ['ORG', 'PERSON', 'GPE', 'LOC', 'FAC']: # Optionally include'PROPN' for more restriction
56
  original = ent_or_token.text
57
  counters[label] += 1
58
  placeholder_with_counter = f"{label}__{counters[label]}"
 
52
  # For recognized named entities
53
  label = ent_or_token.label_
54
 
55
+ if label in ['ORG', 'PERSON', 'GPE', 'LOC', 'FAC', 'PROPN']: # Optionally include'PROPN' for more restriction
56
  original = ent_or_token.text
57
  counters[label] += 1
58
  placeholder_with_counter = f"{label}__{counters[label]}"