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

Should not stop after first spoken text #2016

Merged
merged 3 commits into from
May 22, 2019
Merged

Conversation

compulim
Copy link
Contributor

@compulim compulim commented May 21, 2019

Fixes #1736.

Changelog Entry

Description

In startDictateAfterSpeakActivitySaga, we are using a wrong selector.

Originally, we want to check if "all activities are spoken", but since we used a wrong selector, we was checking "if the currently speaking activity is spoken". And of course it is, because we just set a flag on it.

Specific Changes

  • Instead of checking against "the currently spoken activity", we are checking against all activities
  • Testing Added
    • We don't have any test facility for speech right now

@darrenj
Copy link

darrenj commented May 22, 2019

I believe this issue is the one we've hit with testing, here are some examples to help validate the change. Would be good to validate this with a Bot that @ryanlengel can help provide.

• If one response is sent back WebChat appears to perform TTS reliably, eg:
image

• If two responses are sent back WebChat fails to perform TTS on anything (despite Speak properties being set). Occasionally it will play the last message, sometimes truncated. Other times nothing is heard. I suspect the first is being played, the second comes in and does not wait until the first is completed. Due to the race condition it’s luck of the drawer if you hear anything.
image

• This I believe is another example of “two responses” – “I found the following” and then a carousel of adaptive cards. Speak properties are set on both yet nothing is heard.

image

@compulim
Copy link
Contributor Author

compulim commented May 22, 2019

@darrenj yes, this one is related.

The bug this PR will fix is, "when we finish speaking any activities, we will start dictating and stop speaking." Instead of "any", it should be "all". That's the bug.

The other bug about "cut off" or "not talking at all", is #1829. What I believe is:

  • Chrome has a bug (in Feb) that it may not know it stuck with speech synthesis
    • Our workaround: if Chrome didn't respond in a second, we will restart the speech synthesis part
  • If Chrome takes more than 1 second to decode the audio, we will restart the synthesis

So that's why if the text is too long, you may or may not able to hear it. Working on it now.

@compulim compulim merged commit 9e5288a into microsoft:master May 22, 2019
@compulim compulim mentioned this pull request Jul 8, 2019
26 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Speech: Queuing messages for text-to-speech
3 participants