aaditya commited on
Commit
6b3b5e6
·
1 Parent(s): e73e36b

Add application file

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -41,11 +41,11 @@ class Datas(Resource):
41
  # old_prompt + new_input
42
  total_consumed = 561 + return_output
43
  return {'status': '1', 'token_legth': return_output,
44
- 'character_length': len(return_output),
45
  'remaining_tokens': 4000 - total_consumed}
46
 
47
  except Exception as e:
48
- return {'status': '-1'}
49
 
50
 
51
  api.add_resource(Status, '/')
 
41
  # old_prompt + new_input
42
  total_consumed = 561 + return_output
43
  return {'status': '1', 'token_legth': return_output,
44
+ 'char_length': len(prompt_),
45
  'remaining_tokens': 4000 - total_consumed}
46
 
47
  except Exception as e:
48
+ return {'status': '-1', 'e': e}
49
 
50
 
51
  api.add_resource(Status, '/')