In this paper, we analyzed the performance of different transformer models for regret and hope speech detection on two novel datasets. For the regret detection task, we compared the averaged macro-scores of the transformer models to the previous state-of-the-art results. We found that the transformer models outperformed the previous approaches. Specifically, the roberta-based model achieved the highest averaged macro F1-score of 0.83, beating the previous state-of-the-art score of 0.76. For the hope speech detection task, the bert-based, uncased model achieved the highest averaged-macro F1-score of 0.72 among the transformer models. However, the specific performance of each model varied slightly depending on the task and dataset. Our findings highlight the effectiveness of transformer models for hope speech and regret detection tasks, and the importance of considering the effects of context, specific transformer architectures, and pre-training on their performance.
Hope is a vital coping mechanism, enabling individuals to effectively confront life’s challenges. This study proposes a technique employing Natural Language Processing (NLP) tools like Linguistic Inquiry and Word Count (LIWC), NRC-emotion-lexicon, and vaderSentiment to analyze social media posts, extracting psycholinguistic, emotional, and sentimental features from a hope speech dataset. The findings of this study reveal distinct cognitive, emotional, and communicative characteristics and psycholinguistic dimensions, emotions, and sentiments associated with different types of hope shared in social media. Furthermore, the study investigates the potential of leveraging this data to classify different types of hope using machine learning algorithms. Notably, models such as LightGBM and CatBoost demonstrate impressive performance, surpassing traditional methods and competing effectively with deep learning techniques. We employed hyperparameter tuning to optimize the models’ parameters and compared their performance using both default and tuned settings. The results highlight the enhanced efficiency achieved through hyperparameter tuning for these models.
Hope plays a crucial role in human psychology and well-being, yet its expression and detection across languages remain underexplored in natural language processing (NLP). This study presents MIND-HOPE, the first-ever multiclass hope speech detection datasets for Spanish and German, collected from Twitter. The annotated dataset comprise 19,183 Spanish tweets and 21,043 German tweets, categorized into four classes: Generalized Hope, Realistic Hope, Unrealistic Hope, and Not Hope. The paper also provides a comprehensive review of existing hope speech datasets and detection techniques, and conducts a comparative evaluation of traditional machine learning, deep learning, and transformer-based approaches. Experimental results, obtained using 5-fold cross-validation, show that monolingual transformer models (e.g., bert-base-german-dbmdz-uncased and bert-base-spanish-wwm-uncased) consistently outperform multilingual models (e.g., mBERT, XLM-RoBERTa) in both binary and multiclass hope detection tasks. These findings underscore the value of language-specific fine-tuning for nuanced affective computing tasks. This study advances sentiment analysis by addressing a novel and underrepresented affective dimension-hope, and proposes robust multilingual benchmarks for future research. Theoretically, it contributes to a deeper understanding of hope as a complex emotional state with practical implications for mental health monitoring, social well-being analysis, and positive content recommendation in online spaces. By modeling hope across languages and categories, this research opens new directions in affective NLP and cross-cultural computational social science.