Skip to content
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

Final Result is only posted when calling SpeechRecognizer.stop() #8

Open
paulpv opened this issue Sep 12, 2014 · 3 comments
Open

Final Result is only posted when calling SpeechRecognizer.stop() #8

paulpv opened this issue Sep 12, 2014 · 3 comments

Comments

@paulpv
Copy link

paulpv commented Sep 12, 2014

I find it odd that "mainHandler.post(new ResultEvent(hypothesis, true));" is only ever called in SpeechRecognizer.stop().
I would expect the final result to be posted if the main recognizer loop timed out but had a partial result.
Maybe I am missing the purpose of "Partial" results and what to expect when the thread times out or when "stop()" is called.
Is my "onPartialResult" handler supposed to be handle even the final result?
Should I not expect a call to "onResult" unless "stop()" is explicitly called (ex: even if there is a confident match or a timeout)?

If this is a malfunction, then I can whip together a proposed fix or two.
If this is normal, then is there some better documentation, other than the demo, of how and when to handle onPartialResult and onResult?

Thanks!

@mbait mbait closed this as completed Sep 13, 2014
@nshmyrev nshmyrev reopened this Sep 13, 2014
@nshmyrev
Copy link
Contributor

Yes, there is an issue now on timeout behavior, ideally we should extend timeout when we receive results.

@paulpv
Copy link
Author

paulpv commented Sep 13, 2014

I was going to open another issue that the "timeout" is not really a timed timeout, it is a "number of samples timeout".
It might make more sense to make this a [Milli] second timeout instead of a sample count timeout.

@nshmyrev
Copy link
Contributor

Right, this is another valid problem. I tried to sync timeout with milliseconds but it seems on many devices there is still no match.

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

3 participants