Cangjie input method

Cangjie input method
Coding of "倉頡輸入法" (i.e. Cangjie method) in traditional Chinese characters
Traditional Chinese倉頡輸入法
Simplified Chinese仓颉输入法
Transcriptions
Standard Mandarin
Hanyu PinyinCāngjié Shūrùfǎ
Gwoyeu RomatzyhTsang Jye Shuruhfaa
Wade–GilesTs'ang1-chieh2 Shu1-ju4-fa3
IPA[tsʰáŋtɕjě ʂúɻûfà]
Yue: Cantonese
Yale RomanizationChōngkit Syūyahpfaat
JyutpingCong1kit3 Syu1jap6faat3
Southern Min
Hokkien POJChhong-kiat Su-ji̍p-hoat
Eastern Min
Fuzhou BUCChŏng-kĭk Sṳ̆-ĭk-huák

The Cangjie input method (Tsang-chieh input method, sometimes called Changjie, Cang Jie, Changjei or Chongkit) is a system for entering Chinese characters into a computer using a standard computer keyboard. In filenames and elsewhere, the name "Cangjie" is sometimes abbreviated as "cj".[citation needed]

The input method was invented in 1976 by Chu Bong-Foo, and named after Cangjie (Tsang-chieh), the mythological inventor of the Chinese writing system, at the suggestion of Chiang Wei-kuo, the former Defense Minister of Taiwan. Chu Bong-Foo released the patent for Cangjie in 1982, as he thought that the method should belong to Chinese cultural heritage. Therefore, Cangjie has become open-source software and is on every computer system that supports traditional Chinese characters, and it has been extended so that Cangjie is compatible with the simplified Chinese character set.

A Chinese keyboard in Shek Tong Tsui Municipal Services Building, Hong Kong with Cangjie hints printed on the lower-left corners of the keys. (Printed on the lower-right and upper-right corners are Dayi hints and Zhuyin symbols respectively.)

Cangjie is the first Chinese input method to use the QWERTY keyboard. Chu saw that the QWERTY keyboard had become an international standard, and therefore believed that Chinese-language input had to be based on it. Other, earlier methods use large keyboards with 40 to 2400 keys, except the Four-Corner Method, which uses only number keys.

Unlike the Pinyin input method, Cangjie is based on the graphological aspect of the characters: each graphical unit, called a "radical" (not to be confused with Kangxi radicals), is re-parented by a basic character component, 24 in total, each mapped to a particular letter key on a standard QWERTY keyboard. An additional "difficult character" function is mapped to the X key. Keys are categorized into four groups, to facilitate learning and memorization. Assigning codes to Chinese characters is done by separating the constituent "radicals" of the characters.

Overview

Keys and radicals

The basic character components in Cangjie are called radicals (字根) or letters (字母). There are 24 radicals but 26 keys; the 24 radicals (the basic shapes 基本字形) are associated with roughly 76 auxiliary shapes (輔助字形), which in many cases are either rotated or transposed versions of components of the basic shapes. For instance, the letter A (日) can represent either itself, the slightly wider 曰, or a 90° rotation of itself. (For a more complete account of the 76-odd transpositions and rotations than the ones listed below, see the article on Cangjie entry in Chinese Wikibooks.)

The 24 keys are placed in four groups:

GroupKeyName Auxiliary shapesExamples
Philosophical group A 日 sun
    • 明:日月
    • 書:中土日
    • 巴:日山
    • 眉:日竹月山
B 月 moon
    • 肝:月一十
    • 骨骨:月月月
    • 愛:月月心水
    • 望:卜月竹土
C 金 gold
    • 鏡:金卜廿山
    • 弟:金弓中竹
    • 亦:卜中弓金
    • 四:田金
D 木 wood
    • -{來}-:木人人
    • -{困}-:田木
    • -{才}-:木竹
    • -{也}-:心木
E 水 water
    • -{冰}-:戈一水
    • -{叉}-:水戈
    • -{沿}-:水金口
    • 求:戈十水
F 火 fire
    • -{秋}-:竹木火
    • -{照}-:日口火
    • -{絲}-:女火女戈火
    • -{不}-:一火
G 土 earth
    • -{走}-:土卜人
    • -{再}-:一土月
    • -{吉}-:土口
    • -{樹}-:木土廿戈
Stroke group H 竹 bamboo (斜 apostrophe)
    • -{簡}-:竹日弓日
    • -{白}-:竹日
    • -{乃}-:弓竹尸
    • -{爬}-:竹人日山
I 戈 dagger axe (點 dot)
    • -{我}-:竹手戈
    • -{之}-:戈弓人
    • -{廁}-:戈月金弓
    • -{去}-:土戈
J 十 ten (交 cruciform)
    • -{古}-:十口
    • -{辦}-:卜十大尸十
    • -{安}-:十女
    • -{萱}-:廿十一一
K 大 big (叉 cross)
    • -{爽}-:大大大大
    • -{右}-:大口
    • -{文}-:卜大
    • -{病}-:大一人月
L 中 center (緃 vertical)
    • -{仲}-:人中
    • -{引}-:弓中
    • -{書}-:中土日
    • -{褲}-:中戈十十
M 一 one (橫 horizontal)
    • -{旦}-:日一
    • -{羽}-:尸一尸戈一
    • -{原}-:一竹日火
    • -{空}-:十金一
N 弓 bow (鈎 hook)
    • -{弦}-:弓卜女戈
    • -{到}-:一土中弓
    • -{乃}-:弓竹尸
    • -{色}-:弓日山
    • -{飛}-:弓人竹廿人
Body parts

group

O 人 person
    • -{以}-:女戈人
    • -{象}-:弓日心人
    • -{海}-:水人田卜
    • -{仁}-:人一一
    • -{之}-:戈弓人
P 心 heart
    • -{思}-:田心
    • -{怕}-:心竹日
    • -{恭}-:廿金心
    • -{老}-:十大心
    • -{世}-:心廿
    • -{代}-:人戈心
    • -{砲}-:一口心口山
Q 手 hand
    • -{拿}-:人一口手
    • -{打}-:手一弓
    • -{承}-:弓弓手人
    • -{看}-:竹手月山
    • -{年}-:人手
R 口 mouth
    • -{吹}-:口弓人
    • -{石}-:一口
    • -{區}-:尸口口口
    • -{官}-:十口中口
Character shapes group S 尸 corpse (側 side)
    • -{尺}-:尸人
    • -{己}-:尸山
    • -{司}-:尸一口
    • -{臣}-:尸中尸中
    • -{耳}-;尸十
T 廿 twenty (並 parallel)
    • -{甘}-:廿一
    • -{昔}-:廿日
    • -{草}-:廿日十
    • -{虛}-:卜心廿一
    • -{皿}-:月廿
    • -{立}-:卜廿
U 山 mountain (仰 upward)
    • -{仙}-:人山
    • -{目}-:月山
    • -{孔}-:弓木山
    • -{朔}-:廿山月
V 女 woman (紐 twist)
    • -{威}-:戈竹一女
    • -{互}-:一女弓一
    • -{鼠}-:竹難女卜女
    • -{表}-:手一女
W 田 field ((方 square)
    • -{車}-:十田十
    • -{國}-:田戈口一
    • -{毋}-:田十
Y 卜 branch
    • -{外}-:弓戈卜
    • -{充}-:卜戈竹山
    • -{雨}-:一中月卜
    • -{巡}-:卜女女女
Collision/

Difficult key*

X 難 difficult
    • (1) disambiguation of Cangjie code decomposition collisions
    • (2) code for a "difficult-to-decompose" part
Special character key* Z 重 collision This key is used for entering special characters (no meaning on its own). In most cases, this key combined with other keys will produce Chinese punctuations (such as 。,、,「 」,『 』).

Note: Some variants use Z as a collision key instead of X. In those systems, Z has the name "collision" (重) and X has the name "difficult" (難); but the use of Z as a collision key is neither in the original Cangjie nor used in the current mainstream implementations. In other variants, Z may have the name "user-defined" (造) or some other name.

Wildcard Shift + 8 (*) Wildcard It can replace any in-between keys. It is useful for unknown guesses when you are sure about the first and last input. E.g. Input 竹*竹 will include: 身, 物, 秒, 第 (in this case, the output is identical to that of Simplified Cangjie.)

The auxiliary shapes of each Cangjie radical have changed slightly across different versions of the Cangjie method. Thus, this is one reason that different versions of the Cangjie method are not completely compatible.

Chu also provided alternate names for some letters according to their characteristics as a mnemonics. They form a rhyme to help learners memorize the letters, each group being in a line:

Original keys Mnemonics

日 月 金 木 水 火 土
竹 戈 十 大 中 一 弓
人 心 手 口
尸 廿 山 女 田 卜

日 月 金 木 水 火 土
斜 點 交 叉 縱 橫 鈎
人 心 手 口
側 並 仰 紐 方 卜

Keyboard layout

A typical keyboard layout for Cangjie method, based on United States keyboard layout. Note the non-standard use of Z as the collision key.

Basic rules

There are several general decomposition rules (拆字規則) that define how to analyze a character to arrive at a Cangjie code, as follows:

The rules are subject to various principles:

Examples

Typing Chinese with Cangjie input method version 5
Typing Chinese with Cangjie input method on an Android device

Exceptions

Some forms are always decomposed in the same way, whether the rules say they should be decomposed this way or not. The number of such exceptions is small:

Form Fixed decomposition
Version 2 Version 3 Version 5
門 (door) 日 弓 (AN)
目 (eye) 月 山 (BU)
鬼 (ghost) 竹 戈 (HI) 竹 戈 (HI) or HUI —
几 (small table) 竹 山 (HU) 竹 弓 (HN)
贏 (win) — 卜 口 月 月 弓 (YRBBN) 卜 弓 月 山 金 (YNBUC)
虍 (tiger [radical]) 卜 心 (YP)
亡 on top of 口 (吂) 卜 口 (YR) 卜 女 口 (YVR)
隹 (fowl) 人 土 (OG)
气 (air [radical]) 人 山 (OU) 人 弓 (ON) 人 一 弓 (OMN)
畿 minus the 田 女 戈 (VI)
鬥 (compete) 中 弓 (LN)
阝 (mound or city radical) 弓 中 (NL)

Some forms cannot be decomposed. They are represented by an X, which is the 難 key on a Cangjie keyboard.

FormFixed decomposition (v5)
臼竹 難 (HX)
與竹 難 卜 金 (HXYC)
興竹 難 月 金 (HXBC)
盥竹 難 月 廿 (HXBT)
姊女 中 難 竹 (VLXH)
齊卜 難 (YX)
兼廿 難 金 (TXC)
鹿戈 難 心 (IXP)
身竹 難 竹 (HXH)
卍弓 難 (NX)
黽口 難 山 (RXU)
龜弓 難 山 (NXU)
廌戈 難 火 (IXF)
慶戈 難 水 (IXE)
淵水 中 難 中 (ELXL)
肅中 難 (LX)

Early development

Initially, the Cangjie input method was not intended to produce a character in any character set. Instead, it was part of an integrated system consisting of the Cangjie input rules and a Cangjie controller board. This controller board contains character generator firmware, which dynamically generates Chinese characters from Cangjie codes when characters are output, using the hi-res graphics mode of the Apple II. In the preface of the Cangjie user's manual, Chu Bong-Foo wrote in 1982:

[in translation]
In terms of output: The output and input, in fact, [form] an integrated whole; there is no reason that [they should be] dogmatically separated into two different facilities.… This is in fact necessary.…

Demonstration of character generator Mingzhu's capability to generate characters according to the codes. The first character is 𮨻 (⿰飠它), which denotes a kind of soup in Xuzhou cuisine.

In this early system, when the user types "yk", for example, to get the Chinese character 文, the Cangjie codes do not get converted to any character encoding and the actual string "yk" is stored. The Cangjie code for each character (a string of 1 to 5 lowercase letters plus a space) was the encoding of that particular character.

A particular "feature" of this early system is that, if one sends random lowercase words to it, the character generator will attempt to construct Chinese characters according to the Cangjie decomposition rules, sometimes causing strange, unknown characters to appear. This unintended feature, "automatic generation of characters", is described in the manual and is responsible for producing more than 10,000 of the 15,000 characters that the system can handle. The name Cangjie, evocative of the creation of new characters, was indeed apt for this early version of Cangjie.

The presence of the integrated character generator also explains the historical necessity for the existence of the "X" key, which is used for the disambiguation of decomposition collisions: because characters are "chosen" when the codes are "output", every character that can be displayed must in fact have a unique Cangjie decomposition. It would not make sense—nor would it be practical—for the system to provide a choice of candidate characters when a random text file is displayed, as the user would not know which of the candidates is correct.

Issues

Steep learning curve

Cangjie was designed to be an easy-to-use system to help promote the use of Chinese computing. However, many users find Cangjie is difficult to learn and use, with many difficulties caused by poor instruction.[citation needed]

With enough practice, users can overcome the above problems. Typical touch-typists can type Chinese at 25 characters per minute (cpm), or better, using Cangjie, despite having difficulty remembering the list of auxiliary shapes or the decomposition rules. Experienced Cangjie typists can reportedly attain a typing speed from 60 cpm to over 200 cpm.[citation needed]

According to Chen Minzheng, his teaching experience at Longtian Elementary School in Taitung in 1990, the average typing speed of children was 90 words per minute, and some children even reached more than 130 words per minute.[better source needed]

Limitations in implementation

The decomposition of a character depends on a predefined set of "standard shapes" (標準字形). However, as many variations of Cangjie exist in different countries, the standard shape of a certain character in Cangjie is not always the one the user has learnt before. Learning Cangjie then entails learning not only Cangjie itself but also unfamiliar standard shapes for some characters. The Cangjie input method editor (IME) does not handle mistakes in decomposition except by informing the user (usually by beeping) that there is a mistake. However, Cangjie is originally designed to assign different codes to different variants of a character. For example, in the Cangjie provided on Windows, the code for 產 is YHHQM, which corresponds not to the shape of this character but to another variant, 産. This is a problem resulting from the implementation of Cangjie on Windows. In the original Cangjie, 產 should be YKMHM (the first part is 文) while 産 is YHHQM (the first part is 产).

Punctuation marks are not geometrically decomposed, but rather given predefined codes that begin with ZX followed by a string of three letters related to the ordering of the characters in the Big5 code. (This set of codes was added to Cangjie on the traditional Chinese version of Windows 95. On Windows 3.1, Cangjie did not have a set of codes for punctuation marks.) Typing punctuation marks in Cangjie thus becomes a frustrating exercise involving either memorization or pick-and-peck. However, this is solved on modern systems through accessing a virtual keyboard on screen (On Windows, this is activated by pressing Ctrl + Alt + comma key).

Commonly-made errors include not considered as alternative codes. For example, if one does not decompose 方 from top to bottom into YHS, but instead type YSH according to stroke order, Cangjie does not return the character 方 as a choice.

Since Cangjie requires all 26 keys of the QWERTY keyboard, it cannot be used to input Chinese characters on feature phones, which have only a 12-key keypad. Alternative input methods, such as Zhuyin, 5-stroke (or 9-stroke by Motorola), and the Q9 input method, are used instead.

Versions

The Cangjie input method is commonly said to have gone through five generations (commonly referred to as "versions" in English), each of which is slightly incompatible with the others. Currently, version 3 is the most common and supported natively by Microsoft Windows. Version 5, supported by the Free Cangjie IME and previously the only Cangjie supported by SCIM, represents a significant minority method and is supported by iOS, and supported by Microsoft Windows since Windows Vista. Before Windows Vista, Microsoft Windows needs to install HKSCS update to support Cangjie Version 5.

The early Cangjie system supported by the Zero One card on the Apple II was Version 2; Version 1 was never released.

The Cangjie input method supported on the classic Mac OS resembles both Version 3 and Version 5.

Version 5, like the original Cangjie input method, was created directly by Chu. He had hoped that the release of Version 5, originally slated to be Version 6, would bring an end to the "more than ten versions of Cangjie input method" (slightly incompatible versions created by different vendors).

Version 6 has not yet been released to the public, but is being used to create a database which can accurately store every historical Chinese text.

Variations

Most modern implementations of Cangjie input method editors (IME) provide various convenient features:

Besides the wildcard key, many of these features are convenient for casual users but unsuitable for touch-typists because they make the Cangjie IME unpredictable.

There have also been various attempts to "simplify" Cangjie one way or another:

Applications

Many researchers have discussed ways to decompose Chinese characters into their major components, and tried to build applications based on the decomposition system. The idea can be referred to as the study of the Genes of Chinese Characters [zh]. Cangjie codes offer a basis for such an endeavour. Academia Sinica in Taiwan and Jiaotong University in Shanghai have similar projects as well.

One direct application of the use of decomposed characters is the possibility of computing the similarities between different Chinese characters. The Cangjie input method offers a good starting point for this kind of application. By relaxing the limit of five codes for each Chinese character and adopting more detailed Cangjie codes, visually similar characters can be found by computation. Integrating this with pronunciation information enables computer-assisted learning of Chinese characters.

See also

References

Citations

  1. ↑ A spelling used as filename on ETen Chinese System.
  2. ↑ Chu, Chyi-Hwa (朱麒華) (1 February 2012). "教育科技的專利與普及". National Academy for Educational Research e-Newsletter (in Chinese). Archived from the original on 25 August 2022. Retrieved 14 December 2022.
  3. ↑ Chu Bong-foo (朱邦復). "智慧之旅". 開放文學 (in Traditional Chinese). Archived from the original on 19 October 2017. Retrieved 8 June 2017.
  4. 1 2 "倉頡輸入法/輔助字形 - 维基教科书,自由的教学读本". zh.wikibooks.org (in Chinese). Retrieved 2024-12-06.
  5. ↑ 零壹科技股份有限公司 1984, p. 13
  6. ↑ 零壹科技股份有限公司 1984, p. 2
  7. ↑ 零壹科技股份有限公司 1984, pp. 2–3
  8. ↑ "倉頡取碼規則及方法" [Cangjie code retrieval rules and methods]. Friends of Cangjie (in Chinese). 1997–2002. Archived from the original on 1 January 2019. Retrieved 2 October 2020.
  9. ↑ https://www.chinesecj.com/forum/forum.php?mod=attachment&aid=MTIwNnw1MjMxNmQwMXwxNjg2OTYyNTE4fDB8MTUwMjQ%3D page 58
  10. ↑ "FAQ: How to enable Cantonese characters and Unicode CKJ extensions in Windows :: Pinyin Joe". www.pinyinjoe.com. Retrieved 2025-04-26.
  11. ↑ "漢字構形資料庫" [Chinese Character Configuration Database]. Chinese Document Processing Lab (in Chinese). 2013. Archived from the original on 27 July 2020. Retrieved 2 October 2020.
  12. ↑ 上海交通大學漢字編碼組,上海漢語拼音文字研究組編著。漢字信息字典。北京市科學出版社,1988。
  13. ↑ 宋柔,林民,葛詩利。漢字字形計算及其在校對系統中的應用,小型微型計算機系統,第29卷第10期,第1964至1968頁,2008。
  14. ↑ Liu, Chao-Lin; Lai, Min-Hua; Tien, Kan-Wen; Chuang, Yi-Hsuan; Wu, Shih-Hung; Lee, Chia-Ying (2011). "Visually and phonologically similar characters in incorrect Chinese words: Analyses, identification, and applications". ACM Transactions on Asian Language Information Processing. 10 (2): 1–39. doi:10.1145/1967293.1967297. S2CID 7288710.

Sources