[Paper Review] Learning meters of Arabic and English poems with Recurrent Neural Networks: a step forward for language understanding and synthesis
This paper proposes a character-level Recurrent Neural Network (RNN) approach to classify Arabic and English poem meters without handcrafted features, achieving 96.38% accuracy on Arabic and 82.31% on English. It introduces the first publicly available, large-scale, cleaned dataset of over 1.5 million poetic verses for computational poetry research.
Recognizing a piece of writing as a poem or prose is usually easy for the majority of people; however, only specialists can determine which meter a poem belongs to. In this paper, we build Recurrent Neural Network (RNN) models that can classify poems according to their meters from plain text. The input text is encoded at the character level and directly fed to the models without feature handcrafting. This is a step forward for machine understanding and synthesis of languages in general, and Arabic language in particular. Among the 16 poem meters of Arabic and the 4 meters of English the networks were able to correctly classify poem with an overall accuracy of 96.38\\% and 82.31\\% respectively. The poem datasets used to conduct this research were massive, over 1.5 million of verses, and were crawled from different nontechnical sources, almost Arabic and English literature sites, and in different heterogeneous and unstructured formats. These datasets are now made publicly available in clean, structured, and documented format for other future research. To the best of the authors' knowledge, this research is the first to address classifying poem meters in a machine learning approach, in general, and in RNN featureless based approach, in particular. In addition, the dataset is the first publicly available dataset ready for the purpose of future computational research.
Motivation & Objective
- To develop a machine learning model capable of classifying poetic meters directly from plain text without linguistic feature engineering.
- To address the challenge of automatic meter recognition in Arabic and English poetry, a task traditionally requiring expert knowledge.
- To create and release a large-scale, clean, and structured dataset of poetic verses for future computational research in poetry and language understanding.
- To explore the impact of diacritics and data encoding on model performance in low-resource and high-variability linguistic contexts.
Proposed method
- Input text is encoded at the character level, with diacritics preserved or removed based on experimental conditions.
- Bidirectional and unidirectional Long Short-Term Memory (LSTM) and Gated Recurrent Unit (GRU) networks are used as the core architecture.
- Models are trained end-to-end on raw character sequences, learning phonetic and rhythmic patterns directly from text.
- A comprehensive hyperparameter search is conducted across network depth (3–8 layers), unit size (6–60 units), and cell types (LSTM, BiLSTM, GRU, BiGRU).
- The model is evaluated using 10-fold cross-validation on both Arabic and English datasets to ensure robustness.
- Data preprocessing includes web crawling from non-technical literary sources, followed by normalization, cleaning, and structural formatting into a public repository.
Experimental results
Research questions
- RQ1Can RNNs trained on raw character-level input learn to classify poetic meters in Arabic and English without linguistic feature engineering?
- RQ2How does the presence or absence of diacritics affect the classification accuracy of poetic meter models?
- RQ3What is the relationship between class size (frequency of a meter in the dataset) and per-class classification accuracy?
- RQ4Which network architecture and hyperparameter configuration yield the highest performance across different text encodings?
- RQ5To what extent do encoding strategies (e.g., with/without diacritics, case sensitivity) influence model generalization and accuracy?
Key findings
- The RNN-based model achieved 96.38% overall accuracy in classifying Arabic poem meters, significantly outperforming rule-based systems.
- For English poetry, the model reached 82.31% overall accuracy, demonstrating strong performance despite the lower number of meters and greater linguistic variability.
- The TwoE (two-encoding) strategy consistently produced the highest accuracy across experiments, though performance varied across encodings due to model-architecture interactions.
- Diacritics improved classification accuracy only when rare meters were excluded from the dataset, indicating a complex interaction between data sparsity and phonetic representation.
- Per-class accuracy was strongly correlated with class size, with smaller classes showing lower accuracy, likely due to similarity between rare meters or insufficient training examples.
- The study released a publicly available dataset of over 1.5 million poetic verses in clean, structured, and documented format, enabling future research in computational poetics and language modeling.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.