Using AI to prevent mental illness Mohamed Cherif Braham ATAST , Tunisia. Hatem Slimane Supervisor ATAST , Tunisia. Abstract —This project aims to address the increasing concern of mental health issues in society, particularly depression, and suicide. It proposes the use of artificial intelligence to analyze a person’s behavior on the internet to detect any signs of mental health issues. Once diagnosed, the person is automatically connected to a psychologist and a group of individuals with similar reports to provide support and efficient treatment. The project aims to provide help to individuals before they realize they need it, prevent them from ending their lives, and ultimately improve mental health outcomes. I. I NTRODUCTION Mental illnesses like depression and anxiety are very serious problems that can destroy someone’s life and even take them to suicide. People either don’t realize they’re mentally ill until their case becomes more dangerous, refuse to talk to anyone due to being ashamed, or even refuse to admit their mental illness and talk to a specialist. The internet nowadays has an important influence on our lives, revealing a lot about our personalities and opinions, and especially our mental state due to the algorithms used by social media or google searches. A. Hypothesis Clues of depressive tendencies can also be identified early, not only before the opportunity for professional diagnosis but perhaps also before people are aware of it themselves. So tracking internet use may allow depression, a prevalent and dangerous illness, to be discovered and treated earlier and more effectively. B. Solution 1) Diagnosis: The browser extension and mobile app will monitor a user’s browsing content to identify mental health- related content. The extension will analyze the content with an artificial intelligence model developed using machine learning and natural language processing. The AI can identify mental illness-related content like depression, anxiety, and suicidal thought. Then the AI will make a report containing statistics about the frequency of certain mental issues content to keep the data private. And will also monitor the development of the mental state of the user weekly. 2) Offer Help: When a mental illness is diagnosed, the user will be connected with a psychologist who will receive the report to provide more efficient treatment. The user will have access to development reports and can also join a group of individuals with similar reports on the Psybot website to encourage each other and not feel alone in the situation which makes them stronger and more ready to fight. Both the doctor and the group of people services will be provided on the Psybot website. II. D ATASET AND TRAINING This model was trained on a dataset composed of numerous posts taken from r/depression which is a subreddit where people post about their depression and their stories. Therefore, the AI model can identify patterns in which posts about depression are written including: vocabulary, frequency of certain words, writing style, word order . . . etc. This application will soon include a computer vision model to detect media content. III. N ATURAL L ANGUAGE P ROCESSING METHOD Confusion matrix of the NLP model that detects content related to depression and suicide IV. C ONCLUSION Keeping track of our mental health is important for our well- being, so a project that provides smart monitoring, treatment, and privacy is the perfect solution for the present and future generations who we will rely on to build a better world and achieve success and happiness.