A ROS package for speech-to-text services based on Vosk
- Install this package and vosk
sudo apt install ros-${ROS_DISTRO}-ros-vosk
don't forget to run catkin_make
- Install Dependencies
If using ROS MELODIC run first:
sudo apt install python3-pip
Then run for MELODIC & NOETIC:
roscd ros_vosk
pip3 install -r requirements.txt
And if you want to use the TTS engine please run:
sudo apt install espeak
pip3 install pyttsx3
Launch the speech recognition node
roslaunch ros_vosk ros_vosk.launch
or by running:
rosrun ros_vosk vosk_node.py
Param | Description | Values | Default |
---|---|---|---|
models_path | path to a folder where vosk audio models are stored | string | - |
use_tts_engine | use tts | True/False | False |
Published topics
Topic | Type | Description |
---|---|---|
vosk/speech_recognition/vosk_result | ros_vosk/speech_recognition | a custom "speech_recognition" message |
vosk/speech_recognition/final_result | std_msgs/String | a string with the final result |
vosk/speech_recognition/partial_result | std_msgs/String | a string with the partial result |
Subscribed topics
Topic | Type | Description |
---|---|---|
vosk/tts/status | std_msgs/Bool | the state of the tts engine. True if it is speaking False if it is not. If the status is true vosk_node won't process the audio stream so it won't listen to itself |
Published topics
Topic | Type | Description |
---|---|---|
vosk/tts/status | std_msgs/Bool | the state of the engine. True if it is speaking False if it is not. |
Subscribed topics
Topic | Type | Description |
---|---|---|
vosk/tts/phrase | std_msgs/String | get a string to say |
Angelo Antikatzidis an.antikatzidis@gmail.com Nickolay V. Shmyrev nshmyrev@gmail.com