Hi y'all. I'm trying to add more than one keyphrase to the same recognizer. I've read multiple questions like this, but none of them worked with me. I have this code that creates the recognizer.
It doesn't work. I've tried to add keywords instead, but it just recognizes the first word of the list. I've tried to add grammar, but no matter what I say, it will think that I said some word from the grammar. I've tried to find the documentation of the library, but I didn't find any.
Does anybody know what should I do?
Thanks in advance.
Last edit: Luiz França 2017-12-13
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The file that I tried was actually in portuguese, I had added the wors on the dictionary and it worked fine when using addkeyphrasesearch, but when I use the setKws it only works the wors in English. Does anybody knows why it would work with addKeyphraseSearch and not with setKws?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi y'all. I'm trying to add more than one keyphrase to the same recognizer. I've read multiple questions like this, but none of them worked with me. I have this code that creates the recognizer.
If I try to add just one keyphrase search like this:
It works fine. But if I try:
It doesn't work. I've tried to add keywords instead, but it just recognizes the first word of the list. I've tried to add grammar, but no matter what I say, it will think that I said some word from the grammar. I've tried to find the documentation of the library, but I didn't find any.
Does anybody know what should I do?
Thanks in advance.
Last edit: Luiz França 2017-12-13
You have to use keyphrase list file and addKwsSearch method.
I tried to add kws. There is no addKwsSearch method on the api for android on the SpeechRecognizer. So I tried:
And this was the keyphrase.list:
But it just recognizes the fisrt keyphrase, and only sometimes.
Last edit: Luiz França 2017-12-14
The file that I tried was actually in portuguese, I had added the wors on the dictionary and it worked fine when using addkeyphrasesearch, but when I use the setKws it only works the wors in English. Does anybody knows why it would work with addKeyphraseSearch and not with setKws?
The method name is addKeywordSearch
Maybe thresholds are different, overall you need Portuguese model if you want to spot for Portuguese keyphrases.