Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
100 changes: 83 additions & 17 deletions data/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,12 @@ set(

set(
DICTS_GENERATED
TWPhrases
TWPhrasesRev
CNVocabulary
HKVocabulary
MOVocabulary
MYVocabulary
SGVocabulary
TWVocabulary
TWVariantsRev
HKVariantsRev
JPVariantsRev
Expand Down Expand Up @@ -52,32 +56,78 @@ foreach(DICT ${DICTS_GENERATED})
endforeach(DICT)

set(
DICT_TWPhrases_GENERATING_INPUT
${DICT_DIR}/TWPhrasesIT.txt
${DICT_DIR}/TWPhrasesName.txt
${DICT_DIR}/TWPhrasesOther.txt
DICT_CNVocabulary_GENERATING_INPUT
${DICT_DIR}/CNVocabSciTech.txt
${DICT_DIR}/CNVocabToponym.txt
${DICT_DIR}/CNVocabOthers.txt
)
set(
DICT_TWPhrases_GENERATING_COMMAND
${DICT_MERGE_BIN} ${DICT_TWPhrases_GENERATING_INPUT} TWPhrases.txt
DICT_CNVocabulary_GENERATING_COMMAND
${DICT_MERGE_BIN} ${DICT_CNVocabulary_GENERATING_INPUT} CNVocabulary.txt
)

set(
DICT_TWVariantsRev_GENERATING_INPUT
${DICT_DIR}/TWVariants.txt
DICT_HKVocabulary_GENERATING_INPUT
${DICT_DIR}/HKVocabSciTech.txt
${DICT_DIR}/HKVocabToponym.txt
${DICT_DIR}/HKVocabOthers.txt
)
set(
DICT_TWVariantsRev_GENERATING_COMMAND
${DICT_REVERSE_BIN} ${DICT_TWVariantsRev_GENERATING_INPUT} TWVariantsRev.txt
DICT_HKVocabulary_GENERATING_COMMAND
${DICT_MERGE_BIN} ${DICT_HKVocabulary_GENERATING_INPUT} HKVocabulary.txt
)

set(
DICT_MOVocabulary_GENERATING_INPUT
${DICT_DIR}/MOVocabSciTech.txt
${DICT_DIR}/MOVocabToponym.txt
${DICT_DIR}/MOVocabOthers.txt
)
set(
DICT_MOVocabulary_GENERATING_COMMAND
${DICT_MERGE_BIN} ${DICT_MOVocabulary_GENERATING_INPUT} MOVocabulary.txt
)

set(
DICT_MYVocabulary_GENERATING_INPUT
${DICT_DIR}/MYVocabSciTech.txt
${DICT_DIR}/MYVocabToponym.txt
${DICT_DIR}/MYVocabOthers.txt
)
set(
DICT_MYVocabulary_GENERATING_COMMAND
${DICT_MERGE_BIN} ${DICT_MYVocabulary_GENERATING_INPUT} MYVocabulary.txt
)

set(
DICT_TWPhrasesRev_GENERATING_INPUT
${DICT_GENERATED_DIR}/TWPhrases.txt
DICT_SGVocabulary_GENERATING_INPUT
${DICT_DIR}/SGVocabSciTech.txt
${DICT_DIR}/SGVocabToponym.txt
${DICT_DIR}/SGVocabOthers.txt
)
set(
DICT_TWPhrasesRev_GENERATING_COMMAND
${DICT_REVERSE_BIN} ${DICT_TWPhrasesRev_GENERATING_INPUT} TWPhrasesRev.txt
DICT_SGVocabulary_GENERATING_COMMAND
${DICT_MERGE_BIN} ${DICT_SGVocabulary_GENERATING_INPUT} SGVocabulary.txt
)

set(
DICT_TWVocabulary_GENERATING_INPUT
${DICT_DIR}/TWVocabSciTech.txt
${DICT_DIR}/TWVocabToponym.txt
${DICT_DIR}/TWVocabOthers.txt
)
set(
DICT_TWVocabulary_GENERATING_COMMAND
${DICT_MERGE_BIN} ${DICT_TWVocabulary_GENERATING_INPUT} TWVocabulary.txt
)

set(
DICT_TWVariantsRev_GENERATING_INPUT
${DICT_DIR}/TWVariants.txt
)
set(
DICT_TWVariantsRev_GENERATING_COMMAND
${DICT_REVERSE_BIN} ${DICT_TWVariantsRev_GENERATING_INPUT} TWVariantsRev.txt
)

set(
Expand Down Expand Up @@ -162,19 +212,35 @@ foreach(DICT ${DICTS})
endforeach(DICT)

set(CONFIG_FILES
config/hk2cnp.json
config/hk2myp.json
config/hk2s.json
config/hk2sgp.json
config/hk2t.json
config/jp2t.json
config/s2cnp.json
config/s2hk.json
config/s2hkp.json
config/s2mop.json
config/s2myp.json
config/s2sgp.json
config/s2t.json
config/s2tw.json
config/s2twp.json
config/t2cnp.json
config/t2hk.json
config/t2hkp.json
config/t2jp.json
config/t2mop.json
config/t2myp.json
config/t2s.json
config/t2sgp.json
config/t2tw.json
config/t2twp.json
config/tw2cnp.json
config/tw2myp.json
config/tw2s.json
config/tw2sp.json
config/tw2sgp.json
config/tw2t.json
)

Expand Down
38 changes: 38 additions & 0 deletions data/config/hk2cnp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"name": "Traditional Chinese (Hong Kong standard) to Simplified Chinese, with Mainland China Vocabulary",
"segmentation": {
"type": "mmseg",
"dict": {
"type": "ocd2",
"file": "CNVocabulary.ocd2"
}
},
"conversion_chain": [{
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "HKVariantsRevPhrases.ocd2"
}, {
"type": "ocd2",
"file": "HKVariantsRev.ocd2"
}]
}
}, {
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "TSPhrases.ocd2"
}, {
"type": "ocd2",
"file": "TSCharacters.ocd2"
}]
}
}, {
"dict": {
"type": "ocd2",
"file": "CNVocabulary.ocd2"
}
}]
}
38 changes: 38 additions & 0 deletions data/config/hk2myp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"name": "Traditional Chinese (Hong Kong standard) to Simplified Chinese, with Malaysia Vocabulary",
"segmentation": {
"type": "mmseg",
"dict": {
"type": "ocd2",
"file": "SGVocabulary.ocd2"
}
},
"conversion_chain": [{
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "HKVariantsRevPhrases.ocd2"
}, {
"type": "ocd2",
"file": "HKVariantsRev.ocd2"
}]
}
}, {
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "TSPhrases.ocd2"
}, {
"type": "ocd2",
"file": "TSCharacters.ocd2"
}]
}
}, {
"dict": {
"type": "ocd2",
"file": "SGVocabulary.ocd2"
}
}]
}
38 changes: 38 additions & 0 deletions data/config/hk2sgp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"name": "Traditional Chinese (Hong Kong standard) to Simplified Chinese, with Singapore Vocabulary",
"segmentation": {
"type": "mmseg",
"dict": {
"type": "ocd2",
"file": "SGVocabulary.ocd2"
}
},
"conversion_chain": [{
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "HKVariantsRevPhrases.ocd2"
}, {
"type": "ocd2",
"file": "HKVariantsRev.ocd2"
}]
}
}, {
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "TSPhrases.ocd2"
}, {
"type": "ocd2",
"file": "TSCharacters.ocd2"
}]
}
}, {
"dict": {
"type": "ocd2",
"file": "SGVocabulary.ocd2"
}
}]
}
16 changes: 16 additions & 0 deletions data/config/s2cnp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"name": "Simplified Chinese to Simplified Chinese, with Mainland China Vocabulary",
"segmentation": {
"type": "mmseg",
"dict": {
"type": "ocd2",
"file": "CNVocabulary.ocd2"
}
},
"conversion_chain": [{
"dict": {
"type": "ocd2",
"file": "CNVocabulary.ocd2"
}
}]
}
33 changes: 33 additions & 0 deletions data/config/s2hkp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"name": "Simplified Chinese to Traditional Chinese (Hong Kong standard), with Hong Kong Vocabulary",
"segmentation": {
"type": "mmseg",
"dict": {
"type": "ocd2",
"file": "HKVocabulary.ocd2"
}
},
"conversion_chain": [{
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "STPhrases.ocd2"
}, {
"type": "ocd2",
"file": "STCharacters.ocd2"
}]
}
}, {
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "HKVocabulary.ocd2"
}, {
"type": "ocd2",
"file": "HKVariants.ocd2"
}]
}
}]
}
33 changes: 33 additions & 0 deletions data/config/s2mop.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"name": "Simplified Chinese to Traditional Chinese (Hong Kong standard), with Macau Vocabulary",
"segmentation": {
"type": "mmseg",
"dict": {
"type": "ocd2",
"file": "MOVocabulary.ocd2"
}
},
"conversion_chain": [{
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "STPhrases.ocd2"
}, {
"type": "ocd2",
"file": "STCharacters.ocd2"
}]
}
}, {
"dict": {
"type": "group",
"dicts": [{
"type": "ocd2",
"file": "MOVocabulary.ocd2"
}, {
"type": "ocd2",
"file": "HKVariants.ocd2"
}]
}
}]
}
16 changes: 16 additions & 0 deletions data/config/s2myp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"name": "Simplified Chinese to Simplified Chinese, with Malaysia Vocabulary",
"segmentation": {
"type": "mmseg",
"dict": {
"type": "ocd2",
"file": "MYVocabulary.ocd2"
}
},
"conversion_chain": [{
"dict": {
"type": "ocd2",
"file": "MYVocabulary.ocd2"
}
}]
}
16 changes: 16 additions & 0 deletions data/config/s2sgp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"name": "Simplified Chinese to Simplified Chinese, with Singapore Vocabulary",
"segmentation": {
"type": "mmseg",
"dict": {
"type": "ocd2",
"file": "SGVocabulary.ocd2"
}
},
"conversion_chain": [{
"dict": {
"type": "ocd2",
"file": "SGVocabulary.ocd2"
}
}]
}
Loading