Azure Text To Speech docker container throws an exception with viseme

Jon Peterson 26 Reputation points
2024-06-30T01:37:32.95+00:00

I'm using the Azure Text to Speech docker image (mcr.microsoft.com/azure-cognitive-services/speechservices/neural-text-to-speech:3.3.0-amd64-en-us-jennyneural). I'm passing it SSML through the dotnet SDK. When asking for viseme (via <mstts:viseme type="redlips_front" />), the container logs show there was an exception. I checked the images files and confirmed that there is not a file in that location. This works correctly when using the Azure hosted speech services.

ssml replace failed: System.TypeInitializationException: The type initializer for 'Microsoft.TTS.Ssml.SsmlConstant' threw an exception.
	System.IO.DirectoryNotFoundException: Could not find a part of the path '/onprem_start/phoneset/phoneset.json'.
	at Interop.ThrowExceptionForIoErrno(ErrorInfo errorInfo, String path, Boolean isDirectory, Func`2 errorRewriter)
    at Interop.CheckIo(Error error, String path, Boolean isDirectory, Func`2 errorRewriter)
    at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String path, OpenFlags flags, Int32 mode)
    at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
    at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
    at System.IO.StreamReader.ValidateArgsAndOpenPath(String path, Encoding encoding, Int32 bufferSize)
    at System.IO.File.InternalReadAllText(String path, Encoding encoding)
    at Microsoft.TTS.Ssml.SsmlConstant.InitPhoneset()
    at Microsoft.TTS.Ssml.SsmlConstant..cctor()
    --- End of inner exception stack trace ---
    at Microsoft.TTS.Ssml.Utility.StandardizeDefaultNamespace(String ssml)
    at Microsoft.TTS.Ssml.Ssml.Parse()
    at Microsoft.TTS.CustomTN.RuleEngine.NormalizeSSML(String locale, String ssmlstring)
    at Microsoft.TTS.CustomTN.RuleEngine.ExecuteSsml(String locale, String ssmlString, String& updated, ILogger logger, List`1 editItems)

User's image

Azure AI Speech
Azure AI Speech
An Azure service that integrates speech processing into apps and services.
1,743 questions
{count} votes

1 answer

Sort by: Most helpful
  1. dupammi 8,465 Reputation points Microsoft Vendor
    2024-07-03T07:20:10.6333333+00:00

    Hi @Jon Peterson

    I have consulted with the product team, and it has been confirmed that viseme events are not supported in the current Azure Text to Speech Docker containers. Unfortunately, there are no plans to include viseme support in these containers at this time. To utilize the viseme feature, please continue to use the cloud API.

    Thank you for your understanding.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.