Testing speech recognition grammars with text instead of audio
Last reviewed: 5/23/2023
HOW Article ID: H032308
The information in this article applies to:
- Chant Developer Workbench 2023
- SpeechKit 12
- SpeechManager 3
Emulating speech recognition with text provides an alternative way of testing speech recognition grammars and validating rule matches.
Emulating speech recognition is a powerful feature of Microsoft SpeechAPIs: Microsoft SAPI 5, Microsoft Speech Platform, Microsoft .NET System.Speech, and Microsoft .NET Microsoft.Speech.
SpeechKit 12 extends the TranscribeAudio method for these Speech APIs to emulate speech recognition when text is passed instead of an audio file path.
Grammar rules may be tested interactively via the Speech Recognizers tab in the Developer Workbench. Depending on your speech API, the semantic results vary. Each API uniquely handles returning semantic properties.
Microsoft SAPI 5 Emulate Speech Events: Review semantic properties in the Events window.
Microsoft SAPI 5 Emulate Speech Results: Review recognition results in the Output window.
Microsoft .NET System.Speech Emulate Speech Events: Review semantic properties in the Events window.
Microsoft .NET System.Speech Emulate Speech Results: Review recognition results in the Output window.
Grammar rules may be tested programmatically with SpeechKit applications invoking the TranscribeAudio method. Review the section Recognizing Speech to see how easy it is to emulate speech recognition in application code.
In addition, high-volume testing can be accomplished easily with SpeechManager—instead of making transcription requests with audio files, speech emulation requests can be processed with rule matches. Explore the section Chant SpeechManager to see how easy it is to achieve high-volume testing in a batch application.