hassoudi commited on
Commit
9f1d16e
·
verified ·
1 Parent(s): 8fc278f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -10,12 +10,12 @@ def load_healthcare_ner_pipeline():
10
  """Load the Hugging Face pipeline for Healthcare NER."""
11
  global ner_pipeline
12
  if ner_pipeline is None:
13
- login(token=os.environ["HFTOKEN"])
14
  ner_pipeline = pipeline(
15
  "token-classification",
16
  model="TypicaAI/HealthcareNER-Fr",
17
- use_auth_token=os.environ["HFTOKEN"],
18
- aggregation_strategy="simple" # Groups B- and I- tokens into entities
19
  )
20
  return ner_pipeline
21
 
 
10
  """Load the Hugging Face pipeline for Healthcare NER."""
11
  global ner_pipeline
12
  if ner_pipeline is None:
13
+ #login(token=os.environ["HFTOKEN"])
14
  ner_pipeline = pipeline(
15
  "token-classification",
16
  model="TypicaAI/HealthcareNER-Fr",
17
+ #use_auth_token=os.environ["HFTOKEN"],
18
+ aggregation_strategy="first" # Groups B- and I- tokens into entities
19
  )
20
  return ner_pipeline
21