Scriptable speech synthesis?
March 12, 2009 6:29 PM   Subscribe

Does there exist a piece of scriptable speech synthesis software?

Ideally I'd like a python interface, but anything is fine. Google searches look promising, but there's so many fly-by-night "download" pages for various projects its hard to navigate.

I have a oopic chip called a soundgin that is sort of scriptable, but the quality isn't very good and I'd like an easier interface.

Alternatively, is there such thing as a canonical source of recorded phonemes in variations with which one would be able to write his own?
posted by miniape to Computers & Internet (14 answers total) 4 users marked this as a favorite
 
OS X has the CLI command "say", eg:
say "metafilter"

posted by troy at 6:39 PM on March 12, 2009


Best answer: There's Festival, and its smaller sibling flite. Both free.

I use flite for my daily, random, automatic podcast. It sounds mechanical, but is surprisingly clear.
posted by scruss at 6:53 PM on March 12, 2009


There are a bunch, including a speech synth and SDK and sample code freely downloadable from Microsoft for MS-Windows.

And there's some stuff from CMU, I think.

But. They all sound terrible. They're great technology, but they're nothing you want to listen to for more than a few minutes at a time.
posted by orthogonality at 6:55 PM on March 12, 2009


You don't specify OS, so I'll note that I was able to add speech synthesis to a .NET (C#) app I wrote with one reference and a few lines of code (instantiate, .Speak("Your String");). See here.
posted by SirOmega at 7:25 PM on March 12, 2009


I've played around with this on Mac OS X. It's pretty easy to get Applescript to do what you want (controlling volume, rate, pitch, etc) with any of the built-in voices. You can also embed Applescript within python if you're doing something more complex. I tinkered with this a while back, building a text-to-speech RSS reader on the Mac.

I agree with orthogonality about the quality of voices. Only a handful on the Mac are even worth considering (though they're getting better). AT&T Natural Voices are the best I've found so far.
posted by Jeff Howard at 8:15 PM on March 12, 2009


There's a way to use the OLE automation interface to hook into the windows speech synthesis. I've used it in ruby, but since it's OLE, you should be able to do it with any language that runs on Windows.
posted by ArgentCorvid at 9:27 PM on March 12, 2009


really simple example in ruby:
require 'win32ole'
tts=WIN32OLE.new "Sapi.SpVoice"
tts.speak "Hello there. What is your name?"

posted by ArgentCorvid at 9:40 PM on March 12, 2009


here is the relevant documentation if you are going to go the Windows/Automation route.
posted by ArgentCorvid at 9:48 PM on March 12, 2009


Response by poster: Hello, thanks everyone. I'm actually looking for something that would allow me a low-lever control. I imagine being able to build a word out of individual IPA phonemes and controlling the parameters of each. I haven't looked at all of the above posts, so maybe one of them does what I want, but if you happen to know specifically, please post.

I think a better term for what I want might be a phonetic synthesizer.

Thanks
posted by miniape at 9:52 PM on March 12, 2009


Best answer: I'm sorry if I'm not understanding what you want, but did you mean like this?

I really don't know if that's what you want, mostly just think it's cool that this sort of thing is included in windows.
posted by ArgentCorvid at 10:29 PM on March 12, 2009


If you have a Mac and aren't afraid of writing C code, take a look at Apple's Speech Synthesis Programming Guide.
posted by panic at 11:21 PM on March 12, 2009


This has been in the news a lot recently due to the Kindle's text-to-speech capability. If I were you, I'd follow up with a lot of the experts quoted in the articles (a lot of them seem to be researchers) and see what kind of toolkits they use.
posted by mmascolino at 6:21 AM on March 13, 2009


Best answer: Festival is open source and has a Scheme command interpreter.
posted by flabdablet's sock puppet at 8:36 AM on March 13, 2009


Response by poster: Thanks everyone. It looks like the MS SAPI or Festival might do what I want.
posted by miniape at 10:51 AM on March 13, 2009


« Older Help me spread my blog!   |   UK Web Hosting for Indexhibit? Newer »
This thread is closed to new comments.