flaskbullybert / README.md
Davephoenix's picture
Add Flask app for bullying classification
4991c1b
metadata
title: Bullying Classifier API
emoji: 🛡️
colorFrom: indigo
colorTo: blue
sdk: docker
app_port: 7860
pinned: false

Bullying Classifier API

This Flask application provides a RESTful API for classifying text inputs as bullying or not using a BERT-based model.

Endpoints

  • POST /classify/text – Classifies text as bullying or not.
  • POST /classify/audio – Placeholder for audio classification.
  • POST /classify/image – Placeholder for image classification.

Usage

Send a POST request to /classify/text with a JSON body:

{
  "text": "your text here"
}

Docker

Build and run the container:

docker build -t bullying-classifier .
docker run -p 7860:7860 bullying-classifier