« DIY handcuff keys | Main | Endless alternatives »


Festival is a Text-to-Speech (TTS) converter developed by the Centre for Speech Technology Research at the University of Edinburgh. It’s shipped with most Linux distributions and released under a license that allows unrestricted commercial and non-commercial use.

To install it, simply search on "festival" in your usual Linux package installer. And to run it, open a terminal and type something like:

echo "Hello PC World" | festival --tts

to hear your computer’s very first words.

Alternatively, you can have it read from a file with the command:

cat myfile.txt | festival -tts

or more simply:

festival --tts myfile.txt

(Note that Festival can only read formatted text files. Attempting to read from non-text formats such as .pdfs won’t work.)

In this mode, any input gets read out loud. So a command such as

date '+%A, %B %e, %Y' | festival -tts

will tell you today’s date. That means you can incorporate it into batch files. Add it to our MP3 ripper script for example, and your computer will say what it’s up to and when it’s done. Or what about downloading a book from Project Gutenburg and have Festival read it to you?


Command Mode
Festival’s default mode however is command mode, which you’ll slip into if you just type ”festival„ on its own. Here you’re greeted with a command prompt:

festival>

The usual command mode features are available here such as TAB-completion and history, and to exit just hit Ctrl+D. Type ”help„ for help.

To say a phrase in command mode you need to prefix it with ”SayText„ and surround the whole thing with parentheses:

festival> (SayText "This is a little more complicated.")

To read from a file you enter:

festival> (tts "myfile.txt" nil)

Why bother with command mode? Because there’s a lot more you can do with Festival. The manual gives plenty of details along with some fun examples - such as singing! Try this;

festival> (tts "/usr/share/doc/festival/examples/songs/daisy.xml" 'singing)

Priceless! (Especially if you're a 2001: A Space Odyssey fan.)


Other voices
Lots of work's been done by third-parties to create new and better voices for Festival. You can read about where to find them and how to install them here. You could even computerise your own voice. Check out FestVox, a project that ”aims to make the building of new synthetic voices more systemic and better documented, making it possible for anyone to build a new voice.„


<--Previous Hidden Linux      Next Hidden Linux -->


Comments

I see... but do they have one that sounds exactly like stephen hawkings

Geoff,
I have shared the link for this on the new RevLinuxOS forum where it was well received. It is there under the subject "Say after me..."

Jim

Post a comment

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)