Is there any implementation in java to capture only characters? Will CMU Sphinx be able to do this? I've been trying with no luck at all. For a fact google speech API does a very poor job out of this. Characters like B,W,X are recognized but almost all the vowels are not! Any information is appreciated. Thanks!
Write grammar letters.gram like this:
#JSGF V1.0;
grammar letters;
public <letter> = (a. | b. | c. | d. | e. | f. | j.) *;
Use it sphinx4 like this:
Configuration configuration = new Configuration();
configuration.setAcousticModelPath("resource:/edu/cmu/sphinx/models/en-us/en-us");
configuration.setDictionaryPath("resource:/edu/cmu/sphinx/models/en-us/cmudict-en-us.dict");
configuration.setGrammarPath("file:grammars_folder");
configuration.setGrammarName("letters");
configuration.setUseGrammar(true);
LiveSpeechRecognizer recognizer = new LiveSpeechRecognizer(configuration);
recognizer.startRecognition(true);
SpeechResult result = recognizer.getResult();
recognizer.stopRecognition();
For more details check sphinx4 tutorial
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With