[Feature] Read assistant replies aloud automatically, per session
Is your feature request related to a problem? Please describe.
Read-aloud is manual today. There is a mic button for voice input, and a "Read aloud" button on each assistant message. There is no setting that makes replies speak on their own.
This is a problem in the case where voice helps most. When you run a session from a phone, or from across the room, you are not looking at the screen. You must look at the transcript to see that a reply arrived, then tap a button to hear it. That removes most of the benefit of voice.
Describe the solution you'd like
Add a toggle in the composer that reads each finished assistant reply aloud. Use the voice stack that is already in the app.
Make the setting per session, not global. Some conversations suit listening and some do not. The setting should survive a page reload, and it should follow the conversation to another device.
Two requirements matter as much as the feature itself:
- It must never surprise the user. Audio that starts where no stop button is visible feels like a fault. So it should speak only the conversation that is on screen. It should never catch up on replies that finished while you were somewhere else. Opening a conversation, switching tabs, and reloading the page should all stay silent.
- Replies must be written for the ear. A speech engine reads code blocks, tables and lists as punctuation. So while the toggle is on, the outgoing prompt should ask for a reply that is easy to listen to.
Additional context
I have this implemented against main, with tests, and I am happy to open the
pull request. I am filing this issue first, as CONTRIBUTING.md asks. I am also
happy to change the shape, for example to a global preference, if you prefer.
One design point is worth settling before review. The prompt hint is visible in the transcript. This is not really a choice. The provider saves the prompt it receives, and the app reads history back from that file, so a hidden hint appears again after a reload. If you prefer a version that does not change prompts at all, I can drop that part.
Source: siteboon/claudecodeui