Cartof commited on
Commit
3831c37
1 Parent(s): 7cb4efc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -35,11 +35,11 @@ def get_response(system, context, raw = False):
35
  statistics = f'This conversation Tokens usage【{response["usage"]["total_tokens"]} / 4096】 ( Question + above {response["usage"]["prompt_tokens"]},Answer {response["usage"]["completion_tokens"]} )'
36
  message = response["choices"][0]["message"]["content"]
37
 
38
- message_with_stats = f'{message}\n\n================\n\n{statistics}'
39
  # message_with_stats = markdown.markdown(message_with_stats)
40
 
41
- #return message, parse_text(message_with_stats)
42
- return message
43
 
44
  def predict(chatbot, input_sentence, system, context):
45
  if len(input_sentence) == 0:
 
35
  statistics = f'This conversation Tokens usage【{response["usage"]["total_tokens"]} / 4096】 ( Question + above {response["usage"]["prompt_tokens"]},Answer {response["usage"]["completion_tokens"]} )'
36
  message = response["choices"][0]["message"]["content"]
37
 
38
+ message_with_stats = f'{message}\n\n================\n\n'
39
  # message_with_stats = markdown.markdown(message_with_stats)
40
 
41
+ return message, parse_text(message_with_stats)
42
+ #return message
43
 
44
  def predict(chatbot, input_sentence, system, context):
45
  if len(input_sentence) == 0: