Cisco CVP / VVB Dialogflow QueryParameters

248 views
Skip to first unread message

Matthias Neubacher

unread,
Jan 29, 2019, 9:33:06 AM1/29/19
to UniMRCP
Hi there,

I'm evaluating UniMRCP with GDF Plugin (1.8.0) and Cisco Virtualized Voice Browser (11.6 ES84). Thanks to the discussions in this forum and subsequent GDF Plugins releases it was quite easy to hook things up. VVB itself gets more mature and standards compliance with each ES / release.

Currently I'm struggling with passing additional data to dialogflow. Unfortunately VVB has no support for specifying Vendor-Specific-Parameters through a VXML property.

Arsen, do you have any plans on supporting passing QueryParameters like dialogid/projectid as query input attribute to the built-in speech grammar and in SRGS XML?

I don't like the workarounds that I have in my from the architectural perspective:
1) calling detectIntent upfront with queryParams from my VXML server and using the same sesssionid for UniMRCP.
2) pushing data identified by sesssionid to a seperate webservice and using webhooks in dialogflow for retrieval.

Thanks for your comments,
Matthias

Arsen Chaloyan

unread,
Jan 29, 2019, 11:07:55 PM1/29/19
to UniMRCP
Hi Matthias,

Glad to notice you find the discussions helpful. I would encourage people to use this facility more extensively to share the knowledge and ideas, as things keep evolving and not everything is available in a structured document yet.

You will be surprised, but what you are asking has already been implemented and will be available with upcoming release of GDF 1.9.0 to be published in a couple of days. While the changes have been made to address the interoperability with Avaya Experience Portal, the implementation is mostly generic.

With the upcoming release, QueryParameters can be specified in the following alternate ways. The examples are provided for timeZone and geoLocation, but the same concept applies to all the other parameters.

Vendor Specific Parameters

This method has been available for quite some time, but apparently not many platforms can set a custom vendor-specific parameter. So, the use is quite limited.

Vendor-Specific-Parameters: timeZone=Europe/Paris; geoLocation={"latitude": 48.85,"longitude": ‎2.29}

Built-in Grammar Attributes

This is a new option and can be used with Genesys and Avaya, not sure about Cisco.

builtin:speech/transcribe?timeZone=Europe/Paris;geoLocation={"latitude": 48.85,"longitude": 2.29}

SRGS XML Tag

This method is generic and can be used with any major IVR platform.

<grammar mode="voice" root="transcribe" version="1.0"
            xml:lang="en-US"
            xmlns="http://www.w3.org/2001/06/grammar">
    <meta name="scope" content="builtin"/>
       <tag>
          {"timeZone":"Europe/Paris","geoLocation":{"latitude": 48.85,"longitude": 2.29}}
       </tag>
    <rule id="main"> <one-of/ > </rule>
</grammar>

Questions, ideas are welcome.

--
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.
For more options, visit https://groups.google.com/d/optout.


--
Arsen Chaloyan
Author of UniMRCP
http://www.unimrcp.org

Matthias Neubacher

unread,
Jan 30, 2019, 6:03:08 AM1/30/19
to UniMRCP
Hi Arsen,

Thanks for the answer, it sound's promising.

I did a quick test and it looks like both ways will work with Cisco VVB.

UniMRCP log for Built-in Grammar attributes:

Content-Type:text/uri-list
...


builtin:speech/transcribe?timeZone=Europe/Paris;geoLocation={"latitude": 48.85,"longitude": 2.29}

UniMRCP log for SRGS XML Tag:

Content-Type:application/srgs+xml
...

<?xml version="1.0" encoding="UTF-8"?>
<grammar mode="voice" root="main" version="1.0" xml:lang="en-US" xmlns="http://www.w3.org/2001/06/grammar">
 <meta content="transcribe" name="scope"/>
 <tag>
 {&quot;timeZone&quot;:&quot;Europe/Paris&quot;,&quot;geoLocation&quot;:{&quot;latitude&quot;: 48.85,&quot;longitude&quot;: 2.29}}

 </tag>
 <rule id="main"><one-of/></rule>
</grammar>


Thanks,
Matthias

Arsen Chaloyan

unread,
Jan 30, 2019, 11:30:17 PM1/30/19
to UniMRCP
Hi Mattias,

Thanks for checking this behavior with Cisco VVB.

To be honest, I do not understand why the content of the XML tag element is quoted. As opposed to XML attributes, data inside XML elements may contain quotes without escaping. And I used the tag element on purpose to be able to pass an arbitrary JSON object as is. Anyway, this should not be a problem, as the content will be unquoted and passed to JSON deserializer.

One more observation for future reference regarding the context parameter, as this would be the most usable parameter among others. While specifying one or more contexts to be activated, you may and should specify the name of the context only as follows.

<tag>{"contexts": [{"name":"your-context-id","lifespanCount":5}]}</tag>

The full identifier will be implicitly composed and passed to Dialogflow API based on the following notation.

projects/<Project ID>/agent/sessions/<Session ID>/contexts/<Context ID>

If for any reason, you specify a full identifier, then the supplied identifier will be transparently passed through.



--
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.
For more options, visit https://groups.google.com/d/optout.

Matthias Neubacher

unread,
Feb 1, 2019, 7:56:33 AM2/1/19
to UniMRCP
Hi Arsen,

Thanks for the additional info and for the release 1.9.0. Both ways of parameter passing work with Cisco VVB 11.6 ES84.

Matthias
Reply all
Reply to author
Forward
0 new messages