Speech output delayed by about 10 seconds

Post your questions and help other users.

Moderator: Martin

Post Reply
seb
Posts: 13
Joined: 12 Jan 2015 21:36

Speech output delayed by about 10 seconds

Post by seb » 12 Jan 2015 21:44

Hi,

I've been experimenting with speech input and output.

Input is working perfectly.

Output is waiting about 10 seconds before it starts talking.

Here's an example, where it is supposed to say only a single word, and it took 11 seconds. It is random, it is usually between 10 and 14 seconds.

12.01.2015 21:56:08.170 [Speech input] Flow continues executing with the next step.
12.01.2015 21:56:08.171 [Speech input] Start executing action 'Speech Output: super'
12.01.2015 21:56:19.418 [Speech input] End executing action 'Speech Output: super'
12.01.2015 21:56:19.464 [Speech input] Flow ended.

Not sure if it's relevant, but when I edit the speech output action, the language selection (French) takes a couple of seconds to appear too.

I have a Moto G 1st gen and I admit i disabled a couple of built-in apps, but none seem relevant to text-to-speech (disabled Gallery, Android Live Wallpapers, Google Drive, etc).

I enabled debug log but it's not providing more info.

Any idea?

Thanks!
Seb

Wibbly
Posts: 418
Joined: 17 Mar 2014 09:02

Re: Speech output delayed by about 10 seconds

Post by Wibbly » 12 Jan 2015 22:14

I find speech output is delayed too, but only a few seconds.

User avatar
Martin
Posts: 4468
Joined: 09 Nov 2012 14:23

Re: Speech output delayed by about 10 seconds

Post by Martin » 13 Jan 2015 20:30

Hi,

The text to speech engine seems to take so long to initialize properly on your device. Do you always get such a long delay or is it faster after you've executed the action a few times?
The newer versions of the Google TTS engine introduced a noticeable delay but it's usually not as bad as 10 seconds but more like two or three seconds.
Maybe rebooting the phone could help. You could also try if the embedded synthesis or the network synthesis works faster.

Regards,
Martin

seb
Posts: 13
Joined: 12 Jan 2015 21:36

Re: Speech output delayed by about 10 seconds

Post by seb » 13 Jan 2015 22:09

Hi Martin,

It always takes about the same time, and TTS outside of Automagic starts talking immediately (example in the Android options, the menu where you can test TTS, or with Pocket TTS feature for reading articles out loud).
I've compared the flow with a friend owning a Samsung Galaxy S4, he had the Samsung TTS enabled and he tried the Google TTS engine, and it starts immediately. When he edits the action, the language selection appears immediately too.

I've already rebooted the phone and played with different synthesis options with no luck.

I'm going to try to convince a colleague with a Moto G to install the evaluation version and try on his phone...

I'll keep you updated.

Thanks!
Seb

seb
Posts: 13
Joined: 12 Jan 2015 21:36

Re: Speech output delayed by about 10 seconds

Post by seb » 14 Jan 2015 12:21

I just tried on my colleague's phone with the evaluation version (I'm trying hard to convince him to get Automagic though :)) and his phone has a delay of about 3 seconds, so my phone is to blame here...

User avatar
Martin
Posts: 4468
Joined: 09 Nov 2012 14:23

Re: Speech output delayed by about 10 seconds

Post by Martin » 14 Jan 2015 20:09

Hi Seb,

Maybe I've found a way to reduce the delay (on a Nexus 5 from ~2 seconds to ~zero). I'm not sure if this might have some negative side effects so I will add a new option under menu->Manage->Preferences->Workarounds->Reduce Text to Speech Delay.
Would be great if you could test this workaround on your device when the next version is released (or in a few days when the new EAP version becomes available in the EAP forum).

Regards,
Martin

seb
Posts: 13
Joined: 12 Jan 2015 21:36

Re: Speech output delayed by about 10 seconds

Post by seb » 14 Jan 2015 20:24

Sure, I'll test the latest EAP release. Is there a way to get notified when it is released?

In a few words, what kind of workaround is that? I've seen people on Tasker forums complaining about the same delay (2-3 seconds) issue.

User avatar
Martin
Posts: 4468
Joined: 09 Nov 2012 14:23

Re: Speech output delayed by about 10 seconds

Post by Martin » 14 Jan 2015 20:59

You can subscribe to topic EAP version 1.27.0-dev to get a notification when I release the next EAP (probably on Friday). There should be a link 'Subscribe topic' on the lower left end of the page (when used in desktop style).

Automagic simply keeps the TTS engine initialized when the workaround is enabled so executing the first action Speech Output will still have the delay but subsequent invocations should be faster. I'm not sure if this has any negative side effects like increased memory usage of the system or if the action even breaks in some way when the TTS engine is terminated by Android under heavy load etc.

seb
Posts: 13
Joined: 12 Jan 2015 21:36

Re: Speech output delayed by about 10 seconds

Post by seb » 16 Jan 2015 20:50

I'm currently running the latest EAP.

The first run still takes about 10 seconds but any subsequent output starts immediately.

The TTS engine process keeps running, take no CPU but uses about 50MB of RAM.

It's a shame you have to implement a workaround while the problem is clearly on Google's side.

If I see any side effect, I'll let you know.

Thanks!

Post Reply