SSE 消息重构已完成

This commit is contained in:
GeekMaster
2025-05-27 15:48:07 +08:00
parent e685876cc0
commit 32fc4d86a2
15 changed files with 394 additions and 339 deletions

View File

@@ -1,14 +0,0 @@
package vo
type HistoryMessage struct {
BaseVo
ChatId string `json:"chat_id"`
UserId uint `json:"user_id"`
RoleId uint `json:"role_id"`
Model string `json:"model"`
Type string `json:"type"`
Icon string `json:"icon"`
Tokens int `json:"tokens"`
Content string `json:"content"`
UseContext bool `json:"use_context"`
}

View File

@@ -0,0 +1,19 @@
package vo
type MsgContent struct {
Text string `json:"text"`
Files []File `json:"files"`
}
type ChatMessage struct {
BaseVo
ChatId string `json:"chat_id"`
UserId uint `json:"user_id"`
RoleId uint `json:"role_id"`
Model string `json:"model"`
Type string `json:"type"`
Icon string `json:"icon"`
Tokens int `json:"tokens"`
Content MsgContent `json:"content"`
UseContext bool `json:"use_context"`
}