Downloads · 30 days
100
0% of all-time downloads
gohjiayi/suicidal-bert
suicidal-bert is a text classification model from gohjiayi. Use it when you need a label for a piece of text. It is set up for transformers. The card lists the license as mit.
This text classification model predicts whether a sequence of words are suicidal (1) or non-suicidal (0).
Downloads · 30 days
100
0% of all-time downloads
All-time downloads
20.9K
Public
Repo size
1.3 GB
Likes
2
Public
Click a slice to open those files.
.bin438 MB · 100%
From the Hugging Face model README
This text classification model predicts whether a sequence of words are suicidal (1) or non-suicidal (0).
The model was trained on the Suicide and Depression Dataset obtained from Kaggle. The dataset was scraped from Reddit and consists of 232,074 rows equally distributed between 2 classes - suicide and non-suicide.
The model fine-tuning was conducted on 1 epoch, with batch size of 6, and learning rate of 0.00001. Due to limited computing resources and time, we were unable to scale up the number of epochs and batch size.
The model has achieved the following results after fine-tuning on the aforementioned dataset:
Load the model via the transformers library:
from transformers import AutoTokenizer, AutoModel
tokenizer = AutoTokenizer.from_pretrained("gooohjy/suicidal-bert")
model = AutoModel.from_pretrained("gooohjy/suicidal-bert")
For more resources, including the source code, please refer to the GitHub repository gohjiayi/suicidal-text-detection.