3v324v23 commited on
Commit
4812513
1 Parent(s): 4bd8475

增添报错信息

Browse files
Files changed (1) hide show
  1. request_llm/bridge_chatgpt.py +2 -0
request_llm/bridge_chatgpt.py CHANGED
@@ -208,6 +208,8 @@ def predict(inputs, llm_kwargs, plugin_kwargs, chatbot, history=[], system_promp
208
  chatbot[-1] = (chatbot[-1][0], "[Local Message] You exceeded your current quota. OpenAI以账户额度不足为由,拒绝服务.")
209
  elif "bad forward key" in error_msg:
210
  chatbot[-1] = (chatbot[-1][0], "[Local Message] Bad forward key. API2D账户额度不足.")
 
 
211
  else:
212
  from toolbox import regular_txt_to_markdown
213
  tb_str = '```\n' + traceback.format_exc() + '```'
 
208
  chatbot[-1] = (chatbot[-1][0], "[Local Message] You exceeded your current quota. OpenAI以账户额度不足为由,拒绝服务.")
209
  elif "bad forward key" in error_msg:
210
  chatbot[-1] = (chatbot[-1][0], "[Local Message] Bad forward key. API2D账户额度不足.")
211
+ elif "Not enough point" in error_msg:
212
+ chatbot[-1] = (chatbot[-1][0], "[Local Message] Not enough point. API2D账户点数不足.")
213
  else:
214
  from toolbox import regular_txt_to_markdown
215
  tb_str = '```\n' + traceback.format_exc() + '```'