Posts: 3
Joined: Tue May 19, 2015 8:25 am

Add / Remove grammar at runtime without accessing a file?

Tue May 19, 2015 10:13 pm

i'd like to leverage the JSGF feature but I need to be able to load and unload grammar as my program opens and closes applications.

How do I add/remove JSGF from the recogniser on the fly without having to write my grammars to a file then recreate the object?

User avatar
Lead Software Architect
Posts: 377
Joined: Fri Sep 14, 2012 12:20 pm
Contact: Website

Re: Add / Remove grammar at runtime without accessing a file

Tue May 19, 2015 11:52 pm

At the moment Syn.Speech's JSFG parser heavily relies on FileStream so I don't think there's any feasible way of Loading/Unloading JSFG Grammar at run-time. The only option right now would be to create Grammar files at run-time and load them to a new instance of the SpeechRecognizer.

Having said that, we are still improving Syn.Speech and have plans of enabling On-the-Fly Grammar support.

Return to “General Discussion”

Who is online

Users browsing this forum: No registered users and 1 guest