forked from rime/rime-jyutping
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhkcantonese.schema.yaml
113 lines (104 loc) · 2.99 KB
/
hkcantonese.schema.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
# Rime schema
# encoding: utf-8
schema:
schema_id: hkcantonese
name: 香港廣東話拼音
version: "0.2"
author:
- Matthew Wo <[email protected]>
description: |
耶魯粵語拼音方案
https://github.com/rime/rime-jyutping
dependencies:
- luna_pinyin
switches:
- name: ascii_mode
reset: 0
states: [ 中文, 西文 ]
- name: full_shape
states: [ 半角, 全角 ]
- name: simplification
states: [ 漢字, 汉字 ]
- name: ascii_punct
states: [ 。,, ., ]
engine:
processors:
- ascii_composer
- recognizer
- key_binder
- speller
- punctuator
- selector
- navigator
- express_editor
segmentors:
- ascii_segmentor
- matcher
- abc_segmentor
- punct_segmentor
- fallback_segmentor
translators:
- punct_translator
- script_translator
- reverse_lookup_translator
filters:
- simplifier
- uniquifier
speller:
alphabet: zyxwvutsrqponmlkjihgfedcba
delimiter: " '"
algebra:
- derive/aa/a/ # 煆 haa -> ha
- derive/eo/eu/ # 蹲 deon -> deun
- derive/oe/eu/ # 剁 doek -> deuk
- derive/eot/ut/ # 出 ceot -> chut
- derive/eon/un/ # 論 leon -> sun
- derive/eon/hun/ # 純 seon -> shun
- derive/yun/uen/ # 算 syun -> suen
- derive/u/ue/ # 冤 yun -> yuen
- derive/^jy/y/ # 粵 jyut -> yut
- derive/^j/y/ # 用 jung -> yung
- derive/^z/j/ # 抓 zaa -> ja
- derive/^c/ch/ # 叉 caa -> cha
- derive/^gw/g/ # 廣 gwong -> gong
- derive/eu$/iu/ # 掉 deu -> diu
- derive/em$/im/ # 舐 lem -> lim
- derive/ep$/ip/ # 夾 gep -> gip
- derive/eoi$/ui/ # 最 zeoi -> jui
- derive/yu$/hu/ # 舒 syu -> shu
- derive/un$/oon/ # 盤 pun -> poon
- derive/eong$/eung/ # 將 zeong -> zeung
- derive/(.)a$/$1h/ # 呀 aa -> ah
- derive/^[nl](.)$/l$1/ # 呢 ne -> le
- derive/^ng([a-z]*)/$1/ # 牙 ngaa -> aa
- derive/^([a-z]*)yu$/$1u/ # 豬 zyu -> ju
- derive/^([a-z]*)ou$/$1o/ # 好 hou -> ho
- derive/^(.)o$/$1oh/ # 科 fo -> foh
- derive/^[nl]([a-z]*)/l$1/ # 難 naan -> laan
- abbrev/^([a-z]).+$/$1/ # 首字母簡拼
- abbrev/^(ng).+$/$1/ # 聲母簡拼
- abbrev/^(ch).+$/$1/ # 聲母簡拼
- abbrev/^([gk]w).+$/$1/ # 聲母簡拼
translator:
dictionary: jyutping
prism: yale
spelling_hints: 10
comment_format: &comment_rules
reverse_lookup:
dictionary: luna_pinyin
prefix: "`"
suffix: "'"
tips: 〔拼音〕
preedit_format:
- xform/([nl])v/$1ü/
- xform/([nl])ue/$1üe/
- xform/([jqxy])v/$1u/
comment_format: *comment_rules
punctuator:
import_preset: default
key_binder:
import_preset: default
recognizer:
import_preset: default
patterns:
reverse_lookup: "`[a-z]*'?$"