December 30, 2004

the pinyinator

Hallelujah, it is a dream come true. I've been wanting something like this for almost a decade. Every so often I would get inspired to learn how to read and write Chinese. Then, for about a week, I would digest any Chinese characters I could find, diligently looking up unknown or forgotten words and etching character, pinyin and definition into my journal. No more! Enter the pinyinator.

What is the pinyinator?

The pinyinator is a tool for translating both traditional and simplified Chinese, line by line, into pinyin. It is especially helpful for illiterati wishing (or having) to sing Chinese hymns. But wait, there's more! Simply moving your mouse over a character will pop-up a definition, as well as the character in traditional and simplified Chinese. Admittedly, it runs slow, but I have a couple tweaks in mind which should speed things up, i.e., grabbing the definitions and pinyin in one database call instead of character-by-character.

Here are a few things to pinyinate:

神愛世人、甚至將他的獨生子賜給他們、叫一切信他的、不至滅亡、反得永生。 -約翰福音 3:16

耶穌愛我我知道,
因有聖書告訴我。
凡小孩子主牧養,
我雖軟弱主強壯。
主耶穌愛我,(3x)
有聖書告訴我。

兵者,国之大事,死生之地,存亡之道,不可不察也。

印度洋地震和海啸迄今已造成12.5万多人死亡,其中在印度尼西亚的死亡人数已接近8万,12月29日晚,外交部长李肇星紧急召开会议,商定大幅增加中国政府对受灾国家的物资和现汇援助。

This project would have been impossible without open source information and software. The core of the pinyinator is Paul Denisowski's CEDICT Chinese-English Dictionary. The dictionary, in UTF-8 format, was imported into MySQL with assistance from Christopher Sexton's phpCEDICT code. The pinyinator also relies util.php from phpCEDICT. Specifically, it calls Scott Reynen's UTF-8 to Unicode conversion tools as well as Konrad Mitchell Lawson's pinyin to unicode function.

What's up ahead? It would be nice if characters could be saved in a user account to be retrieved for things like flashcard use (see my earlier posts on the Leitner cardfile system). This is a major endeavor in itself and may have to wait another decade... It would be nice if I could email the system with some Chinese and have it respond with pinyinated and defined text. It would be nice if the system could periodically email me with Chinese snippets, verses or sayings pinyinated and defined. A good source for this would have been zhongwen.com's extensive list of Chinese material. Unfortunately, most of the text there is stored in a graphic. Chinaknowledge, a site located in Germany, uses UTF-8 encoding, which will work. It hosts a large volume of Confucian and Doaist literature, among other things.

Posted by torque at December 30, 2004 11:19 PM | TrackBack
Comments

i'm glad you found the utf8 to unicode stuff helpful. this looks like a useful tool. my only problem was the source text moving around as the definition lists grew larger or smaller - at least in firefox.

Posted by: scott reynen at January 8, 2005 11:51 AM

Hi,

I found your pinyinator on the web after trawling for hours, looking for a way to translate from english to pinyin.

I think it's a terrific app, but when i tried to load it this morning, aaargh, it couldn't be found!! please don't tell me you've removed it....PLEASE!

Posted by: Fred Williamson at February 18, 2005 8:10 PM

Very nice little tool. Will come in handy for reading, and for Hymns too!

Posted by: Jason at June 21, 2005 5:12 PM

Good job!

Posted by: Markus at December 11, 2006 11:05 AM

Good job!

Posted by: Markus at December 12, 2006 7:58 PM
Post a comment









Remember personal info?