## 3 Research Methodology
### Preparation Dataset
#### 3.1.1 Data Collection  
The aim of this step is to collect a large dataset of tweets written in English. The period of tweets related to depression and anxiety is from 1 December 2019 to 31 December 2021. This period corresponds to the circumstances of the COVID-19 pandemic, where many people were affected by the requirements of confinement, isolation, risk of illness, loss of  
Figure 1: The proposed methodology for building effective classifiers of mental disorders detection. loved ones, etc. These poor living conditions have encouraged people to use social media to express their feelings. In contrast, the period of the tweets related to normal behaviors is from 25 January 2022 to 31 January 2022. The keywords used to collect the data were carefully inspired by the symptoms of depression and anxiety summarized in Table 1. This procedure for collecting the data from Twitter is widely adopted by several deep learning approaches for many purposes. In what follows, we give some typical cases. For instance, [PERSON] et al. have collected data for depression detection using keywords close to \"(I'm/I was/I am/I've been) diagnosed depression\" [36]. These data were reused in other works [5,28,36,37,38,36] for different purposes. [PERSON] et al. use the disease name 'Borderline, bpd, bipolar' as keywords to predict borderline personality disorder (BPD) and bipolar disorder (BD) [39]. In [40], [PERSON] collected data based on the name of five dietary supplements 'Melatonin, Kava, Ginkgo, Biloba, Ginseng' to predict depression, anxiety and mood Disorders. Note that the use of a single word as a keyword (e.g., name of a disease or a food supplement) does not confirm that the user is sick, so the ambiguity rate is systematically high. In contrast, using these words by indicating one symptom or more within an explanatory sentence may reduce the rate of ambiguity. This is because such sentences correspond to user statements and thus their content is more likely contain negative sentiments and expressions that help train models. To generate depressive and anxiety tweets, we first used patterns close to: \"I am/was/have been **diagnosed/identified** with **depression/anxiety**\". The aim is to target users who self-report their issues. Then, we intensified the search around these data using other keywords related to both common and non-common symptoms between depression and anxiety disorders. For common symptoms, we used several verbs like \"feel\", \"suffer\", \"want\", \"can\", \"be\", \"have\" under several forms (conjugated in the past and the present according to negative and affirmative forms, depending on the meaning targeted) combined with words related to \"sleep\", \"appetite\", \"fatigue\", \"suicide\", \"death\", \"sadness\", \"melancholy\", \"fear\", \"worry\", under several forms (nouns, adjectives, gerunds in addition to some of their synonyms). The degree of a given symptom was expressed using adverbs such as \"so\", \"very\", \"little\" (e.g., so sad, little sad). In the same way, we have generated depressive and anxiety tweets based on the symptoms which are not in common. For depression disorder, we used keywords close to \"loss of pleasure\", \"despair about the future\", \"feelings of failure\". Regarding anxiety disorder, we used keywords close to \"Dizziness\", \"heart palpitations\", \"panic attack\". All these keywords were involved under several forms such as nouns, adjectives, gerunds in addition to some of their synonyms. Finally, normal tweets were generated based on keywords related to positive sentiments and feelings such as \"happiness\", \"love\" and \"beauty\". Table 5 gives typical examples of such keywords used within some parts of sentences that can appear in tweets.