Alfred 3 workflow for saying a given text or a file content with a selected voice.
- Install alfred-say-you-say-me workflow.
- All further updates are handled automatically.
- Requires a python3 interpreter to be installed via a Homebrew.
Select a UTF-8 encoded text file in finder and invoke the alfred file actions ⌃⌘\.
Choose the Say...
in a displayed menu and select appropriate voice.
Then, the resulting file will appear in your Desktop
directory.
Alternatively, you can pass the text you want to hear to this workflow. In Alfred, type say
and pass the text as an argument.
Then, select a voice and your text will be spoken. Voices are sorted by their locales and previously selected voices are prioritized. Notice, that each voice in a menu contains its locale, name and a localized voice introduction.
If you press ⌘ during a voice selection, spoken text will be saved in a file stored in your Desktop
directory.
Have too many voices for a selection is pretty useless, so you can configure the language filter in a workflow configuration.
Fill all required locales in language_filter
variable. Filter is case insensitive and is a regular expression. If you don't know what the regular expression is, just put there all locales divided by the pipe symbol |
. See the screenshot below.
Then, you will see just voices which your languages support.
There is another variable you could set. It's a buggy_voices_filter
variable, which contains a list of buggy voices. Currently, there is a problem in the Apple Synthetization Daemon and some voices can stick it. At the moment, only the en_us - Alex
voice is added there. Again, list is a regular expression.
Stuck daemon could be unstuck by typing .say-unstick
in Alfred.