Actions7
Speech Synthesis
AI-generatedOverview
This node performs speech synthesis, converting input text into spoken audio using various AI models. It is useful for generating audio content from text, such as voiceovers, accessibility features, or automated announcements. Users can specify the model, input text, and fine-tune audio generation options like codec, sample rate, and voice characteristics.
Use Case Examples
- Generating an MP3 audio file from a text script for a podcast intro.
- Creating subtitles and audio output for accessibility in a video project.
- Using a specific voice model to produce a custom voice assistant response.
Properties
| Name | Meaning |
|---|---|
| Model Name or ID | Select the AI model to use for speech synthesis or specify a model ID via expression. |
| Text | The text input that will be converted into spoken audio. |
| Extract From Response | Choose which part of the speech synthesis response to return: audio as base64, audio URL, or full raw JSON response. |
| Speech Options | Optional parameters to fine-tune the generated audio, such as codec, sample rate, voice selection, subtitle generation, and other model-specific settings. |
Output
JSON
audioBase64- Base64 encoded audio content generated from the input text.audioUrl- URL pointing to the generated audio file.raw- Full raw JSON response from the speech synthesis API containing detailed synthesis data.
Dependencies
- An API key credential for the AI/ML API service
Troubleshooting
- Ensure the selected model supports speech synthesis; unsupported models will cause errors.
- Verify the API credentials and endpoint URL are correctly configured to avoid authentication errors.
- If the audio output is not as expected, check the speech options for compatibility with the chosen model.
- Common error messages include 'Unsupported operation' if the operation parameter is incorrect, and HTTP errors if the API request fails.
Links
- n8n Expressions Documentation - Documentation on how to use expressions to specify dynamic values in node parameters.