KvrParaskevi commited on
Commit
47b339a
·
verified ·
1 Parent(s): c39746a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -5
app.py CHANGED
@@ -23,18 +23,20 @@ def chatbot(message, history):
23
 
24
  # Create a Gradio chatbot interface
25
  with gr.Blocks() as demo:
26
- chatbot_interface = gr.Chatbot()
27
- msg = gr.Textbox()
28
- clear = gr.Button("Clear")
29
 
30
  # Define the chatbot function as a Gradio interface
31
  demo.chatbot_interface = gr.Interface(
32
  fn=chatbot,
33
- inputs="text",
 
 
 
34
  outputs="text",
35
  title="Langchain Chatbot",
36
  description="A simple chatbot using Langchain and Hugging Face"
37
  )
38
 
39
- # Launch the Gradio app
40
  demo.launch()
 
23
 
24
  # Create a Gradio chatbot interface
25
  with gr.Blocks() as demo:
26
+ #chatbot_interface = gr.Chatbot()
27
+ #msg = gr.Textbox()
28
+ #clear = gr.Button("Clear")
29
 
30
  # Define the chatbot function as a Gradio interface
31
  demo.chatbot_interface = gr.Interface(
32
  fn=chatbot,
33
+ inputs=[
34
+ gr.inputs.Textbox(lines=1, label="Input"),
35
+ gr.inputs.Textbox(lines=5, label="Chat History"),
36
+ ],
37
  outputs="text",
38
  title="Langchain Chatbot",
39
  description="A simple chatbot using Langchain and Hugging Face"
40
  )
41
 
 
42
  demo.launch()