sandz7 commited on
Commit
0bae6f9
Β·
1 Parent(s): 6e54d32

added chatinterface for the text generation

Browse files
Files changed (1) hide show
  1. app.py +5 -4
app.py CHANGED
@@ -303,10 +303,11 @@ with gr.Blocks(fill_height=True) as demo:
303
  <p>This contains a Generative LLM from <a href="https://openai.com/"><b>Open AI</b></a> called GPT-3.5-Turbo</p>
304
  </div>
305
  ''')
306
- text_prompt = gr.Textbox(label="Text Prompt")
307
- text_output = gr.Textbox(label="Generated Text")
308
- generate_text_button = gr.Button("Generated Text")
309
- generate_text_button.click(fn=bot_comms, inputs=text_prompt, outputs=text_output)
 
310
 
311
  # gr.Markdown(DESCRIPTION)
312
  # if mode == "chatting":
 
303
  <p>This contains a Generative LLM from <a href="https://openai.com/"><b>Open AI</b></a> called GPT-3.5-Turbo</p>
304
  </div>
305
  ''')
306
+ # text_prompt = gr.Textbox(label="Text Prompt")
307
+ # text_output = gr.Textbox(label="Generated Text")
308
+ # generate_text_button = gr.Button("Generated Text")
309
+ # generate_text_button.click(fn=bot_comms, inputs=text_prompt, outputs=text_output)
310
+ chat = gr.ChatInterface(fn=bot_comms, label="Chat with Bot.")
311
 
312
  # gr.Markdown(DESCRIPTION)
313
  # if mode == "chatting":