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.


.. image:: https://www.pakutaso.com/shared/img/thumb/doiteneko171027_TP_V.jpg
:target: https://www.pakutaso.com/shared/img/thumb/doiteneko171027_TP_V.jpg
:alt: Demo Image.



.. raw:: html

<!--
https://www.pakutaso.com/20171036300post-13829.html
-->



Behold, the power of HateSonar:

.. code-block:: python

>>> 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``\ :

.. code-block:: bash

$ pip install hatesonar


.. raw:: html

<!--
## How to Contribute
1. Check for open issues or open a fresh issue to start a discussion around a feature idea or a bug. There is a Contributor Friendly tag for issues that should be ideal for people who are not very familiar with the codebase yet.
2. Fork the repository on GitHub to start making your changes to the master branch (or branch off of it).
3. Write a test which shows that the bug was fixed or that the feature works as expected.
4. Send a pull request and bug the maintainer until it gets merged and published. :) Make sure to add yourself to AUTHORS.
-->



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 Distribution

hatesonar-0.0.1.tar.gz (878.0 kB view details)

Uploaded Source

Built Distribution

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

Uploaded Python 3

File details

Details for the file hatesonar-0.0.1.tar.gz.

File metadata

  • Download URL: hatesonar-0.0.1.tar.gz
  • Upload date:
  • Size: 878.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for hatesonar-0.0.1.tar.gz
Algorithm Hash digest
SHA256 1b58b55a1ba222bb5c57ca29fd17dc5df593d0eb07dc87e28145680388321178
MD5 8b1ed1fc2d10cff87b50595a938c8c2d
BLAKE2b-256 e7fc9dc759febccadb759fca9b62f93b3241322fbbd7f585d84c62c1ce297e06

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for hatesonar-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 98583da1263e8197440ffee8c32da89262f92f1a23d74c6a79f7cdf88f3faf5a
MD5 ee02068d29aefe34a37b4bcaefcd2e65
BLAKE2b-256 28bee8200d1eefc84cb4fa6da85038c6671808345f0399374e3967afb2a388ad

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