Skip to content

Adaptive Card speak problem #2243

@Monomoy88

Description

@Monomoy88

In my web app I'm using hybrid speech model as per the webchat sample code.
If adapive card has a speak field & I'm comunicating with bot using microphone then the bot is not speaking when the card is coming as response.
To get rid of this I've specified the same text in place of ssml in my Bot code as shown below:

var result = JsonConvert.DeserializeObject<AdaptiveModel>(cardAttachment.Content.ToString());
if (!string.IsNullOrEmpty(result.speak))
    await turnContext.SendActivityAsync(MessageFactory.Attachment(cardAttachment, "", result.speak, "en")), cancellationToken);

Now the bot is speaking same text twice as it has generated the Webchat have generated ssml as follows while sending it to cognitive speech:

<speak version="1.0" xml:lang="en-US">
  <voice xml:lang="en-US" xml:gender="undefined" name="Microsoft Server Speech Text to Speech Voice (en-US, ZiraRUS)">
    <prosody pitch="+0%" rate="+0%" volume="+0%">
      <s>Adaptive Card Text</s>
<s>Adaptive Card Text</s>
    </prosody>
  </voice>
</speak>

So either the bot is not speaking at all or speaking twice the same text for Adaptive card.
How to get rid of this problem?

Metadata

Metadata

Assignees

Labels

Bot ServicesRequired for internal Azure reporting. Do not delete. Do not change color.bugIndicates an unexpected problem or an unintended behavior.customer-replied-toRequired for internal reporting. Do not delete.customer-reportedRequired for internal Azure reporting. Do not delete.needs-reproWaiting for repro or investigation

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions