From 4773dba7d3e4605409f22a577a578def0a279264 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E6=96=87=E9=9D=99?= <1319697849@qq.com> Date: Mon, 16 Jun 2025 10:43:49 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=9B=BD=E5=AD=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 1 + c2c.http | 18 +++++++++++++++--- service/speechNlu/constant.go | 2 +- service/speechNlu/register.go | 2 +- 4 files changed, 18 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c333a32..3663bd3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ - 修改sessionId记录 - 修改播控 - 增加一个http的入口 +- 增加国学 ## [0.0.1-beta.2] - 2025.5.29 ### Changed diff --git a/c2c.http b/c2c.http index f2a9e5c..cc92425 100644 --- a/c2c.http +++ b/c2c.http @@ -1,3 +1,15 @@ +POST https://testnlu.gree.com/semantic/unisoundc2c/speech-nlu-parse +Content-Type: application/json + +{ + "ip": "14.215.222.17", + "mac": "ece154a865eb", + "mid": "11011", + "query":"播放弟子规", + "requestId": "123456111" +} + +### POST http://localhost:13302/semantic/unisoundc2c/speech-nlu-parse Content-Type: application/json @@ -5,7 +17,7 @@ Content-Type: application/json "ip": "14.215.222.17", "mac": "ece154a865eb", "mid": "11011", - "query":"明天天气", + "query":"播放弟子规", "requestId": "123456111" } @@ -26,7 +38,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": {} } @@ -67,7 +79,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/constant.go b/service/speechNlu/constant.go index 5c015e0..334565a 100644 --- a/service/speechNlu/constant.go +++ b/service/speechNlu/constant.go @@ -78,7 +78,7 @@ const ( SCIENCE = "计算器" CHENGYU = "成语" BAIKE = "百科" - FM = "网络电台" + FM = "国学" CHILDMUSIC = "儿歌" GLOBALCTRL = "中控" PlayCTRL = "播放控制" diff --git a/service/speechNlu/register.go b/service/speechNlu/register.go index f84a130..f8c92d4 100644 --- a/service/speechNlu/register.go +++ b/service/speechNlu/register.go @@ -38,7 +38,7 @@ func register() { DomainRegister(SCIENCE, scienceDomain) DomainRegister(CHENGYU, chengyuDomain) DomainRegister(BAIKE, baikeDomain) - //DomainRegister(FM, fmDomain) + DomainRegister(FM, fmDomain) DomainRegister(CHILDMUSIC, childMusicDomain) DomainRegister(GLOBALCTRL, globalCtrlDomain) DomainRegister(PlayCTRL, playCtrlDomain) -- GitLab