Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -21,13 +21,13 @@ def generate_response(user_input):
|
|
| 21 |
response = "I'm still under development, but I understand you said: {}".format(user_input)
|
| 22 |
return response
|
| 23 |
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
# Get user input
|
| 27 |
-
user_input = st.text_input("Enter your input: ")
|
| 28 |
|
| 29 |
-
|
| 30 |
-
|
|
|
|
|
|
|
| 31 |
|
| 32 |
|
| 33 |
# Generate response based on user input
|
|
|
|
| 21 |
response = "I'm still under development, but I understand you said: {}".format(user_input)
|
| 22 |
return response
|
| 23 |
|
| 24 |
+
st.title("Simple Sentiment Chatbot")
|
| 25 |
+
user_input = st.text_input("Enter your message:")
|
|
|
|
|
|
|
| 26 |
|
| 27 |
+
# Preprocess and generate response when the user hits Enter
|
| 28 |
+
if user_input:
|
| 29 |
+
if user_input.lower() == "quit":
|
| 30 |
+
st.stop()
|
| 31 |
|
| 32 |
|
| 33 |
# Generate response based on user input
|