Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
|
|
| 1 |
import torch
|
| 2 |
import os
|
| 3 |
import requests
|
|
@@ -23,9 +24,7 @@ def analyze_sentiment(text):
|
|
| 23 |
prompt = f"Tu es un analyseur de sentiment. Ton rôle est d'évaluer le sentiment général du texte fourni. Réponds uniquement par 'positif' ou 'négatif'. N'ajoute aucune explication. Voici le texte à analyser :{text}"
|
| 24 |
|
| 25 |
|
| 26 |
-
|
| 27 |
demo = gr.Interface(
|
| 28 |
-
fn=greet,
|
| 29 |
inputs=["text"],
|
| 30 |
outputs=["text"],
|
| 31 |
)
|
|
|
|
| 1 |
+
|
| 2 |
import torch
|
| 3 |
import os
|
| 4 |
import requests
|
|
|
|
| 24 |
prompt = f"Tu es un analyseur de sentiment. Ton rôle est d'évaluer le sentiment général du texte fourni. Réponds uniquement par 'positif' ou 'négatif'. N'ajoute aucune explication. Voici le texte à analyser :{text}"
|
| 25 |
|
| 26 |
|
|
|
|
| 27 |
demo = gr.Interface(
|
|
|
|
| 28 |
inputs=["text"],
|
| 29 |
outputs=["text"],
|
| 30 |
)
|