kaborg15 commited on
Commit
4474c1d
1 Parent(s): e4fe88f

Added waiting spinner

Browse files
Files changed (1) hide show
  1. app.py +5 -4
app.py CHANGED
@@ -26,10 +26,11 @@ def main():
26
  # Text input
27
  user_input = st.text_area("Enter your prompt:", height=300)
28
 
29
- if st.button('Generate'):
30
- # Get the model's completion
31
- completion = get_completion(user_input)
32
- st.text_area("Model Completion:", value=completion, height=300, key="2")
 
33
 
34
  if __name__ == '__main__':
35
  main()
 
26
  # Text input
27
  user_input = st.text_area("Enter your prompt:", height=300)
28
 
29
+ with st.spinner('Generating completion...'):
30
+ if st.button('Generate'):
31
+ # Get the model's completion
32
+ completion = get_completion(user_input)
33
+ st.text_area("Model Completion:", value=completion, height=300, key="2")
34
 
35
  if __name__ == '__main__':
36
  main()