Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -629,9 +629,10 @@ chain = load_chain("lc://chains/vector-db-qa/stuff/chain.json", vectorstore=vect
|
|
629 |
def run_chain(query):
|
630 |
return chain.run(query)
|
631 |
|
632 |
-
|
633 |
-
|
634 |
-
description="Enter a question and get an answer from Shegardi.")
|
635 |
|
636 |
-
|
|
|
637 |
|
|
|
|
629 |
def run_chain(query):
|
630 |
return chain.run(query)
|
631 |
|
632 |
+
inputs = gr.inputs.Textbox(lines=1, label="Enter your Question:")
|
633 |
+
outputs = gr.outputs.Textbox(label="Answer:")
|
|
|
634 |
|
635 |
+
def run_app(input):
|
636 |
+
return run_chain(input)
|
637 |
|
638 |
+
gr.Interface(fn=run_app, inputs=inputs, outputs=outputs, title="The following is a conversation with a human called Shegardi. Shegardi is helpful, precise, truthful, and very friendly. Also, Shegardi is an employee of Warba Bank, located in Kuwait. Shegardi will only use the information provided to him.").launch(share=True)
|