Microsoft Speech Platform - how to update rules at runtime

391 Views Asked by At

I am using the System.Speech to build a C# application with voice recognition capabilities.

I read this post http://msdn.microsoft.com/en-us/library/jj127913.aspx that mentions how to update rules dynamically at runtime.

I wonder how I can do the same trick with the C# System.Speech API. Do you have any idea?

Thank you

1

There are 1 best solutions below

5
On

System.Speech is a bit different from the SAPI described under this link, however, it's even easier to construct grammars in runtime, you can use GrammarBuilder class for that. You can add any structure of choices and rules to construct the language you need to recognize.

Once you updated the grammar you can load the grammar into recognizer recognizer with LoadGrammar