mirror of
https://github.com/HKUDS/nanobot.git
synced 2026-04-02 17:32:39 +00:00
feat: support retrieving DingTalk voice recognition text
This commit is contained in:
parent
947ed508ad
commit
35d811c997
@ -57,6 +57,8 @@ class NanobotDingTalkHandler(CallbackHandler):
|
||||
content = ""
|
||||
if chatbot_msg.text:
|
||||
content = chatbot_msg.text.content.strip()
|
||||
elif chatbot_msg.extensions.get("content", {}).get("recognition"):
|
||||
content = chatbot_msg.extensions["content"]["recognition"].strip()
|
||||
if not content:
|
||||
content = message.data.get("text", {}).get("content", "").strip()
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user