feat(voice): 百炼声音复刻create_voice + TTS instruction情绪驱动(主TTS-昔涟复刻音色)
CI / Backend (build / vet / test / cross-compile) (push) Has been cancelled
CI / Frontend (tsc + vite build) (push) Has been cancelled

This commit is contained in:
Aska committed 2026-09-08 06:48:15 +08:00
1 parent 73dabb9dde
commit 03d7050e1e
15 files changed
+686 -30

No files matched your search

+6 -1
View File
@@ -19,8 +19,13 @@ import (
type VoiceService interface {
// STT transcribes audio to text.
STT(ctx context.Context, audio voice.Audio) (string, error)
// TTS synthesizes audio from text.
// TTS synthesizes audio from text. A per-request emotion/tone instruction may
// be threaded through ctx (voice.WithTTSInstruction) to override the configured
// VOICE_TTS_INSTRUCTION for one call.
TTS(ctx context.Context, text string) (voice.Audio, error)
// CloneVoice creates a custom voice (声音复刻 create_voice) from a public
// reference audio URL and returns its voice_id.
CloneVoice(ctx context.Context, referenceURL, prefix string) (string, error)
}
// voiceInputRequest is the decoded payload of a voice_input frame. Audio is a