Freeswitch + GDF Plugin using builtin:event vs builtin:speech

216 views
Skip to first unread message

Gaurav Bhagwat

unread,
Oct 11, 2019, 5:55:47 AM10/11/19
to UniMRCP
The help document on GDF plugin provides passing event name which maps to Intent's event in dialogflow

thus, when using

<action application="play_and_detect_speech" data="say: Welcome detect:unimrcp:google-mrcp-v2 {start-input-timers=false,no-input-timeout=5000,recognition-timeout=50000}builtin:event/welcome?project_id=abcrde-1234;caller_id=+188888888"/>

welcome intent is triggered in DialogFlow and parameter passed are caller_id as in example above.

The DialogFlow log shows the request as

{"session":"901005f9c5be478e","query_input":"{\n \"event\": {\n \"name\": \"welcome\"\n }\n}","timezone":"Asia/Colombo"}

However, no TTS for the say: Welcome is heard nor the audio spoken to gets added as part of RECOGNIZE and sent to Dialogflow

This is only possible using builtin:speech, the max parameter that can be passed is context forexample:

<action application="play_and_detect_speech" data="say: Welcome detect:unimrcp:google-mrcp-v2 {start-input-timers=false,no-input-timeout=5000,recognition-timeout=50000}builtin:speech/transcribe?projectid=abcrde-1234;context=input.something"/>

the DialogFlow log shows this request as

{"session":"35e7b6c9c85e4de7","query_input":"{\n \"text\": {\n \"textInputs\": [{\n \"text\": \"hi \"\n }]\n }\n}","timezone":"Asia/Colombo"}"

 My question is:

1. Am I using the builtin:event grammar incorrectly?
2. Is there any other way to pass parameters like caller_id using builtin:speech grammar?


Gaurav Bhagwat

unread,
Oct 11, 2019, 6:30:32 AM10/11/19
to UniMRCP
Fixing a typo in projectid

<action application="play_and_detect_speech" data="say: Welcome detect:unimrcp:google-mrcp-v2 {start-input-timers=false,no-input-timeout=5000,recognition-timeout=50000}builtin:event/welcome?projectid=abcrde-1234;caller_id=+188888888"/>

Arsen Chaloyan

unread,
Oct 18, 2019, 10:50:51 AM10/18/19
to UniMRCP
My comments below.

On Fri, Oct 11, 2019 at 2:55 AM Gaurav Bhagwat <bhagw...@gmail.com> wrote:
The help document on GDF plugin provides passing event name which maps to Intent's event in dialogflow

thus, when using

<action application="play_and_detect_speech" data="say: Welcome detect:unimrcp:google-mrcp-v2 {start-input-timers=false,no-input-timeout=5000,recognition-timeout=50000}builtin:event/welcome?project_id=abcrde-1234;caller_id=+188888888"/>

OK.


welcome intent is triggered in DialogFlow and parameter passed are caller_id as in example above.

The DialogFlow log shows the request as

{"session":"901005f9c5be478e","query_input":"{\n \"event\": {\n \"name\": \"welcome\"\n }\n}","timezone":"Asia/Colombo"}

Good.


However, no TTS for the say: Welcome is heard nor the audio spoken to gets added as part of RECOGNIZE and sent to Dialogflow

It is up to your application to retrieve the fulfillment in the response and play it to the caller.


This is only possible using builtin:speech, the max parameter that can be passed is context forexample:

<action application="play_and_detect_speech" data="say: Welcome detect:unimrcp:google-mrcp-v2 {start-input-timers=false,no-input-timeout=5000,recognition-timeout=50000}builtin:speech/transcribe?projectid=abcrde-1234;context=input.something"/>

the DialogFlow log shows this request as

{"session":"35e7b6c9c85e4de7","query_input":"{\n \"text\": {\n \"textInputs\": [{\n \"text\": \"hi \"\n }]\n }\n}","timezone":"Asia/Colombo"}"

 My question is:

1. Am I using the builtin:event grammar incorrectly?
2. Is there any other way to pass parameters like caller_id using builtin:speech grammar?


--
You received this message because you are subscribed to the Google Groups "UniMRCP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to unimrcp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/unimrcp/77a82228-bb70-4dd9-a822-03c5c91e9cc2%40googlegroups.com.


--
Arsen Chaloyan
Author of UniMRCP
http://www.unimrcp.org
Reply all
Reply to author
Forward
0 new messages