I’ve been so bored not tinkering lately, when I saw the follow tweet today from @tsimonite, I just had to have a 5 minute play:
So here was my thought process:
– hmm, Google has a language detection API, so we can just pass the tweets through that and filter on language; it’s probably easiest for a proof of concept to just filter a person’s Twitter RSS feed…
– now where’s the API? Search for google language detection api and turn up Google AJAX Language API documentation.
– ah, buggrit, too much like hard work – I’m sure I built a a pipe round this before: search for language detection yahoo pipe… This’ll do nicely:
(For reference, the call to the API is simply:
So not that hard at all! ;-)
Clone the pipe, and pop it into another pipe that accepts a Twitter RSS feed:
Hmm… that’s probably too hard for most people to use, expecting people to be able to find someone’s RSS twitter feed… so make it easy – create the feed URL from a Twitter username:
Here’s the pipe: English tweets only.
(Just by the by, it took considerably longer to write this post than it did from seeing the tweet to publishing the pipe…)
PS What would be really nice would be for a Twitter client, such as Tweetdeck, to offer its own plugin architecture/API, so I could create a little routine based on something like the above to provide a language filter for incoming tweets, maybe on a per column basis, as required (or not).