zakerytclarke commited on
Commit
718818d
·
verified ·
1 Parent(s): 62c86e1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -304,9 +304,9 @@ def handle_chat(prompt, user_input, teapot_ai):
304
 
305
  return response
306
 
307
- def suggestion_button(suggestion_text, teapot_ai):
308
  if st.button(suggestion_text):
309
- handle_chat(suggestion_text, teapot_ai)
310
 
311
 
312
  def main():
@@ -329,11 +329,11 @@ def main():
329
 
330
  s1, s2, s3 = st.columns([1, 2, 3])
331
  with s1:
332
- suggestion_button("Tell me about teapotllm", teapot_ai)
333
  with s2:
334
- suggestion_button("Who invented quantum mechanics?", teapot_ai)
335
  with s3:
336
- suggestion_button("Extract the year Google was founded", teapot_ai)
337
 
338
  if user_input:
339
  with st.spinner('Generating Response...'):
 
304
 
305
  return response
306
 
307
+ def suggestion_button(user_prompt, suggestion_text, teapot_ai):
308
  if st.button(suggestion_text):
309
+ handle_chat(user_prompt, user_input, teapot_ai)
310
 
311
 
312
  def main():
 
329
 
330
  s1, s2, s3 = st.columns([1, 2, 3])
331
  with s1:
332
+ suggestion_button(user_prompt, "Tell me about teapotllm", teapot_ai)
333
  with s2:
334
+ suggestion_button(user_prompt, "Who invented quantum mechanics?", teapot_ai)
335
  with s3:
336
+ suggestion_button(user_prompt, "Extract the year Google was founded", teapot_ai)
337
 
338
  if user_input:
339
  with st.spinner('Generating Response...'):