Skip to main content

Hate Speech Detection Library for Python

Project description

HateSonar: Hate Speech Detection

HateSonar is the hate speech detection library for Python.

Demo Image.

Behold, the power of HateSonar:

>>> from hatesonar import Sonar
>>> sonar = Sonar()
>>> sonar.ping(text="At least I'm not a nigger")
{
  "text" : "At least I'm not a nigger",
  "top_class" : "hate_speech",
  "classes" : [ {
    "class_name" : "hate_speech",
    "confidence" : 0.6001793646345871
  }, {
    "class_name" : "offensive_language",
    "confidence" : 0.399548534507691
  }, {
    "class_name": "neither",
    "confidence": 0.0002721008577219325
  } ]
}

HateSonar allows you to detect hate speech and offensive language in text, without the need for training. There's no need to train the model. You have only to fed text into HateSonar. It detects hate speech with the confidence score.

Feature Support

  • Hate speech and offensive language detection

HateSonar officially supports Python 2.7 & 3.4–3.6

Installation

To install HateSonar, simply use pip:

$ pip install hatesonar

Reference

Thomas Davidson, Dana Warmsley, Michael Macy, and Ingmar Weber. 2017. "Automated Hate Speech Detection and the Problem of Offensive Language." ICWSM.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

hatesonar-0.0.7-py3-none-any.whl (883.5 kB view details)

Uploaded Python 3

File details

Details for the file hatesonar-0.0.7-py3-none-any.whl.

File metadata

  • Download URL: hatesonar-0.0.7-py3-none-any.whl
  • Upload date:
  • Size: 883.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.7.7

File hashes

Hashes for hatesonar-0.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 c640a32b9e1f99190d97fefe40306c6421622161e9a26eb3c25c3a2408071835
MD5 accc5eb131a79b2197d67dc5efa002f0
BLAKE2b-256 d7858b2fc72232935c1833a556969194c183c5781c445f08404472e2dd941a3d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page