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.0.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.0-py3-none-any.whl (6.7 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: perspective-1.0.0.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.0.tar.gz
Algorithm Hash digest
SHA256 b2fd24f06fc628a7761a7267877acb7884b31eb9d7e1b3ea204873be1422843e
MD5 888354a8336b80043229be507322a80f
BLAKE2b-256 35abd70de018b65fee46cb09bd78a2bc3278df0a9844bdd5ed6450684387c17b

See more details on using hashes here.

File details

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

File metadata

  • Download URL: perspective-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 6.7 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.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e8f6e5a1ec8f4f4734704e6e9f5614658df636d466ca05df0a0f922f767fec43
MD5 806ed2a3948a750cb4101bc39593ae13
BLAKE2b-256 a3dbb3e93e2b6915887033f8f4b916b943add2d4e9d4e74f1a4896c48ddb56a7

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