Web pages with Mandarin text to speech

the Chinese character '?' and with the pinyin 'niàn' above itMy recent addition to this site of Mandarin text with audio brought to mind the issue of text-to-speech for Mandarin.

Here are some Web pages that allow you to input texts (albeit very brief ones in most cases) in Chinese characters and hear them pronounced in Mandarin and, in a few instances, Cantonese as well.

  • Oddcast (Sitepal). Although one of the options is for “Taiwanese,” texts are not read in that language (Hoklo) but rather in Mandarin.
  • Cling
  • Sinovoice. Be sure to enter the “code” number or the text won’t be spoken aloud.
  • Ekho
  • Iflytek. This is is particularly interesting because it can add Hanyu Pinyin above the Hanzi that are being read. Unfortunately, this does not work in Opera; but Firefox and IE are OK.

Does anyone have any favorites?

v for ü

Typing the letter v to produce ü is pretty standard in most Pinyin-related software — the letter v not being used in Pinyin except for loan words, and the letter ü not being found on traditional qwerty keyboards.

Here’s an official sign not far from Tian’anmen Square in Beijing that provides an example of an unconverted v.

official directional sign reading '?????? ZHINVQIAODONGHEYAN' in white letters against a blue background

Of course there’s the usual word-parsing trouble as well, which can indeed be tricky in some cases (but not so much that everythingneedstobewrittensolidlikethis).

This should be “Zh?n? Qiáo d?ng héyán” (?????? / ?????? / Weaver Girl’s Bridge, east bank) or perhaps “Zhinü Qiao Dong Heyan” or “ZHINÜ QIAO DONG HEYAN”.

Some people might not think this is worth categorizing as a problem. My position, however, is that government has an obligation to write things properly on its official signage. (If this were on some ad hoc sign put up privately it would still be interesting but less problematic.) So, if anyone’s OK with the V, would you also be OK with, say, “??????”?

OTOH, as mistakes go, at least v remains distinct, unlike when ü gets incorrectly written as u, which is so common in Taiwan that I don’t recall ever having seen a ü on official signage. (Pinyin has the following distinct pairs: and nu, and lu; nüe (rare) and lüe are also used but not nue or lue since the latter two sounds are not used in modern standard Mandarin.

major updates to Chinese KEY

key_softwareIf you are using one or more programs from the Chinese Key family of software, you should definitely update if you haven’t in the past few months, as some significant improvements have been made.

One of the things I particularly like about Key is that it has the rare virtue of following proper Pinyin orthography. So if you’re not familiar with it, you might want to give it or one of its sibling programs a 30-day test drive.

No, I get no kickbacks from the company; I just admire the software.

new tools for writing Pinyin

I’ve received word from software writers of not one but two useful new tools for writing Hanyu Pinyin with tone marks (i.e., not using Pinyin to enter Chinese characters but really writing Hanyu Pinyin texts).

P?ny?n Editor, by Bengt Moss-Petersen, is an online tool that currently works best with IE 6+ and Firefox.

click to visit the online Pinyin editor

(I made text much larger than the default size, since I had to reduce the image to make it fit in my blog. Users can choose among several sizes and fonts.)

And Pinyin Builder, by Wayne Kirk, is freeware for Windows systems.

click to visit the download page for Pinyin Builder

If you have an open Microsoft Office document, clicking Pinyin Builder’s “GO” button will insert your Pinyin text into that document. You don’t need to bother with copying and pasting.

In both of these, ü + tone mark is produced by v + tone number. Pinyin Builder also offers a combination using the CTRL key.

The tone number can be entered either immediately after the vowel or later in the syllable (e.g., zho1ng, zhong1, and zhon1g all yield “zh?ng”). Pinyin Editor also offers the option to simply click on buttons with the vowels and tone marks.

I hope people make frequent use of both of these terrific new tools.

Related:

convert Chinese characters to Unicode character references: javascript

I’ve had a spate of requests recently for the code for Pinyin.info’s tool that converts Chinese characters to Unicode numeric character references (i.e., something that converts, say, “????” into “漢語拼音”). Since I’m a believer in open-source work — and since people could find the code anyway if they look carefully enough in the Web page’s source code — I might as well publish it.

This tool can be very handy when making Web pages that use a variety of scripts. (It works on Cyrillic, etc., as well.) I often employ it myself.

Here’s the heart of the code:


function convertToEntities() {
var tstr = document.form.unicode.value;
var bstr = '';
for(i=0; i<tstr.length; i++)
{
if(tstr.charCodeAt(i)>127)
{
bstr += '&#' + tstr.charCodeAt(i) + ';';
}
else
{
bstr += tstr.charAt(i);
}
}
document.form.entity.value = bstr;
}

This sleek little bit of Javascript is originally by Steve Minutillo and used here on Pinyin.info with his permission. I may have tweaked the code a little myself; but that was so long ago I don’t remember well. (I’ve had the converter here for about five years.) Anyway, if you use this please acknowledge Steve’s authorship; and of course I always greatly appreciate links back to Pinyin.info.

If anyone knows how to do the same thing in PHP — preferably with no more code than used above, please let me know.

See also: separating Pinyin syllables: PHP code.

software for Shanghainese

Professor Qián N?iróng (Qian Nairong / ???) of Shanghai University has just issued free software to help with the writing of Shanghainese (???). People may now download the 1.3 MB zip file of the program.

Some examples:

shanghe ??
shanghehhehho ???/???????
whangpugang ???
suzouhhu???
shyti ??????
makshy ??????
bhakxiang ?????
dangbhang ???????
ghakbhangyhou ????????
cakyhangxiang ???????????
linfhakqin ???(????)
dhaojiangwhu ??????
aoshaoxhin ?????????????
ghe ????
kang ????
yin ??????
dia ?
whakji ??

The program offers two flavors of romanization. Here are some examples of the differences between the two styles:

New Folk Old Timers
makshy ??????
bhakxiang ?????
dangbhang ???????
ghakbhangyhou ????????
cakyhangxiang ???????????
linfhakqin ???(????)
mekshy ??????
bhekxian ?????
danbhan ???????
ghakbhanyhou ????????
cekyhanxian ???????????
linfhekqin ???(????)

Here’s a brief story on this:

Xiànzài, w?men zài w?ngluò zh?ng liáoti?n de shíhou yuèláiyuè du? de péngyou d?u k?ish? x?huan yòng Shàngh?ihuà. Dànshì y?ushíhou shìbushì juéde xi?ng bi?odá dehuà bùzh?dào z?nme d?, nòng de y?udi?n bùlúnbùlèi ne? Xiànzài, y? ge k?y? q?ngs?ng d?ch? Shàngh?ihuà de chéngxù ch?lai le.

J?ngguò li?ng nián n?lì, Shàngh?i dàxué Zh?ngwénxì Qián N?iróng jiàoshòu jí t? de yánji?sh?ng hé d?dàng zh?ngyú yú b?nyuè wánchéng le Shàngh?ihuà sh?rùf? de zhìzuò. Zhíde gu?nzhù de shì, zhè tào sh?rùf? hái b?okuò x?n-l?o li?ng ge b?nb?n, 45 suì y?shàng de l?o Shàngh?i rénhé niánq?ng y? dài de Shàngh?irén d?u k?y? zh?odào zìj? de “d?f?.”

Háishi tóngyàng 26 ge zìm? de jiànpán, 8 yuè 1 rì q? xiàzài le Shàngh?ihuà sh?rùf? zh?hòu, nín jiù k?y? t?ngguò sh?rù “linfhakqin” d?ch? “l?n wù q?ng,” sh?rù “dhaojiangwhu” d?ch? “táo jiànghu” d?ng yuánzh? yuán wèi de Shàngh?ihuà le. Zuóti?n, jìzh? tíqián xiàzài dào g?i ru?njiàn. Ànzhào sh?yòng shu?míng, yòng quánp?n de f?ngshì chángshì sh?rù “laoselaosy” zhèxi? zìm?, píngmù shàng, lìjí ch?xiàn le “l?o s?nl?o sì” (Shàngh?ihuà, yìsi shì “màil?o, ch?ng l?ochéng de yàngzi”).

Jùx?, yóuyú Shàngh?ihuà y? P?t?nghuà de dúf? y?usu?bùtóng, su?y? zài p?ny?n p?nxi? f?ngshì shàng háishi x?yào sh?yòng shu?míng de b?ngzhù. B?rú jìzh? f?xiàn, fánshì y? P?t?nghuà sh?ngm?, yùnm? xi?ngtóng de zì, zài Shàngh?ihuà sh?rùf? zh?ng zuìzh?ng yòng de háishi P?t?nghuà p?ny?n, bùtóng de zé c?iyòng Shàngh?ihuà sh?rùf? de p?nxi? f?ngshì. Rú “chéngu?ng” de “chén,” “hu?tou” de “tóu” d?u f?chéng zhuóy?n, Shàngh?ihuà p?ny?n sh?rùf? zh?ng yàozài sh?ngm? zh?ng ji? y? ge zìm? h, p?nchéng “shen,” “dhou;” fánshì rùsh?ng zì, zé zài p?ny?n hòu ji? zìm?k, rú “báixi?ng” de “bái” jiù p?nchéng bhek.

Bùguò, dàji? bùyào juéde tài nán. Jìzh? f?xiàn, Shàngh?ihuà sh?rùf? y? P?t?nghuà de sh?rùf? zuìdà xi?ngtóng zh? ch?zài yú, zh?yào liánxù sh?rù sh?ngm? hé yùnm? jiù k?y?, bùx? sh?rù sh?ngdiào. C?wài, Shàngh?ihuà p?ny?n sh?rù xìt?ng háiy?u lèisì “zhìnéng” y?udi?n, k?yòng su?lüè f?ngshì b? cíy? p?nxi? ch?lai.

Zh?chí Shàngh?ihuà sh?rùf? k?if? de Shàngh?i dàxué Zh?ngwénxì Qián N?iróng jiàoshòu gàosu jìzh?, zhè tào sh?rùf? bùj?n néng d?ch? Shàngh?ihuà dà cídi?n zh?ng 15,000 du? ge cítiáo, érqi? hái néng yòng Shàngh?ihuà p?ny?n d?ch? Shàngh?ihuà zh?ng sh?yòng zhe de, y? P?t?nghuà cíyì xi?ngtóng dàn y?y?n bùtóng de chángyòng cíy?. Rú “Huángp? Ji?ng” sh?rù “whangpugang” , “l?xi?ng” zéshì lixiang d?ng, gòngjì 10,000 du? ge cítiáo.

sources:

Find Chinese characters online by drawing them with your mouse

Nciku, a Web site that bills itself as “more than a dictionary,” has a nifty feature that allows users to find Chinese characters by drawing them with a mouse.

interface for the character-drawing tool

As you draw, possible character matches will appear in the box to the right of your drawing, with the results refined as your drawing progresses. You don’t need to know the canonical stroke order to get this to work, nor do your calligraphy skills need to be perfect, as this example shows.
, showing the results with a sloppily drawn ? (the 'pin' of 'Pinyin')

Once you see the correct character offered as a choice, click on it and it will be entered into the search box for the site’s online dictionary. This dictionary feature can handle multiple-character input and will even prompt you with likely choices to fill out your search.

via Keywords

Beginners should skip writing characters by hand, use computers instead: teachers

Sino-Platonic Papers is rereleasing a much more recent issue this week. This issue, no. 102 from March 2000, is by two university professors of Mandarin Chinese who advocate a “penless” approach for beginning students of Mandarin: i.e., students should use specially designed software on computers to write characters and not bother at first with learning to write characters by hand.
Here is the abstract:

In view of the fact that hand-writing Chinese characters is the most frustrating factor in Chinese language learning, we propose in this article a fairly radical approach that could bring a fundamental change into Chinese language teaching. Our suggestion is abolishing the requirement for writing Chinese characters by hand at the beginning of Chinese language learning process, and utilizing Chinese word-processing software instead to help the students

  1. bypass the difficulties entailed by character hand-writing,
  2. achieve an early development of writing skill, and
  3. reach a comprehensive improvement of their language competence.

In this article, we have offered our assessment on the following three aspects:

  1. The degree to which character hand-writing constitutes a major obstacle to early Chinese language learning;
  2. The benefits of using Chinese word-processing software in acquisition of Chinese language skills;
  3. The side effects from adopting this approach and the possibilities of their overcoming.

We believe this proposal addresses one of the most pressing issues in today’s Chinese language teaching, and should generate fruitful discussions among Chinese language teachers, as well as general interest in the field of foreign language teaching.

The full article is here: Penless Chinese Character Reproduction, by Theresa Jen and Ping Xu. This is a quick-loading HTML file.

The “penless” approach also has a website: Penless Chinese Language Learning: A Computer-Assisted Approach. Has anyone tried the software available there?