Uberi / Uberi/speech_recognition
speech_recognition does not implemented the vosk wrapper
Open
@ftnext is already working on this.
Since Sep 30, 2022.
- Dominant language
- Python
- Stars
- 9k
- Forks
- 2.4k
- Avg merge
- 12h 24m
- Merged PRs (30d)
- 3
Description
I'm trying to use speech_regognition with vosk. But when I try to call the vosk method I receive the following message:
Traceback (most recent call last):
File "C:\Users\user\projects\\studies\speechreco.py", line 27, in <module>
text = recognizer.recognize_vosk(audio)
AttributeError: 'Recognizer' object has no attribute 'recognize_vosk'. Did you mean: 'recognize_api'?
The method is:
import speech_recognition as speechreco
import vosk
while True:
try:
print("begin loop")
with speechreco.Microphone() as mic:
recognizer.adjust_for_ambient_noise(mic)
print("begin listening")
audio = recognizer.listen(mic)
text = recognizer.recognize_vosk(audio)
...
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:

Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.