feat: 支持音色切换

This commit is contained in:
2025-07-01 01:27:29 +08:00
parent faa4ca20b1
commit ec6bd7db88
14 changed files with 308 additions and 57 deletions

View File

@@ -1,5 +1,6 @@
import { useWebSocketStore } from "@/services";
import { convertToPCM16 } from "@/utils";
import { useChatStore } from "./chat_store";
export const useAsrStore = defineStore("asr", () => {
// 是否正在录音
@@ -125,6 +126,7 @@ export const useAsrStore = defineStore("asr", () => {
if (router.currentRoute.value.path === "/voice") {
msg.messageId = messageId;
msg.voiceConversation = true;
msg.speaker = useChatStore().speakerInfo?.speaker_id;
}
sendMessage(JSON.stringify(msg));