feat: 使用量估算值不再与key切换挂钩,现在仅根据接口报错进行切换

This commit is contained in:
Rock Chin
2023-01-03 00:02:18 +08:00
parent 2e3befea54
commit b9250908c8
4 changed files with 60 additions and 36 deletions

View File

@@ -26,6 +26,7 @@ def reload_all(notify=True):
main.stop()
# 重载所有模块
pkg.utils.context.context['exceeded_keys'] = pkg.utils.context.get_openai_manager().key_mgr.exceeded
context = pkg.utils.context.context
walk(pkg)
importlib.reload(__import__('config'))