Virtual assistant with offline voice recognition. Despite being primarily designed for Raspberry Pi, it should compile on any computer running Linux or macOS.
- The PocketSphinx installation currently requires Node.js 6
- This can be achieved by using a version manager such as nvm:
nvm install 6
- This can be achieved by using a version manager such as nvm:
- Install the PocketSphinx dependencies:
apt-get install cmake pkg-config libpcre3-dev bisonswigfrom GitHubsphinxbasefrom GitHubpocketsphinxfrom GitHub- Note that certain tweaks might be required prior to install:
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfigln -s /usr/bin/swig3.0 /usr/bin/swig(Create a symlink forswig3.0)
npm install cmake-js -g
- Install Festival with a default voice:
apt-get install festival festvox-rablpc16k
npm install
- Make sure that this repository (
OkPi) is in the same folder as the clonedpocketsphinxrepository npm run start- Or alternatively using watch mode:
npm run watchnpm run launch(in a separate terminal)
-
The application roughly implements the following structure:
-
Speech input
- ->
AudioInput - ->
SpeechRecognitionEngine - ->
UtteranceProcessor - ->
Skill - ->
OutputFacade
- ->