Tuesday, 4 March 2014

Using Coding to solve simple problems!

One of the major disadvantage of not being brought-up in my native place that I'm facing is that I don't know how to read and write in my mother toungue! It may sound strange to you, but there are a lot of people like me, who are unable to do so.

To make up for it, I decided to learn it, but learning the "A,B,C's" of malayalam isn't easy it seems, or so it is for me. I just can't get the variety of "double alphabets" in the language.

But, I have a problem, being part of the Mozilla Kerala community here, the facebook groups are often flooded with comments written in Malayalam, and I do want to read them, really!

Now, how to solve this problem?
While brainstorming for a quick solution to this, I remembered about Volunteers from SMC whom I had met in  the Wiki event at Alappuzha. I remember looking up for SMC's projects and found an interesting one : Silpa, an Indic language computing platform. While I couldn't think up a use for it at that point of time, it turns out to be a life saver for me now!
The Transliteration module of Shilpa was just what I wanted, and now I can read Malayalam transliterated into English. But copying Malayalam text every time I wanted to read turned out to be very tedious and I decided to make an extension for myself. Thankfully, the Silpa project had an API up and running, so it was a quick fix for me. I did get into trouble with Cross Domain requests and JSON - RPC. I do think the API should be made more RESTful.
After a little fumbling around I did manage to get the desired behavior. Now, I just have to select the text to be transliterated, right click to reveal a menu and then click on "Transliterate" option and voila! I can read Malayalam!

Here's a screencast in which i'm using the tool to understand more about the Grantham project by SMC.(View in full screen, change quality setting if fuzzy)


In case you're interested in the code behind this or want to use the add-on for yourselves(highly unlikely) go here : https://github.com/psbots/transliterate

1 comment:

  1. RESTification of SILPA is one of the project ideas of this year's Google Summer of Code. Details can be found here - http://wiki.smc.org.in/SoC/2014/Project_ideas