fnx
fnx

Reputation: 491

Change word emphasis in a sentence with Azure Text-To-Speech SSML

I want to change the emphasis to a different word and SSML supports the <emphasis> element, but it isn't listed in the Microsoft documentation. It was ignored when I added it to the SSML markup. It seems like you could use the prosody-element to change the emphasis.

Update: It looks like the following prosody element results in a similar output than the <emphasis> element. The pitch is raised in this case by 30% for the word that has to be emphasised:

This is a <prosody pitch="+30.00%">Test</prosody>

May be there are other suggestions on how to best emulate emphasis on a word.

Upvotes: 1

Views: 976

Answers (2)

fnx
fnx

Reputation: 491

<emphasis> is now a supported element (https://learn.microsoft.com/en-us/azure/cognitive-services/speech-service/speech-synthesis-markup?tabs=csharp#adjust-emphasis). Currently it is only supported for some English voices however.

Upvotes: 0

Egil Sandfeld
Egil Sandfeld

Reputation: 106

Adding a short break before the emphasized word(s) seems to increase the importance. Around 70-200ms seems to be nice.

Also, I tend to slow the rate instead of increasing the pitch.

This is a <break time="100ms"/><prosody rate="-10.00%">test</prosody>

Upvotes: 1

Related Questions