Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -56,11 +56,22 @@ def gradio_interface():
|
|
56 |
#title="Mental Health Chatbot"
|
57 |
)
|
58 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
59 |
# Add button to clear chat history
|
60 |
clear_button = gr.Button("Clear Chat History")
|
61 |
clear_button.click(fn=clear_chat, inputs=[], outputs=chatbot) # Clear chat on button click
|
62 |
|
63 |
-
demo.launch()
|
64 |
|
65 |
# Run the interface
|
66 |
gradio_interface()
|
|
|
56 |
#title="Mental Health Chatbot"
|
57 |
)
|
58 |
|
59 |
+
# Custom CSS to control size of the chatbox
|
60 |
+
css = """
|
61 |
+
#chatbot .input_textarea {
|
62 |
+
height: 100px !important; /* Adjust the height of the input box */
|
63 |
+
}
|
64 |
+
|
65 |
+
#chatbot .output_textarea {
|
66 |
+
height: 150px !important; /* Adjust the height of the output box */
|
67 |
+
}
|
68 |
+
"""
|
69 |
+
|
70 |
# Add button to clear chat history
|
71 |
clear_button = gr.Button("Clear Chat History")
|
72 |
clear_button.click(fn=clear_chat, inputs=[], outputs=chatbot) # Clear chat on button click
|
73 |
|
74 |
+
demo.launch(css=css)
|
75 |
|
76 |
# Run the interface
|
77 |
gradio_interface()
|