sonus icon indicating copy to clipboard operation
sonus copied to clipboard

Implement a simple pause / resume

Open simon-tannai opened this issue 4 years ago • 1 comments

Hi !

I have implemented a simple pause() and resume() methods to have a solution to the issue that I met with the orginal methods (https://github.com/evancohen/sonus/issues/95)

simon-tannai avatar Feb 08 '20 20:02 simon-tannai

Thank you! Sorry for totally missing the notification for this PR.

From a quick glance your PR only stops keyword emission, which might lead to unexpected results. For example calling pause() in the middle of an utterance won't stop the audio stream from being set to the speech provider and detection will run until the end of the utterance. I think the "right" way to solve this is to mute the hardware device or the audio stream that being consumed by Sonus.

Going to keep this PR open, in case it helps anyone, at least until I manage to get around to fixing this.

evancohen avatar Mar 21 '20 05:03 evancohen