TKM03 commited on
Commit
069bc7e
·
verified ·
1 Parent(s): 3cf8dcc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -8
app.py CHANGED
@@ -60,14 +60,15 @@ def process_resumes(files):
60
  entities = ner_pipeline(cleaned_text)
61
  classification = classify_resume_ner(entities)
62
 
63
- all_results[file_name] = {
64
- "Persons": list({e["word"] for e in entities if e["entity_group"] == "PER"}),
65
- "Organizations": list({e["word"] for e in entities if e["entity_group"] == "ORG"}),
66
- "Locations": list({e["word"] for e in entities if e["entity_group"] == "LOC"]),
67
- "Other Entities": list({e["word"] for e in entities if e["entity_group"] not in ["PER", "ORG", "LOC"]}),
68
- "Cleaned_Text": cleaned_text,
69
- "Classification (NER)": classification
70
- }
 
71
  return all_results
72
 
73
  def classify_resumes_with_model(files):
 
60
  entities = ner_pipeline(cleaned_text)
61
  classification = classify_resume_ner(entities)
62
 
63
+ all_results[file_name] = {
64
+ "Persons": list({e["word"] for e in entities if e["entity_group"] == "PER"}),
65
+ "Organizations": list({e["word"] for e in entities if e["entity_group"] == "ORG"}),
66
+ "Locations": list({e["word"] for e in entities if e["entity_group"] == "LOC"}),
67
+ "Other Entities": list({e["word"] for e in entities if e["entity_group"] not in ["PER", "ORG", "LOC"]}),
68
+ "Cleaned_Text": cleaned_text,
69
+ "Classification (NER)": classification
70
+ }
71
+
72
  return all_results
73
 
74
  def classify_resumes_with_model(files):