aghoraguru commited on
Commit
5fb7795
·
verified ·
1 Parent(s): c1d3e54

lets see if this works

Browse files
Files changed (1) hide show
  1. app.py +8 -5
app.py CHANGED
@@ -51,11 +51,12 @@ def create_chat_widget():
51
  with gr.Blocks() as chatblock:
52
  # Adding a row for the New Chat button at the top
53
  with gr.Row():
54
- new_chat_button = gr.Button("New Chat")
55
- new_chat_button.click(
56
- lambda: ([], ""),
57
- inputs=[],
58
- outputs=[chatbot] )
 
59
 
60
  # Main chat interface
61
  with gr.Row():
@@ -67,6 +68,8 @@ def create_chat_widget():
67
  bubble_full_width=False,
68
  height=600,
69
  )
 
 
70
  with gr.Row():
71
  txt = gr.Textbox(
72
  placeholder="Enter text and press enter to chat with the bot.",
 
51
  with gr.Blocks() as chatblock:
52
  # Adding a row for the New Chat button at the top
53
  with gr.Row():
54
+ new_chat_button = gr.Button(
55
+ "New Chat",
56
+ scale=3,
57
+ interactive=True,
58
+ )
59
+ new_chat_button.click(new_chat, [], [chatbot, txt])
60
 
61
  # Main chat interface
62
  with gr.Row():
 
68
  bubble_full_width=False,
69
  height=600,
70
  )
71
+
72
+
73
  with gr.Row():
74
  txt = gr.Textbox(
75
  placeholder="Enter text and press enter to chat with the bot.",