bullying-detector

BERT toxicity regressor (google/bert_uncased_L-4_H-512_A-8 + Linear(512 -> 1)) trained on google/civil_comments with the raw toxicity float (0-1) as target — no 0/1 binarization. Outputs a toxicity score; > 0.5 reads as BULLYING.

  • Model repo: jacob5269/bullying-detector
  • Task: toxicity regression (NOT_BULLYING / BULLYING at threshold 0.5)
  • Tokenizer: WordPiece (tokenizer.json), max_len=128
  • Weights: model.safetensors, config in config.json

Use (local bundle)

pip install torch transformers safetensors
python pipeline_example.py "you are worthless and nobody likes you"

Use (from Hub)

hf download jacob5269/bullying-detector --local-dir ./bullying-detector-hf
python bullying-detector-hf/pipeline_example.py --repo ./bullying-detector-hf "hello friend"
from pipeline_example import load_bundle, predict
model, tok = load_bundle("./bullying-detector-hf")
print(predict("you are worthless", model, tok))

Training

Training code lives in the source repo (src/train_civil.py), not in this Hub repo. This folder was generated with python -m src.export_hf.

Limitations

  • Demo model trained on a 50k stratified subset; not production-ready.
  • English only, no handling of obfuscation / sarcasm / context.
  • Re-train on larger, representative data before real use.
Downloads last month
5
Safetensors
Model size
28.8M params
Tensor type
F32
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for jacob5269/bullying-detector

Finetuned
(28)
this model