forked from DreamAfar/Rime-IME-for-iOS-iRime
-
Notifications
You must be signed in to change notification settings - Fork 0
/
sbhj.schema.yaml
226 lines (204 loc) · 5.83 KB
/
sbhj.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
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
# Rime schema settings
# encoding: utf-8
schema:
schema_id: sbhj
name: "声笔鹤简"
version: "9.5"
author:
- 戴石麟 <https://sbxlm.gitee.io>
dependencies:
- sbzdy
- sf
- shf
switches:
- name: ascii_mode
reset: 0
states: [ 中文, 西文 ]
- name: ascii_punct
states: [ 。,, ., ]
- name: full_shape
reset: 0
- name: zh_trad
reset: 0
states: [ 简体, 繁體 ]
- name: pro_char
reset: 0
states: [ 词组, 单字 ]
- name: auto_inline
reset: 1
engine:
processors:
- selector
- ascii_composer
- recognizer
- key_binder
- speller
- punctuator
- navigator
- express_editor
segmentors:
- ascii_segmentor
- matcher
- abc_segmentor
- affix_segmentor@sbzdy
- affix_segmentor@bihua_lookup
- affix_segmentor@pinyin_lookup
- affix_segmentor@zhlf_lookup
- punct_segmentor
- fallback_segmentor
translators:
- punct_translator
- table_translator
- lua_translator@date_translator
- lua_translator@time_translator
- lua_translator@number_translator
# - table_translator@sf #支持sf标点简词
# - table_translator@shf #支持shf标点简词
- table_translator@sbzdy #自定义词典
- table_translator@xhss
- table_translator@xhssb
- table_translator@bihua_lookup
- script_translator@pinyin_lookup
- script_translator@zhlf_lookup
filters:
- reverse_lookup_filter@bihua_reverse_lookup
- reverse_lookup_filter@pinyin_reverse_lookup
- reverse_lookup_filter@zhlf_reverse_lookup
- simplifier@prompt
- simplifier
- uniquifier
speller:
alphabet: "qwertasdfgzxcvbyuiophjklnmQWRTSDFGZXCVBYPHJKLNMAEUIO,;/.'"
initials: "qwrtsdfgzxcvbyphjklnm"
auto_select: true
auto_clear: max_length
max_code_length: 6
translator:
dictionary: sbhj
enable_user_dict: true
enable_encoder: true
enable_sentence: false
strict_spelling: true
enable_completion: false
encode_commit_history: true
single_selection: false # 默认为false,表示采用两次选重而不是单次选重
enable_filtering: false # 默认为true,表示sss码位滤掉掉多字词
stop_change: false # 默认为false,要进行调频和自动造词
delete_threshold: 10000 # 废词删除阈值,默认为10000
max_phrase_length: 5 # 自动造词长度限制,默认为5,建议不超过10
initial_quality: 1000
sf:
dictionary: sf
enable_user_dict: false
enable_encoder: false
enable_sentence: false
enable_completion: true
strict_spelling: true
initial_quality: 10
xhss:
dictionary: xhss
enable_user_dict: false
enable_encoder: false
enable_sentence: false
enable_completion: true
strict_spelling: true
initial_quality: 3
xhssb:
dictionary: xhssb
enable_user_dict: false
enable_encoder: false
enable_sentence: false
enable_completion: true
strict_spelling: true
initial_quality: 1
shf:
dictionary: shf
enable_user_dict: false
enable_encoder: false
enable_sentence: false
enable_completion: true
strict_spelling: true
initial_quality: 10
sbzdy:
tag: sbzdy
dictionary: sbzdy
enable_user_dict: false
enable_encoder: false
enable_sentence: false
strict_spelling: true
enable_completion: true
encode_commit_history: false
prefix: "u"
tips: "〔自定义〕"
simplifier:
opencc_config: s2t.json
option_name: zh_trad
bihua_lookup:
tag: bihua_lookup
dictionary: bihua
enable_user_dict: false
enable_encoder: false
enable_sentence: false
strict_spelling: true
enable_completion: true
encode_commit_history: false
tips: "〔笔画反查〕"
bihua_reverse_lookup:
tags: [ bihua_lookup ]
overwrite_comment: true
dictionary: sbhj
pinyin_lookup:
tag: pinyin_lookup
dictionary: sbpy
enable_user_dict: false
enable_encoder: false
enable_sentence: false
strict_spelling: true
enable_completion: true
encode_commit_history: false
prefix: "a"
tips: "〔拼音反查〕"
pinyin_reverse_lookup:
tags: [ pinyin_lookup ]
overwrite_comment: true
dictionary: sbhj
zhlf_lookup:
tag: zhlf_lookup
dictionary: zhlf
enable_user_dict: false
enable_encoder: false
enable_sentence: false
strict_spelling: true
enable_completion: true
encode_commit_history: false
prefix: "i"
tips: "〔两分反查〕"
zhlf_reverse_lookup:
tags: [ zhlf_lookup ]
overwrite_comment: true
dictionary: sbhj
punctuator:
import_preset: symbols
recognizer:
patterns:
sbzdy: "^u[qwrtsdfgzxcvbyphjklnm][a-z0-9]*$"
bihua_lookup: "^[aeiou][aeiou]*'?$"
pinyin_lookup: "^a[qwrtsdfgzxcvbyphjklnm][a-z]*'?$"
zhlf_lookup: "^i[qwrtsdfgzxcvbyphjklnm][a-z]*'?$"
retention: "^o[qwrtsdfgzxcvbyphjklnm0-9][a-z0-9]*$"
punct: '^\\([0-9]|10|[A-Za-z]+)$'
key_binder:
bindings:
- { when: has_menu, accept: Shift+Tab, send_sequence: "{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}{Page_Down}" }
- { when: paging, accept: Shift+Tab, send: Page_Up }
- { when: has_more, accept: Tab, send: Page_Down }
- { when: last_punct, accept: Return, send_sequence: "{Left}{space}{space}" }
- { when: last_punct, accept: Tab, send_sequence: "{Left}{Left}{space}{space}" }
- { when: ok_second, accept: Return, send_sequence: "{Left}{space}{space}" }
- { when: ok_third, accept: Return, send_sequence: "{Left}{Left}{space}{space}" }
- { when: ok_third, accept: Tab, send_sequence: "{Left}{space}{space}" }
- { when: ok_fourth, accept: Return, send_sequence: "{Left}{Left}{space}{space}" }
menu:
page_size: 6
alternative_select_keys: " aeuio"
alternative_select_labels: [" ",a,e,u,i,o]