awacke1 commited on
Commit
d920797
โ€ข
1 Parent(s): 902a8b5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +22 -22
app.py CHANGED
@@ -424,38 +424,38 @@ def FileSidebar():
424
  if len(file_contents) > 0:
425
  if next_action=='open':
426
  file_content_area = st.text_area("File Contents:", file_contents, height=500)
427
- try:
428
- if st.button("๐Ÿ”", key="filecontentssearch"):
429
- #search_glossary(file_content_area)
430
- filesearch = PromptPrefix + file_content_area
431
- st.markdown(filesearch)
432
- if st.button(key=rerun, label='๐Ÿ”Re-Spec' ):
433
- search_glossary(filesearch)
434
- except:
435
- st.markdown('GPT is sleeping. Restart ETA 30 seconds.')
436
 
437
  if next_action=='md':
438
  st.markdown(file_contents)
439
  buttonlabel = '๐Ÿ”Run'
440
  if st.button(key='Runmd', label = buttonlabel):
441
  user_prompt = file_contents
442
- try:
443
- search_glossary(file_contents)
444
- except:
445
- st.markdown('GPT is sleeping. Restart ETA 30 seconds.')
446
 
447
  if next_action=='search':
448
  file_content_area = st.text_area("File Contents:", file_contents, height=500)
449
  user_prompt = file_contents
450
- try:
451
- #search_glossary(file_contents)
452
- filesearch = PromptPrefix2 + file_content_area
453
- st.markdown(filesearch)
454
- if st.button(key=rerun, label='๐Ÿ”Re-Code' ):
455
- search_glossary(filesearch)
456
-
457
- except:
458
- st.markdown('GPT is sleeping. Restart ETA 30 seconds.')
459
  # ----------------------------------------------------- File Sidebar for Jump Gates ------------------------------------------
460
  FileSidebar()
461
 
 
424
  if len(file_contents) > 0:
425
  if next_action=='open':
426
  file_content_area = st.text_area("File Contents:", file_contents, height=500)
427
+ #try:
428
+ if st.button("๐Ÿ”", key="filecontentssearch"):
429
+ #search_glossary(file_content_area)
430
+ filesearch = PromptPrefix + file_content_area
431
+ st.markdown(filesearch)
432
+ if st.button(key=rerun, label='๐Ÿ”Re-Spec' ):
433
+ search_glossary(filesearch)
434
+ #except:
435
+ st.markdown('GPT is sleeping. Restart ETA 30 seconds.')
436
 
437
  if next_action=='md':
438
  st.markdown(file_contents)
439
  buttonlabel = '๐Ÿ”Run'
440
  if st.button(key='Runmd', label = buttonlabel):
441
  user_prompt = file_contents
442
+ #try:
443
+ search_glossary(file_contents)
444
+ #except:
445
+ st.markdown('GPT is sleeping. Restart ETA 30 seconds.')
446
 
447
  if next_action=='search':
448
  file_content_area = st.text_area("File Contents:", file_contents, height=500)
449
  user_prompt = file_contents
450
+ #try:
451
+ #search_glossary(file_contents)
452
+ filesearch = PromptPrefix2 + file_content_area
453
+ st.markdown(filesearch)
454
+ if st.button(key=rerun, label='๐Ÿ”Re-Code' ):
455
+ search_glossary(filesearch)
456
+
457
+ #except:
458
+ st.markdown('GPT is sleeping. Restart ETA 30 seconds.')
459
  # ----------------------------------------------------- File Sidebar for Jump Gates ------------------------------------------
460
  FileSidebar()
461