Skip to content

add macOS say backend support#1

Open
DiogoDoreto wants to merge 1 commit intomainfrom
macos-say
Open

add macOS say backend support#1
DiogoDoreto wants to merge 1 commit intomainfrom
macos-say

Conversation

@DiogoDoreto
Copy link
Owner

Introduce a new TTS backend using the built-in macOS 'say' command for text-to-speech generation. The default backend now automatically selects 'say' on Darwin systems and 'kokoro' elsewhere. This provides native, zero-dependency TTS backend for macOS users.


This is a basic implementation based on the documentation found here: https://ss64.com/mac/say.html

I'll leave this PR open until someone can confirm this works, as I don't have this OS available to me.

Introduce a new TTS backend using the built-in macOS 'say' command for
text-to-speech generation. The default backend now automatically selects
'say' on Darwin systems and 'kokoro' elsewhere. This provides native,
zero-dependency TTS backend for macOS users.
@DiogoDoreto DiogoDoreto mentioned this pull request Oct 19, 2025
6 tasks
@DiogoDoreto
Copy link
Owner Author

  • should probably pair with afplay as a new frontend

@riscy
Copy link

riscy commented Oct 26, 2025

I tested this out and it seems to not work on my mac -

Despite what the man page says, "say" does not seem to support wav outputs (at least on my machine) with the default voice (the log shows: [tts-say] Opening output file failed: fmt?, where fmt? is say's obscure way of saying it doesn't work with that file format). It works fine if .aiff is the tts-audio-extension so it may be a good idea to guide users in that direction.

You probably already know this, but macOS "say" also lets you skip the step where you write to a file and invoke ffplay. But ffplay is easy to install on macOS (so I read).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants