Add TTS to a chat block

I’m quite new so apologies if I’m missing something obvious. I’m building out a website agent to help colleagues navigate a large intranet of documentation. For accessibility reasons, I’m hoping to have the chatbot’s output be available both as the usual text AND have it read out (or have a button or choice for it to be read out). I created a text-to-speech block and it is converting the chat blocks output after they hit next - but I’m hoping some might have a better or cleaner example of how to accomplish this?

Thank you!

Hi @rdrake, welcome to the Community!

Dynamic Tools in Chat is a good fit for this. I put together a quick agent you can remix here:
https://app.mindstudio.ai/agents/rdrake-dynamic-tools-in-chat-8a66cab5/remix

The setup lets the model trigger a Generate Speech block whenever the user requests TTS in chat, and displays the audio player once the speech is generated.

You can learn more about Dynamic Tools here:

This is perfect, thank you!