Hi khoweilip,
I will take a look into an Android implementation.
I may have to branch my code, and change a few things to get it to work with pocketsphinx-android.
In windows based news, I have a further update.
Instructions for Sample Project:
- Extract the archive to a folder in your Unreal Projects directory (SpeechTest)
- Open SpeechTest.uproject, and run the project.
- Hit ‘I’ to initialize, and say any of the following phrases
‘start game’, ‘end game’, ‘open menu’
- Examine SpeechRecognitionCharacter blueprint, to see the structure.
Phrases are stored as structs. (RecognitionKeyWord)
RecognitionKeyWord’s have a keyword, and a tolerance setting.
Note: Keywords must be built from words that exist in the dictionary. (content/en-us/en-us.dict)
At the moment, I have set Tolerance as an Enumeration, ranging from a very low cut-off, to a very high cut-off.
As a test, try saying the following sentences, one at a time.
- Being angry about something that happened in the past; a grudge.
- When something is extremely common and simple to acquire.
- Someone acting foolish can easily lose his or her money through carelessness or trickery.
- A task that is simple to complete; similar to the common phrase “as easy as pie.”
- Something that is extremely expensive; an idiom meaning the price paid was costly, excessively so.
- When something is incomprehensible due to complexity.
Now, change each of the structs to a very low cut-off, and try again.
The sentences should record false positive for the added phrases.
For simpler phrases, set a high cut-off, and vice versa for a phonetically complex phrase.
At the moment, I sort of tested and guessed with the setting for the tolerances
Here’s what they match to
Instructions for Implementation in your project:
- From the archive, copy the following to your project
content/model
Plugin
- In your blueprints, copy the blueprint structure of SpeechRecognitionCharacter.
Would love feedback and suggestions cheers
Known Issues
At the moment, there is a minor issue, where a phrase is spoken eg “start game”, and the phrase is not detected.
The phrase is then spoken again, and then both phrases are detected.
Eg. “start game” “start game”