Open ramleda opened 2 years ago
version 3.8.1 doesn't include vosk (master does, so I guess it will be in the next release?): https://github.com/Uberi/speech_recognition/blob/3.8.1/speech_recognition/__init__.py
I'm also interested in using Vosk as it seems to be the only offline option that actually works.
Yeah same problem, any fix?
As @Enhex mentioned (Thanks! ❤️),
recognize_vosk
method
For example if you install from PyPI, recognize_vosk
was not implemented
$ pip install SpeechRecognition
>>> import speech_recognition as speechreco
>>> recognizer = speechreco.Recognizer()
>>> "recognize_vosk" in dir(recognizer)
False
Clone this repository and install from source (👉See simpler command by @nshmyrev https://github.com/Uberi/speech_recognition/issues/613#issuecomment-1264475131 )
$ # I recommend to prepare another virtual environment for source installation
$ git clone https://github.com/Uberi/speech_recognition.git
$ cd speech_recognition/
$ pip install -e .
>>> import speech_recognition as speechreco
>>> recognizer = speechreco.Recognizer()
>>> "recognize_vosk" in dir(recognizer)
True
Thanks for reporting this issue. ❤️ Can you try this workaround, @ramleda @mattiasu96 ?
I will prepare for PyPI release. It is preferable as solution.
Clone this repository and install from source
You can do it with a single pip command actually:
pip3 install git+https://github.com/Uberi/speech_recognition
@nshmyrev Thanks!
Actually, I misunderstood the project's metadata and was not able to install like pip install SomeProject@git+https://git.repo/some_pkg.git@1.3.1
https://pip.pypa.io/en/stable/cli/pip_install/#examples (example 5)
Your comment gave me suggestions and helped me realize the misunderstanding.
pip install speech-recognition@git+https://github.com/Uberi/speech_recognition.git
I'm trying to use speech_regognition with vosk. But when I try to call the vosk method I receive the following message:
The method is:
It looks like the vosk wrapper is not implemented at the version:
vosk - 0.3.42 python - 3.10.4
Need I use a downgrade version?
I follow the sample: