subhankarfynd commited on
Commit
36cb77d
Β·
1 Parent(s): 6a9b638

Update pages/3_πŸ“ˆ_Question_And_Answering.py

Browse files
pages/3_πŸ“ˆ_Question_And_Answering.py CHANGED
@@ -23,8 +23,9 @@ title = st.text_input('Enter your question', '')
23
 
24
  if title:
25
  response_status_code, response = make_request(title)
26
- if response_status_code == 200:
27
- st.subheader('Generated answer')
28
- st.text_area(label=' ', value=str(response.get('text')), height=350)
29
- else:
30
- st.write(f"Unable to find any results. Response Error Code: {response_status_code}")
 
 
23
 
24
  if title:
25
  response_status_code, response = make_request(title)
26
+ with st.spinner('Wait for it...'):
27
+ if response_status_code == 200:
28
+ st.subheader('Generated answer')
29
+ st.text_area(label=' ', value=str(response.get('text')), height=350)
30
+ else:
31
+ st.write(f"Unable to find any results. Response Error Code: {response_status_code}")