fix: streamline monitored model maintenance

This commit is contained in:
kim
2026-04-01 13:29:10 +08:00
parent 63658dadd2
commit 2f1c2642e5
7 changed files with 565 additions and 259 deletions
+15 -7
View File
@@ -3,11 +3,17 @@ x-definitions: &token_pricing
input_cost_per_token: 1
output_cost_per_token: 1
model_list:
#=======================火山平台,限时免费
model_list:
# ======================= 监控模型维护入口 =======================
# 1. 这里的火山模型条目,就是“纳入监控模型”的主入口。
# 2. 常规版本号模型(如 xxx-260215)会由 volc_limit_sync.py 自动推导成监控别名 xxx。
# 3. 只有“资源包名与上游模型名不一致”或“一包多模型”时,才需要再改
# volc_limit_sync.py 里的 MANUAL_MONITORED_MODEL_ALIASES。
# 4. 改完后运行 `python generate_keys.py`,检查监控别名和 HARD_DAILY_LIMITS 的限额来源。
#=======================火山平台,限时免费
@@ -164,8 +170,10 @@ litellm_settings:
# type: "redis" # 指定使用 Redis
# supported_call_types: ["completion", "embedding", "acompletion"] # 支持的类型
allowed_fails: 3 # cooldown model if it fails > 1 call in a minute.
# 关键配置:注册自定义回调,实现单上游模型每日token限制的关键
callbacks: ["volc_limit_sync.proxy_handler_instance"]
# 当前生效入口:volc_limit_sync.py
# 监控模型发现、监控别名推导、资源包同步、HARD_DAILY_LIMITS 都在这个脚本里。
# daily_limit.py 当前未启用,仅保留作历史参考。
callbacks: ["volc_limit_sync.proxy_handler_instance"]
router_settings: # router_settings are optional
routing_strategy: simple-shuffle