Skip to content

voskSpeechRecognition: Implementation of an offline speech recognition system using the vosk API in Python. Network audio source reception via YARP. Broadcast of voice recognition results over the network. via YARP.

Notifications You must be signed in to change notification settings

davidvelascogarcia/voskSpeechRecognition

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

voskSpeechRecognition Homepage Latest Release Build Status

Vosk Speech Recognition: voskSpeechRecognition (Python API)

Introduction

voskSpeechRecognition module use Vosk Speech Recognition API in python. This module performs speech recognition using Kaldi speech recognition backend and converts to text. Also use YARP to send text detection by network. Also admits YARP source audio like input. This module also publish recognition results in YARP port. voskSpeechRecognition require models to perform the module. Some pre-trained models in english, spanish, chinese, russian, french, german, portuguese, greek, turkish, vietnamese are available in vosk models.

Documentation available on docs.

Use

voskSpeechRecognition requires audio like input.voskSpeechRecognition models should be located in voskSpeechRecognition/models/model-x, being x your selected language. Download vosk models and extract content in your model-x dir. Also configure language.ini with your x selected language.

The process to running the program:

  1. Execute programs/voskSpeechRecognition.py, to start de program.
python3 speechRecognition.py
  1. Connect recognition source.
yarp connect /voskSpeechRecognition/data:o /yourport/data:i

NOTE:

  • Data results are published on /voskSpeechRecognition/data:o

Configure language

To configure speech recognition language model, language table is attached:

Language table:

Table 1. Language table

Language x
Spanish es
English en
Chinese cn
Russian ru
French fr
German de
Portuguese pt
Greek gr
Turkish tr
Vietnmaese vn

Requirements

voskSpeechRecognition requires:

pip3 install vosk

Possible errors:

vosk python version requirements:

  • vosk require python 3.8+ to be used in Windows.
  • vosk require python 3.5+ to be used in Linux.
  • vosk require python 3.8+ to be used in Mac OS X.
  • vosk require python 3.7+ to be used in Raspbian. (Raspberry also require to download and install .whl manually. vosk Raspberry version here

Tested on: windows 10, ubuntu 14.04, ubuntu 16.04, ubuntu 18.04, lubuntu 18.04 and raspbian.

Status

Build Status

Issues

Related projects

About

voskSpeechRecognition: Implementation of an offline speech recognition system using the vosk API in Python. Network audio source reception via YARP. Broadcast of voice recognition results over the network. via YARP.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages