gsar78 commited on
Commit
bc2f0ea
·
verified ·
1 Parent(s): 2bbb059

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -8
app.py CHANGED
@@ -1,9 +1,4 @@
1
  import gradio as gr
2
- import torch
3
- from transformers import AutoModelForSequenceClassification, AutoTokenizer
4
-
5
- model = AutoModelForSequenceClassification.from_pretrained("gsar78/Greek_Sentiment")
6
- tokenizer = AutoTokenizer.from_pretrained("gsar78/Greek_Sentiment")
7
 
8
  def predict(text):
9
  # Tokenize the input text
@@ -34,8 +29,8 @@ iface = gr.Interface(
34
  fn=predict,
35
  inputs="text",
36
  outputs=[
37
- gr.outputs.Textbox(label="Prediction"),
38
- gr.outputs.Label(label="Label Confidence")
39
  ],
40
  title="Hellenic Sentiment AI",
41
  description=None,
@@ -54,4 +49,4 @@ iface = gr.Interface(
54
  footer="Development by Geo Sar"
55
  )
56
 
57
- iface.launch()
 
1
  import gradio as gr
 
 
 
 
 
2
 
3
  def predict(text):
4
  # Tokenize the input text
 
29
  fn=predict,
30
  inputs="text",
31
  outputs=[
32
+ gr.Textbox(label="Prediction"),
33
+ gr.Label(label="Label Confidence")
34
  ],
35
  title="Hellenic Sentiment AI",
36
  description=None,
 
49
  footer="Development by Geo Sar"
50
  )
51
 
52
+ iface.launch()