awacke1 commited on
Commit
f0cfb69
1 Parent(s): d691b74

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -7
app.py CHANGED
@@ -771,23 +771,27 @@ def main():
771
  file_content_area = st.text_area("File Contents:", file_contents, height=500)
772
  if next_action=='md':
773
  st.markdown(file_contents)
 
774
  if next_action=='search':
775
  file_content_area = st.text_area("File Contents:", file_contents, height=500)
776
  st.write('Reasoning with your inputs...')
777
 
778
- # new - llama
 
 
 
779
  response = StreamLLMChatResponse(file_contents)
780
  filename = generate_filename(user_prompt, ".md")
781
  create_file(filename, file_contents, response, should_save)
782
  SpeechSynthesis(response)
783
 
784
- # old - gpt
785
- #response = chat_with_model(user_prompt, file_contents, model_choice)
786
- #filename = generate_filename(file_contents, choice)
787
- #create_file(filename, user_prompt, response, should_save)
 
788
 
789
- st.experimental_rerun()
790
-
791
 
792
  # Function to encode file to base64
793
  def get_base64_encoded_file(file_path):
 
771
  file_content_area = st.text_area("File Contents:", file_contents, height=500)
772
  if next_action=='md':
773
  st.markdown(file_contents)
774
+
775
  if next_action=='search':
776
  file_content_area = st.text_area("File Contents:", file_contents, height=500)
777
  st.write('Reasoning with your inputs...')
778
 
779
+ user_prompt = file_contents
780
+
781
+ # Llama versus GPT Battle!
782
+ # llama
783
  response = StreamLLMChatResponse(file_contents)
784
  filename = generate_filename(user_prompt, ".md")
785
  create_file(filename, file_contents, response, should_save)
786
  SpeechSynthesis(response)
787
 
788
+ # gpt
789
+ response2 = chat_with_model(user_prompt, file_contents, model_choice)
790
+ filename2 = generate_filename(file_contents, choice)
791
+ create_file(filename2, user_prompt, response, should_save)
792
+ SpeechSynthesis(response)
793
 
794
+ #st.experimental_rerun()
 
795
 
796
  # Function to encode file to base64
797
  def get_base64_encoded_file(file_path):