Implement text analysis solutions 4.2 Implement speech solutions

A publisher uses the Speech batch synthesis API to create audiobook chapters from SSML.

Study guide skill: Implement workflows to convert speech to text and text to speech for agentic interactions

Question B7-016

A publisher uses the Speech batch synthesis API to create audiobook chapters from SSML. It sets a destination storage account that allows access only from selected networks, and the jobs fail to deliver the audio. What should you do?

Select one answer.

  • A Grant the Speech resource's managed identity the Storage Blob Data Contributor role on the restricted account
  • B Use a destination storage account that allows access from all networks ✓ Correct answer
  • C Change inputKind to PlainText without setting a voice so the audio is written to the default location
  • D Keep the restricted account and connect it to the Speech resource through a private endpoint so the service can write to it

Answer: B

If you specify a destination storage account for batch synthesis, it must allow access from all networks, because the service doesn't support network-restricted storage accounts. So neither a role assignment nor a private endpoint makes a restricted account work. Switching inputKind to PlainText doesn't change where the audio is written; it only means you must also set the voice in synthesisConfig.

Deep dive

How it works

Speech batch synthesis turns large amounts of text or SSML into audio asynchronously. Where the results go depends on destinationContainerUrl:

  • If you set it (a container URL with a SAS token), results are written to your writable Azure container. SAS with stored access policies isn't supported.
  • If you don't, the Speech service stores the results in a container managed by Microsoft, and deleting the job deletes the result data too.

The batch synthesis pages are explicit about your own container: if you specify a destination storage account, it must allow access from all networks. The service doesn't support network-restricted storage accounts. A "selected networks" account is network-restricted, which is why delivery fails. The fix is a destination account that allows access from all networks, or omit the destination so results go to the Microsoft-managed container.

The other options, and when you'd use them

  • Grant the Speech managed identity Storage Blob Data Contributor: The limitation is about network restriction, not permissions. Network-restricted accounts aren't supported.
  • Switch inputKind to PlainText without a voice: The input format doesn't change where audio is written, and with PlainText you must also set the voice in synthesisConfig, so the request would be incomplete.
  • Private endpoint to the restricted account: The account would still be network-restricted, which the service doesn't support.

Exam tip

Batch synthesis destination storage = must allow all networks. No destination = Microsoft-managed container.

References

Last reviewed:

Ready to test yourself? The quiz asks this and every other AI-103 question, with instant feedback. Practice this in a quiz →

All Text analysis questions · AI-103 study guide

Thanks for your feedback!