Reputation: 85
I can see on this page that Actions on Google does support SSML, however I'm having trouble getting it to work in my agent.
I'm using DialogFlow with a PHP webhook.
To test it, my webhook is providing the following response via the 'speech' parameter:
<speak>First sentence. <break time="1s"/> Second sentence. <prosody pitch="+5st">and now high pitched</prosody></speak>
Testing this via Google Assistant on my Samsung S8, it is read in the male voice (this is the setting for my Action in Actions on Google). The break is not displayed in text and is ignored by the speech engine. The prosody tag appears in text and is also ignored by the speech engine.
Trying this same output in the Actions on Google audio simulator does correctly interpret the SSML tags.
Am I doing something obviously wrong, or are these tags perhaps not supported?
Upvotes: 1
Views: 1385
Reputation: 136
I found this strange behavior (January 2021): When i test my project as "Smart Display" on the Actions Console, everything works perfect. But when i change to the "Phone", some of my actions are not spoken, though shown on the simulator-display. But testing the action directly on my Android smartphone, everything works smooth.
As i pointed out at the beginning: this might be a small bug in the simulator.
Upvotes: 0
Reputation: 50701
Actions on Google supports SSML and supports all three of the tags that you're using.
That the simulator generates the speech correctly is a pretty good sign that you're both doing things correctly and that the tags are supported.
From the description, it more sounds like an error with the Samsung or the Assistant on the Samsung than anything else.
Upvotes: 3