kalixlouiis commited on
Commit
08ccfb9
·
verified ·
1 Parent(s): c45e7dd

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +150 -0
README.md ADDED
@@ -0,0 +1,150 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ language:
4
+ - my
5
+ pipeline_tag: feature-extraction
6
+ tags:
7
+ - myanmar
8
+ - burmese
9
+ - nlp
10
+ - embeddings
11
+ - semantic
12
+ - fasttext
13
+ library_name: fasttext
14
+ datasets:
15
+ - DatarrX/myX-Mega-Corpus
16
+ ---
17
+
18
+ # myX-Semantic: A High-Performance Burmese Word Embedding Model
19
+
20
+ ## ၁။ နိဒါန်း (Introduction)
21
+ **myX-Semantic** သည် မြန်မာဘာသာစကား၏ အနက်အဓိပ္ပာယ် ဆက်စပ်မှုများကို ကိန်းဂဏန်းများအဖြစ် ပြောင်းလဲပေးနိုင်သော (Word Embedding) မော်ဒယ်တစ်ခုဖြစ်သည်။ ဤမော်ဒယ်သည် မြန်မာစာသားများအတွင်းရှိ စကားလုံးများ၏ ရှေ့နောက်ဆက်စပ်မှု (Contextual relationships) နှင့် အဓိပ္ပာယ်တူညီမှု (Semantic similarity) များကို နားလည်နိုင်ရန် FastText (Skip-gram) နည်းပညာကို အခြေခံ၍ တည်ဆောက်ထားခြင်းဖြစ်သည်။
22
+
23
+ ## ၂။ ထုတ်လုပ်သူ (Developer Information)
24
+ ဤ Model ကို [**DatarrX (Myanmar Open Source NGO)**](https://huggingface.co/DatarrX) မှ ထုတ်ဝေခြင်းဖြစ်ပြီး [**Khant Sint Heinn (Kalix Louis)**(https://huggingface.co/kalixlouiis)] မှ အဓိက ဖန်တီးတည်ဆောက်ထားခြင်း ဖြစ်ပါသည်။ မြန်မာဘာသာစကားဆိုင်ရာ သဘာဝဘာသာစကား စီမံဆောင်ရွက်မှု (Natural Language Processing - NLP) အရင်းအမြစ်များကို ပိုမိုပေါများလာစေရန် ရည်ရွယ်၍ ဖန်တီးခဲ့ခြင်းဖြစ်သည်။
25
+
26
+ ## ၃။ အသုံးပြုနိုင်သည့် နယ်ပယ်များ (Intended Use)
27
+ myX-Semantic ကို အောက်ပါ NLP လုပ်ငန်းစဉ်များတွင် အခြေခံအုတ်မြစ်အဖြစ် အသုံးပြုနိုင်သည် -
28
+ * **Semantic Search:** စာလုံးပေါင်း တိတိကျကျ မတူသော်လည်း အဓိပ္ပာယ်တူညီသည့် စာသားများကို ရှာဖွေခြင်း။
29
+ * **Text Classification:** စာသားများကို အမျိုးအစား ခွဲခြားခြင်း။
30
+ * **Sentiment Analysis:** စာသားများ၏ ခံစားချက်ဖော်ပြမှုကို ခွဲခြားခြင်း။
31
+ * **Foundation for LLMs:** ကြီးမားသော ဘာသာစကားမော်ဒယ်များ (Large Language Models) အတွက် အဓိပ္ပာယ်ပိုင်းဆိုင်ရာ အခြေခံအဖြစ် အသုံးပြုခြင်း။
32
+
33
+ ## ၄။ နည်းပညာဆိုင်ရာ အချက်အလက်များ (Technical Details)
34
+ ဤမော်ဒယ်ကို လေ့ကျင့်ရာတွင် အောက်ပါ နည်းပညာဆိုင်ရာ သတ်မှတ်ချက်များကို အသုံးပြုထားသည် -
35
+ * **မော်ဒယ်တည်ဆောက်ပုံ (Architecture):** FastText (Skip-gram)။
36
+ * **လေ့ကျင့်ထားသော ဒေတာပမာဏ (Training Data):** စာကြောင်းရေ ၁၆ သန်းကျော် (၅.၃ GB ဝန်းကျင်) ရှိသော [**myX-Mega-Corpus**](https://huggingface.co/datasets/DatarrX/myX-Mega-Corpus)။
37
+ * **စကားလုံးခွဲစနစ် (Tokenizer):** myX-Tokenizer (64,000 Vocabulary size)။
38
+ * **Vector Dimension:** 100။
39
+ * **အနည်းဆုံးပါဝင်မှုနှုန်း (Min Count):** 20။
40
+ * **Window Size:** 5။
41
+ * **Epochs:** 3။
42
+
43
+ ## ၅။ ကန့်သတ်ချက်များနှင့် လိုင်စင် (Limitations and License)
44
+
45
+ ### ၅.၁ ကန့်သတ်ချက်များ (Limitations)
46
+ * ဤမော်ဒယ်သည် Unicode စံနှုန်းဖြင့် ရေးသားထားသော စာသားများတွင်သာ အကောင်းဆုံး စွမ်းဆောင်နိုင်မည်ဖြစ်သည်။
47
+ * လေ့ကျင့်ထားသော ဒေတာများအတွင်းမှ ဘက်လိုက်မှု (Bias) များသည် မော်ဒယ်၏ ရလဒ်အပေါ် သက်ရောက်မှု ရှိနိုင်သည်။
48
+
49
+ ### ၅.၂ လိုင်စင် (License)
50
+ ဤမော်ဒယ်အား **Apache License 2.0** အောက်တွင် ထုတ်ဝေထားပါသည်။ စီးပွားရေးလုပ်ငန်းများနှင့် သုတေသနလုပ်ငန်းများတွင် လွတ်လပ်စွာ အသုံးပြုနိုင်သော်လည်း မူရင်းဖန်တီးသူကို သတ်မှတ်ထားသည့်အတိုင်း ကိုးကားဖော်ပြရမည်ဖြစ်သည်။
51
+
52
+ ## ၆။ အသုံးပြုနည်း လမ်းညွှန် (How to Use)
53
+ ဤ Model ကို Python environment တွင် အောက်ပါအဆင့်များအတိုင်း အသုံးပြုနိုင်သည်။
54
+
55
+ ### ၆.၁ လိုအပ်သော Library များ ထည့်သွင်းခြင်း (Installation)
56
+
57
+ ပထမဦးစွာ Model ကို Load လုပ်ရန်နှင့် Hugging Face မှ Download ရယူရန် လိုအပ်သော Library များကို Install လုပ်ပါ။
58
+ ```BASH
59
+ pip install fasttext huggingface_hub
60
+ ```
61
+ ### ၆.၂ Model ကို Load လုပ်ခြင်း (Loading the Model)
62
+
63
+ Hugging Face Hub မှ Model ကို တိုက်ရိုက် Download ရယူပြီး Load လုပ်ရန် အောက်ပါ Code ကို အသုံးပြုပါ။
64
+
65
+ ```Python
66
+ import fasttext
67
+ from huggingface_hub import hf_hub_download
68
+
69
+ # Hugging Face မှ model ဖိုင်ကို download ဆွဲခြင်း
70
+ model_path = hf_hub_download(repo_id="DatarrX/myX-Semantic", filename="myX-Semantic.bin")
71
+
72
+ # fasttext ကို သုံးပြီး model ကို load လုပ်ခြင်း
73
+ model = fasttext.load_model(model_path)
74
+ ```
75
+ ### ၆.၃ အခြေခံ အသုံးပြုနည်းများ (Basic Operations)
76
+ Model ရရှိပြီးနောက် အောက်ပါ NLP လုပ်ငန်းစဉ်များကို စမ်းသပ်နိုင်သည်။
77
+
78
+ - က) အဓိပ္ပာယ်တူညီသော စကားလုံးများ ရှာဖွေခြင်း (Finding Nearest Neighbors)
79
+ စကားလုံးတစ်လုံးနှင့် အနီးစပ်ဆုံး အဓိပ္ပာယ်ရှိသော စကားလုံး (၁၀) လုံးကို ရှာဖွေရန်:
80
+
81
+ ```Python
82
+ # 'နည်းပညာ' နှင့် အနီးစပ်ဆုံးစကားလုံးများ ရှာခြင်း
83
+ neighbors = model.get_nearest_neighbors("နည်းပညာ")
84
+ for score, neighbor in neighbors:
85
+ print(f"{neighbor}: {score:.4f}")
86
+ ```
87
+ - ခ) စကားလုံးနှစ်လုံး၏ အဓိပ္ပာယ် နီးစပ်မှုကို စစ်ဆေးခြင်း (Calculating Similarity Score)
88
+ စကားလုံးနှစ်လုံးသည် အဓိပ္ပာယ်အရ မည်မျှ နီးစပ်သလဲဆိုသည်ကို တွက်ချက်ရန်:
89
+
90
+ ```Python
91
+ import numpy as np
92
+
93
+ def get_similarity(w1, w2):
94
+ v1 = model.get_word_vector(w1)
95
+ v2 = model.get_word_vector(w2)
96
+ return np.dot(v1, v2) / (np.linalg.norm(v1) * np.linalg.norm(v2))
97
+
98
+ score = get_similarity("ပျော်တယ်", "ဝမ်းသာတယ်")
99
+ print(f"Similarity Score: {score:.4f}")
100
+ ```
101
+
102
+ - ဂ) စာကြောင်းတစ်ခုလုံး၏ Vector ကို ရယူခြင်း (Getting Sentence Vector)
103
+ စာကြောင်းတစ်ခုလုံးကို Vector အဖြစ် ပြောင်းလဲရန် (Text Classification သို့မဟုတ် Semantic Search လုပ်ရန်အတွက် အသုံးဝင်သည်):
104
+
105
+ ```Python
106
+ sentence_vector = model.get_sentence_vector("မြန်မာနိုင်ငံ၏ နည်းပညာ ကဏ္ဍ တိုးတက်လာပုံ")
107
+ print(sentence_vector)
108
+ ```
109
+
110
+ ## ၇။ လေ့ကျင့်မှု ဖြစ်စဉ် အကျဉ်းချုပ် (Training Procedure Summary)
111
+ ဤမော်ဒယ်ကို အဆင့် (၂) ဆင့်ဖြင့် စနစ်တကျ လေ့ကျင့်ခဲ့သည် -
112
+ * **အဆင့် (၁) - Tokenization:** [myX-Tokenizer](https://huggingface.co/DatarrX/myX-Tokenizer) ကို အသုံးပြု၍ ၁၆ သန်းကျော်သော စာကြောင်းများကို Subword units များအဖြစ် ခွဲခြားခဲ့သည်။ လုပ်ဆောင်ချက် မြန်ဆန်စေရန် Multiprocessing စနစ်ကို အသုံးပြုခဲ့သည်။
113
+ * **အဆင့် (၂) - FastText Training:** ခွဲခြားထားသော Token များကို FastText (Skip-gram) algorithm သုံး၍ Dimension 100 ဖြင့် လေ့ကျင့်ခဲ့သည်။ ပိုမိုတိကျသော Context များရရှိရန် Window Size 5 နှင့် Negative Sampling နည်းလမ်းကို အသုံးပြုခဲ့သည်။
114
+
115
+ ## ၈။ လေ့ကျင့်မှုဆိုင်ရာ ကုဒ်များ (Training Code)
116
+ မော်ဒယ်အား ပြန်လည်စမ်းသပ်နိုင်ရန်နှင့် ပွင့်လင်းမြင်သာမှုရှိစေရန်အတွက် အသုံးပြုခဲ့သော ကုဒ်အပြည့်အစုံကို အောက်ပါ GitHub link တွင် လေ့လာနိုင်သည် -
117
+ 👉 [https://github.com/DatarrX/myX-Semantic](https://github.com/DatarrX/myX-Semantic)
118
+
119
+ ## ၉။ မော်ဒယ်ဆိုင်ရာ အချက်အလက်များ (Model File Info)
120
+ * **Model Version:** 1.0
121
+ * **File Format:** Binary (.bin)
122
+ * **File Size:** ~851.71 MB
123
+ * **Vector Dimension:** 100
124
+ * **Architecture:** FastText (Skip-gram)
125
+
126
+ ## ၁၀။ DatarrX အကြောင်း (About DatarrX)
127
+ [**DatarrX**](https://huggingface.co/DatarrX) သည် မြန်မာဘာသာစကားအတွက် အဆင့်မြင့် သဘာဝဘာသာစကား စီမံဆောင်ရွက်မှု (Natural Language Processing) အရင်းအမြစ်များကို ဖန်တီးပေးနေသည့် Open-source NGO အဖွဲ့အစည်းတစ်ခုဖြစ်သည်။ မြန်မာနိုင်ငံ၏ ဒစ်ဂျစ်တယ်နည်းပညာကဏ္ဍတွင် AI နှင့် Open Data များ ပိုမိုပေါများလာစေရန်နှင့် မြန်မာဘာသာစကားဆိုင်ရာ ဒေတာစုများ၊ မော်ဒယ်များကို လူတိုင်း အခမဲ့ အသုံးပြုနိုင်ရန် ရည်ရွယ်၍ ဖွဲ့စည်းထားခြင်းဖြစ်သည်။
128
+
129
+ ## ၁၁။ ကိုးကားအသုံးပြုရန် (Citation)
130
+ သင်၏ သုတေသန သို့မဟုတ် ပရောဂျက်များတွင် ဤမော်ဒယ်ကို အသုံးပြုပါက အောက်ပါအတိုင်း ကိုးကားပေးပါရန် မေတ္တာရပ်ခံအပ်ပါသည် -
131
+
132
+ ### APA Style
133
+
134
+ Khant Sint Heinn. (2026). *myX-Semantic: A Burmese word embedding model for NLP tasks* [Computer software]. DatarrX. https://huggingface.co/DatarrX/myX-Semantic
135
+
136
+ ### BibTeX
137
+ ```bibtex
138
+ @software{khantsintheinn2026myxsemantic,
139
+ author = {Khant Sint Heinn},
140
+ title = {myX-Semantic: A Burmese Word Embedding Model for NLP Tasks},
141
+ year = {2026},
142
+ publisher = {DatarrX},
143
+ url = {https://huggingface.co/DatarrX/myX-Semantic},
144
+ note = {Myanmar Open Source NGO}
145
+ }
146
+ ```
147
+
148
+ ## ၁၂။ အသုံးပြုနိုင်သည့် ဘာသာစကား (Intended Language)
149
+
150
+ ဤမော်ဒယ်ကို **မြန်မာဘာသာစကား (Burmese)** တစ်မျိုးတည်းအတွက်သာ ရည်ရွယ်၍ တည်ဆောက်ထားခြင်းဖြစ်သည်။ အခြားဘာသာစကားများအတွက် အသုံးပြုပါက ရလဒ်ကောင်းမွန်ရန် အာမမခံပါ။