Compare commits
3
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
78bb7d87ab | ||
|
|
d516dddf1d | ||
|
|
677f606935 |
@@ -51,7 +51,7 @@ func buildRequest(opts Options) ([]byte, error) {
|
||||
|
||||
body := requestBody{
|
||||
User: ttsUser{UID: opts.UID},
|
||||
Namespace: "BidirectionalTTS",
|
||||
Namespace: "UnidirectionalTTS",
|
||||
ReqParams: ttsReqParams{
|
||||
Text: opts.Text,
|
||||
Speaker: opts.Speaker,
|
||||
|
||||
@@ -105,11 +105,7 @@ func ParseStream(body io.Reader, started time.Time) (*ParsedStream, error) {
|
||||
gotFirstChunk = true
|
||||
}
|
||||
case "":
|
||||
// 无 event 字段的元数据行(上游 TTSSentenceStart 偶发省略 event),
|
||||
// debug 模式打印便于排查;正常情况静默跳过。
|
||||
if common.DebugLog && resp.Code == 0 {
|
||||
log.Printf("volcano: 无 event 字段 code=%d sequence=%d sentence=%s data_len=%d", resp.Code, resp.Sequence, resp.SentenceText(), len(resp.Data))
|
||||
}
|
||||
// 传输帧,跳过
|
||||
default:
|
||||
if common.DebugLog {
|
||||
log.Printf("volcano: 忽略未识别事件 event=%q sequence=%d sentence=%s data_len=%d", resp.Event, resp.Sequence, resp.SentenceText(), len(resp.Data))
|
||||
|
||||
Reference in New Issue
Block a user