Skip to main content

Python client for the Greenophy substantiveness classification API.

Project description

Greenophy Client

Small Python helper package for calling the Greenophy substantiveness API.

Installation

pip install .

Usage

from greenophy_client import SubstantivenessClient

client = SubstantivenessClient(
    base_url="https://greenophy-service-xyz.a.run.app",
    api_key="your-shared-token",  # optional
)

results = client.classify_text("We transitioned 70% of our fleet to EVs in 2023.\nWe value teamwork.")
for item in results:
    print(item.index, item.label_name, item.sentence)

The same client exposes classify_sentences([...]) if you prefer passing your own sentence list.

Use client.close() when you are done (or create it with a context manager).

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

greenophy_client-0.1.0.tar.gz (2.8 kB view details)

Uploaded Source

Built Distribution

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

greenophy_client-0.1.0-py3-none-any.whl (3.2 kB view details)

Uploaded Python 3

File details

Details for the file greenophy_client-0.1.0.tar.gz.

File metadata

  • Download URL: greenophy_client-0.1.0.tar.gz
  • Upload date:
  • Size: 2.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.7

File hashes

Hashes for greenophy_client-0.1.0.tar.gz
Algorithm Hash digest
SHA256 4188b1f3224b117a46145501fb73966ca4d5bfcd5858fe7ebca58ed05b535732
MD5 c26d16651b3bfc8b2cd7a8b2216d6f4b
BLAKE2b-256 fb306158664c2e6e62d8a3df70bdbc6e0eb44b7883a1ee13fbf0d3df0a7db6b1

See more details on using hashes here.

File details

Details for the file greenophy_client-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for greenophy_client-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 84e9988c64591ff2a371d4a038472b8af3f5e75bf1a73ab8e8fef52a706ea575
MD5 db640048e986e527660acc48d29eb294
BLAKE2b-256 2d71f124ec487180209aef408e2b3e016029a302c2843963b95b7942980fab10

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