Elamur Research⌕
☰
home / papers / 2021 / Correcting Arabic Soft Spelling Mistakes using BiLSTM-based Machine Learning

Correcting Arabic Soft Spelling Mistakes using BiLSTM-based Machine Learning

Summary

The paper tackles Arabic "soft" spelling mistakes. These are errors caused by letters that sound the same but have several written forms, such as the hamza seats, alef versus alef maksura, teh marbuta versus teh or heh, and an alef added or dropped after a final waw. Native writers and learners make them often because the governing rules are intricate. The authors cast correction as character-level, one-to-one sequence transcription handled by BiLSTM networks. Some soft errors insert or delete characters, so they introduce a lightweight trick that keeps input and output aligned without a costly encoder-decoder. Models were trained on classical Arabic (Tashkeela) and MSA (ATB3) using two regimes: transformed input, and stochastic error injection at several rates. They compared 2- and 4-layer variants with and without dropout. The recommended setup is two BiLSTM layers with dropout, trained with 40% error injection. It fixes 96.4% of injected errors and reaches a 1.28% CER on Test200, a small set of real soft mistakes. This shows that a cheap tagging architecture can handle a frequent, rule-heavy error class.

Key points

  • Data: Tashkeela (classical Arabic, the larger set) and ATB3 (MSA) for training, with Test200 as an external set of real user errors. Training on Tashkeela gave the better results.
  • With the transformed-input approach, the 2-layer BiLSTM with dropout achieved the top F1 of 98.7% on the Tashkeela test set.
  • Raising the injection rate from 2.5% up to 40% lowered the standard scores (accuracy, F1, CER, WER) but improved real correction ability as measured by the FP/Changes ratio. Rates above 40% (50%, 70%, 100%) gave no further gain.
  • CER on Test200 was about ten times higher than on the synthetic test splits. The authors attribute this to artificial errors that do not match real ones and call for a large expert-annotated corpus.
  • Most leftover errors involve final heh, teh and teh marbuta, along with mix-ups between the alef that carries a hamza on top and the alef that carries it underneath. The 4-layer model trained longest (48.5 h on Tashkeela, 9.2 h on ATB3), and all models converged within 50 epochs.

Interesting ideas

  • I1. Treating correction as per-character, length-preserving tagging rather than free generation means every edit maps to a specific input position, which makes changes auditable and the model cheap. — For Mova (tokens): A character-aligned normalizer for English typos and confusables (its/it's, then/than) could sit before the tokenizer and report exactly which characters it altered and why.
  • I2. Corrupting clean text with synthetic errors at a controlled probability, then sweeping that probability, revealed a sweet spot (40%) beyond which extra noise stops helping. — For Mova (learn): When training parsers or taggers on silver data, inject controlled noise and sweep its rate instead of guessing a fixed amount.
  • I3. Reporting false positives relative to total changes exposes over-correction, meaning edits to input that was already right, which plain accuracy hides when most characters need no change. — For Mova (learn): Any repair-rule or self-induced correction stage should track a "harmful edits per edit" ratio, so rules that damage correct parses are caught.
  • I4. Keeping a small set of genuine human errors apart from the synthetic test split exposed a tenfold gap, a warning that synthetic benchmarks flatter the model. — For Mova (learn): Pair every synthetic evaluation with a small real-world held-out set as a reality check, alongside the existing negative controls.
  • I5. Restricting a confusion matrix to the handful of mutually confusable symbols pinpoints exactly which pairs remain hard. — For Mova (tree): Build confusion matrices over commonly swapped UD labels (e.g. obl/nmod, xcomp/ccomp) to target treebank fixes and parser training where errors actually concentrate.

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

Topics: Semitic languages

Cite

The paper itself, not this page. BibTeX from the library's record of the work. DOI 10.48550/arxiv.2108.01141 · arXiv 2108.01141

@misc{abandah2021correcting,
  title = {{Correcting Arabic Soft Spelling Mistakes using BiLSTM-based Machine Learning}},
  author = {Abandah, Gheith A. and Suyyagh, Ashraf and Khedher, Mohammed Z.},
  year = {2021},
  doi = {10.48550/arxiv.2108.01141},
  eprint = {2108.01141},
  archivePrefix = {arXiv},
  url = {https://doi.org/10.48550/arxiv.2108.01141}
}

References

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

  1. UNESCO. World Arabic language day, Dec 2019. find
  2. Ethnologue. Arabic language statistics, 2020. find
  3. J. Clement. Internet: Most common languages online 2019, Jul 2019. find
  4. Kareem Darwish and Walid Magdy. Arabic information retrieval. Foundations and Trends in Information Retrieval, 7(4):239–342, 2014. find
  5. Teresa Tinsley and Kathryn Board. Languages for the future. Report ISBN 978-0-86355-883-2, British Council, 2017. find
  6. Glosbe. Transliteration and Romanization utilities, 2020. find
  7. Karin C Ryding. Learning Arabic as a foreign language, 2020. find
  8. G Abandah, M Khedher, W Anati, A Zghoul, S Ababneh, and Mamoun S Hattab. The Arabic language status in the Jordanian social networking and mobile phone communications. In 7th Int’l Conference on Information Technology (ICIT 2015), pages 449–456, 2015. find
  9. The school of language studies - language categories, 2017. find
  10. Gheith A Abandah, Alex Graves, Balkees Al-Shagoor, Alaa Arabiyat, Fuad Jamour, and Majid Al-Taee. Automatic diacritization of Arabic text using recurrent neural networks. International Journal on Document Analysis and Recognition (IJDAR), 18(2):183–197, 2015. find
  11. S. Alqudah, G. Abandah, and A. Arabiyat. Investigating hybrid approaches for Arabic text diacritization with recurrent neural networks. In 2017 IEEE Jordan Conference on Applied Electrical Engineering and Computing Technologies (AEECT), pages 1–6, Oct 2017. find
  12. Gheith Abandah and Asma Abdel-Karim. Accurate and fast recurrent neural network solution for the automatic diacritization of Arabic text. Jordanian Journal of Computers and Information Technology, 6(2):103–121, 2020. find
  13. Aqil M Azmi, Manal N Almutery, and Hatim A Aboalsamh. Real-word errors in Arabic texts: A better algorithm for detection and correction. IEEE/ACM Transactions on Audio, Speech, and Language Processing, 27(8):1308–1320, 2019. find
  14. Asma Zahui, Wahiba Elhor, and Mohamed Amine Cheragui. EL-Mossahih V1.0: A hybrid approach for detection and correction of typographical and phonetic transcription errors in Arabic texts. In 2017 8th International Conference on Information Technology (ICIT), pages 774–779. IEEE, 2017. find
  15. Mohammed Attia, Pavel Pecina, Younes Samih, Khaled Shaalan, and Josef Van Genabith. Arabic spelling error detection and correction. Natural Language Engineering, 22(5):751–773, September 2016. find
  16. Abd-Muhsin Hamad Al-Ameri. Common spelling mistakes among students of teacher education institutes. The Islamic College University Journal, 1(33):445–474, 2015. find
  17. Michael Flor, Michael Fried, and Alla Rozovskaya. A benchmark corpus of English misspellings and a minimally-supervised model for spelling correction. In Proceedings of the Fourteenth Workshop on Innovative Use of NLP for Building Educational Applications, pages 76–86, Florence, Italy, 2019. Association for Computational Linguistics. find
  18. Migucl BIazquez and Catherine Fan. The efficacy of spell check packages specifically designed for second language learners of Spanish. Pertanika Journal of Social Sciences & Humanities, 27(2), 2019. find
  19. Michael Flor, Yoko Futagi, Melissa Lopez, and Matthew Mulholland. Patterns of misspellings in L2 and L1 English: a view from the ETS spelling corpus. Bergen Language and Linguistics Studies, 6, 2015. find
  20. Hao Li, Yang Wang, Xinyu Liu, Zhichao Sheng, and Si Wei. Spelling error correction using a nested RNN model and pseudo training data. arXiv:1811.00238 [cs], November 2018. ↗
  21. Eva D’hondt, Cyril Grouin, and Brigitte Grau. Low-resource OCR error detection and correction in French clinical texts. In Proceedings of the Seventh International Workshop on Health Text Mining and Information Analysis, pages 61–68, Auxtin, TX, 2016. Association for Computational Linguistics. find
  22. Eva D’hondt, Cyril Grouin, and Brigitte Grau. Generating a training corpus for OCR post-correction using encoder-decoder model. In Proceedings of the Eighth International Joint Conference on Natural Language Processing, pages 1006–1014, 2017. find
  23. Mohammad Bagher Dastgheib, Seyed Mostafa Fakhrahmad, and Mansoor Zolghadri Jahromi. Perspell: A New Persian Semantic-based Spelling Correction System. Digital Scholarship in the Humanities, 32(3):543–553, 03 2016. find
  24. Azita Yazdani, Marjan Ghazisaeedi, Nasrin Ahmadinejad, Masoumeh Giti, Habibe Amjadi, and Azin Nahvijou. Automated misspelling detection and correction in Persian clinical text. Journal of Digital Imaging, pages 1–8, 2019. find
  25. Shahin Salavati and Sina Ahmadi. Building a lemmatizer and a spell-checker for Sorani Kurdish. CoRR, abs/1809.10763, 2018. ↗
  26. Pravallika Etoori, Manoj Chinnakotla, and Radhika Mamidi. Automatic spelling correction for resource-scarce languages using deep learning. In Proceedings of ACL 2018, Student Research Workshop, pages 146–152, Melbourne, Australia, 2018. Association for Computational Linguistics. find
  27. Mourad Mars. Toward a robust spell checker for Arabic text. In International Conference on Computational Science and Its Applications, pages 312–322. Springer, 2016. find
  28. Nouf AlShenaifi, Rehab AlNefie, Maha Al-Yahya, and Hend Al-Khalifa. ARIB@ QALB-2015 shared task: a hybrid cascade model for Arabic spelling error detection and correction. In Proceedings of the Second Workshop on Arabic Natural Language Processing, pages 127–132, 2015. find
  29. Hamdy Mubarak and Kareem Darwish. Automatic correction of arabic text: A cascaded approach. In Proceedings of the EMNLP 2014 Workshop on Arabic Natural Language Processing (ANLP), pages 132–136, 2014. find
  30. Houda Bouamor, Hassan Sajjad, Nadir Durrani, and Kemal Oflazer. Qcmuq@ qalb-2015 shared task: Combining character level mt and error-tolerant finite-state recognition for Arabic spelling correction. In Proceedings of the Second Workshop on Arabic Natural Language Processing, pages 144–149, 2015. find
  31. Hatem M Noaman, Shahenda S Sarhan, and M Rashwan. Automatic Arabic spelling errors detection and correction based on confusion matrix-noisy channel hybrid system. Egypt Comput Sci J, 40(2):54–64, 2016. find
  32. Majed M Al-Jefri and Sabri A Mahmoud. Context-sensitive Arabic spell checker using context words and n-gram language models. In 2013 Taibah University International Conference on Advances in Information Technology for the Holy Quran and Its Sciences, pages 258–263. IEEE, 2013. find
  33. Chiraz Ben Othmane Zribi and Mohamed Ben Ahmed. Detection of semantic errors in Arabic texts. Artificial Intelligence, 195:249–264, 2013. find
  34. Mahmoud Rokaya. Arabic semantic spell checking based on power links. International Information Institute (Tokyo). Information, 18(11):4749, 2015. find
  35. Daniel Watson, Nasser Zalmout, and Nizar Habash. Utilizing character and word embeddings for text normalization with sequence-to-sequence models. arXiv preprint arXiv:1809.01534, 2018. ↗
  36. Manar Alkhatib, Azza Abdel Monem, and Khaled Shaalan. Deep learning for Arabic error detection and correction. ACM Transactions on Asian and Low-Resource Language Information Processing (TALLIP), 19(5):1–13, 2020. find
  37. Aiman Solyman, Wang Zhenyu, Tao Qian, Arafat Abdulgader Mohammed Elhag, Muhammad Toseef, and Zeinab Aleibeid. Synthetic data with neural machine translation for automatic correction in arabic grammar. Egyptian Informatics Journal, 2020. find
  38. Alex Kuznetsov and Hector Urdiales. Spelling correction with denoising transformer. arXiv preprint arXiv:2105.05977, 2021. ↗
  39. Sepp Hochreiter and Jürgen Schmidhuber. Long short-term memory. Neural Computation, 9(8):1735– 1780, 1997. find
  40. Wikimedia_Commons. Long short-term memory, 2007. find
  41. Gheith A. Abandah, Mohammed Z. Khedher, Mohammad R. Abdel-Majeed, Hamdi M Mansour, Salma F Hulliel, and Lara M Bisharat. Classifying and diacritizing Arabic poems using deep recurrent neural networks. Journal of King Saud University - Computer and Information Sciences, 2020. find
  42. Ikbel Hadj Ali, Zied Mnasri, and Zied Lachiri. Dnn-based grapheme-to-phoneme conversion for arabic text-to-speech synthesis. International Journal of Speech Technology, 23(3):569–584, 2020. find
  43. Nizar Habash, Anas Shahrour, and Muhamed Al-Khalil. Exploiting arabic diacritization for high quality automatic annotation. In Proceedings of the Tenth International Conference on Language Resources and Evaluation (LREC’16), pages 4298–4304, 2016. find our card
  44. Ibrahim Bounhas, Nadia Soudani, and Yahya Slimani. Building a morpho-semantic knowledge graph for arabic information retrieval. Information Processing & Management, 57(6):102124, 2020. find
  45. Abdulrahman Alosaimy and Eric Atwell. Diacritization of a highly cited text: a classical arabic book as a case. In 2018 IEEE 2nd International Workshop on Arabic and Derived Script Analysis and Recognition (ASAR), pages 72–77. IEEE, 2018. find
  46. Adel Abdelli, Fayçal Guerrouf, Okba Tibermacine, and Belkacem Abdelli. Sentiment analysis of arabic algerian dialect using a supervised method. In 2019 International Conference on Intelligent Systems and Advanced Computing Sciences (ISACS), pages 1–6. IEEE, 2019. find
  47. Rajae Moumen, Raddouane Chiheb, Rdouan Faizi, and Abdellatif El Afia. Arabic diacritization with gated recurrent unit. In Proceedings of the International Conference on Learning and Optimization Algorithms: Theory and Applications, pages 1–4, 2018. find
  48. Mokthar Ali Hasan Madhfar and Ali Mustafa Qamar. Effective deep learning models for automatic diacritization of arabic text. IEEE Access, 9:273–288, 2020. find
  49. Ali Fadel, Ibraheem Tuffaha, Mahmoud Al-Ayyoub, et al. Arabic text diacritization using deep neural networks. In 2019 2nd International Conference on Computer Applications & Information Security (ICCAIS), pages 1–7. IEEE, 2019. find our card
  50. Mohamed Maamouri, Ann Bies, Tim Buckwalter, and Wigdan Mekki. The Penn Arabic treebank: Building a large-scale annotated Arabic corpus. In NEMLAR Conference on Arabic Language Resources and Tools, volume 27, pages 466–467. Cairo, 2004. find
  51. Imed Zitouni, Jeffrey Sorensen, and Ruhi Sarikaya. Maximum entropy based restoration of Arabic diacritics. In Proceedings of the 21st International Conference on Computational Linguistics and 44th Annual Meeting of the Association for Computational Linguistics, pages 577–584, 2006. find our card
  52. Maha M Alamri and William J Teahan. Automatic correction of Arabic dyslexic text. Computers, 8(1):19, 2019. find
  53. Yo Joong Choe, Jiyeon Ham, Kyubyong Park, and Yeoil Yoon. A neural grammatical error correction system built on better pre-training and sequential transfer learning. arXiv preprint arXiv:1907.01256, 2019. ↗

↑ back to top

This page in Markdown → https://md.research.elamur.ai/free/en/papers/abandah-2021-correcting-arabic-soft-spelling-mistakes/