Skip to content

Commit

Permalink
0.6.8
Browse files Browse the repository at this point in the history
  • Loading branch information
fatwang2 committed Jan 21, 2024
1 parent 4d1795f commit 95586e2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
1 change: 1 addition & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
[telegram频道 ](https://sum4all.site/telegram)

## 更新日志
- V0.6.8,20230121,增加对不支持文件类型忽略的逻辑;更换底层搜索、内容获取服务,更快更稳定;更新配置文件里的搜索默认prompt
- V0.6.7,20230109,增加讯飞代理,简化讯飞部分代码与依赖
- V0.6.6,20230106,增加Gemini代理,解决非美国IP无法访问Gemini的问题
- V0.6.5,20231217,结构化配置文件config.json,支持更灵活的调整文件、图片、URL、搜索的配置,升级后需按照新格式配置
Expand Down
11 changes: 7 additions & 4 deletions sum4all.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
name="sum4all",
desire_priority=2,
desc="A plugin for summarizing all things",
version="0.6.7",
version="0.6.8",
author="fatwang2",
)

Expand Down Expand Up @@ -175,9 +175,12 @@ def on_handle_context(self, e_context: EventContext):
# 更新params_cache中的last_file_content
self.params_cache[user_id] = {}
file_content = self.extract_content(file_path)
self.params_cache[user_id]['last_file_content'] = file_content
logger.info('Updated last_file_content in params_cache for user.')
self.handle_file(file_content, e_context)
if file_content is None:
logger.info("文件内容无法提取,跳过处理")
else:
self.params_cache[user_id]['last_file_content'] = file_content
logger.info('Updated last_file_content in params_cache for user.')
self.handle_file(file_content, e_context)
else:
logger.info("文件总结功能已禁用,不对文件内容进行处理")
# 删除文件
Expand Down

0 comments on commit 95586e2

Please sign in to comment.