EkhiAzur commited on
Commit
80f9f0f
1 Parent(s): 7b6d8e8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -2
app.py CHANGED
@@ -2,7 +2,7 @@ import gradio as gr
2
 
3
  from transformers import AutoModel, pipeline, AutoTokenizer, AutoModelForSequenceClassification
4
 
5
- access_token = "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"
6
 
7
  model = AutoModelForSequenceClassification.from_pretrained("EkhiAzur/RoBERTA_3", token=access_token)
8
 
@@ -22,7 +22,6 @@ def prozesatu(Testua, request: gr.Request):
22
  return {"Gai":prediction["score"], "Ez gai": 1-prediction["score"]}
23
  else:
24
  return {"Gai":1-prediction["score"], "Ez gai": prediction["score"]}
25
- #return 'C1:{}. Probabilitatea:{:.2f}'.format(prediction["label"], round(prediction["score"], 2))
26
 
27
  prozesatu.classifier = classifier
28
 
 
2
 
3
  from transformers import AutoModel, pipeline, AutoTokenizer, AutoModelForSequenceClassification
4
 
5
+ access_token = os.environ['ACCES_TOKEN']
6
 
7
  model = AutoModelForSequenceClassification.from_pretrained("EkhiAzur/RoBERTA_3", token=access_token)
8
 
 
22
  return {"Gai":prediction["score"], "Ez gai": 1-prediction["score"]}
23
  else:
24
  return {"Gai":1-prediction["score"], "Ez gai": prediction["score"]}
 
25
 
26
  prozesatu.classifier = classifier
27