Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -7,6 +7,7 @@ def greet(text):
|
|
7 |
data = pipe(text)[0]
|
8 |
label = data["label"]
|
9 |
score = data["score"]
|
10 |
-
|
|
|
11 |
iface = gr.Interface(fn=greet, inputs="text", outputs="text")
|
12 |
iface.launch()
|
|
|
7 |
data = pipe(text)[0]
|
8 |
label = data["label"]
|
9 |
score = data["score"]
|
10 |
+
score = score * 100
|
11 |
+
return f"The text is {label}, with {score:.1f}% possibility."
|
12 |
iface = gr.Interface(fn=greet, inputs="text", outputs="text")
|
13 |
iface.launch()
|