Spaces:
Sleeping
Sleeping
File size: 344 Bytes
148f3f2 d308807 148f3f2 d308807 148f3f2 d308807 2b6660c d308807 |
1 2 3 4 5 6 7 8 9 10 11 12 13 |
import gradio as gr
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-classification", model="CAMeL-Lab/bert-base-arabic-camelbert-mix-sentiment")
def analyze(text):
result = pipe(text)
return result
demo = gr.Interface(fn=analyze, inputs="text", outputs="text")
demo.launch(debug=True)
|