We've Moved! Please visit our new and improved forum over at our new portal: https://portal.plumvoice.com/hc/en-us/community/topics

Dynamic <say-as>

Questions and answers about IVR programming for Plum DEV

Moderators: admin, support

Post Reply
jcanter
Posts: 47
Joined: Thu Jun 19, 2003 8:54 am

Dynamic <say-as>

Post by jcanter »

I am having an issue where I am pulling company names from a database to be spoken by the TTS engine. If I pull a with a name such as "The A and G Company", I would like that have the "A" and the "G" spoken as an acronym. However, since this name is stored in a variable, I cannot just stick a <say-as> tag around the characters. Is there some other way of handeling this?

abenamer
Posts: 2
Joined: Wed Nov 17, 2004 5:09 pm

<BUMP> I have the same problem </BUMP>

Post by abenamer »

My problem is similar -- I want digits entered by the user to be returned as distinct digits and not as a number. When a user enteres 26609 -- it should NOT be returned to the user as "twenty-six thousand six hundred and nine" but as 2 6 6 0 9.

support
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA
Contact:

IVR platform uses AT&T Natural Voices

Post by support »

jcanter wrote:I am having an issue where I am pulling company names from a database to be spoken by the TTS engine. If I pull a with a name such as "The A and G Company", I would like that have the "A" and the "G" spoken as an acronym. However, since this name is stored in a variable, I cannot just stick a <say-as> tag around the characters. Is there some other way of handeling this?
In this specific case, no... at least not with out pre-parsing the name somehow as it is pulled out of the database (resulting in):

<prompt>The <say-as type="acronym">A</say-as> and <say-as type="acronym">G</say-as> Company </prompt>

On a side note, the various speech synthesis engines have surprised me with the occassional "intelligent" pronunciation (our hosted IVR platform uses AT&T Natural Voices). E.g. I think Natural Voices is smart enough to look at something like "TN" and pronounce it "Tennessee" (while at the same time not knowing what to do with "FL" and just spelling it out). Unfortunately, these "intelligent" instances are not very well documented.


Plum Support
Last edited by support on Wed Jan 06, 2010 12:33 pm, edited 1 time in total.

support
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA
Contact:

Re: <BUMP> - use say-as tag for IVR fix

Post by support »

abenamer wrote:My problem is similar -- I want digits entered by the user to be returned as distinct digits and not as a number. When a user enteres 26609 -- it should NOT be returned to the user as "twenty-six thousand six hundred and nine" but as 2 6 6 0 9.
The <say-as> tag will do the trick for this IVR problem:

<say-as type="acronym">26609</say-as>
<!-- caller hears "two six six zero nine" -->

Plum Support
Last edited by support on Fri Jan 15, 2010 2:48 pm, edited 1 time in total.

abenamer
Posts: 2
Joined: Wed Nov 17, 2004 5:09 pm

Specs may not match the engine???

Post by abenamer »

Sorry - I still have the same problem

<say-as type="acronym">
<value expr="ClientID">
</say-as>

is the code I have. It won't return that expression (previously entered by user) as a 2-6-6-0-9 but as "twenty-six thousand six hundred and nine". Is there anyway I can make it say that?

I tried creating a JSGF grammar for it -- it DOES pronounce it back to the user the way I want it to do it but it garbles the value of the variable and inserts ASCII character 20 and other data into it rendering it impossible to use in a SQL search field. :( Please give me a fix.

jcanter
Posts: 47
Joined: Thu Jun 19, 2003 8:54 am

Re: Dynamic <say-as>

Post by jcanter »

support wrote:
jcanter wrote:I am having an issue where I am pulling company names from a database to be spoken by the TTS engine. If I pull a with a name such as "The A and G Company", I would like that have the "A" and the "G" spoken as an acronym. However, since this name is stored in a variable, I cannot just stick a <say-as> tag around the characters. Is there some other way of handeling this?
In this specific case, no... at least not with out pre-parsing the name somehow as it is pulled out of the database (resulting in):

<prompt>The <say-as type="acronym">A</say-as> and <say-as type="acronym">G</say-as> Company </prompt>

On a side note, the various speech synthesis engines have surprised me with the occassional "intelligent" pronunciation (our hosted platform uses AT&T Natural Voices). E.g. I think Natural Voices is smart enough to look at something like "TN" and pronounce it "Tennessee" (while at the same time not knowing what to do with "FL" and just spelling it out). Unfortunately, these "intelligent" instances are not very well documented.


Plum Support
Well, that is kind of what I was getting at here. I can't use that as a solution either. I can pre-parse the data when I take it out the the database, but then what? I can't store that in a variable. So I could this:

Code: Select all

<assign name="theCompany" expr="'The <say-as type="acronym">A</say-as> and <say-as type="acronym">G</say-as> Company'"/>
Also, I think the only way to get that to work is to replace all of the "<"'s and ">"'s with ">"s and "<"'s corrent?

However, when I try to speak this, it will ignore the <say-as> tags:

Code: Select all

<prompt>
<value expr="theCompany"/>
</prompt>

support
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA
Contact:

IVR use for <say-as> tag

Post by support »

An alternative may be to use the "number:digits" type for your <say-as> tag. The acronym tag is quite useful and we tend to rely on it for its simplicity, here for our IVR platform at Plum. It's an IVR tag type that's specific to the AT&T Natural Voices engine which we must've mistakenly assumed you had.
Last edited by support on Thu Feb 25, 2010 4:07 pm, edited 2 times in total.

support
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA
Contact:

using <prompt> tag in IVR script

Post by support »

jcanter wrote:
Well, that is kind of what I was getting at here. I can't use that as a solution either. I can pre-parse the data when I take it out the the database, but then what? I can't store that in a variable. So I could this:

Code: Select all

<assign name="theCompany" expr="'The <say-as type="acronym">A</say-as> and <say-as type="acronym">G</say-as> Company'"/>
Also, I think the only way to get that to work is to replace all of the "<"'s and ">"'s with ">"s and "<"'s corrent?

However, when I try to speak this, it will ignore the <say-as> tags:

Code: Select all

<prompt>
<value expr="theCompany"/>
</prompt>

A clever idea, but I'm pretty sure that sticking a combination of VXML tags - even if they're escaped - and plain text into an Ecmascript variable isn't going to cut it (though I'm happy to be proven wrong)...

The only alternative is to directly interpolate the company name (formatted as needed using your pre-processor - PHP, ASP, etc.) - rather than an ecmascript variable containing the company name - between the <prompt> tags (e.g. replace every instance of a single capital letter in the company name string with <say-as type="acronym">X</say-as>, where X is the letter).


Does this IVR script idea help at all?


Plum Support
Last edited by support on Fri Jan 15, 2010 2:54 pm, edited 1 time in total.

jcanter
Posts: 47
Joined: Thu Jun 19, 2003 8:54 am

Re: Dynamic <say-as>

Post by jcanter »

support wrote:
jcanter wrote:
Well, that is kind of what I was getting at here. I can't use that as a solution either. I can pre-parse the data when I take it out the the database, but then what? I can't store that in a variable. So I could this:

Code: Select all

<assign name="theCompany" expr="'The <say-as type="acronym">A</say-as> and <say-as type="acronym">G</say-as> Company'"/>
Also, I think the only way to get that to work is to replace all of the "<"'s and ">"'s with ">"s and "<"'s corrent?

However, when I try to speak this, it will ignore the <say-as> tags:

Code: Select all

<prompt>
<value expr="theCompany"/>
</prompt>

A clever idea, but I'm pretty sure that sticking a combination of VXML tags - even if they're escaped - and plain text into an Ecmascript variable isn't going to cut it (though I'm happy to be proven wrong)...
Heh, ok. That was my point of the post. That in fact will not work.
support wrote: The only alternative is to directly interpolate the company name (formatted as needed using your pre-processor - PHP, ASP, etc.) - rather than an ecmascript variable containing the company name - between the prompt tags (e.g. replace every instance of a single capital letter in the company name string with <say-as type="acronym">X</say-as>, where X is the letter).


Does this help at all?


Plum Support
This is a thought though. I will give it a try.

Post Reply