AhmadAbbass commited on
Commit
75e8eee
·
verified ·
1 Parent(s): 3e80ace

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +163 -32
README.md CHANGED
@@ -1,34 +1,165 @@
1
  ---
2
- dataset_info:
3
- features:
4
- - name: id
5
- dtype: int64
6
- - name: poem verses
7
- list: string
8
- - name: base_meter
9
- dtype: string
10
- - name: form
11
- dtype: string
12
- - name: poem theme
13
- dtype: string
14
- - name: poem meter
15
- dtype: string
16
- - name: poem url
17
- dtype: string
18
- splits:
19
- - name: train
20
- num_bytes: 261783137.77126893
21
- num_examples: 143025
22
- - name: validation
23
- num_bytes: 1614352.2287310555
24
- num_examples: 882
25
- download_size: 133189758
26
- dataset_size: 263397490.0
27
- configs:
28
- - config_name: default
29
- data_files:
30
- - split: train
31
- path: data/train-*
32
- - split: validation
33
- path: data/validation-*
34
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ license: cc-by-sa-4.0
3
+ language:
4
+ - ar
5
+ tags:
6
+ - arabic
7
+ - poetry
8
+ - arud
9
+ - meter
10
+ - classical-arabic
11
+ - nlp
12
+ - text-generation
13
+ - supervised-finetuning
14
+ - reinforcement-learning
15
+ pretty_name: Ashaar V1 – Arabic Poetry with Meter Control
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
16
  ---
17
+
18
+ # Ashaar V1 – Arabic Poetry with Meter Control
19
+
20
+ ## Dataset Summary
21
+
22
+ **Ashaar V1** is a cleaned and structured Arabic poetry dataset designed for **meter-conditioned poetry generation**.
23
+
24
+ The dataset is derived from the original *Ashaar* corpus and has been carefully filtered, normalized, and restructured to support **explicit control over Arabic poetic meter** using two fields:
25
+
26
+ - `base_meter` — the classical Arabic meter (البحر)
27
+ - `form` — the structural form of the meter (تام، مجزوء، مخلع، أحذ)
28
+
29
+ This version is intended for:
30
+ - supervised fine-tuning (SFT) of large language models
31
+ - reinforcement learning with preference optimization (e.g. GRPO)
32
+ - meter-aware generation and evaluation pipelines
33
+
34
+ ---
35
+
36
+ ## Motivation
37
+
38
+ Arabic poetic meter (ʿIlm al-ʿArūḍ) is highly structured.
39
+ Training models directly on raw labels leads to noisy or unlearnable control signals.
40
+
41
+ This dataset was built with the following principles:
42
+ - keep only **learnable meter/form combinations**
43
+ - remove extremely rare or noisy variants
44
+ - preserve poetic content while stabilizing control labels
45
+ - enable reliable generation of multiple candidates per meter for ranking and evaluation
46
+
47
+ ---
48
+
49
+ ## Dataset Structure
50
+
51
+ The dataset is provided as a `DatasetDict` with two splits:
52
+
53
+ - `train`
54
+ - `validation` (stratified across meter and form)
55
+
56
+ ### Columns
57
+
58
+ | Column name | Description |
59
+ |------------|-------------|
60
+ | `id` | Stable numeric identifier |
61
+ | `poem verses` | List of verses composing the poem |
62
+ | `base_meter` | Classical Arabic meter (e.g. الطويل، الكامل، البسيط…) |
63
+ | `form` | Meter form (تام، مجزوء، مخلع، أحذ) |
64
+ | `poem theme` | Thematic label (when available) |
65
+ | `poem meter` | Original raw meter label from source |
66
+ | `poem url` | Source URL (for reference/debugging) |
67
+
68
+ ---
69
+
70
+ ## Supported Meters and Forms (V1)
71
+
72
+ ### Base meters (14)
73
+
74
+ ```
75
+
76
+ الطويل، الكامل، البسيط، الوافر، الخفيف،
77
+ السريع، الرجز، الرمل، المتقارب، المجتث،
78
+ المنسرح، المديد، الهزج، المتدارك
79
+
80
+ ```
81
+
82
+ Two extremely rare meters (المضارع، المقتضب) were excluded in V1 due to insufficient data.
83
+
84
+ ### Forms
85
+
86
+ - **تام** (full form)
87
+ - **مجزوء** (truncated form)
88
+ - **مخلع** (only for البسيط)
89
+ - **أحذ** (only for الكامل)
90
+
91
+ All other rare or inconsistent forms (e.g. مشطور، منهوك، مربع، تفعيلة) were removed to avoid noisy control signals.
92
+
93
+ ---
94
+
95
+ ## Validation Split
96
+
97
+ The validation set is **stratified by (base_meter, form)** using the rule:
98
+
99
+ ```
100
+
101
+ take = min(50, ceil(5% of each (meter, form) group))
102
+
103
+ ```
104
+
105
+ This ensures:
106
+ - coverage of all supported meter/form combinations
107
+ - no over-removal from small meters
108
+ - meaningful evaluation of control fidelity
109
+
110
+ ---
111
+
112
+ ## Intended Use
113
+
114
+ This dataset is intended for:
115
+
116
+ - Meter-conditioned Arabic poetry generation
117
+ - Supervised fine-tuning of LLMs (e.g. QLoRA)
118
+ - Reinforcement learning with reward models or judges
119
+ - Meter classification and verification research
120
+ - Human-in-the-loop poetic evaluation
121
+
122
+ It is **not** intended as a general-purpose Arabic text corpus.
123
+
124
+ ---
125
+
126
+ ## Limitations
127
+
128
+ - Some meters have significantly more data than others
129
+ - Rare classical forms are intentionally excluded in V1
130
+ - Meter correctness depends on source annotations (though spot-checked using meter classifiers)
131
+
132
+ Future versions may introduce:
133
+ - additional meters
134
+ - curriculum-style rare forms
135
+ - rhyme annotations
136
+ - era/style conditioning
137
+
138
+ ---
139
+
140
+ ## Citation
141
+
142
+ If you use this dataset, please cite or reference:
143
+
144
+ ```
145
+
146
+ Ashaar V1 – Arabic Poetry with Meter Control
147
+ Shaer-AI
148
+
149
+ ```
150
+
151
+ ---
152
+
153
+ ## Acknowledgements
154
+
155
+ This dataset builds upon the original Ashaar poetry corpus and benefits from classical Arabic prosody scholarship and open-source meter classification models.
156
+
157
+ ---
158
+
159
+ ## Contact
160
+
161
+ For questions, improvements, or collaborations, please contact:
162
+
163
+ **Shaer-AI**
164
+ https://huggingface.co/Shaer-AI
165
+