Twitter2Mp3
From Rabbi Blog
I have no idea if this will go anywhere and the concept came from listening to Adam Curry on No Agenda.
Idea
Premise: parse Twitter feed using Perl, utilize Text2Wav (Festival) to convert to a wav file and then LAME encode the result to mp3.
Audio Result
<flashmp3>http://www.rabbibob.com/cstrike/20090321_twitter.mp3%7Cautostart=no%7Cloop=no%7CfirstTrackName=Sleeper39_1997</flashmp3>
Command Line
text2wave -F 16000 htt.txt -o test2.wav
lame -s 8 test2.wav test2.mp3
Text Origin
- replaced http urls with 'weblink'
Tweet 0 JohnCleese posted Retweeting @tippyjohn: Weblink - @JohnCleese I often wear this when tweeting. Tweet 1 pralphman said Tiered ... need sleep ... work tomorrow ... Tweet 2 JohnCleese posted Just looking at Tweet costumes. Is this a little over the top? Weblink Tweet 3 JohnCleese said Preparing to Tweet a second time Tweet 4 JohnCleese said The surprising thing here is that many of you seem to know what I am on about, which makes it a moment which, rather than when. Good news! Tweet 5 jessicamullen posted 12seconds - my new GTD tool Weblink Tweet 6 JohnCleese said a Tweet 7 JohnCleese said I'll have to go again, just give me moment. Tweet 8 JohnCleese said I just had one. Tweet 9 JohnCleese said Do you ever get those moments when? Tweet 10 AliceMalin posted Stuff white people like; Madmen. Weblink Tweet 11 JohnCleese said erroneous reports. I'll have to start this again. Tweet 12 JohnCleese said been Tweet 13 JohnCleese said There's... Tweet 14 jessicamullen said dear activity monitor: how is it possible for java to use 16,777,216 terabytes of virtual memory? Tweet 15 drewdomkus said with dawn safely on the plane, bachelor time may now commence ;) Tweet 16 JohnCleese said Putting characters in the correct order Tweet 17 JohnCleese said Preparing to Tweet Tweet 18 MonkeyBucket posted chicken ala free - Photo: Weblink Tweet 19 closedblueyes said @YvoLaLu & sorry about your friend. Terrible news. Tweet 20 closedblueyes said @YvoLaLu crazy. We've been driving by so many piles of junk. Tweet 21 YvoLaLu said @fortheinsane @showbiz_cousin Thanks loves Tweet 22 jessicamullen posted congratulations to the 2009 uiuc graphic design class - wonderful work at their senior ISPACE show site: Weblink Tweet 23 marcapitman said Just paid for the meal of the people behind me at the drive-thru. It's so fun showing God's love in practical ways! Tweet 24 noahleaman said eating paninis at Cafe Limelight in Santa Cruz Tweet 25 merlyn said noticed swelling was biggest problem, stopped oxycontin, started ibuprofen. head is clearer, and less pain! yeay. Tweet 26 LeoLaporte posted Live now: @JasonCalanis, @KevinRose, @GinaTapani, @DanPatterson for TWiT 187, Weblink Tweet 27 fortheinsane said @YvoLaLu oh no, sending you lots of love. Tweet 28 YvoLaLu said Just found out an old friend from high school passed away this morning :( Tweet 29 fortheinsane said at work. about to start my day. good good Tweet 30 Oblivion said FINALLY, the Blackhawks catch a break (or two). Interesting game. Tweet 31 tomit posted Our day at the Zoo! Weblink Tweet 32 adamcurry said My least favourite moment of the month. Admin. Grrrr Tweet 33 fortheinsane said @Smorgy because I'm loved Tweet 34 VincentTheBAMF said fire dept made me shave. feel like a baby. Tweet 35 tomit said Home and ready for a Nap. Tweet 36 tomit posted Checking in... Saint Augustine - Weblink Tweet 37 rabbibob said @UberSchwarz Very nice! couple angles I wouldn't have thought of. Good job Tweet 38 rabbibob said @UberSchwarz You miss my DM? Tweet 39 Smorgy said OMG i actually opened my computer before 2pm. Tweet 40 Smorgy said @fortheinsane why are you a lucky boy? Tweet 41 Oblivion said Worked on my motorcycles, hung with Em, and did some yard work today. Resting my feets now. Doesn't look like my TwitPics have come through. Tweet 42 WLBZ2 posted Milo Police Chief Charged with Domestic Assault Weblink Tweet 43 adamcurry said The lighting trusses are now installed @ the crackpot comand center Tweet 44 jessicamullen posted amsterdam is my fav place in the world - pls send me to next web? 750€ just for the conference pass...! Weblink Tweet 45 jessicamullen said is wondering if there is a free twitter iphone app that lets u have groups like in tweetdeck? Tweet 46 UberSchwarz posted @rabbibob @shack70 @draithon Posted my Wayside Walk pictures on Flickr Weblink Tweet 47 closedblueyes said Need to get the motivation to go to the gym. Wonder what we'll do today. Cardio? Tweet 48 WLBZ2 posted Cigarette To Blame For Kittery Apartment Fire Weblink Tweet 49 marcapitman said Is anyone else having trouble with TCM? It keeps going blank on our TV. (We have DirecTV) Tweet 50 dashdrum said @MuyLani My son has been taking Adderall in the AM for years. As long as he doesn't take it after lunch, his sleeping is fine. Tweet 51 jessicamullen said 1 of rudy corrales' friends just called me and left a voicemail "drinking beers with rudy, he just wants to say hi..." is guilt appropriate? Tweet 52 arthurdent said "You were attacked by Consigliere Arthur Dent. You lost the fight, taking 26 damage and losing $100,000" - Arthur Dent is everywhere! Tweet 53 fortheinsane said have any of you guys seen Knowing? apparently they show alot of Melbourne in it. and one of my friends is in it Tweet 54 MuyLani said @drewdomkus I love those kinds of shows 'cause you two are so cute when you're missing each other. Tweet 55 MuyLani said retweet@plasticemerson: a serial uriner peed on his PC before the feds could track him down, he said he would never give up his IP Freely #punday Tweet 56 jntracks said Wii bowling with moms friends. Plus wine and cheese Tweet 57 jessicamullen said dreamt about getting caught in lies by twitter all night. can't wait for universal telepathy... relationships will b like chemical reactions Tweet 58 MuyLani said So excited to install my new faucet mounted water filter. *domesticated* Tweet 59 jessicamullen posted downloading the new nin / janes addiction ep from Weblink and missing my @trent_reznor obsession Tweet 60 WLBZ2 posted Maine Recycles Video Winner Gives Back Weblink Tweet 61 drewdomkus said getting ready to take dawn to the airport. sad she'll be gone for 2 weeks but excited for her adventure #fb Tweet 62 marcapitman said retweet @cfocoach: AIG bonuses R 4/100's of 1% of this year's budget deficits. No wonder politicians don't want ppl 2 take eyes off AIG mess. Tweet 63 MuyLani said Made breakfast and Aaron's finally passed out. Think I might go watch tv in bed. It's cold today. Tweet 64 MuyLani said Worried about Aaron's sleeping pattern. he barely went to sleep right now after waking up at 10am yesterday. b/c of Adderall? Tweet 65 marcapitman said retweet @HildyGottlieb: retweet @chrisbrogan: What tests are between you and your next level of success? Tweet 66 justinrussell said Upon reviewing a number of Twitter clients and hating bits of all of them, I just upgraded my homemade client to support multiple accounts. Tweet 67 chrismarquardt said Waaaah. My feet are sore. Tweet 68 darthvader said I feel a tremor in the Force. No, actually it was just my special lunch burrito. My bad. Tweet 69 dashdrum said BTW... I ROCK!!! Tweet 70 dashdrum said Don't know why I find myself using vibrato on the Guitar Hero controller, but it's fun. Tweet 71 ambermacarthur posted After a delicious brunch with friends and family, this article makes me so sad - Weblink (sent from @jeffmacarthur) Tweet 72 adamcurry said re Tweet 73 Phreak said issac or isaac? help Tweet 74 toyotaboy posted careful what you post on twitter: Weblink Tweet 75 Coverville said My favorite typo from the Asian fusion restaurant menu last night: "Lettuce Warp Chicken". Tweet 76 MonkeyBucket posted test it now - Photo: Weblink Tweet 77 tomit posted Checking in... Zoo Rd & Bayshore Dr, Jacksonville, FL , United States - Weblink Tweet 78 tomit said At the Jax Zoo. Tweet 79 draithon said Lets hope Coach Umile can get his cats over the hump & do something spectacular in the frozen 4 tournament this year. Good Luck UNH Tweet 80 draithon said Frozen 4 selections were made today. There were a few surprises on the the teams selected but not many. UNH has a tough challenge. GL UNH Tweet 81 draithon said I have gotten Jill addicted to my rush hour traffic game. I love puzzle games that make ur brain think. I need to order more puzzles for it Tweet 82 justinrussell said I work on web sites 40 hours a week. What do I do on weekends to relax? Why, I work on web sites, of course. Such is the life I lead. Tweet 83 merlyn said used 20 of my post-surgery oxycontin in 72 hours... been relatively pain free, but I can definitely tell when that 3 hours are about done Tweet 84 Oblivion said Just took the WR250R out to look for the glove I lost yesterday. Didn't find it, but found another pair. Nice ride until the bike acted up. Tweet 85 adamcurry said We're live now on noagendastream.com Tweet 86 alyankovic said On a plane to Atlanta with @nerdist today... wheee! Tweet 87 chrismarquardt said Kaffee und kuchen beim Feuerwehrfest in Klein Oedesse. Wow. Tweet 88 THErealDVORAK said 10 minute warning. noagendastream.com about to switch to the live show. #noagenda Tweet 89 cc_chapman said Seeing some old friends that we don't see nearly often enough today. Can't wait. Tweet 90 WLBZ2 posted Colorectal Cancer Awareness Month Weblink Tweet 91 dashdrum said So apparently, the new thing is to bring your baby in the carseat into the coffee shop. Tweet 92 dashdrum said Downloading tons of Irish trad music on bittorrent. Thanks to @toyotaboy for funding the Panera WiFi. Tweet 93 AliceMalin said retweet @thooor God created the world in 7 days... why can't Obama fix America in 2 months?! "ROFL"/Malin Tweet 94 LeoLaporte posted Photo: Ink Is More Expensive Than Blood | Wizonk Online Image Publishing Weblink Tweet 95 adamcurry said Why is mother's day different in the UK from the US and other countries? Doesn't work well when you live in a different country. Tweet 96 adamcurry said /me is thinking that I need to set up Dm with @noagendastream so I don't duplicate tweets and spoken messages on the stream... Tweet 97 dashdrum said If all the Purdue police are here, who's patrolling the campus? Tweet 98 dashdrum said I need to convince @gentryart to make a logo for me Tweet 99 marcapitman said Daughters are playing checkers. 6 yo yelled "Cheater butt" to my 4 yo. Not sure what that is but I'm LMBO! Tweet 100 rabbibob said Maine Maple Sunday time! Tweet 101 marcapitman said retweet @m_amyknits "Noah was a brave man to sail in a wooden boat with two termites." -unknown Tweet 102 fortheinsane said In bed watching DVDs, smiling. I'm a lucky boy. Tweet 103 marcapitman said retweet @brandonacox retweet @farrhad: "When all you have is a hammer, everything looks like a nail." Tweet 104 chrismarquardt said But before the hike the gods have put the traffic jam... Tweet 105 adamcurry said troff #noagenda Tweet 106 adamcurry said tron #noagenda Tweet 107 adamcurry said troff mums Tweet 108 Shack70 said @rabbibob got 12 or so....worth the income ;) Tweet 109 Smorgy said I wish Evermore would just give up. Changing your hair styles and outfit doesnt change the fact you recorded shit like 'RUNNING!!' Tweet 110 chrismarquardt said Alright, getting ready for a 14km hike today. Stichworte: Erdölpumpen. Kniekuhlen. Schwarzwasserniederung. Mammutbaum. Flugplatz Eddessee. Tweet 111 rabbibob said debating on a MegaCasino built on a Prime Downtown Lot for $40,000,000. Tweet 112 Smorgy said Cooper is doing the cutest snores Tweet 113 fortheinsane said Watching more Frasier, watching season 3...the last episode. Tweet 114 chrismarquardt said Sonntagsfrühstück mit Parmaschinken, Kaffee, O-Saft, Trüffelsalami und frisch gekochten Eiern: heute Nachmittag mindestens 3h spazieren! Tweet 115 Smorgy said cooper is wearing his new black leather collar now... Customized to fit him ofcourse Tweet 116 Smorgy said packing up the work for now. 5 hours of straight data. I wish i hadn't already had two cokes today Tweet 117 WLBZ2 posted Fire Destroys Kittery Apartment Building Weblink Tweet 118 Smorgy said @fortheinsane it was sooo sad Tweet 119 fortheinsane said @Smorgy did you love it? Tweet 120 Smorgy said just finished season 3 of six feet under Tweet 121 Smorgy said @fortheinsane its painful. Tweet 122 fortheinsane said @Smorgy mmm im looking forward to eating them! hows your data stuff coming along? Tweet 123 wootsellout posted $42.99 : VTech 5.8GHz 4 Handset Cordless Phone with Digital Answering System Weblink Tweet 124 woot posted $19.99 : Dazzle DVD Recorder Weblink Tweet 125 Smorgy said @fortheinsane oooh well they will be here for the next time you come over Tweet 126 fortheinsane said @Smorgy damn, i totally ate all of those lollies you packed for me this morning and i was rummaging through my bag trying to find more! Tweet 127 Smorgy said @fortheinsane theres plenty here Tweet 128 fortheinsane said @Smorgy mmmmmm i want some tacos....I could eat a million of them right now Tweet 129 Smorgy said just got some late lunch tacos and a coke Tweet 130 tomit said Ok... Finished BSG. I liked the ending. I Liked the whole "it will all happen again" part. Could have done without all the angel stuff. Tweet 131 jntracks said L4d first spawn hunter. 3 pounces 3 kills 2400 points. Teammate cpulls ftw. Short round Tweet 132 Shultzman said Went to a kids birthday party today. 30 adults, 20 kids, pure craziness! Tweet 133 Smorgy said @dashdrum hhahahaa 14 is a horrible age, it gets better after 17 i promise Tweet 134 dashdrum said @Smorgy Good for you! After dealing with my 14 year old tonight, I'm glad someone has a nice daughter. Tweet 135 Smorgy said @dashdrum i cant do that... im a nice daughter Tweet 136 dashdrum said @Smorgy That's no good. Time to go on strike! Tweet 137 Smorgy said doing lots of un-paid overtime today Tweet 138 WLBZ2 posted Adults Apply For Jobs At Funtown Splashtown USA Weblink Tweet 139 DAVEfromNY said Just back from shooting one of those outta control Westchester Bat Mitzvahs that probably cost 100K! House is freezing - new furnace Monday! Tweet 140 DAVEfromNY said @Oblivion Maybe you should compare to a control viewing with no wine ;-) Tweet 141 alyankovic posted Gotta update my head shot. Weblink Tweet 142 jessicamullen said OH: "can i put the dick in your panties again?" Tweet 143 tomit said Trying to finish BSG. Tweet 144 justinrussell said Hm. It's pretty obvious when Joss writes an episode... Tweet 145 dashdrum said Was sitting outside web surfing with the dogs until the battery died. It's just so hot in the house tonight. Tweet 146 draithon said @Shack70 LOL isn't that the truth. They upped my rate so they could pay out their bonus's..... Tweet 147 Oblivion said Watching _Enchanted_. Thank god for wine. Tweet 148 ambermacarthur posted About to start watching FLOW the film with @chrisdick - Weblink - can't wait!!! Tweet 149 toyotaboy said @drewdomkus: I think your priority is to get the data back, if you restore to factory settings using the disc you'll probably overwrite it Tweet 150 drewdomkus said this iRiver is killing me! the accidental format gave it a UMS firmware and wiped out the factory settings. how the hell do i get it back? Tweet 151 Shack70 said @draithon banks suck...that's why they are all going under Tweet 152 dashdrum said Sent the boy out for a haircut, and came back totally clean-cut looking. He's had the messy mop look for a couple of years. Tweet 153 toyotaboy said watching the movie "the lakehouse", unbelievable they built that house on stilts just for the movie and tore it down, what a waste Tweet 154 fortheinsane said @Smorgy just take him into the shower with you. he can get clean Tweet 155 draithon said @Shack70 it just blows my mind. I have never been late & they have no reason to raise my rate. Soo angry, I have had this CC for 10+yrs too Tweet 156 Smorgy said @fortheinsane well which ever night you come over... we will watch more OZ Tweet 157 jessicamullen posted new episodes up at Weblink --- kelly has a new crush, @jasonstoddard can't run for congress now, +a new @bradaus vid Tweet 158 Oblivion said Man, Blackhawks are suckin' lately. So they had 2/3 of a good season. Oh well. Tweet 159 fortheinsane said @Smorgy it will be all good soon. i wanna watch more OZ!!!!!!!!!!! Tweet 160 Smorgy said got a puppy sitter so i can go have a shower Tweet 161 fortheinsane said @dashdrum haha, i thought thats what you were going for. well played Tweet 162 Oblivion said Ouch. sunburned dome is not happy. Mild headache. Foo. Tweet 163 dashdrum said @fortheinsane I was going for the Penthouse letters story. "I never thought these letters were true, until my boss bought breakfast... " Tweet 164 fortheinsane said @dashdrum nah, there are 5 of us here today.....its nice and quiet Tweet 165 Smorgy said Im soo behind in looking at the 365er's because of my stupid slow internet Tweet 166 dashdrum said @fortheinsane Are you and the boss the only ones in the office? Tweet 167 Oblivion said Odd, local weather stations are only showing ahighs around 60F today, but both of our thermometers showed 70+. Tweet 168 Oblivion said Shoot, running out of daylight to go pick up my water bottles and look for my glove. Tomorrow, I guess. Tweet 169 Shack70 said @draithon yeah I would just go elsewhere. No use doing business with a company you can't trust Tweet 170 WLBZ2 posted New England Trade Show Opens Weblink Tweet 171 Oblivion said Watching last night's Blackhawks/Oilers game. Each time the 'Hawks tie it up, the Oilers score again less than a minute later. WTF? Tweet 172 draithon said @Shack70 they said they would close the account and not reduce it. I am in the process of doing a balance transfer then I will close it Tweet 173 draithon said @Shack70 they said they will not switch it back because it is not in their best interest they said. Never late & never carried a big balance Tweet 174 Shack70 said @draithon Call them and ask them to switch it back or you are leaving them. They do that crap all the time. Tweet 175 fortheinsane said @Smorgy oh also, if you wanna send me emails at work, do it through my gmail, emails may be checked now...crazy Tweet 176 Smorgy said @fortheinsane watching a six feet, then ill fix the frame and do some cleaning Tweet 177 fortheinsane said @Smorgy whats your plan of attack for the day today? Tweet 178 fortheinsane posted Weblink Tweet 179 Smorgy said @fortheinsane hahahaa crazy Tweet 180 fortheinsane said @Smorgy the mormon campaign was just advertised on video hits, so it got crazy for about 1 minute....silly mormons Tweet 181 Smorgy said @Phreak the hippo seems to be making the dinosaur very happy Tweet 182 Smorgy said @fortheinsane he wanted to lie on my lap but the mac was there so he got onto of it instead :P Tweet 183 Phreak said @fortheinsane baby hippo has been holding his own for a couple of hours now, only spotted him on my way to bed-he'll be fine, i just know it Tweet 184 Smorgy said @fortheinsane Coop is still being cute Tweet 185 fortheinsane said @Phreak noooooooooo! dont let the t-rex get him! Tweet 186 fortheinsane said @Smorgy breakfast was good. i enjoyed it. work is going pretty good, im not bored at least, phones are dead, coop was cute this morning Tweet 187 closedblueyes said @Phreak haha! Tweet 188 Oblivion said 20.30 mi. 3:40:19 10:52 (avg) 11:23/10:08 = 12:30 negative split, fastest 9:21 - M20, 2,921 (kcal) HR 152 (avg) stopped time 9:56 #runners Tweet 189 Phreak posted Oh no poor baby hippo. Weblink Tweet 190 YvoLaLu said 30 min until post time with Jenna's mom and Grandma Tweet 191 draithon said I've not missed a payment either. So they raised my rate from 9.9 to 19.9. WTF The name of the bank is Direct Merchants Bank Stay away em!! Tweet 192 draithon said I just found out my CC decided I needed to help pay off their deadbeat assests so they raised my interest rate to 19.9. WTF I've not been L8 Tweet 193 Smorgy said @fortheinsane yeah and it's worse after sleeping. Hows work? and breakfast? Tweet 194 fortheinsane said @Smorgy hey, still got a headache Tweet 195 Smorgy said Woke up with such a headache, pain when opening eyes and cooper licking my face Tweet 196 draithon said @UberSchwarz no problem. I had a blast! I look forward to the next time we get together to take some more pictures. Emma rules BTW! Tweet 197 draithon said Just got home from a great afternoon of shooting pictures with @uberschwarz I look forward to the next shoot. Thanks again for a gr8 day Tweet 198 WLBZ2 posted UMaine Reports TB Case Weblink Tweet 199 cc_chapman said Sitting on the deck thinking about video journalism while the sizzle of steaks on the grill fills my ears.
Fetch Code
#!/usr/bin/perl use strict; use warnings; use Net::Twitter; my $twit = Net::Twitter->new({username=>"user", password=>"password" }); my $last_id=1363944982; #work this out later my @timeline = $twit->friends_timeline({count => 200, since_id => $last_id }); my $timeline; my $i; while ($timeline[0][$i]) { my $location=$timeline[0][$i]{'user'}{'location'}; my $screenname=$timeline[0][$i]{'user'}{'screen_name'}; my $msg=$timeline[0][$i]{'text'}; $msg=~s/https?:\/\/([-\w\.]+)+(:\d+)?(\/([\w\/_\.]*(\?\S+)?)?)?/link /g; print "$screenname said $msg\n"; $i++; }
Code Notes
$msg=~s/https?:\/\/([-\w\.]+)+(:\d+)?(\/([\w\/_\.]*(\?\S+)?)?)?/link /g;
Fetch Result
results in (chopped)
$VAR1 = [ [ { 'source' => 'web', 'favorited' => bless( do{\(my $o = 0)}, 'JSON::PP::Boolean' ), 'truncated' => $VAR1->[0][0]{'favorited'}, 'created_at' => 'Sat Mar 21 10:27:17 +0000 2009', 'text' => '@uberschwarz @draithon short HDR bit discussed on TFTTF #346', 'user' => { 'location' => 'Behind you...', 'followers_count' => 99, 'profile_image_url' => 'http://s3.amazonaws.com/twitter_production/profile_images/105270932/3371878294_7e0723920e_normal.jpg', 'protected' => $VAR1->[0][0]{'favorited'}, 'name' => 'Rabbi Bob', 'url' => 'http://www.rabbibob.com/', 'id' => 2955291, 'description' => 'degradable', 'screen_name' => 'rabbibob' }, 'in_reply_to_user_id' => 3708131, 'id' => 1365343447, 'in_reply_to_status_id' => undef, 'in_reply_to_screen_name' => 'UberSchwarz' } ] ]