CobaltZvc commited on
Commit
5cf5dd1
1 Parent(s): e172198

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -8
app.py CHANGED
@@ -110,7 +110,7 @@ def search_internet(question):
110
  # snippets
111
 
112
  response = openai.Completion.create(
113
- model="gpt-3.5-turbo",
114
  prompt=f'''following are snippets from google search with these as knowledge base only answer questions and print reference link as well followed by answer. \n\n {snippets}\n\n question-{question}\n\nAnswer-''',
115
  temperature=0.49,
116
  max_tokens=256,
@@ -157,7 +157,7 @@ def search_internet(question):
157
  # snippets
158
 
159
  response = openai.Completion.create(
160
- model="gpt-3.5-turbo",
161
  prompt=f'''following are snippets from google search with these as knowledge base only answer questions and print reference link as well followed by answer. \n\n {snippets}\n\n question-{question}\n\nAnswer-''',
162
  temperature=0.49,
163
  max_tokens=256,
@@ -203,7 +203,7 @@ def search_internet(question):
203
  # snippets
204
 
205
  response = openai.Completion.create(
206
- model="gpt-3.5-turbo",
207
  prompt=f'''following are snippets from google search with these as knowledge base only answer questions and print reference link as well followed by answer. \n\n {snippets}\n\n question-{question}\n\nAnswer-''',
208
  temperature=0.49,
209
  max_tokens=256,
@@ -394,7 +394,7 @@ if Usage == 'Questions based on custom CSV data':
394
  else:
395
  st.success("Plotting...")
396
  response_graph = openai.Completion.create(
397
- engine="gpt-3.5-turbo",
398
  prompt = gr_prompt,
399
  max_tokens=1024,
400
  n=1,
@@ -462,7 +462,7 @@ if Usage == 'Questions based on custom CSV data':
462
  else:
463
  st.success("Plotting...")
464
  response_graph = openai.Completion.create(
465
- engine="gpt-3.5-turbo",
466
  prompt = gr_prompt,
467
  max_tokens=1024,
468
  n=1,
@@ -502,7 +502,7 @@ elif Usage == 'Random Questions':
502
  if st.button("SUBMIT"):
503
  question=mytext
504
  response = openai.Completion.create(
505
- model="gpt-3.5-turbo",
506
  prompt=f'''Your name is HyperBot and knowledge cutoff date is 2021-09, and you are not aware of any events after that time. if the
507
  Answer to following questions is not from your knowledge base or in case of queries like weather
508
  updates / stock updates / current news or people which requires you to have internet connection then print i don't have access to internet to answer your question,
@@ -646,7 +646,7 @@ elif Usage == 'Random Questions':
646
  if "GET_TEXT" in result:
647
  question = result.get("GET_TEXT")
648
  response = openai.Completion.create(
649
- model="gpt-3.5-turbo",
650
  prompt=f'''Your knowledge cutoff is 2021-09, and it is not aware of any events after that time. if the
651
  Answer to following questions is not from your knowledge base or in case of queries like weather
652
  updates / stock updates / current news Etc which requires you to have internet connection then print i don't have access to internet to answer your question,
@@ -720,7 +720,7 @@ elif Usage == 'Random Questions':
720
 
721
  # question = result
722
  # response = openai.Completion.create(
723
- # model="gpt-3.5-turbo",
724
  # prompt=f'''Your knowledge cutoff is 2021-09, and it is not aware of any events after that time. if the
725
  # Answer to following questions is not from your knowledge base or in case of queries like weather
726
  # updates / stock updates / current news Etc which requires you to have internet connection then print i don't have access to internet to answer your question,
 
110
  # snippets
111
 
112
  response = openai.Completion.create(
113
+ model="text-davinci-003",
114
  prompt=f'''following are snippets from google search with these as knowledge base only answer questions and print reference link as well followed by answer. \n\n {snippets}\n\n question-{question}\n\nAnswer-''',
115
  temperature=0.49,
116
  max_tokens=256,
 
157
  # snippets
158
 
159
  response = openai.Completion.create(
160
+ model="text-davinci-003",
161
  prompt=f'''following are snippets from google search with these as knowledge base only answer questions and print reference link as well followed by answer. \n\n {snippets}\n\n question-{question}\n\nAnswer-''',
162
  temperature=0.49,
163
  max_tokens=256,
 
203
  # snippets
204
 
205
  response = openai.Completion.create(
206
+ model="text-davinci-002",
207
  prompt=f'''following are snippets from google search with these as knowledge base only answer questions and print reference link as well followed by answer. \n\n {snippets}\n\n question-{question}\n\nAnswer-''',
208
  temperature=0.49,
209
  max_tokens=256,
 
394
  else:
395
  st.success("Plotting...")
396
  response_graph = openai.Completion.create(
397
+ engine="text-davinci-003",
398
  prompt = gr_prompt,
399
  max_tokens=1024,
400
  n=1,
 
462
  else:
463
  st.success("Plotting...")
464
  response_graph = openai.Completion.create(
465
+ engine="text-davinci-003",
466
  prompt = gr_prompt,
467
  max_tokens=1024,
468
  n=1,
 
502
  if st.button("SUBMIT"):
503
  question=mytext
504
  response = openai.Completion.create(
505
+ model="text-davinci-003",
506
  prompt=f'''Your name is HyperBot and knowledge cutoff date is 2021-09, and you are not aware of any events after that time. if the
507
  Answer to following questions is not from your knowledge base or in case of queries like weather
508
  updates / stock updates / current news or people which requires you to have internet connection then print i don't have access to internet to answer your question,
 
646
  if "GET_TEXT" in result:
647
  question = result.get("GET_TEXT")
648
  response = openai.Completion.create(
649
+ model="text-davinci-003",
650
  prompt=f'''Your knowledge cutoff is 2021-09, and it is not aware of any events after that time. if the
651
  Answer to following questions is not from your knowledge base or in case of queries like weather
652
  updates / stock updates / current news Etc which requires you to have internet connection then print i don't have access to internet to answer your question,
 
720
 
721
  # question = result
722
  # response = openai.Completion.create(
723
+ # model="text-davinci-003",
724
  # prompt=f'''Your knowledge cutoff is 2021-09, and it is not aware of any events after that time. if the
725
  # Answer to following questions is not from your knowledge base or in case of queries like weather
726
  # updates / stock updates / current news Etc which requires you to have internet connection then print i don't have access to internet to answer your question,