drelhaj commited on
Commit
068483a
·
verified ·
1 Parent(s): b10b20b

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +197 -172
README.md CHANGED
@@ -1,173 +1,198 @@
1
- ---
2
- license: "cc-by-4.0"
3
- language:
4
- - ar
5
- task_categories:
6
- - text-classification
7
- tags:
8
- - arabic
9
- - dialect-identification
10
- - multilingual
11
- - sociolinguistics
12
- - code-switching
13
- - bivalency
14
- configs:
15
- - config_name: full_text
16
- description: "Raw dialectal text files for EGY, GLF, LAV, NOR and MSA."
17
- - config_name: freq_lists
18
- description: "Dialect-specific vocabulary lists, bivalency-removed lists and MSA shared lists."
19
- ---
20
-
21
- # Arabic Dialects Dataset (Bivalency & Code-Switching)
22
-
23
- The **Arabic Dialects Dataset** is a specialised corpus designed for automatic dialect identification, with a focus on the linguistic phenomena of **bivalency** and **written code-switching** between major Arabic dialects and Modern Standard Arabic (MSA).
24
- It covers five varieties:
25
-
26
- - **EGY** – Egyptian Arabic
27
- - **GLF** – Gulf Arabic
28
- - **LAV** – Levantine Arabic
29
- - **NOR** – North African / Tunisian Arabic
30
- - **MSA** – Modern Standard Arabic
31
-
32
- The dataset was created for research on fine-grained linguistic variation and has been used to evaluate new methods such as **Subtractive Bivalency Profiling (SBP)**, achieving over **76% accuracy** in supervised dialect identification.
33
-
34
- This HuggingFace release makes the dataset machine-readable and ready for text classification, feature engineering, or corpus linguistic exploration.
35
-
36
- ---
37
-
38
- ## 📘 Citation
39
-
40
- If you use this dataset, please cite:
41
-
42
- **El-Haj M., Rayson P., Aboelezz M. (2018)**
43
- *Arabic Dialect Identification in the Context of Bivalency and Code-Switching.*
44
- In **Proceedings of the 11th International Conference on Language Resources and Evaluation (LREC 2018)**, Miyazaki, Japan, pp. 3622–3627.
45
- European Language Resources Association (ELRA).
46
- PDF: https://elhaj.uk/docs/237_Paper.pdf
47
-
48
- ---
49
-
50
- ## 📂 Dataset Structure
51
-
52
- The dataset is distributed across two main sections:
53
-
54
- ### **1. Dialects Full Text**
55
- Five files, each containing all instances belonging to one dialect:
56
-
57
- ```
58
- Dialects Full Text/
59
- │── allEGY.txt
60
- │── allGLF.txt
61
- │── allLAV.txt
62
- │── allMSA.txt
63
- └── allNOR.txt
64
- ```
65
-
66
- ---
67
-
68
-
69
- Each file contains raw text samples, one per line, suitable for direct use in dialect classification experiments.
70
-
71
- ---
72
-
73
- ### **2. Dialectal Frequency Lists**
74
-
75
- These resources support linguistic analysis and the SBP approach introduced in the paper.
76
-
77
- ```
78
- Dialects Frequency Lists/
79
-
80
- ├── Bivalency Removed (dialect - MSA)/
81
- │ allEGY_minusMSA.txt
82
- │ allGLF_minusMSA.txt
83
- │ allLAV_minusMSA.txt
84
- │ allNOR_minusMSA.txt
85
-
86
- ├── Dialects’ MSA/
87
- │ allEGY_dialectal_MSA.txt
88
- │ allGLF_dialectal_MSA.txt
89
- │ allLAV_dialectal_MSA.txt
90
- │ allNOR_dialectal_MSA.txt
91
-
92
- ├── Dialects Tokens WITH Frequency Count/
93
- │ all-EGY_FreqList.txt
94
- │ all-GLF_FreqList.txt
95
- │ all-LAV_FreqList.txt
96
- │ all-MSA_FreqList.txt
97
- │ all-NOR_FreqList.txt
98
-
99
- └── Dialects Tokens NO Frequency Count/
100
- all-EGY_FreqList2.txt
101
- all-GLF_FreqList2.txt
102
- all-LAV_FreqList2.txt
103
- all-MSA_FreqList2.txt
104
- all-NOR_FreqList2.txt
105
- ```
106
-
107
- **These include:**
108
-
109
- - **Bivalency-removed lists:** dialect-specific vocabularies after removing shared (bivalent) words
110
- - **Dialectal-MSA lists:** vocabulary shared with MSA via written code-switching
111
- - **Frequency lists:** token frequency counts
112
- - **Non-frequency lists:** raw token lists without counts
113
-
114
- ---
115
-
116
- ## 🧪 Intended Use
117
-
118
- This dataset supports several research tasks:
119
-
120
- ### **Dialect Identification**
121
- - Train machine-learning models to classify EGY/GLF/LAV/NOR/MSA
122
- - Evaluate performance on highly bivalent and lexically overlapping dialects
123
- - Benchmark features beyond n-grams
124
-
125
- ### **Bivalency & Code-Switching Analysis**
126
- - Study how words shift between dialects and MSA
127
- - Explore written code-switching in online text and commentary discourse
128
-
129
- ### **Linguistic Feature Engineering**
130
- - Use SBP lists as interpretable features
131
- - Combine stylistic, grammatical, and frequency-based signals
132
-
133
- ---
134
-
135
- ## 📊 Data Statistics
136
-
137
- (From the original publication)
138
-
139
- | Dialect | Sentences | Words |
140
- |--------|-----------|-------|
141
- | EGY | 4,061 | 118,152 |
142
- | GLF | 2,546 | 65,752 |
143
- | LAV | 2,463 | 67,976 |
144
- | MSA | 3,731 | 49,985 |
145
- | NOR | 3,693 | 53,204 |
146
- | **Total** | **16,494** | **355,069** |
147
-
148
- ---
149
-
150
- ## 🔍 Example Usage
151
-
152
- ### Load the full text for dialect classification
153
-
154
- ```python
155
- from datasets import load_dataset
156
-
157
- ds = load_dataset("YOUR_REPO_NAME", "full_text")
158
- print(ds["train"][0])
159
- ds = load_dataset("YOUR_REPO_NAME", "freq_lists")
160
- freq_list = ds["EGY_freq"]
161
- ```
162
-
163
- ---
164
- ## Licence
165
-
166
- This dataset is released for research purposes only.
167
- Texts originate from publicly available online sources or earlier datasets where redistribution for research is permitted.
168
-
169
- ---
170
-
171
- ## 🙏 Acknowledgements
172
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
173
  This dataset was developed at UCREL, Lancaster University, as part of research into Arabic dialect variation, bivalency, and automatic dialect identification.
 
1
+ ---
2
+ license: "cc-by-4.0"
3
+ language:
4
+ - ar
5
+ task_categories:
6
+ - text-classification
7
+ tags:
8
+ - arabic
9
+ - dialect-identification
10
+ - multilingual
11
+ - sociolinguistics
12
+ - code-switching
13
+ - bivalency
14
+ configs:
15
+ - config_name: full_text
16
+ description: "Raw dialectal text files for EGY, GLF, LAV, NOR and MSA."
17
+ - config_name: freq_lists
18
+ description: "Dialect-specific vocabulary lists, bivalency-removed lists and MSA shared lists."
19
+ ---
20
+
21
+ # Arabic Dialects Dataset (Bivalency & Code-Switching)
22
+
23
+ The **Arabic Dialects Dataset** is a specialised corpus designed for automatic dialect identification, with a focus on the linguistic phenomena of **bivalency** and **written code-switching** between major Arabic dialects and Modern Standard Arabic (MSA).
24
+ It covers five varieties:
25
+
26
+ - **EGY** – Egyptian Arabic
27
+ - **GLF** – Gulf Arabic
28
+ - **LAV** – Levantine Arabic
29
+ - **NOR** – North African / Tunisian Arabic
30
+ - **MSA** – Modern Standard Arabic
31
+
32
+ The dataset was created for research on fine-grained linguistic variation and has been used to evaluate new methods such as **Subtractive Bivalency Profiling (SBP)**, achieving over **76% accuracy** in supervised dialect identification.
33
+
34
+ This HuggingFace release makes the dataset machine-readable and ready for text classification, feature engineering, or corpus linguistic exploration.
35
+
36
+ ---
37
+
38
+ ## 📘 Citation
39
+
40
+ If you use this dataset, please cite:
41
+
42
+ **El-Haj M., Rayson P., Aboelezz M. (2018)**
43
+ *Arabic Dialect Identification in the Context of Bivalency and Code-Switching.*
44
+ In **Proceedings of the 11th International Conference on Language Resources and Evaluation (LREC 2018)**, Miyazaki, Japan, pp. 3622–3627.
45
+ European Language Resources Association (ELRA).
46
+ PDF: https://elhaj.uk/docs/237_Paper.pdf
47
+
48
+ ---
49
+
50
+ ## 📂 Dataset Structure
51
+
52
+ The dataset is distributed across two main sections:
53
+
54
+ ### **1. Dialects Full Text**
55
+ Five files, each containing all instances belonging to one dialect:
56
+
57
+ ```
58
+ Dialects Full Text/
59
+ │── allEGY.txt
60
+ │── allGLF.txt
61
+ │── allLAV.txt
62
+ │── allMSA.txt
63
+ └── allNOR.txt
64
+ ```
65
+
66
+ ---
67
+
68
+
69
+ Each file contains raw text samples, one per line, suitable for direct use in dialect classification experiments.
70
+
71
+ ---
72
+
73
+ ### **2. Dialectal Frequency Lists**
74
+
75
+ These resources support linguistic analysis and the SBP approach introduced in the paper.
76
+
77
+ ```
78
+ Dialects Frequency Lists/
79
+
80
+ ├── Bivalency Removed (dialect - MSA)/
81
+ │ allEGY_minusMSA.txt
82
+ │ allGLF_minusMSA.txt
83
+ │ allLAV_minusMSA.txt
84
+ │ allNOR_minusMSA.txt
85
+
86
+ ├── Dialects’ MSA/
87
+ │ allEGY_dialectal_MSA.txt
88
+ │ allGLF_dialectal_MSA.txt
89
+ │ allLAV_dialectal_MSA.txt
90
+ │ allNOR_dialectal_MSA.txt
91
+
92
+ ├── Dialects Tokens WITH Frequency Count/
93
+ │ all-EGY_FreqList.txt
94
+ │ all-GLF_FreqList.txt
95
+ │ all-LAV_FreqList.txt
96
+ │ all-MSA_FreqList.txt
97
+ │ all-NOR_FreqList.txt
98
+
99
+ └── Dialects Tokens NO Frequency Count/
100
+ all-EGY_FreqList2.txt
101
+ all-GLF_FreqList2.txt
102
+ all-LAV_FreqList2.txt
103
+ all-MSA_FreqList2.txt
104
+ all-NOR_FreqList2.txt
105
+ ```
106
+
107
+ **These include:**
108
+
109
+ - **Bivalency-removed lists:** dialect-specific vocabularies after removing shared (bivalent) words
110
+ - **Dialectal-MSA lists:** vocabulary shared with MSA via written code-switching
111
+ - **Frequency lists:** token frequency counts
112
+ - **Non-frequency lists:** raw token lists without counts
113
+
114
+ ---
115
+
116
+ ## 📊 **CSV Conversion + Train/Dev/Test Splits**
117
+ The original text files were converted into a unified sentence-level CSV: arabic_dialects_full.csv
118
+
119
+
120
+ with the schema:
121
+
122
+ | sentence | dialect |
123
+ |----------|---------|
124
+ | … | EGY / GLF / LAV / MSA / NOR |
125
+
126
+ Each sentence corresponds to one line from the original files.
127
+
128
+ This CSV was then **stratified and split** into:
129
+ arabic_dialects_train.csv
130
+ arabic_dialects_dev.csv
131
+ arabic_dialects_test.csv
132
+
133
+
134
+
135
+ Splits preserve dialect balance and follow an 80/10/10 ratio.
136
+
137
+ These files power the `csv_splits` configuration for immediate model training.
138
+
139
+ ---
140
+
141
+ ## 🧪 Intended Use
142
+
143
+ This dataset supports several research tasks:
144
+
145
+ ### **Dialect Identification**
146
+ - Train machine-learning models to classify EGY/GLF/LAV/NOR/MSA
147
+ - Evaluate performance on highly bivalent and lexically overlapping dialects
148
+ - Benchmark features beyond n-grams
149
+
150
+ ### **Bivalency & Code-Switching Analysis**
151
+ - Study how words shift between dialects and MSA
152
+ - Explore written code-switching in online text and commentary discourse
153
+
154
+ ### **Linguistic Feature Engineering**
155
+ - Use SBP lists as interpretable features
156
+ - Combine stylistic, grammatical, and frequency-based signals
157
+
158
+ ---
159
+
160
+ ## 📊 Data Statistics
161
+
162
+ (From the original publication)
163
+
164
+ | Dialect | Sentences | Words |
165
+ |--------|-----------|-------|
166
+ | EGY | 4,061 | 118,152 |
167
+ | GLF | 2,546 | 65,752 |
168
+ | LAV | 2,463 | 67,976 |
169
+ | MSA | 3,731 | 49,985 |
170
+ | NOR | 3,693 | 53,204 |
171
+ | **Total** | **16,494** | **355,069** |
172
+
173
+ ---
174
+
175
+ ## 🔍 Example Usage
176
+
177
+ ### Load the full text for dialect classification
178
+
179
+ ```python
180
+ from datasets import load_dataset
181
+
182
+ ds = load_dataset("YOUR_REPO_NAME", "full_text")
183
+ print(ds["train"][0])
184
+ ds = load_dataset("YOUR_REPO_NAME", "freq_lists")
185
+ freq_list = ds["EGY_freq"]
186
+ ```
187
+
188
+ ---
189
+ ## ⚠ Licence
190
+
191
+ This dataset is released for research purposes only.
192
+ Texts originate from publicly available online sources or earlier datasets where redistribution for research is permitted.
193
+
194
+ ---
195
+
196
+ ## 🙏 Acknowledgements
197
+
198
  This dataset was developed at UCREL, Lancaster University, as part of research into Arabic dialect variation, bivalency, and automatic dialect identification.