Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -4,9 +4,9 @@ from transformers import pipeline
|
|
| 4 |
sentiment_pipeline = pipeline("sentiment-analysis")
|
| 5 |
|
| 6 |
st.title("Sentiment Analysis with HuggingFace Spaces")
|
| 7 |
-
st.write("Enter a sentence to analyze its sentiment:")
|
| 8 |
|
| 9 |
user_input = st.text_input("")
|
|
|
|
| 10 |
if user_input:
|
| 11 |
result = sentiment_pipeline(user_input)
|
| 12 |
sentiment = result[0]["label"]
|
|
|
|
| 4 |
sentiment_pipeline = pipeline("sentiment-analysis")
|
| 5 |
|
| 6 |
st.title("Sentiment Analysis with HuggingFace Spaces")
|
|
|
|
| 7 |
|
| 8 |
user_input = st.text_input("")
|
| 9 |
+
user_input.label = "Enter a sentence to analyze its sentiment:"
|
| 10 |
if user_input:
|
| 11 |
result = sentiment_pipeline(user_input)
|
| 12 |
sentiment = result[0]["label"]
|