docs: README 补充手动软踢 manual_evict 用法
This commit is contained in:
@@ -228,6 +228,35 @@ python volc_limit_sync.py
|
|||||||
DAILY_LIMIT_LOG_LEVEL=DEBUG python volc_limit_sync.py
|
DAILY_LIMIT_LOG_LEVEL=DEBUG python volc_limit_sync.py
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### 手动软踢某个模型(运维应急,立即 429)
|
||||||
|
|
||||||
|
模型踩采集上限/异常时,无需等脚本同步阈值,直接往 Redis 写一个 `manual_evict` key 即可将该模型**立即、持续地**软踢(恒 429,直到显式解除)。
|
||||||
|
|
||||||
|
key 格式:`manual_evict:<config.yaml 中该条目的完整 model 字段>`(**含渠道前缀,全匹配**,如 `volcengine/deepseek-v4-flash-ga-260731`;同一 clean 名但不同渠道的模型不会被误伤)。
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 软踢:立即对该模型返回 429(key 落 Redis 持久卷,重启 litellm 后仍生效)
|
||||||
|
docker exec litellm_redis redis-cli SET manual_evict:volcengine/<model> 1
|
||||||
|
|
||||||
|
# 解除软踢
|
||||||
|
docker exec litellm_redis redis-cli DEL manual_evict:volcengine/<model>
|
||||||
|
|
||||||
|
# 查看当前手动软踢的模型
|
||||||
|
docker exec litellm_redis redis-cli KEYS manual_evict:*
|
||||||
|
```
|
||||||
|
|
||||||
|
示例(软踢 deepseek-v4-flash-ga-260731):
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker exec litellm_redis redis-cli SET manual_evict:volcengine/deepseek-v4-flash-ga-260731 1
|
||||||
|
```
|
||||||
|
|
||||||
|
注意:
|
||||||
|
|
||||||
|
- 软踢只作用于**纳入监控**的火山模型(`MONITORED_MODEL_PAIRS` 内);非监控渠道不受影响。
|
||||||
|
- 幂等:key 在期间每个请求都 429,重复 SET 无副作用。
|
||||||
|
- 解除后立即恢复按正常限额判定。
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
## 文件职责
|
## 文件职责
|
||||||
|
|||||||
Reference in New Issue
Block a user