feat(voice): 提升桌面端语音交互与本地任务执行支持
This commit is contained in:
@@ -35,6 +35,10 @@ type ServerMsg struct {
|
||||
TaskID string `json:"task_id,omitempty"`
|
||||
// error:出错文案
|
||||
Msg string `json:"msg,omitempty"`
|
||||
// action:JARVIS 让客户端执行的界面动作(P2 动作通道,见 JARVIS_BRAIN_DESIGN.md §2.2)。
|
||||
// 目前仅 navigate:Action="navigate" + View(+可选 TaskID 聚焦某任务)。客户端按白名单执行。
|
||||
Action string `json:"action,omitempty"`
|
||||
View string `json:"view,omitempty"`
|
||||
}
|
||||
|
||||
// 服务端消息类型。
|
||||
@@ -46,6 +50,8 @@ const (
|
||||
ServerSpeaking = "speaking" // Agent 开始出声(首段 TTS 音频将至)
|
||||
ServerTTSEnd = "tts_end" // 本轮 TTS 播放完毕
|
||||
ServerError = "error" // 出错
|
||||
ServerAction = "action" // 界面动作指令(navigate 等,客户端白名单执行)
|
||||
ServerAnnounce = "announce" // 主动播报(text 显示到对话流;随后照常走 speaking/音频/tts_end)
|
||||
)
|
||||
|
||||
// 音频格式(与火山 ASR/TTS 约定,客户端按此采集/播放)。
|
||||
|
||||
Reference in New Issue
Block a user