feat(im): add AI card streaming for DingTalk and improve IM platform robustness

- Add DingTalk AI Card streaming support with create/deliver/update via OpenAPI
- Extract shared think-block rendering into reusable im.TransformThinkBlocks
- Add stream orphan reaper and edit throttling for DingTalk and Telegram
- Apply think-block transform on all reply paths (DingTalk, Telegram, Feishu)
- Add Card Template ID config to frontend IM channel panel with i18n
This commit is contained in:
nullkey
2026-03-24 20:12:40 +08:00
committed by lyingbug
parent a1a384ec67
commit 1bf6603271
11 changed files with 414 additions and 136 deletions
+1 -1
View File
@@ -63,7 +63,7 @@ func (c *LongConnClient) Start(ctx context.Context) error {
func (c *LongConnClient) onChatBotMessage(ctx context.Context, data *chatbot.BotCallbackDataModel) ([]byte, error) {
chatType := im.ChatTypeDirect
chatID := ""
if data.ConversationType == "2" {
if data.ConversationType == dingtalkConvTypeGroup {
chatType = im.ChatTypeGroup
chatID = data.ConversationId
}