質問

I don't know if I could get an answer here... The problem I am trying to solve is: The system listens to the user's input,judge if the user's input contains the word "loop".

Does VoiceXML support grammars for this kind of task? It seems that it can only pick up word from words listed. The user can say: using a loop, loop, for loop, looping through the array...... Is there a way for me to only consider if the sentence contains "loop"?

Thanks in advance.

役に立ちましたか?

解決

You can create your own grammer and attach to your field:

<field name="loopField">
    <prompt>What's your way to say loop?</prompt>
    <grammar src="mygrammar.gram" type="application/srgs+xml" />
    <help> Please say your employee number. </help>
</field>

See more on W3C grammar here

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top