SXP-Simon
|
022dd77ea9
|
fix(thread-safety): 已为
templates.py
中的 Jinja2 环境缓存添加线程安全保护,具体改动如下:
使用双重检查锁定(Double-Checked Locking)保护缓存访问
读取缓存时加锁,避免多线程同时读取时的数据竞争
创建新环境后再次加锁检查,防止高并发下重复创建相同模板的环境
原代码中 _envs 字典会通过 asyncio.to_thread(self._get_env_sync) 被多个线程同时访问和修改,存在数据竞争风险。现在通过 threading.Lock 确保了线程安全。
|
2026-01-07 00:35:40 +08:00 |
|
SXP-Simon
|
3840e84b93
|
Merge branch 'main' of github.com:SXP-Simon/astrbot-qq-group-daily-analysis
|
2026-01-07 00:30:14 +08:00 |
|
SXP-Simon
|
2af39fa3b5
|
fix(debug): 删除一些不必要的 debug 调试
|
2026-01-07 00:28:35 +08:00 |
|
SXP-Simon
|
3ca7f71376
|
fix(typo): 调整文档
|
2026-01-07 00:28:35 +08:00 |
|
SXP-Simon
|
9a09e56f13
|
fix: 性能优化,CPU 密集型计算(统计和分析)已卸载到各线程池,避免阻塞事件循环
feat: 存储路径规范化:PDF 报告现在存储在 data/plugin_data/astrbot_plugin_qq_group_daily_analysis/reports
|
2026-01-07 00:28:35 +08:00 |
|
SXP-Simon
|
4297bf4f99
|
refactor: 全局变量重构,受保护成员访问修复,同步 I/O 操作异步化
|
2026-01-07 00:28:35 +08:00 |
|
SXP-Simon
|
5b72997a28
|
refactor: 全局变量重构,受保护成员访问修复,同步 I/O 操作异步化
|
2026-01-06 23:07:03 +08:00 |
|
SXP-Simon
|
64ae5e1a6d
|
[v4.5.4] 更新插件 metadata 描述,为了使用户更容易搜索到此插件,重新在插件市场提交
|
2026-01-06 22:20:55 +08:00 |
|
SXP-Simon
|
c562cd49ca
|
fix(typo): metadata
|
2026-01-06 22:14:02 +08:00 |
|
Helian Nuits
|
d1a3de9e21
|
[v4.5.3] 更新版本号,处理 rebase 合并 PR 导致自动 release 发版 workflow 失效的问题
|
2026-01-03 01:34:09 +08:00 |
|
Helian Nuits
|
f458bcfefa
|
[v4.5.2] 添加查看模板指令,合并转发模板图片供用户查看,优化选择模板命令 (@clown145)
|
2026-01-03 01:30:52 +08:00 |
|
clown145
|
5f8309f461
|
跑pre-commit
|
2026-01-03 01:24:51 +08:00 |
|
clown145
|
a52a9afa4f
|
feat: 回退对群分析指令的更改
|
2026-01-03 01:24:51 +08:00 |
|
clown145
|
92142b4b9f
|
feat: 优化查看模板的显示
|
2026-01-03 01:24:51 +08:00 |
|
clown145
|
094dbfe2ad
|
feat: 优化查看模板信息显示
|
2026-01-03 01:24:51 +08:00 |
|
clown145
|
9fef747b46
|
feat: 添加查看模板指令
|
2026-01-03 01:24:51 +08:00 |
|
SXP-Simon
|
099421931e
|
fix(typo): 增加 readme 新模板 retro_futurism 演示
|
2025-12-31 14:50:21 +08:00 |
|
SXP-Simon
|
d339f1b7c0
|
[v4.5.0] 添加新的模板主题 retro_futurism, 灵感来源明日方舟 孤星 未来复古主义主题;添加模板调试工具 scripts/debug_render.py,方便用户在不启动 AstrBot 的情况下调试模板效果 (@Saramanda9988)
|
2025-12-31 14:44:23 +08:00 |
|
Saramanda9988
|
7583a906bb
|
fix: fix pre-commit
|
2025-12-31 14:29:27 +08:00 |
|
Saramanda9988
|
569f1a0aab
|
feat: add debug render tool for report templates with mock data
|
2025-12-31 14:29:27 +08:00 |
|
Saramanda9988
|
1b2182cfc5
|
feat: add debug render tool for report templates with mock data
|
2025-12-31 14:29:27 +08:00 |
|
Saramanda9988
|
8ddfa7e713
|
feat: Update report templates and improved layout
|
2025-12-31 13:56:35 +08:00 |
|
Saramanda9988
|
fa89e4b8ed
|
feat: Improve styling and lenhanced font properties
|
2025-12-31 13:56:35 +08:00 |
|
Saramanda9988
|
777469c2e6
|
feat: Update Retro Futurism templates with enhanced styling and layout adjustments
|
2025-12-31 13:56:35 +08:00 |
|
Saramanda9988
|
0d704e8ed6
|
feat: Enhance Retro Futurism templates with new header icons and layout adjustments
|
2025-12-31 13:56:35 +08:00 |
|
Saramanda9988
|
59b82a29c9
|
feat: Add Retro Futurism report templates and components
|
2025-12-31 13:56:35 +08:00 |
|
SXP-Simon
|
4ca8180933
|
[v4.4.0] 修复可能的图片生成成功但是发送失败的情况,增加 Fallback 的 BASE64 编码的图片发送方式 @Heximiao
|
2025-12-20 21:10:56 +08:00 |
|
SXP-Simon
|
c216ccb009
|
fix(auto_scheduler): 设置请求超时和响应大小限制,避免卡死或下载过大,增加过程的健壮性
|
2025-12-20 21:01:55 +08:00 |
|
liuchunyu44
|
926ec65b59
|
修改发送图片的逻辑
|
2025-12-20 20:42:10 +08:00 |
|
SXP-Simon
|
8f107f6c05
|
[v4.3.0] 纠正关闭特定分析区但是基础样式没有去除的 bug
|
2025-11-29 00:19:02 +08:00 |
|
SXP-Simon
|
23ca2f9ade
|
fix(simple): 提取排版,纠正关闭分析分区但是基础样式没有去除的 bug
|
2025-11-29 00:07:14 +08:00 |
|
SXP-Simon
|
122a2fa36a
|
fix(scrapbook): 提取排版,纠正关闭分析分区但是基础样式没有去除的 bug
|
2025-11-29 00:04:53 +08:00 |
|
SXP-Simon
|
3d6378792e
|
fix(format): 提取排版,纠正关闭分析分区但是基础样式没有去除的 bug
|
2025-11-29 00:04:36 +08:00 |
|
SXP-Simon
|
964f8478ea
|
[v4.2.7] 模板文档更新
|
2025-11-26 13:07:49 +08:00 |
|
SXP-Simon
|
0d62985e51
|
fix(template/simple): 纠正 simple 符合规范
|
2025-11-26 12:48:16 +08:00 |
|
SXP-Simon
|
a81640c289
|
[v4.2.6] fix(延迟启动调度器失败): 'xxxPlatformAdapter' object has no attribute 'metadata'
|
2025-11-26 00:42:40 +08:00 |
|
SXP-Simon
|
1a08d6cb59
|
fix(延迟启动调度器失败): PlatformAdapter' object has no attribute 'metadata'
|
2025-11-26 00:35:04 +08:00 |
|
SXP-Simon
|
bb124a96f6
|
[v4.2.5] 正确获取 platform_id
|
2025-11-25 23:42:41 +08:00 |
|
Helian Nuits
|
03c35f49d0
|
Fix(bot manager): _get_platform_id_for_group 是一个异步方法(async def),但在 main.py 中调用时忘记加 await (#54)
* fix(bot-manager): 正确处理实例获取
* fix(import); AiocqhttpAdapter 导入
* fix: 通过 meta 实现 aiocqhttp 判断
* fix(_get_platform_id_for_group): _get_platform_id_for_group 是一个异步方法(async def),但在 main.py 中调用时忘记加 await 了,导致它返回了一个协程对象而不是字符串 ID
* fix(pre-commit)
|
2025-11-25 23:37:13 +08:00 |
|
SXP-Simon
|
5a0731e492
|
fix(bot_manager): get_bot_instance
|
2025-11-25 21:59:41 +08:00 |
|
SXP-Simon
|
3d60a14445
|
[v4.2.0] (!!!要求:AstrBot v4.5.7+!!!) 适配 AstrBot v4.5.7+ 的新 LLM API 标准,支持多套主题模板切换使用,欢迎为插件贡献新的报告模板
|
2025-11-25 21:12:30 +08:00 |
|
SXP-Simon
|
6ca52e24ee
|
fix(auto-release): 迁移到 main
|
2025-11-25 20:59:39 +08:00 |
|
SXP-Simon
|
41f49ee6b3
|
fix(cr): pre-commit
|
2025-11-25 20:55:33 +08:00 |
|
SXP-Simon
|
d942a5a2eb
|
docs(templates-customization): 欢迎为插件贡献新的报告模板!!!
|
2025-11-25 20:55:33 +08:00 |
|
SXP-Simon
|
89d79a5491
|
fix(old): 调整 old 样式
|
2025-11-25 20:55:33 +08:00 |
|
SXP-Simon
|
de31c0514f
|
refactor(chart): 拆分 chart 部分到 template
|
2025-11-25 20:55:33 +08:00 |
|
SXP-Simon
|
aba98cbd05
|
feat(old): 恢复 old 版本 HTML template
|
2025-11-25 20:55:33 +08:00 |
|
SXP-Simon
|
150f6c37a9
|
feat(mutli-templates): 适配多套排版选择
|
2025-11-25 20:55:33 +08:00 |
|
SXP-Simon
|
e385c294a1
|
feat(llm_utils): 更新了
src/analysis/utils/llm_utils.py
文件,以适配 AstrBot v4.5.7+ 的新 API 标准。
主要更改如下:
重构了 Provider 选择逻辑:
将 get_provider_with_fallback 重命名并修改为
get_provider_id_with_fallback
。
现在它返回的是 Provider ID (字符串),而不是 Provider 对象实例。这是因为新的 llm_generate 接口需要通过 ID 来指定使用的模型。
使用了新的 await context.get_current_chat_provider_id(umo=umo) 方法来获取当前会话的模型 ID。
更新了 LLM 调用方式:
在
call_provider_with_retry
函数中,不再直接调用 provider.text_chat(...)。
改为使用统一的 await context.llm_generate(...) 接口。这是 AstrBot 推荐的新方式,更加简洁且统一。
兼容性调整:
更新了
extract_token_usage
函数,使其能够从 llm_generate 返回的新响应格式中正确提取 Token 使用统计(优先检查
usage
属性)。
这些更改确保了插件能够利用 AstrBot 新版本的特性,同时保持了原有的多级回退(配置 -> 主模型 -> 会话模型 -> 任意可用)逻辑不变。
|
2025-11-25 20:55:33 +08:00 |
|
SXP-Simon
|
c211ea7050
|
chore(copilot_instructions.md): 插件开发文档写入 copilot instructions, 更新 README.
|
2025-11-25 20:55:33 +08:00 |
|