diff --git a/CHANGELOG.md b/CHANGELOG.md index 6a2eb2259344b612e429c8f00dca0b5ade15c513..592f3974e90b1566dbe6d4e62e3cdce49e07d4e7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ - 修改日志打印 - 故事返回增加专辑字段 - http入口新增需要AppKey校验 +- 增加换一首歌 ## [0.0.1-beta.3] - 2025.6.19 ### Changed diff --git a/c2c.http b/c2c.http index c73316788ff3534920cfec5e8e37186846824db6..10de800752ee8de170cd3b1a49211fb1d46ceedc 100644 --- a/c2c.http +++ b/c2c.http @@ -10,7 +10,7 @@ Content-Type: application/json }, "nluRet": { "asr_recongize": "", - "text": "暂停闹钟" + "text": "合肥今天几点下雨" } }, "version": "v0" @@ -19,12 +19,13 @@ Content-Type: application/json ### POST https://testnlu.gree.com/semantic/unisoundc2c/speech-nlu-parse Content-Type: application/json +X-AppKey: 391b50b5ed634fc49a3db7cfd6bc40db { "ip": "14.215.222.17", "mac": "ece154a865eb", "mid": "11011", - "query":"暂停闹钟", + "query":"换一首歌", "requestId": "123456111" } @@ -38,7 +39,7 @@ X-AppKey: 391b50b5ed634fc49a3db7cfd6bc40db "ip": "14.215.222.17", "mac": "ece154a865eb", "mid": "11011", - "query":"播放故事", + "query":"播放正版", "requestId": "123456111" } @@ -59,7 +60,7 @@ Content-Type: application/json "trafficParameter": "mode=childxxx;macWifi=28b77c218ed1;mid=10f05;vender=7e000025;macVoice=testyuntiancloud;ver=3.0;scenario=smarthome;filterName=nlu;req_nlu_length=1;returnType=json;fullDuplex=true;appendLength=1;additionalService=geli_nlu2;version=0.5;filterUrl=https://testnlu.gree.com:443/semantic/unisoundc2c/querys;" }, "nluRet": { - "text": "暂停闹钟" + "text": "哈萨克斯坦的全称" }, "postProc": {} } @@ -100,7 +101,7 @@ Content-Type: application/json "trafficParameter": "mode=childxx;macWifi=ece154a73d38;mid=11011;macVoice=testyuntiancloud;ver=3.0;scenario=smarthome;filterName=nlu;req_nlu_length=1;returnType=json;fullDuplex=true;appendLength=1;additionalService=geli_nlu2;version=0.5;filterUrl=https://testnlu.gree.com:443/semantic/unisoundc2c/querys;" }, "nluRet": { - "text": "暂停闹钟" + "text": "换一首歌" }, "postProc": {} } diff --git a/service/speechNlu/domain.go b/service/speechNlu/domain.go index bab4a3f6f81c10db45167ee37caf7dfcf5083b79..13defc17ee0a1ea73db0585ac29f9871fcab7daf 100644 --- a/service/speechNlu/domain.go +++ b/service/speechNlu/domain.go @@ -780,7 +780,7 @@ func playCtrlDomain(params *model.SpeechDomainParams) []byte { return transformGreeProtocolReply(query, "PlayControl", "control_resume", nil) case "DUI.MediaController.Stop": return transformGreeProtocolReply(query, "PlayControl", "control_stop", nil) - case "DUI.MediaController.Next": + case "DUI.MediaController.Next", "DUI.MediaController.Switch": return transformGreeProtocolReply(query, "PlayControl", "control_next", nil) case "DUI.MediaController.Prev": return transformGreeProtocolReply(query, "PlayControl", "control_previous", nil)