Telefriday

The game of Telephone is a group game where a phrase is whispered into a person’s ear, that person whispers the phrase into another person’s ear, and so on, until the last person says what they thought the phrase is. Small mistakes will accumulate with each person, so usually the phrase has significantly changed by the time it reaches the last person.

I wanted to create an automated game of Telephone using text2wave, Asterisk, and Google Voice. Text2wave can turn a text file into an audio file, Asterisk can play that audio file into a Google Voice account, and Google Voice will transcribe the audio back into text. The script periodically checks a gmail account for transcribed voicemail messages, and if it finds one, repeats the process with the new text. The script uses a different text2wave “voice” for each new audio file. When the audio file has been created, the script generates a call file which calls Google Voice. The dialplan is very simple and just plays the audio file into Google Voice’s voicemail.

[ck987_funfunfun]
exten => s,1,Answer()
exten => s,n,Wait(6); waits until voicemail "beep"
exten => s,n,Playback(${fridayWav}); fridayWav variable is set in the call file.
exten => s,n,Hangup()

I chose the first 20 seconds of lyrics from the song “Friday” as the first phrase to kick things off. I figured that Rebecca Black sounds like a robot in the original song, so the synthesized speech wouldn’t be too far off from the original.

Telefriday source code

0 (Original Lyrics): voice- kal_diphone

Seven a.m., waking up in the morning.
Gotta be fresh, gotta go downstairs.
Gotta have my bowl, gotta have cereal.
Seeing everything, the time is going.
Ticking on and on, everybody's rushing.
Gotta get down to the bus stop.
Gotta catch my bus, I see my friends.

First Pass mp3

1: voice- ked_diphone

Sunday, I'm, waking up in the morning
that'll be slash gotta go downstairs,
gotta have my both gotta of cereal,
see if everything The time is it going,
take him and and I'm everybody's Russian 
gotta get down to the bus stop.
Dr catch my boss. I seen my friends.

Second Pass mp3

2: voice- cmu_us_awb_arctic_hts

Sunday. I'm waking up in the morning
of that gotta have my books.Got of cereal,
see if reason the time, as a go and
take him and and I'm everybody's Russian 
got the got down to the bus stop.
Dr catch my boss HI seen my friends.

Third Pass mp3

3: voice- cmu_us_bdl_arctic_hts

Sunday. I'm waking up in the morning
of that thought, have my boots. Thought of save you see you 
for using the time, as a go and 
take him. ON sun time everybody's Russian
talked about done to the postal. 
Dr catch my boss. I see my friends.

Fourth Pass mp3

4: voice- cmu_us_jmk_arctic_hts

Helen day. I'm waking up in the morning
of that thought have my boots thought of save you
see you for using the time as a go and 
take him on some time everybody's Russian
talked about done to the postal
doctor catch my boss. I see my friend.

Fifth Pass mp3

5: Final Translation

Heaven them making up in the morning.
That'll 3. Slash prodigal downstairs.
They also have my bills, composts Ariel, see him everything. 
The time is it going to come in and I'm everybody's Version, 
Content, cut down to the bus stop, 
talk to her catch my boss. I actually my friends.