The Mavericks@ LT - EDI -2023: Detection of signs of Depression from social Media Texts using Navie Bayse approach (2023)

Abstract: Social media platforms have revolutionized the landscape of communication, providing individuals with an outlet to express their thoughts, emotions, and experiences openly. This paper focuses on the development of a model to determine whether individuals exhibit signs of depression based on their social media texts. With the aim of optimizing performance and accuracy, a Naive Bayes approach was chosen for the detection task.The Naive Bayes algorithm, a probabilistic classifier, was applied to extract features and classify the texts. The model leveraged linguistic patterns, sentiment analysis, and other relevant features to capture indicators of depression within the texts. Preprocessing techniques, including tokenization, stemming, and stop-word removal, were employed to enhance the quality of the input data.The performance of the Naive Bayes model was evaluated using standard metrics such as accuracy, precision, recall, and F1-score, it acheived a macro- avergaed F1 score of 0.263.

## introduction depression, @xcite a widespread and serious medical illness, poses a significant burden on individuals globally. the timely detection of depression signs plays a crucial role in providing appropriate interventions and improving treatment outcomes. social media platforms have emerged as a valuable resource for identifying mental health issues, including depression. by analyzing social media text, researchers can gain valuable insights into an individual's emotional state and detect potential signs of depression. this paper presents our solution for the shared task on detecting signs of depression from social media text. our main objective is to classify the level of depression in english social media posts, categorizing them as 'not depressed,' 'moderately depressed,' or 'severely depressed.' we aim to contribute to the improvement of individuals' lives by effectively detecting and addressing depression through the analysis of social media text. for this task, we utilize a carefully curated dataset specifically designed for the lt-edi@ranlp shared task. this dataset is composed of social media posts in english, annotated with the corresponding depression levels. we describe the dataset in detail, including its composition, annotation process, and any necessary modifications made for the task. additionally, we discuss the preprocessing steps employed to ensure the quality and suitability of the data for training our depression detection model. in conclusion, our solution for the lt-edi@ranlp shared task on detecting signs of depression from social media text demonstrates the potential of utilizing social media platforms to detect and address depression. by leveraging social media text, we aim to facilitate the timely identification of depression and contribute to improved intervention and treatment outcomes. in our study, we employed five distinct models -k-nearest neighbors (knn), naive bayes, random forest, decision tree, and support vector machine (svm). the evaluation process encompassed various metrics, including accuracy, macro-averaged precision, macro-averaged recall, and macro-averaged f1-score across all classes. notably, the macroaveraged f1-score emerged as the primary measure for assessing solutions. among these models, our solution harnessed naive bayes, as it yielded a commendable f1-score, solidifying its effectiveness in addressing the problem at hand. ## related works the study by @xcite demonstrated the effectiveness of ml algorithms in analyzing twitter data for depression detection. by incorporating lexical, syntactic, and social network features, the model achieved promising results, revealing strong correlations between linguistic patterns and depression. @xcite conducted a comprehensive study using ml techniques to detect depressive symptoms from social media data. their classification model integrated linguistic, @xcite sentiment, and behavioral features, showcasing the potential of ml in accurately identifying individuals with depression. macavaney et al. @xcite focused on detecting depression and ptsd(post-traumatic stress disorder) from reddit posts using an ml approach. their model incorporated linguistic, psycholinguistic, and social contextual features, achieving high accuracy in identifying individuals with depression. @xcite developed a deep learningbased approach for depression detection from social media text. their hierarchical attention network effectively captured textual information and demonstrated the power of deep learning in accurately detecting depression symptoms. coppersmith et al. @xcite conducted a largescale study involving various social media platforms for depression detection. their ml algorithms analyzed linguistic, sentiment, and contextual features, showcasing the scalability of depression detection from social media data. research was conducted by a large-scale study utilizing the bert model on multiple social media platforms to detect depression. the machine learning algorithms analyzed linguistic, sentiment, and contextual features, demonstrating the bert model's effectiveness and scalability in identifying depression from social media data @xcite .similary another variant of bert al-bert model was used for detecting the signs of depression @xcite . a chat bot was created using the bayesian modeling and it was used to detect single emotion only.employing multiple kernels may be used to predict several labels with higher performance angel deborah et al. @xcite . these notable works collectively emphasize the potential of ml models in detecting signs of depression from social media text. by incorporating diverse features and utilizing advanced techniques such as deep learning, researchers have achieved significant advancements in accurately identifying individuals with depression. these studies con-tribute to the growing understanding of the role of social media analysis in mental health monitoring and highlight the importance of continued research in this critical field. ## data set the dataset used in the competition for detecting signs of depression from social media text comprises english posts. each post was annotated with one of three labels: "not depression," "moderate," or "severe" . the "not depression" label indicates posts without any signs of depression, while the other labels indicate varying levels of depression severity. the dataset was divided into train, dev, and test sets. the test set, used for evaluating solutions, had undisclosed labels. the datset had a large number of duplicate records this was the reason for the lower efficiency.the data was biased containing a large number of moderately depressed samples. it is worth noting that the dataset is unbalanced, with the "severe" class being underrepresented. in summary, the dataset used for detecting signs of depression from social media text exhibited class imbalance .the sample data is shown in the data was examined on multiple models after the preparation processes, and the results are reported below. ## our solution when comparing the results of several machine learning algorithms like random forest, support vector machine (svm), k-nearest neighbors (knn), decision tree, and naive bayes algorithms, each has its strengths and weaknesses that make them suitable for different scenarios. random forest is figure 3: random forest in the context of text processing, naive bayes is often favored due to its computational efficiency, handling of high-dimensional data, interpretability, and ability to work with limited training data. however, the choice of algorithm ultimately depends on the specific problem, dataset characteristics, and desired performance metrics. so we implemented all the above mentioned algorithms and we found that naïve bayes is good for this problem. the implementation results are given below 6 future work as a future work, the efficiency of the model can be further enhanced by addressing two key aspects: removing duplicates from the given dataset and fine-tuning the model to achieve a balanced representation of the data. currently, the dataset exhibits an underrepresented distribution, which can impact the model's performance. by implementing duplicate removal techniques and leveraging the robustness of models like roberta, it is possible to optimize the model's efficiency and enhance its overall performance. ## conclusion in conclusion, the application of the naive bayes algorithm in detecting signs of depression from social media text lt-edi@ranlphas shown promising results. naive bayes offers several advantages in this context, making it a suitable choice for such tasks. the computational efficiency of naive bayes enables the processing of large volumes of social media text data efficiently. its ability to handle highdimensional feature spaces, often encountered in text data, is advantageous when dealing with the diverse and extensive vocabulary found in social media posts.