Skip to main content

A package for interacting with the Perspective API

Project description

perspective

perspective is an API wrapper for Google's Perspective API

Installation

To install, use pip install perspective

Usage

A simple example:

from perspective import PerspectiveAPI
p = Perspective("API_KEY")
result = p.score("This is a comment")
print("Toxicity score: " + result["TOXICITY"])

More complex

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

perspective-1.0.2.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

perspective-1.0.2-py3-none-any.whl (6.9 kB view details)

Uploaded Python 3

File details

Details for the file perspective-1.0.2.tar.gz.

File metadata

  • Download URL: perspective-1.0.2.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.4 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.1 CPython/3.9.6

File hashes

Hashes for perspective-1.0.2.tar.gz
Algorithm Hash digest
SHA256 d9b920a185d568f037ec013dd0ca449b6940f11cd2bdf4b0dcbef8ed27aa3486
MD5 cbe4efb341feae1d0f53a87ab6f665eb
BLAKE2b-256 fe81da52db9fc6c104e1f3780ab19f84be7efd15677dda022dd893fd5c034c61

See more details on using hashes here.

File details

Details for the file perspective-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: perspective-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 6.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.4 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.1 CPython/3.9.6

File hashes

Hashes for perspective-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 127abdc09813dca8657231d39182cca99b298085b228f3c36fcf000ee1157fc6
MD5 2dfa93ec213ab317d29befe51bdbdba4
BLAKE2b-256 5e27f15f1ce8ca1c42f2a3b3be862f8bd1bdc392d93fe4d9fc56c5b4dea251eb

See more details on using hashes here.

Supported by

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