Debug Your Infrastructure

Get Instant Solutions for Kubernetes, Databases, Docker and more

AWS CloudWatch
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.
Pod Stuck in CrashLoopBackOff
Database connection timeout
Docker Container won't Start
Kubernetes ingress not working
Redis connection refused
CI/CD pipeline failing

AWS Polly MarksNotSupportedForFormatException

Speech marks are not supported for the specified output format.

Understanding AWS Polly: A Powerful Voice AI Tool

AWS Polly is a cloud-based service provided by Amazon Web Services that converts text into lifelike speech. It allows developers to create applications that can 'speak' in a variety of voices and languages, enhancing user interaction with voice-enabled applications. AWS Polly is widely used in applications such as news reading, e-learning platforms, and any other service that benefits from text-to-speech capabilities.

Recognizing the Symptom: MarksNotSupportedForFormatException

When using AWS Polly, you might encounter the error MarksNotSupportedForFormatException. This error typically arises when you attempt to request speech marks for an output format that does not support them. Speech marks provide metadata about the speech, such as word boundaries, which can be useful for synchronizing animations or highlighting text as it is spoken.

Delving into the Issue: Understanding the Error

The MarksNotSupportedForFormatException error indicates that the output format you have chosen does not support speech marks. AWS Polly supports speech marks only for certain output formats, such as JSON. If you attempt to use an unsupported format, this error will be triggered, interrupting the text-to-speech conversion process.

Supported Formats for Speech Marks

To avoid this error, ensure that you are using a format that supports speech marks. Currently, JSON is the primary format that supports this feature. For more information on supported formats, you can refer to the AWS Polly Documentation.

Steps to Fix the Issue: Correcting the Output Format

To resolve the MarksNotSupportedForFormatException, follow these steps:

Step 1: Verify Your Output Format

Check the output format specified in your AWS Polly request. Ensure that it is set to a format that supports speech marks, such as JSON. Here is an example of how to specify the output format in your request:

{
"OutputFormat": "json",
"Text": "Hello, world!",
"VoiceId": "Joanna",
"SpeechMarkTypes": ["word"]
}

Step 2: Modify Your Request

If your current format does not support speech marks, modify your request to use JSON. This change will enable you to receive speech marks metadata along with the synthesized speech.

Step 3: Test Your Configuration

After making the necessary changes, test your configuration to ensure that the error is resolved. You can use the AWS CLI or SDKs to send a test request and verify the output. For more detailed instructions, visit the AWS Polly Getting Started Guide.

Conclusion

By ensuring that your output format supports speech marks, you can effectively resolve the MarksNotSupportedForFormatException error in AWS Polly. This will allow you to leverage the full potential of AWS Polly's text-to-speech capabilities, enhancing your application's user experience.

Master 

AWS Polly MarksNotSupportedForFormatException

 debugging in Minutes

— Grab the Ultimate Cheatsheet

(Perfect for DevOps & SREs)

Most-used commands
Real-world configs/examples
Handy troubleshooting shortcuts
Your email is safe with us. No spam, ever.

Thankyou for your submission

We have sent the cheatsheet on your email!
Oops! Something went wrong while submitting the form.

🚀 Tired of Noisy Alerts?

Try Doctor Droid — your AI SRE that auto-triages alerts, debugs issues, and finds the root cause for you.

Heading

Your email is safe thing.

Thank you for your Signing Up

Oops! Something went wrong while submitting the form.

MORE ISSUES

Deep Sea Tech Inc. — Made with ❤️ in Bangalore & San Francisco 🏢

Doctor Droid