Skip to content

🔊 It's a simple voice assistant which base on RasPi、Snowboy and Baidu ASR~

License

Notifications You must be signed in to change notification settings

raspberry-pi-org/voiceAssistant

 
 

Repository files navigation

Voice Assistant Of RasPi

🔊 It's a simple voice assistant which base on RasPi4BSnowboy and Baidu ASR, Please refer to This airticle if you want to know more detail info about it.

This Project Forked From : https://github.com/passerma/voiceAssistant Thanks A Lot bro ~

OS

  • Raspberry Pi 4B 4GB

Env

  • Python 3.7
  • apscheduler
  • python3-pyaudio
  • swig
  • libatlas-base-dev
  • baidu-aip
  • Baidu AIP SDK( aip-python-sdk-2.2.15 )

How To Run

  1. the first step : install the dependencies of Wake-on-voice
sudo apt-get install python3-pyaudio
sudo apt-get install swig
sudo apt-get install libatlas-base-dev

You need to change the fifth line of code : from * import snowboydetect to import snowboydetect in the snowboy/examples/Python3/snowboydecoder.py after you installed the dependencies of Wake-on-voice successfully.

  1. the second step : install the snowboy project
git clone https://github.com/Kitt-AI/snowboy.git
cd snowboy/swig/Python3 && make

let's execute the following command to test it whether installed successfully.

cd snowboy/examples/Python3
python3.7 demo.py resources/models/snowboy.umdl

Then speak the world of Wake-on-voice : snowboy,Verify installed successfully if you hear this sound is similar to : D~

  1. the third step : git clone this project
git clone https://github.com/raspberry-pi-org/voiceAssistant.git
  1. the fourth step : install some dependencies of this project needed
$ pip3 install apscheduler
$ cd aip-python-sdk-2.2.15
$ pip3 install baidu-aip
$ python3.7 setup.py install
  1. The fifth step : open the config/apiConfig.py file and add your Baidu API and ServerChan configuration information into it.

  2. The last step : run it and enjoy it bro

# the word of Wake-on-voice is : snowboy
$ python3.7 voiceAssistant.py

Problems

If the program throw a error info such as [Errno -9985] Device unavailable ...,Please fix it by the following command !

# install the pulseaudio
sudo apt-get install pulseaudio
# start it
pulseaudio --start

Speech Sound Plugins

  • Play Music
  • System Data
  • Weather Data
  • Hot Top Of Weibo.com
  • Hot Event Of Baidu.com
  • Movice Data Of Douban.com
  • Movice Data Of Maoyan.com
  • Universal Counting Leader

Thanks for your contribution if you want to add some funny or useful plugins into it.

Thanks

About

🔊 It's a simple voice assistant which base on RasPi、Snowboy and Baidu ASR~

Topics

Resources

License

Stars

Watchers

Forks

Languages

  • Python 100.0%