  The World Health Organization (WHO) estimated that approximately 1.4 million
individuals worldwide died by suicide in 2022. This figure indicates that one
person died by suicide every 20 s during the year. Globally, suicide is the
tenth-leading cause of death, while it is the second-leading cause of death
among young people aged 15329 years. In 2022, it was estimated that
approximately 10.5 million suicide attempts would occur. The WHO suggests that
along with each completed suicide attempt, many individuals attempt suicide.
Today, social media is a place in which people share their feelings. Thus,
social media can help us understand the thoughts and possible actions of
individuals. This study leverages this advantage and focuses on developing an
automated model to use information from social media to determine whether
someone is contemplating self-harm. This model is based on the Suicidal-ELECTRA
model. We collected datasets of social media posts, processed them, and used
them to train and fiune-tune our model. Evaluation of the refined model with a
testing dataset consistently yielded outstanding results. The model had an
impressive accuracy rate of 93% and commendable F1 score of 0.93. Additionally,
we developed an application programming interface that seamlessly integrated
our tool with third-party platforms, enhancing its implementation potential to
address the concern of rising suicide rates.
