alphacep / vosk-api

Offline speech recognition API for Android, iOS, Raspberry Pi and servers with Python, Java, C# and Node
Apache License 2.0
7.36k stars 1.04k forks source link

support very long grammar #1525

Closed YangangCao closed 4 months ago

YangangCao commented 4 months ago

Hi, dear author, I try to construct very long(about more than 400 words) grammar in Vosk, Now Vosk will report an error in such situation. Any idea about support very long grammar?

Actually I want to align the very long text and the corresponding audio in pronunciation assessment, ASR with grammar is accurate and fast. The text is in order, I am not sure ordered text is helpful for constructing very long grammar?

Thanks for your attention!

nshmyrev commented 4 months ago

What kind of error do you see?

YangangCao commented 4 months ago

Sorry, it's my fault, too short char grammar buffer to use long grammar, when I change into long buffer, it runs as normal.