vosk-api
vosk-api copied to clipboard
Text punctuation support
Hello, Do you know if the solution supports text punctuation or how to add this functionality?
You can use external tools like https://github.com/ottokart/punctuator2 or https://github.com/kaituoxu/X-Punctuator
thanks, so Vosk itself does not support punctuation?
No, not yet.
ok. i see. thanks
Latest recommendation is https://github.com/benob/recasepunc
We don't plan to have it immediately, maybe, some time in the future.
Btw, we have released some punctuation models, links are in https://alphacephei.com/vosk/models
Latest recommendation is https://github.com/benob/recasepunc
We don't plan to have it immediately, maybe, some time in the future.
Good Afternoon Dear @nshmyrev, I see you developed 2 customized models for Russian and German languages using https://github.com/benob/recasepunc Could you tell me short hints how may I add text punctuation support of my language in recasepunc? Thank you in advance!
P.S. The solution is here https://github.com/benob/recasepunc/issues/6
Btw, we have released some punctuation models, links are in https://alphacephei.com/vosk/models
This is so great! I was curious...are there plans / is it even possible to release a small model version with punctuation?
@szeidner
This is so great! I was curious...are there plans / is it even possible to release a small model version with punctuation?
Thats actually a big research question. BERT and alike models are accurate, but they are not easy to compress to a small size. Things like distillbert are much less accurate for practical applications. Another approach to punctuation prediction is required. Distillation somewhat works, but not easy.
@nshmyrev could you give an example on how to use the punctuation model? Might be doing something completely wrong but I get an error while passing this model instead of the en-us model -
Folder 'model' does not contain model files. Make sure you specified the model path properly in Model constructor. If you are not sure about relative path, use absolute path specification.
@nshmyrev could you give an example on how to use the punctuation model? Might be doing something completely wrong but I get an error while passing this model instead of the en-us model -
Folder 'model' does not contain model files. Make sure you specified the model path properly in Model constructor. If you are not sure about relative path, use absolute path specification.
I see the same thing here - that link looks like a self contained recasepunc model, was that the intention? It isn't a drop in replacement for other vosk models right? It would be pretty great if that could work!
@nshmyrev could you give an example on how to use the punctuation model? Might be doing something completely wrong but I get an error while passing this model instead of the en-us model -
Folder 'model' does not contain model files. Make sure you specified the model path properly in Model constructor. If you are not sure about relative path, use absolute path specification.
@nshmyrev I have the same question. Could you please give the steps/example?
It looks like those punctuation models are for use with recasepunc
(not Vosk), so you would have to use it as the checkpoint file. Something like:
python recasepunc.py predict checkpoint/path_to_checkpoint_model < input.txt > output.txt
Hello, is the generation of a model with Italian punctuation planned? The Italian model available at the link works very well, but all transcriptions are lowercase and without punctuation.
Hello, is the generation of a model with Italian punctuation planned?
You can easily train it yourself probably with recasepunc
I proceeded to train an Italian model of recasepunc. Is there a way to train an Italian model of Vosk (for example this) on the basis of that of recasepunc?
I don't understand "train on the basis"
Sorry, I meant to understand how I could combine a Vosk model with the recasepunc model (as I think you have been done with this).
You just feed recognized text into punctuation model and get punctuated text.
I apologize again. For a moment I assumed that models like this were a Vosk model (like this) which also recognized punctuation (without dependencies on recasepunc), but after downloading it (vosk-recasepunc-en-0.22.zip) and consulting the content, I realized that it is just as you tell me: the text is simply transcribed with the Vosk model then punctuation is added with the recasepunc model. Thanks for your patience.
Latest recommendation is https://github.com/benob/recasepunc
@nshmyrev just curiosity, do you have more recommendations? (especially in C/C++)
(the last update in this repo was 2y ago 😕)