feat(auto_scheduler): 添加自动调度器,使用信号量(Semaphore)并发限制和弱引用字典(WeakValueDictionary)优化锁管理;群黑白名单机制。 (#50)

* feat(auto_scheduler): 添加自动调度器,使用信号量(Semaphore)并发限制和弱引用字典(WeakValueDictionary)优化锁管理。

* feat(auto_scheduler): 群黑白名单机制

* feat(自动分析最大并发数): 可配置项添加信号量自定义控制

* debug(获取群)

* fix(config)

* fix(pre-commit): cr
This commit is contained in:
Helian Nuits
2025-11-23 13:26:09 +08:00
committed by GitHub
parent 06290b8118
commit e5320969ee
4 changed files with 215 additions and 60 deletions
+16 -3
View File
@@ -1,13 +1,26 @@
{
"enabled_groups": {
"group_list_mode": {
"description": "群聊权限模式",
"type": "string",
"options": ["whitelist", "blacklist", "none"],
"default": "none",
"hint": "whitelist: 仅允许列表内群;blacklist: 拒绝列表内群;none: 不限制"
},
"group_list": {
"type": "list",
"description": "启用分析功能的QQ群列表",
"description": "群组名单列表",
"default": [],
"hint": "填入允许使用分析功能的QQ群号",
"hint": "黑白名单模式下使用的群号列表",
"items": {
"type": "string"
}
},
"max_concurrent_tasks": {
"type": "int",
"description": "自动分析最大并发数",
"default": 5,
"hint": "同时进行的群聊分析任务数量,建议根据机器性能调整,过高可能导致LLM API RPM 超出限制,卡顿或被风控"
},
"max_messages": {
"type": "int",
"description": "单次分析的获取最大消息条数基准",