Datasets:
File size: 3,869 Bytes
f8d9004 4191d32 f8d9004 4191d32 f8d9004 4191d32 f8d9004 4191d32 f8d9004 4191d32 f198cc8 4191d32 f198cc8 4191d32 f198cc8 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 |
---
license: apache-2.0
task_categories:
- text-to-image
language:
- ar
tags:
- arabic
- Qari
- OCR
- ArabicOCR
- BookStyle
- Markdown
pretty_name: Qari-OCR
size_categories:
- 10K<n<100K
---
# QARI Markdown Mixed Dataset
<div align="center">




</div>
<div align="center">
<img src="https://cdn-uploads.huggingface.co/production/uploads/628f7a71dd993507cfcbe587/Txz_HjVy6NsdmcghXqVH_.png" alt="QARI Logo" width="400">
</div>
## 📋 Dataset Summary
The QARI v0.3 Markdown Mixed Dataset is a specialized synthetic dataset designed for training Arabic OCR models with a focus on complex document layouts and HTML structure understanding.
This dataset is part of the QARI-OCR project, which achieves state-of-the-art performance in Arabic text recognition.
This dataset contains **37,000 synthetically generated Arabic document images** (29.6k train, 3.7k validation, 3.7k test) with corresponding ground truth text in HTML/Markdown format, featuring:
- 🔤 **Full diacritical marks (tashkeel)** support
- 📝 **Mixed font sizes** within documents (headers, body text, annotations)
- 🎨 **12 distinct Arabic fonts** ranging from common Naskh to ornate calligraphic styles
- 📄 **Realistic document layouts** with structural HTML tags
- 🖼️ **Multiple text sources** including Basma2423 and YoussefAnwar Arabic news
## 🎯 Intended Use
This dataset is specifically designed for:
- Training OCR models that need to understand document structure
- Fine-tuning vision-language models for Arabic text recognition
- Developing systems that preserve formatting and layout information
- Research in Arabic document analysis and understanding
## 📊 Dataset Statistics
| Metric | Value |
|--------|-------|
| **Total Images** | 37,000 |
| **Train Set** | 29,600 (80%) |
| **Validation Set** | 3,700 (10%) |
| **Test Set** | 3,700 (10%) |
| **Text Sources** | oddadmix/Basma2423-Text-with-Diacritics-Correction + YoussefAnwar/Arabic-news |
| **Font Variety** | 12 Arabic fonts |
| **Font Size Range** | 14px - 100px |
| **Diacritics Support** | ✅ Full tashkeel |
| **HTML Structure** | ✅ Preserved |
| **Layout Complexity** | ✅ High (mixed sizes, headers) |
## 🔧 Data Generation Pipeline
<div align="center">
| Stage | Process | Details |
|-------|---------|---------|
| **1. Text Collection** | Source gathering | Basma2423 (with diacritics) + YoussefAnwar Arabic news |
| **2. HTML Templating** | Layout generation | Mixed font sizes, structural elements |
| **3. Rendering** | WeasyPrint → PDF → Image | High-quality document rendering |
| **4. Degradation** | Synthetic noise | Clean / Moderate / Heavy variants |
</div>
## 📈 Model Performance
When used to train QARI v0.3, this dataset enables:
| Metric | Score |
|--------|-------|
| **Character Error Rate (CER)** | 0.300 |
| **Word Error Rate (WER)** | 0.485 |
| **BLEU Score** | 0.545 |
| **Training Time** | 11 hours |
| **CO₂ Emissions** | 1.88 kg eq. |
### Key Advantages:
- 📐 **Superior layout understanding** compared to plain text models
- 🏷️ **HTML tag preservation** for structured document conversion
- ⚡ **Resource efficient** - 5x less training time than larger datasets
- 🎯 **Specialized performance** for document structure tasks
## Citation
```markdown
@article{wasfy2025qari,
title={QARI-OCR: High-Fidelity Arabic Text Recognition through Multimodal Large Language Model Adaptation},
author={Wasfy, Ahmed and Nacar, Omer and Elkhateb, Abdelakreem and Reda, Mahmoud and Elshehy, Omar and Ammar, Adel and Boulila, Wadii},
journal={arXiv preprint arXiv:2506.02295},
year={2025}
}
```
|