ali-issa commited on
Commit
8bb8a84
·
verified ·
1 Parent(s): 1b507a9

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +235 -101
README.md CHANGED
@@ -1,91 +1,148 @@
1
  ---
2
  license: cc-by-4.0
3
- task_categories:
4
- - text-classification
5
  language:
6
- - ar
 
7
  size_categories:
8
- - n<1K
 
 
9
  tags:
10
- - arabic
11
- - diacritics
12
- - tashkeel
13
- - minimal-pairs
14
- - disambiguation
15
- - morphology
16
- - evaluation
 
 
 
 
17
  configs:
18
- - config_name: default
19
- data_files: taad.parquet
 
 
20
  ---
21
 
22
- # TAAD: Teacher-Approved Arabic Diacritics
 
 
 
 
 
 
 
 
23
 
24
- A small benchmark of 110 Arabic minimal pairs in which **the diacritics alone
25
- decide the meaning**. Each item is one sentence written two ways. Strip the
26
- short vowel marks and the two spellings become the identical string, so a model
27
- that cannot read the marks has no information with which to choose.
 
 
 
 
 
 
 
 
 
28
 
29
  ## What is in it
30
 
31
- Each item gives two vocalizations of the same consonantal skeleton, and one
32
- short continuation that fits each reading:
33
 
34
- | | Arabic | reading |
35
- |---|---|---|
36
  | A | أُحِبُّ الشِّعْرَ → العَرَبِيَّ | *I love Arabic poetry* |
37
  | B | أُحِبُّ الشَّعْرَ → الطَّوِيلَ | *I love long hair* |
38
 
39
- Both sentences reduce to **أحب الشعر** once diacritics are removed.
 
 
40
 
41
- The intended use is a forced choice: given one reading of the sentence, is its
42
- own continuation scored above the other one? Each item is asked in both
43
- directions, giving 220 decisions in total, so a model that simply prefers one
44
- continuation wins once and loses once and gains nothing.
 
 
 
 
 
 
 
 
 
45
 
46
  ## Construction constraints
47
 
48
- Every item satisfies all of the following, checked mechanically:
49
-
50
- 1. The two sentences are identical once diacritics are stripped.
51
- 2. Shadda (U+0651) is identical in both readings. The stripping convention
52
- preserves shadda, so a pair differing in it would be visible to a
53
- diacritic-blind model.
54
- 3. Exactly one word differs between the readings, and it is the last word.
55
- 4. **Both continuations carry the same final short vowel.** This is the most
56
- important constraint. Without it, a model can succeed by copying the case
57
- vowel of the preceding word rather than by reading the ambiguous word. In an
58
- earlier version of this design that lacked the constraint, the copying
59
- shortcut alone resolved every position in the set.
60
- 5. The two continuations are different words, never one adjective in two cases.
61
- 6. One word per continuation.
62
- 7. The contrast is lexical, not a case contrast: the two forms differ inside
63
- the word, not only in a final inflectional vowel.
 
 
 
 
 
 
 
 
64
 
65
  ## Provenance
66
 
67
- Items were written and reviewed by an Arabic language teacher. Rows marked
68
- `authored` were composed by the reviewer; rows marked `validated` were drafted
69
- as candidates against the constraints above and then checked and approved by
70
- the same reviewer. All 110 passed review.
 
 
 
 
 
 
 
71
 
72
- Candidates that failed any construction constraint were discarded before
73
- review.
 
 
 
74
 
75
  ## Dataset structure
76
 
77
- | field | type | description |
78
- |---|---|---|
79
- | `id` | string | Stable item identifier, `taad-001` … `taad-110` |
80
- | `sentence_a` | string | Reading A, fully diacritized |
81
- | `ending_a` | string | The one-word continuation that fits reading A |
82
- | `sentence_b` | string | Reading B, fully diacritized |
83
- | `ending_b` | string | The one-word continuation that fits reading B |
84
- | `word_pair` | string | The ambiguous word, undiacritized |
85
- | `provenance` | string | `authored` or `validated` |
86
- | `undiacritized` | string | The shared consonantal string both readings reduce to |
 
 
87
 
88
- 110 rows, one configuration, no splits.
 
 
89
 
90
  ## Usage
91
 
@@ -95,72 +152,149 @@ from datasets import load_dataset
95
  ds = load_dataset("ali-issa/TAAD", split="train")
96
  item = ds[0]
97
 
98
- # the two forced choices for this item
99
- # given sentence_a: is ending_a scored above ending_b?
100
- # given sentence_b: is ending_b scored above ending_a?
 
 
101
  print(item["sentence_a"], "->", item["ending_a"])
102
  print(item["sentence_b"], "->", item["ending_b"])
103
- print(item["undiacritized"]) # identical for both readings
104
  ```
105
 
106
- ### Suggested scoring
107
 
108
- Tokenize `sentence + " " + continuation` as a single string, run one forward
109
- pass, and sum the log-probability of the continuation's tokens only. The
110
- sentence is identical across the two continuations and would otherwise dominate
111
- the comparison.
112
 
113
- Because the two continuations are different words, a raw sum favours the
114
- shorter one. Dividing by the character length of the **undiacritized
115
- continuation** gives a divisor that is a property of the item and identical for
116
- every model, so it cannot favour one tokenizer over another. Dividing by a
117
- model's own token count does not have this property and is not comparable
118
- across tokenizers.
119
 
120
- A graded alternative that needs no normalization at all:
 
121
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
122
  ```
123
- displacement = [logP(end_a | sent_a) − logP(end_b | sent_a)]
124
- − [logP(end_a | sent_b) − logP(end_b | sent_b)]
125
- ```
126
 
127
- Each continuation appears once with each sign, so its length, frequency and
128
- token count cancel exactly. What remains reflects only the change between the
129
- two vocalizations. Zero means the diacritics changed nothing.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
130
 
131
- ### A note on the expected floor
132
 
133
- A model whose vocabulary cannot encode short vowels maps both readings of every
134
- item to the identical token sequence. Its two scores are then equal by
135
- construction and it scores exactly chance with exactly zero displacement. This
136
- is arithmetic rather than a measurement of ability, and it is the point of the
137
- set: these sentences are unresolvable without the marks as a matter of what is
138
- written.
139
 
140
- When reporting confidence intervals, resample **items** rather than decisions.
141
- The two directions of an item are strongly anti-correlated by construction and
142
- are not independent observations.
 
 
 
143
 
144
  ## Citation
145
 
 
 
146
  ```bibtex
147
- @misc{taad2026,
148
- title = {{TAAD}: Teacher-Approved Arabic Diacritics},
149
- author = {{Author names withheld during review}},
150
- year = {2026},
151
  publisher = {Hugging Face},
152
- note = {Author list and URL will be added once the accompanying paper is published}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
153
  }
154
  ```
155
 
156
  ## License
157
 
158
- CC BY 4.0.
 
159
 
160
- ## Authors
 
161
 
162
- Author names withheld during review.
 
 
 
 
 
 
 
 
 
 
 
 
 
163
 
164
  ## Contact
165
 
166
- Contact details will be added once the accompanying paper is published.
 
 
 
1
  ---
2
  license: cc-by-4.0
 
 
3
  language:
4
+ - ar
5
+ pretty_name: "TAAD: Teacher-Approved Arabic Diacritics"
6
  size_categories:
7
+ - n<1K
8
+ task_categories:
9
+ - text-classification
10
  tags:
11
+ - arabic
12
+ - diacritics
13
+ - tashkeel
14
+ - minimal-pairs
15
+ - disambiguation
16
+ - morphology
17
+ - evaluation
18
+ - benchmark
19
+ - arabic-nlp
20
+ - text
21
+ - datasets
22
  configs:
23
+ - config_name: default
24
+ data_files:
25
+ - split: train
26
+ path: taad.parquet
27
  ---
28
 
29
+ # TAAD — Teacher-Approved Arabic Diacritics
30
+
31
+ **TAAD** is a small evaluation benchmark of **110 Arabic minimal pairs** in which
32
+ the diacritics alone determine the intended meaning.
33
+
34
+ Each item contains the same underlying consonantal string with two different
35
+ vocalizations. Once the relevant Arabic short-vowel marks are removed, the two
36
+ readings become identical. A model therefore needs access to the diacritics to
37
+ distinguish the intended interpretations.
38
 
39
+ TAAD was developed during the evaluation and public review process surrounding
40
+ **NOHA: A Diacritic-Aware Rule-Based Morphophonological Tokenizer for Arabic**,
41
+ published in **Transactions on Machine Learning Research (TMLR)** in 2026.
42
+
43
+ > **Related publication and public review discussion**
44
+ > Ali Issa, Tina Yaacoub, and Patrick Abi Salloum.
45
+ > **NOHA: A Diacritic-Aware Rule-Based Morphophonological Tokenizer for Arabic.**
46
+ > *Transactions on Machine Learning Research (TMLR), 2026.*
47
+ > https://openreview.net/forum?id=Vyc4Ormkqp
48
+
49
+ TAAD was discussed in the public OpenReview review and author-response thread
50
+ associated with the NOHA paper, but it is **not included as a benchmark in the
51
+ final archival TMLR manuscript**.
52
 
53
  ## What is in it
54
 
55
+ Each item provides two vocalizations of the same consonantal skeleton together
56
+ with one short continuation appropriate for each reading.
57
 
58
+ | | Arabic | Reading |
59
+ | --- | --- | --- |
60
  | A | أُحِبُّ الشِّعْرَ → العَرَبِيَّ | *I love Arabic poetry* |
61
  | B | أُحِبُّ الشَّعْرَ → الطَّوِيلَ | *I love long hair* |
62
 
63
+ Both sentence prefixes reduce to:
64
+
65
+ **أحب الشعر**
66
 
67
+ once the relevant short-vowel diacritics are removed.
68
+
69
+ The intended use is a paired forced-choice evaluation:
70
+
71
+ - given `sentence_a`, determine whether `ending_a` is scored above `ending_b`;
72
+ - given `sentence_b`, determine whether `ending_b` is scored above `ending_a`.
73
+
74
+ Each of the 110 items is therefore evaluated in both directions, yielding
75
+ **220 forced-choice decisions**.
76
+
77
+ Because each continuation appears once as the intended continuation and once as
78
+ the competing continuation, a fixed preference for one continuation cannot by
79
+ itself improve performance across the pair.
80
 
81
  ## Construction constraints
82
 
83
+ Every released item satisfies the following constraints, checked mechanically:
84
+
85
+ 1. The two sentence readings are identical after the relevant short-vowel
86
+ diacritics are stripped.
87
+
88
+ 2. **Shadda (U+0651) is identical in both readings.**
89
+ The stripping convention preserves shadda, so a pair differing in shadda
90
+ would remain distinguishable even after the other short-vowel marks were
91
+ removed.
92
+
93
+ 3. Exactly one word differs between the two vocalizations, and it is the final
94
+ word of the sentence prefix.
95
+
96
+ 4. **Both continuations carry the same final short vowel.**
97
+ This prevents a model from solving the task merely by copying the case vowel
98
+ of the preceding word instead of interpreting the ambiguous vocalized word.
99
+
100
+ 5. The two continuations are different lexical items rather than the same word
101
+ appearing in two different grammatical cases.
102
+
103
+ 6. Each continuation consists of exactly one word.
104
+
105
+ 7. The ambiguity is lexical rather than purely case-based: the two readings
106
+ differ internally within the word and not only in a final inflectional vowel.
107
 
108
  ## Provenance
109
 
110
+ The benchmark was designed and assembled by **Ali Issa**.
111
+
112
+ Items were written and reviewed with the involvement of an Arabic-language
113
+ teacher.
114
+
115
+ Rows marked `authored` were composed directly by the teacher. Rows marked
116
+ `validated` were first drafted as candidate items satisfying the benchmark's
117
+ construction constraints and were subsequently reviewed and approved by the
118
+ same teacher.
119
+
120
+ All **110 released items** passed this review process.
121
 
122
+ Candidate items that violated any construction constraint were discarded before
123
+ inclusion in the released dataset.
124
+
125
+ The benchmark was not scraped from an existing evaluation set and was not
126
+ translated from another language.
127
 
128
  ## Dataset structure
129
 
130
+ | Field | Type | Description |
131
+ | --- | --- | --- |
132
+ | `id` | `string` | Stable item identifier, from `taad-001` to `taad-110`. |
133
+ | `sentence_a` | `string` | Reading A, fully diacritized. |
134
+ | `ending_a` | `string` | One-word continuation appropriate for reading A. |
135
+ | `sentence_b` | `string` | Reading B, fully diacritized. |
136
+ | `ending_b` | `string` | One-word continuation appropriate for reading B. |
137
+ | `word_pair` | `string` | Ambiguous word represented without the relevant short-vowel diacritics. |
138
+ | `provenance` | `string` | Either `authored` or `validated`. |
139
+ | `undiacritized` | `string` | Shared form obtained after stripping the relevant diacritics. |
140
+
141
+ The dataset contains **110 rows** and one configuration.
142
 
143
+ The Hugging Face dataset is exposed through a split named `train` for loading
144
+ convenience. **TAAD is an evaluation benchmark and is not intended as training
145
+ data.**
146
 
147
  ## Usage
148
 
 
152
  ds = load_dataset("ali-issa/TAAD", split="train")
153
  item = ds[0]
154
 
155
+ # Two paired forced-choice comparisons:
156
+ #
157
+ # sentence_a: ending_a should score above ending_b
158
+ # sentence_b: ending_b should score above ending_a
159
+
160
  print(item["sentence_a"], "->", item["ending_a"])
161
  print(item["sentence_b"], "->", item["ending_b"])
162
+ print(item["undiacritized"])
163
  ```
164
 
165
+ ## Suggested scoring
166
 
167
+ For each candidate continuation, tokenize
 
 
 
168
 
169
+ ```text
170
+ sentence + " " + continuation
171
+ ```
 
 
 
172
 
173
+ as a single sequence and compute the log-probability of the **continuation
174
+ tokens only**.
175
 
176
+ The sentence context should not itself be included in the scoring sum.
177
+
178
+ ### Length-normalized forced-choice score
179
+
180
+ Because the two candidate continuations may have different lengths, raw summed
181
+ log-probability can favor shorter continuations.
182
+
183
+ For comparisons across tokenizers, one possible normalization is to divide the
184
+ continuation log-probability by the character length of its **undiacritized
185
+ form**.
186
+
187
+ Unlike normalization by a model's own token count, character length is a
188
+ property of the text rather than of the tokenizer being evaluated.
189
+
190
+ ### Displacement score
191
+
192
+ A paired alternative that does not require length normalization is:
193
+
194
+ ```text
195
+ displacement =
196
+ [logP(end_a | sent_a) - logP(end_b | sent_a)]
197
+ - [logP(end_a | sent_b) - logP(end_b | sent_b)]
198
  ```
 
 
 
199
 
200
+ Each continuation appears once with each sign. This paired construction reduces
201
+ fixed effects associated with the continuation itself, such as lexical
202
+ frequency, length, or tokenization cost.
203
+
204
+ A displacement value of zero means that changing the vocalization did not
205
+ change the model's relative preference between the two continuations.
206
+
207
+ ## Expected behavior without usable diacritics
208
+
209
+ If a model's input representation removes or cannot distinguish the relevant
210
+ short-vowel diacritics, the two readings of an item collapse to the same input
211
+ representation.
212
+
213
+ Such a model therefore has no information in the written input with which to
214
+ systematically distinguish the two intended readings. Under the paired
215
+ forced-choice construction, its expected performance is at chance, and its
216
+ displacement is zero when the two contexts become representation-identical.
217
+
218
+ When estimating confidence intervals, resample **items rather than individual
219
+ directions**. The two directions derived from the same minimal pair are paired
220
+ observations and should not be treated as independent samples.
221
+
222
+ ## Relationship to the NOHA paper and review
223
+
224
+ TAAD was developed during the evaluation and review process for:
225
+
226
+ **NOHA: A Diacritic-Aware Rule-Based Morphophonological Tokenizer for Arabic**
227
+ Ali Issa, Tina Yaacoub, and Patrick Abi Salloum
228
+ *Transactions on Machine Learning Research (TMLR), 2026*
229
 
230
+ https://openreview.net/forum?id=Vyc4Ormkqp
231
 
232
+ TAAD appears in the **public OpenReview review and author-response discussion**
233
+ associated with the paper.
 
 
 
 
234
 
235
+ However, TAAD was **not included as an evaluation benchmark in the final
236
+ archival TMLR manuscript**.
237
+
238
+ The NOHA paper and its OpenReview forum are therefore provided here as context
239
+ for the research and review process in which TAAD was developed. The NOHA paper
240
+ should not be interpreted as the publication formally introducing TAAD.
241
 
242
  ## Citation
243
 
244
+ If you use **TAAD** in your work, please cite the dataset directly:
245
+
246
  ```bibtex
247
+ @misc{issa2026taad,
248
+ title = {{TAAD}: Teacher-Approved Arabic Diacritics},
249
+ author = {Ali Issa},
250
+ year = {2026},
251
  publisher = {Hugging Face},
252
+ url = {https://huggingface.co/datasets/ali-issa/TAAD},
253
+ note = {Arabic diacritic minimal-pair evaluation benchmark}
254
+ }
255
+ ```
256
+
257
+ When discussing the broader research context in which TAAD was developed, the
258
+ associated NOHA paper may additionally be cited:
259
+
260
+ ```bibtex
261
+ @article{
262
+ issa2026noha,
263
+ title={{NOHA}: A Diacritic-Aware Rule-Based Morphophonological Tokenizer for Arabic},
264
+ author={Ali Issa and Tina Yaacoub and Patrick Abi Salloum},
265
+ journal={Transactions on Machine Learning Research},
266
+ issn={2835-8856},
267
+ year={2026},
268
+ url={https://openreview.net/forum?id=Vyc4Ormkqp},
269
+ note={}
270
  }
271
  ```
272
 
273
  ## License
274
 
275
+ TAAD is released under the **Creative Commons Attribution 4.0 International
276
+ (CC BY 4.0)** license.
277
 
278
+ You may use, share, and adapt the dataset, including commercially, provided
279
+ appropriate attribution is given.
280
 
281
+ https://creativecommons.org/licenses/by/4.0/
282
+
283
+ ## Author
284
+
285
+ **Ali Issa**
286
+ Université Saint-Joseph de Beyrouth
287
+
288
+ ## Acknowledgements
289
+
290
+ TAAD was developed in the broader context of the NOHA research project.
291
+
292
+ The author thanks the Arabic-language teacher who contributed to the authorship
293
+ and validation of the benchmark items, and **Tina Yaacoub** for supervision and
294
+ feedback on the broader research.
295
 
296
  ## Contact
297
 
298
+ Questions, corrections, and reports concerning individual items are welcome.
299
+
300
+ Please open a discussion on this Hugging Face repository.