---
title: "Calliar: An Online Handwritten Dataset for — Alyafeai 2021"
description: "Online Arabic handwriting datasets already exist, but none of them cover calligraphy."
authors: ["Zaid Alyafeai", "Maged S. Al-shaibani", "Mustafa Ghaleb", "Yousif Ahmed Al-Wajih"]
year: 2021
venue: "arXiv:2106.10745"
source: "https://arxiv.org/abs/2106.10745"
doi: "10.48550/arxiv.2106.10745"
arxiv: "2106.10745"
licence: "CC BY 4.0 (arXiv)"
licence_url: "http://creativecommons.org/licenses/by/4.0/"
summary_licence: "Elamur Cosmic License"
canonical: "https://research.elamur.ai/free/en/papers/alyafeai-2021-calliar-online-handwritten-dataset-arabic/"
---
[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/alyafeai-2021-calliar-online-handwritten-dataset-arabic/)

[home](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2021](https://md.research.elamur.ai/free/en/papers/2021/page/5/) / Calliar: An Online Handwritten Dataset for Arabic Calligraphy

# Calliar: An Online Handwritten Dataset for Arabic Calligraphy

**Authors:** [Zaid Alyafeai](https://md.research.elamur.ai/free/en/authors/zaid-alyafeai/), [Maged S. Al-shaibani](https://md.research.elamur.ai/free/en/authors/maged-s-al-shaibani/), [Mustafa Ghaleb](https://md.research.elamur.ai/free/en/authors/mustafa-ghaleb/), Yousif Ahmed Al-Wajih · **Year:** 2021 · **Venue:** arXiv:2106.10745 · **Licence:** [CC BY 4.0 (arXiv)](http://creativecommons.org/licenses/by/4.0/)

**Links:** [Publisher's page](https://arxiv.org/abs/2106.10745) · [PDF](https://arxiv.org/pdf/2106.10745) · [DOI 10.48550/arxiv.2106.10745](https://doi.org/10.48550/arxiv.2106.10745) · [arXiv 2106.10745](https://arxiv.org/abs/2106.10745) · [OpenAlex](https://openalex.org/W3175568057)

**Citations:** 4 citations (OpenAlex, 2026-10-14) · 4 in our library, of the 140884 papers whose bibliographies we read

## Summary
Online Arabic handwriting datasets already exist, but none of them cover calligraphy. Collections of calligraphic styles such as Diwani, Thuluth, Kufi and Farisi exist only as offline images, with no record of how each letter was drawn. The authors close this gap with Calliar. They gathered calligraphy images from the web, and four annotators retraced each one with a digital pen on a tablet. Every pen-down-to-pen-up movement was stored as a sequence of (x, y) points and labelled with the letter component it represents. Each sketch is a JSON file that can be read at the level of strokes, characters, words or whole sentences. The released resource holds 2,500 sentences and roughly 45k strokes, divided at random into training, validation and test portions. The authors argue that this fine-grained online data supports character and sentence classification, Arabic OCR without a separate letter-segmentation step, and generative calligraphy models, which have so far been built mostly for English. They also present it as a way to digitally preserve regional calligraphic traditions that could otherwise be lost.

## Key points
- Calliar contains 2,500 sketches (sentences), 7,556 words, 30,720 characters and 45,572 strokes, with 2,000 sketches in the training split.
- The vocabulary has 37 unique letter symbols. Diacritics and decorative marks are deliberately left out, and Maddah is the only exception.
- Letters are broken into stroke components, so a dot or Hamza becomes its own stroke. A mark above the letter is written before the base letter, and a mark below is written after it.
- Each sketch is scaled so its longer side is 600 px while keeping the aspect ratio. The full zip is about 52 MB, and a lighter 8.6 MB version in the QuickDraw format omits stroke-level labels.
- The data is public on GitHub. Some sentences, such as the Basmala, appear many times on purpose to show stylistic variety.

## Interesting ideas
- Each letter is split into its separately drawn parts, and a fixed positional rule (above goes before, below goes after) gives every sub-unit a deterministic order in the label string, which makes the labels unambiguous. — For Mova (tokens): Contractions, clitics and hyphenated compounds could be split by similarly explicit ordering conventions, so that every token sequence maps back to the surface form in one documented way.
- The annotation interface lets the annotator edit the target transcription while tracing, so wrong source labels get fixed at the moment they are spotted rather than in a later cleanup pass. — For Mova (learn): When humans or an LLM teacher review silver parses, the tool could allow correcting the input sentence or tokenization on the spot, keeping source errors from being baked into training data.
- A single record keeps all granularities at once (stroke, character, word, sentence), so one file serves tasks at very different levels without re-annotation. — For Mova (world): Each world entity or event could store links back through the frame and tree nodes down to token spans, giving every answer a full, explainable path to the text.
- The data ships in two forms: a rich native format and a stripped-down one compatible with an established ecosystem (QuickDraw). — For Mova (tree): Treebanks and dialect-converted outputs could be published both in a rich internal format with provenance and in plain CoNLL-U, so outside UD tools can use them directly.
- The same sentence is included many times in different drawings to capture variation while the content stays fixed. — For Mova (learn): Sets of paraphrases with identical meaning could serve as an invariance test, where the frames and world built from each variant should match and any mismatch flags a parser or frame error.

*Our summary of the paper, in our own words — not its text. The work belongs to its authors; read it at the links above.*

Fields: [Linguistics & languages](https://md.research.elamur.ai/free/en/shelves/linguistics/)

Topics: [Semitic languages](https://md.research.elamur.ai/free/en/topics/semitic-languages/)

## Cite

The paper itself, not this page. BibTeX from the library's record of the work.

```bibtex
@misc{alyafeai2021calliar,
  title = {{Calliar: An Online Handwritten Dataset for Arabic Calligraphy}},
  author = {Alyafeai, Zaid and Al-shaibani, Maged S. and Ghaleb, Mustafa and Al-Wajih, Yousif Ahmed},
  year = {2021},
  doi = {10.48550/arxiv.2106.10745},
  eprint = {2106.10745},
  archivePrefix = {arXiv},
  url = {https://doi.org/10.48550/arxiv.2106.10745}
}
```

- [← previous ArSarcasm Shared Task: An Ensemble BERT Model for SarcasmDetection in Arabic Tweets](https://md.research.elamur.ai/free/en/papers/bashmal-2021-arsarcasm-shared-task-ensemble-bert/)
- [next → Chandler: An Explainable Sarcastic Response Generator](https://md.research.elamur.ai/free/en/papers/oprea-2021-chandler-explainable-sarcastic-response-generator/)
- [↑ back to papers of 2021](https://md.research.elamur.ai/free/en/papers/2021/page/5/)

## References

25 references, 0 of them with a card of ours. ↗ leads to the work, «find» searches for one we have no id for yet.

1. Sabri A Mahmoud, Irfan Ahmad, Wasfi G Al-Khatib, Mohammad Alshayeb, Mohammad Tanvir Parvez, Volker Märgner, and Gernot A Fink. Khatt: An open arabic offline handwritten text database. Pattern Recognition, 47(3):1096–1112, 2014. [find](https://scholar.google.com/scholar?q=Sabri+A+Mahmoud%2C+Irfan+Ahmad%2C+Wasfi+G+Al%2DKhatib%2C+Mohammad+Alshayeb%2C+Mohammad+Tanvir+Parvez%2C+Volker+M%C3%A4rgner%2C+and+Gernot+A+Fink%2E+Khatt%3A+An+open+arabic+offline+handwritten+text+database%2E+Pattern+Recognit)
2. Volker Märgner and Haikal El Abed. Icdar 2009 arabic handwriting recognition competition. In 2009 10th International Conference on Document Analysis and Recognition, pages 1383–1387. IEEE, 2009. [find](https://scholar.google.com/scholar?q=Volker+M%C3%A4rgner+and+Haikal+El+Abed%2E+Icdar+2009+arabic+handwriting+recognition+competition%2E+In+2009+10th+International+Conference+on+Document+Analysis+and+Recognition%2C+pages+1383%E2%80%931387%2E+IEEE%2C+2009%2E)
3. U-V Marti and Horst Bunke. The iam-database: an english sentence database for offline handwriting recognition. International Journal on Document Analysis and Recognition, 5(1):39–46, 2002. *Figure 8: Different styles of calligraphy.* [find](https://scholar.google.com/scholar?q=U%2DV+Marti+and+Horst+Bunke%2E+The+iam%2Ddatabase%3A+an+english+sentence+database+for+offline+handwriting+recognition%2E+International+Journal+on+Document+Analysis+and+Recognition%2C+5%281%29%3A39%E2%80%9346%2C+2002%2E+%2AFigure+8%3A+)
4. Cheng-Lin Liu, Fei Yin, Da-Han Wang, and Qiu-Feng Wang. Casia online and offline chinese handwriting databases. In 2011 International Conference on Document Analysis and Recognition, pages 37–41. IEEE, 2011. [find](https://scholar.google.com/scholar?q=Cheng%2DLin+Liu%2C+Fei+Yin%2C+Da%2DHan+Wang%2C+and+Qiu%2DFeng+Wang%2E+Casia+online+and+offline+chinese+handwriting+databases%2E+In+2011+International+Conference+on+Document+Analysis+and+Recognition%2C+pages+37%E2%80%9341%2E+IEEE)
5. Nazly Sabbour and Faisal Shafait. A segmentation-free approach to arabic and urdu ocr. In Document recognition and retrieval XX, volume 8658, page 86580N. International Society for Optics and Photonics, 2013. [find](https://scholar.google.com/scholar?q=Nazly+Sabbour+and+Faisal+Shafait%2E+A+segmentation%2Dfree+approach+to+arabic+and+urdu+ocr%2E+In+Document+recognition+and+retrieval+XX%2C+volume+8658%2C+page+86580N%2E+International+Society+for+Optics+and+Photonic)
6. Sabri A Mahmoud, Hamzah Luqman, Baligh M Al-Helali, Galal BinMakhashen, and Mohammad Tanvir Parvez. Online-khatt: an open-vocabulary database for arabic online-text processing. The Open Cybernetics & Systemics Journal, 12(1), 2018. [find](https://scholar.google.com/scholar?q=Sabri+A+Mahmoud%2C+Hamzah+Luqman%2C+Baligh+M+Al%2DHelali%2C+Galal+BinMakhashen%2C+and+Mohammad+Tanvir+Parvez%2E+Online%2Dkhatt%3A+an+open%2Dvocabulary+database+for+arabic+online%2Dtext+processing%2E+The+Open+Cybernetics+%26+)
7. Sourour Njah, Badreddine Ben Nouma, Hala Bezine, and Adel M Alimi. Mayastroun: A multilanguage handwriting database. In 2012 International Conference on Frontiers in Handwriting Recognition, pages 308–312. IEEE, 2012. [find](https://scholar.google.com/scholar?q=Sourour+Njah%2C+Badreddine+Ben+Nouma%2C+Hala+Bezine%2C+and+Adel+M+Alimi%2E+Mayastroun%3A+A+multilanguage+handwriting+database%2E+In+2012+International+Conference+on+Frontiers+in+Handwriting+Recognition%2C+pages+308)
8. Zineb Kaoudja, Mohammed Lamine Kherfi, and Belal Khaldi. An efficient multiple-classifier system for arabic calligraphy style recognition. In 2019 International Conference on Networking and Advanced Systems (ICNAS), pages 1–5. IEEE, 2019. [find](https://scholar.google.com/scholar?q=Zineb+Kaoudja%2C+Mohammed+Lamine+Kherfi%2C+and+Belal+Khaldi%2E+An+efficient+multiple%2Dclassifier+system+for+arabic+calligraphy+style+recognition%2E+In+2019+International+Conference+on+Networking+and+Advanced+S)
9. SR Allaf and R Al-Hmouz. Automatic recognition of artistic arabic calligraphy types. Journal of King Abdulaziz University, 27(1):3–17, 2016. [find](https://scholar.google.com/scholar?q=SR+Allaf+and+R+Al%2DHmouz%2E+Automatic+recognition+of+artistic+arabic+calligraphy+types%2E+Journal+of+King+Abdulaziz+University%2C+27%281%29%3A3%E2%80%9317%2C+2016%2E)
10. Kalthoum Adam, Asim Baig, Somaya Al-Maadeed, Ahmed Bouridane, and Sherine El-Menshawy. Kertas: dataset for automatic dating of ancient arabic manuscripts. International Journal on Document Analysis and Recognition (IJDAR), 21(4):283–290, 2018. [find](https://scholar.google.com/scholar?q=Kalthoum+Adam%2C+Asim+Baig%2C+Somaya+Al%2DMaadeed%2C+Ahmed+Bouridane%2C+and+Sherine+El%2DMenshawy%2E+Kertas%3A+dataset+for+automatic+dating+of+ancient+arabic+manuscripts%2E+International+Journal+on+Document+Analysis+an)
11. Seetah AL Salamah and Ross King. Towards the machine reading of arabic calligraphy: a letters dataset and corresponding corpus of text. In 2018 IEEE 2nd International Workshop on Arabic and Derived Script Analysis and Recognition (ASAR), pages 19–23. IEEE, 2018. [find](https://scholar.google.com/scholar?q=Seetah+AL+Salamah+and+Ross+King%2E+Towards+the+machine+reading+of+arabic+calligraphy%3A+a+letters+dataset+and+corresponding+corpus+of+text%2E+In+2018+IEEE+2nd+International+Workshop+on+Arabic+and+Derived+Sc)
12. Bilal Bataineh, Siti Norul Huda Sheikh Abdullah, Khairuddin Omar, and Anas Batayneh. Arabic-jawi scripts font recognition using first-order edge direction matrix. In International Multi-Conference on Artificial Intelligence Technology, pages 27–38. Springer, 2013. [find](https://scholar.google.com/scholar?q=Bilal+Bataineh%2C+Siti+Norul+Huda+Sheikh+Abdullah%2C+Khairuddin+Omar%2C+and+Anas+Batayneh%2E+Arabic%2Djawi+scripts+font+recognition+using+first%2Dorder+edge+direction+matrix%2E+In+International+Multi%2DConference+on+)
13. Bilal Bataineh, Siti Norul Huda Sheikh Abdullah, and Khairudin Omar. Arabic calligraphy recognition based on binarization methods and degraded images. In 2011 International Conference on Pattern Analysis and Intelligence Robotics, volume 1. IEEE, 2011. [find](https://scholar.google.com/scholar?q=Bilal+Bataineh%2C+Siti+Norul+Huda+Sheikh+Abdullah%2C+and+Khairudin+Omar%2E+Arabic+calligraphy+recognition+based+on+binarization+methods+and+degraded+images%2E+In+2011+International+Conference+on+Pattern+Analy)
14. Fouad Slimane, Rolf Ingold, Slim Kanoun, Adel M Alimi, and Jean Hennebert. A new arabic printed text image database and evaluation protocols. In 2009 10th International Conference on Document Analysis and Recognition, pages 946–950. IEEE, 2009. [find](https://scholar.google.com/scholar?q=Fouad+Slimane%2C+Rolf+Ingold%2C+Slim+Kanoun%2C+Adel+M+Alimi%2C+and+Jean+Hennebert%2E+A+new+arabic+printed+text+image+database+and+evaluation+protocols%2E+In+2009+10th+International+Conference+on+Document+Analysis)
15. Manal M Khayyat and Lamiaa A Elrefaei. A deep learning based prediction of arabic manuscripts handwriting style. Int. Arab J. Inf. Technol., 17(5):702–712, 2020. [find](https://scholar.google.com/scholar?q=Manal+M+Khayyat+and+Lamiaa+A+Elrefaei%2E+A+deep+learning+based+prediction+of+arabic+manuscripts+handwriting+style%2E+Int%2E+Arab+J%2E+Inf%2E+Technol%2E%2C+17%285%29%3A702%E2%80%93712%2C+2020%2E)
16. Kalthoum Adam, Somaya Al-Maadeed, and Ahmed Bouridane. based classification of arabic scripts style in ancient arabic manuscripts: Preliminary results. In 2017 1st International Workshop on Arabic Script Analysis and Recognition (ASAR), pages 95–98. IEEE, 2017. [find](https://scholar.google.com/scholar?q=Kalthoum+Adam%2C+Somaya+Al%2DMaadeed%2C+and+Ahmed+Bouridane%2E+based+classification+of+arabic+scripts+style+in+ancient+arabic+manuscripts%3A+Preliminary+results%2E+In+2017+1st+International+Workshop+on+Arabic+Scr)
17. David Ha and Douglas Eck. A neural representation of sketch drawings. arXiv preprint arXiv:1704.03477, 2017. [↗](https://arxiv.org/abs/1704.03477)
18. David H Douglas and Thomas K Peucker. Algorithms for the reduction of the number of points required to represent a digitized line or its caricature. Cartographica: the international journal for geographic information and geovisualization, 10(2):112–122, 1973. [find](https://scholar.google.com/scholar?q=David+H+Douglas+and+Thomas+K+Peucker%2E+Algorithms+for+the+reduction+of+the+number+of+points+required+to+represent+a+digitized+line+or+its+caricature%2E+Cartographica%3A+the+international+journal+for+geogra)
19. Laurens Van der Maaten and Geoffrey Hinton. Visualizing data using t-sne. Journal of machine learning research, 9(11), 2008. [find](https://scholar.google.com/scholar?q=Laurens+Van+der+Maaten+and+Geoffrey+Hinton%2E+Visualizing+data+using+t%2Dsne%2E+Journal+of+machine+learning+research%2C+9%2811%29%2C+2008%2E)
20. Lei Kang, Pau Riba, Yaxing Wang, Marçal Rusiñol, Alicia Fornés, and Mauricio Villegas. Ganwriting: Content-conditioned generation of styled handwritten word images. In European Conference on Computer Vision, pages 273–289. Springer, 2020. [find](https://scholar.google.com/scholar?q=Lei+Kang%2C+Pau+Riba%2C+Yaxing+Wang%2C+Mar%C3%A7al+Rusi%C3%B1ol%2C+Alicia+Forn%C3%A9s%2C+and+Mauricio+Villegas%2E+Ganwriting%3A+Content%2Dconditioned+generation+of+styled+handwritten+word+images%2E+In+European+Conference+on+Computer+)
21. Sharon Fogel, Hadar Averbuch-Elor, Sarel Cohen, Shai Mazor, and Roee Litman. Scrabblegan: semi-supervised varying length handwritten text generation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 4324–4333, 2020. [find](https://scholar.google.com/scholar?q=Sharon+Fogel%2C+Hadar+Averbuch%2DElor%2C+Sarel+Cohen%2C+Shai+Mazor%2C+and+Roee+Litman%2E+Scrabblegan%3A+semi%2Dsupervised+varying+length+handwritten+text+generation%2E+In+Proceedings+of+the+IEEE%2FCVF+Conference+on+Compu)
22. Ming Tao, Hao Tang, Songsong Wu, Nicu Sebe, Xiao-Yuan Jing, Fei Wu, and Bingkun Bao. Df-gan: Deep fusion generative adversarial networks for text-to-image synthesis. arXiv preprint arXiv:2008.05865, 2020. [↗](https://arxiv.org/abs/2008.05865)
23. Ayan Das, Yongxin Yang, Timothy Hospedales, Tao Xiang, and Yi-Zhe Song. Béziersketch: A generative model for scalable vector sketches. arXiv preprint arXiv:2007.02190, 2020. [↗](https://arxiv.org/abs/2007.02190)
24. Songwei Ge, Vedanuj Goswami, C Lawrence Zitnick, and Devi Parikh. Creative sketch generation. arXiv preprint arXiv:2011.10039, 2020. [↗](https://arxiv.org/abs/2011.10039)
25. Ilahm Chaker, Rachid Benslimane, and Mostafa Harti. Creation of al mabsout moroccan fonts format. In 2011 Colloquium in Information Science and Technology, pages 3–4. IEEE, 2011. [find](https://scholar.google.com/scholar?q=Ilahm+Chaker%2C+Rachid+Benslimane%2C+and+Mostafa+Harti%2E+Creation+of+al+mabsout+moroccan+fonts+format%2E+In+2011+Colloquium+in+Information+Science+and+Technology%2C+pages+3%E2%80%934%2E+IEEE%2C+2011%2E)
