Abstract
Recognizing handwritten Arabic characters written by children via scanned or camera-captured images is a challenging task due to variations in writing style, stroke irregularity, and diacritical marks. Although deep learning has advanced this field, building reliable systems remains challenging. This study introduces a stacking ensemble framework for sensor-acquired handwriting data, enhanced with a dynamic confidence-thresholding mechanism designed to improve prediction reliability. The framework integrates three high-performing convolutional neural networks (ConvNeXtBase, DenseNet201, and VGG16) through a fully connected meta-learner. A key feature is the use of an optimized threshold that filters out uncertain predictions by maximizing the macro F1 score on validation data. The framework is evaluated on two benchmark datasets for children's Arabic handwriting: Hijja and Dhad. The results demonstrate state-of-the-art performance, with an accuracy of 95.13% and F1 score of 94.62% on Hijja and an accuracy of 96.14% and F1 score of 95.59% on Dhad. Compared to existing methods, the proposed approach achieves more than a 3% improvement in Hijja accuracy while maintaining robust performance across diverse character classes. These findings highlight the effectiveness of confidence-based stacking ensembles in enhancing reliability for Arabic handwriting recognition and suggest strong potential for automated educational assessment tools and intelligent tutoring systems.