新增飞书应用通道

- 支持自建机器人的私聊和群聊
 - 支持图片生成
 - 支持文件总结
This commit is contained in:
Saboteur7
2023-11-21 22:41:54 +08:00
parent 061d8a3a5f
commit 86a58c3d80
8 changed files with 371 additions and 6 deletions

View File

@@ -238,7 +238,8 @@ class ChatChannel(Channel):
reply = super().build_text_to_voice(reply.content)
return self._decorate_reply(context, reply)
if context.get("isgroup", False):
reply_text = "@" + context["msg"].actual_user_nickname + "\n" + reply_text.strip()
if not context.get("no_need_at", False):
reply_text = "@" + context["msg"].actual_user_nickname + "\n" + reply_text.strip()
reply_text = conf().get("group_chat_reply_prefix", "") + reply_text + conf().get("group_chat_reply_suffix", "")
else:
reply_text = conf().get("single_chat_reply_prefix", "") + reply_text + conf().get("single_chat_reply_suffix", "")