我有问题,让语音浏览器重复我的字段值作为一系列的数字,而不是一个大的多位数数字。例如,我的字段将使用“数字”或“数字”类型收集输入--在这种情况下,它是一个传输扩展。在填充部分中,我将收集到的值重复返回。电话分机号码2345不是“2-3-4-5”,而是“233445”。
怎样才能使这个值按顺序重复?我试着指定一个“say-as”标记,但没有结果。下面是我尝试使用的代码:
<field name="extension" type="digits?length=4">
<prompt bargein="false">
Please dial in or say the extension of the <value expr="application.extensionValues" /> you are trying to reach.
</prompt>
<grammar type="application/x-nuance-gsl">
[ dtmf-1 dtmf-2 dtmf-3 dtmf-4 dtmf-5 dtmf-6 dtmf-7 dtmf-8 dtmf-9 dtmf-0 ]
</grammar>
<grammar type="application/x-nuance-gsl">
[ one two three four five six seven eight nine ]
</grammar>
</field>
<filled>
<prompt>
I received extension number <say-as interpret-as="vxml:number"><value expr="extension"/></say-as>. Transfering you now.
</prompt>
</filled>编辑1
是的,我使用的平台是"BeVocal咖啡厅“开发环境。我将它指向一个URI,其中存储了vxml脚本。
不幸的是,你的建议对我无效。我试图将“解释”改为“电话”,翻译没有理解并错误地说出了错误。我尝试使用“字符”,这些字符看起来更像我想要的,虽然没有错误,但是解释器日志表明解释是‘未知的’。
发布于 2009-09-30 02:10:57
作为标签是最好的选择。尝试将解释-as属性更改为电话:http://www.w3.org/TR/2005/NOTE-ssml-sayas-20050526/#S3.3
发布于 2009-12-31 18:51:07
下面是带有适当BeVocal标记的代码。请注意,标记的实现依赖于供应商,因此这是不可移植的。
<field name="extension" type="digits?length=4">
<prompt bargein="false">
Please dial in or say the extension of the <value expr="application.extensionValues" /> you are trying to reach.
</prompt>
<grammar type="application/x-nuance-gsl">
[ dtmf-1 dtmf-2 dtmf-3 dtmf-4 dtmf-5 dtmf-6 dtmf-7 dtmf-8 dtmf-9 dtmf-0 ]
</grammar>
<grammar type="application/x-nuance-gsl">
[ one two three four five six seven eight nine ]
</grammar>
</field>
<filled>
<prompt>
I received extension number <say-as type="number:digits"><value expr="extension"/></say-as>. Transfering you now.
</prompt>
</filled>发布于 2018-06-11 19:08:47
我也有过类似的问题。但我绕开了它,把它设为首字母缩略词。这让IVR一个接一个地拼出数字。请注意,这是在PlumVoice IVR。我希望它对你有用。这是你修改过的代码。
<field name="extension" type="digits?length=4">
<prompt bargein="false">
Please dial in or say the extension of the <value expr="application.extensionValues" /> you are trying to reach.
</prompt>
<grammar type="application/x-nuance-gsl">
[ dtmf-1 dtmf-2 dtmf-3 dtmf-4 dtmf-5 dtmf-6 dtmf-7 dtmf-8 dtmf-9 dtmf-0 ]
</grammar>
<grammar type="application/x-nuance-gsl">
[ one two three four five six seven eight nine ]
</grammar>
</field>
<filled>
<prompt>
I received extension number <say-as type="acronym"><value expr="extension"/></say-as>. Transfering you now.
</prompt>
</filled>
https://stackoverflow.com/questions/1495792
复制相似问题