feat(channels): IM 车道生成并写入真实 turn_id(user/assistant 成对 + 同源 WithTurnID;群聊隔离与静默语义不变)
This commit is contained in:
1 parent
ba1974038a
commit
8f6a75b7d7
9 files changed
+215
-21
No files matched your search
@@ -238,7 +238,9 @@ func (b *Bridge) mentionsTriggerWord(text string) bool {
|
||||
func (b *Bridge) registerSilenced(ctx context.Context, msg adapter.UnifiedMessage, actor adapter.Actor, sess session.Session, a adapter.PlatformAdapter) {
|
||||
// 被静默的消息不摄取附件(摄取在闸门之后),因此这两列恒为空 ——
|
||||
// 绝不写一条指向不存在文件的引用,也绝不写一张没进过上下文的图片。
|
||||
b.persistIsolated(ctx, history.RoleUser, msg.Content, "", "", deviceIDFor(msg), sess, msg.Platform, senderDisplayName(msg, actor), adapterName(a))
|
||||
// turn_id 同样传 "":这条消息**根本不会被回答**,不存在「它属于哪一路回合」,
|
||||
// 给它编一个标识就是把不属于任何回合的行说成有回合(见 turnid.go 的口径)。
|
||||
b.persistIsolated(ctx, history.RoleUser, msg.Content, "", "", deviceIDFor(msg), sess, msg.Platform, senderDisplayName(msg, actor), adapterName(a), "")
|
||||
b.log.Debug("non-owner message silenced, registered only",
|
||||
"platform", msg.Platform, "channel", msg.ChannelID, "session", sess.SessionID)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user