Skip to content

about grammar: not work in Chinaese,but work in English. #1719

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
odd809 opened this issue Mar 5, 2025 · 2 comments
Open

about grammar: not work in Chinaese,but work in English. #1719

odd809 opened this issue Mar 5, 2025 · 2 comments

Comments

@odd809
Copy link

odd809 commented Mar 5, 2025

I use this function:
public VoskRecognizer(Model model, float sample_rate, string grammar)

Use English Model,grammar set such as "this","stop" , success!
But Use Chinaese Model,grammar set such "停止“,”苹果",model ignored the gammar word。

@nshmyrev
Copy link
Collaborator

nshmyrev commented Mar 6, 2025

Probably the string has wrong encoding or the words are missing in the dictionary. Which model are you trying?

@odd809
Copy link
Author

odd809 commented Mar 21, 2025

Thanks nshmyrev2 !!!
Model is vosk-model-small-cn-0.22
words such as "停止“ encoding to utf8
but debug info show me: the grammar ignored the words.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants