Bargerya commited on
Commit
f4fafda
1 Parent(s): b49206c

beta V0.92

Browse files
Files changed (2) hide show
  1. app.py +3 -3
  2. savedata.db +0 -0
app.py CHANGED
@@ -286,7 +286,7 @@ def get_advice(API_KEY, model="gpt-3.5-turbo-16k"):
286
  openai.api_key = API_KEY
287
  else:
288
  openai.api_key = DESKTOP_KEY
289
- print(openai.api_key)
290
 
291
  if openai.api_key == False:
292
  output = '你需要有 OPENAI 的 API 金鑰,我才能提供您建議。(我們程式不會儲存你的金鑰)有了建議後再請你評分,謝謝。\
@@ -307,7 +307,7 @@ def get_advice(API_KEY, model="gpt-3.5-turbo-16k"):
307
  msum = ''
308
  gw_main_star = ''
309
  print(star_name)
310
- for i in range(0, 13):
311
  if myData[i]['命宮星象'] == star_name:
312
  msum = msum + myData[i]['整體描述']
313
  print(msum)
@@ -366,7 +366,7 @@ def get_advice(API_KEY, model="gpt-3.5-turbo-16k"):
366
  messages=messages,
367
  temperature=0.1, # this is the degree of randomness of the model's output
368
  )
369
- returndata = '紫微斗數全書上面說:\n\n' + msum + '\n\n我給您的建議是:\n\n' + response.choices[0].message.content
370
  if API_KEY:
371
  ming_feedback.info = 'YES'
372
  ming_feedback.value = ming_star.value + '\n\n' + returndata
 
286
  openai.api_key = API_KEY
287
  else:
288
  openai.api_key = DESKTOP_KEY
289
+ # print(openai.api_key)
290
 
291
  if openai.api_key == False:
292
  output = '你需要有 OPENAI 的 API 金鑰,我才能提供您建議。(我們程式不會儲存你的金鑰)有了建議後再請你評分,謝謝。\
 
307
  msum = ''
308
  gw_main_star = ''
309
  print(star_name)
310
+ for i in range(0, 14):
311
  if myData[i]['命宮星象'] == star_name:
312
  msum = msum + myData[i]['整體描述']
313
  print(msum)
 
366
  messages=messages,
367
  temperature=0.1, # this is the degree of randomness of the model's output
368
  )
369
+ returndata = '紫微斗數全書上面說:\n\n' + msum + '\n\n' + response.choices[0].message.content
370
  if API_KEY:
371
  ming_feedback.info = 'YES'
372
  ming_feedback.value = ming_star.value + '\n\n' + returndata
savedata.db CHANGED
Binary files a/savedata.db and b/savedata.db differ