Have Speech Recognition pick a single word out of a sentence

1.1k views Asked by At

I am working with System.Speech.Recognition in VS2012 on Windows7 64 bit.

My issue is that when a user starts to speak the recognition engine seems to listen to everything that was spoken (i.e. the whole sentence "Please close the active program") and tries to match that whole sentence to my grammar. Due to reliability I don't want to have to match whole sentences and would like to listen only for key words, such as "close" and "active program".

From what I understand, the engine will map the user input "Please close the active program" to a single correct response while I would like some way for it to recognize that there were multiple 'hits' in that single input.

What I have now works fine if the user puts gaps between each word so they are all processed as individual inputs, but the issue is when you speak normally and it accepts the whole sentence as a single input.

Is there any way I can get the engine to detect just the key words out of the input without having to find a match in my grammar for the entire input? (or possibly a way to set up a regex in my grammar?)

I am using a simple SpeechRecognitionEngine with a Grammar built from Choices.

1

There are 1 answers

0
Nikolay Shmyrev On

You need to include Garbage rule in your Choices, then it will be able to match other part of the sentence with the garbage. It's not straightforward to implement keyword spotting with a recognizer though since you won't be able to tune the detection/false alarm rate properly. A specialized solution might be better.