feat: remove file word calc and support url link

This commit is contained in:
zhayujie
2023-09-24 14:33:39 +08:00
parent bd1c6361d3
commit 5b5dbcd78b
4 changed files with 11 additions and 14 deletions

View File

@@ -61,7 +61,8 @@ class LinkAI(Plugin):
_set_reply_text(res.get("summary") + "\n\n💬 发送 \"开启对话\" 可以开启与文件内容的对话", e_context, level=ReplyType.TEXT)
return
if context.type == ContextType.SHARING and self._is_summary_open(context):
if (context.type == ContextType.SHARING and self._is_summary_open(context)) or \
(context.type == ContextType.TEXT and LinkSummary().check_url(context.content)):
if not LinkSummary().check_url(context.content):
return
_send_info(e_context, "正在为你加速生成摘要,请稍后")