mentalhealthbot / app.py
Royals404's picture
Create app.py
3b4acd6
raw
history blame contribute delete
945 Bytes
import gradio as gr
def qa_interface(question):
QUESTION = question
PROMPT = " You are an empathetic mental health chatbot. input: " + QUESTION + "output:"
json_op = predict_large_language_model_sample(PROMPT)
return json_op
iface = gr.Interface(fn=qa_interface,
inputs=[
gr.Textbox(label="Enter your queries")
#, gr.Slider(0, 1, 0.3)
#, gr.Slider(0, 1, 1)
#, gr.Slider(0, 1024, 700)
#, gr.Slider(0, 40, 40)
],
outputs=[
gr.Textbox(label="Bot"),
],
title="Mental Health ChatBot ",
description="Emphathetic Mental Health bot",
allow_flagging=False,
theme=gr.themes.Soft()
)
iface.launch(share=True)