Spaces:
Runtime error
Runtime error
Commit
·
8942d1e
1
Parent(s):
b233ca6
Update app.py
Browse files
app.py
CHANGED
@@ -4,14 +4,14 @@ def article_selection(sentiment):
|
|
4 |
if sentiment == "Positive":
|
5 |
return f"""The sentence you requested is Positive!"""
|
6 |
elif sentiment == "Negative":
|
7 |
-
return f"""The sentence you requested is
|
8 |
else:
|
9 |
-
return f"""The sentence you requested is
|
10 |
|
11 |
demo = gr.Interface(
|
12 |
fn=article_selection,
|
13 |
-
inputs = gr.inputs.Dropdown(["Positive","Negative","Neutral"]),
|
14 |
-
outputs = [gr.outputs.Textbox(label="Sentiment
|
15 |
)
|
16 |
|
17 |
|
|
|
4 |
if sentiment == "Positive":
|
5 |
return f"""The sentence you requested is Positive!"""
|
6 |
elif sentiment == "Negative":
|
7 |
+
return f"""The sentence you requested is Negative!"""
|
8 |
else:
|
9 |
+
return f"""The sentence you requested is Neutral!"""
|
10 |
|
11 |
demo = gr.Interface(
|
12 |
fn=article_selection,
|
13 |
+
inputs = gr.inputs.Dropdown(["Positive","Negative","Neutral"], label="What type of news articles would you like recommended?"),
|
14 |
+
outputs = [gr.outputs.Textbox(label="Sentiment of News Articles")],
|
15 |
)
|
16 |
|
17 |
|