Skip to main content

Official Python SDK for Kynth Core — the AI back-end for your product.

Project description

kynth

Official Python SDK for Kynth Core — the AI back-end for your product. Parse documents, extract fields, redact PII, analyze contracts, fight chargebacks, and enrich companies.

pip install kynth

Quickstart

from kynth import Kynth

client = Kynth(api_key="ksk_live_...")

doc = client.parse(file_url="https://.../invoice.pdf")
print(doc["totalAmount"])              # 4820.5
print(doc["usage"]["balanceRemaining"])  # 490

Get a key (and 500 free credits) at api.kynth.studio. Zero dependencies — stdlib only, Python 3.8+.

Methods

Every method returns the endpoint result as a dict, including a usage envelope. A non-2xx response raises a typed KynthError (and never burns credits).

client.parse(file_url=...)                                  # documents → JSON
client.extract(text=..., fields=["order", "total"])         # pull named fields
client.classify(text=..., labels=["billing", "tech"])       # label text
client.summarize(text=..., length="standard")               # summary + actions
client.redact(text=...)                                      # strip PII/PHI
client.sentiment(text=..., aspects=["product"])             # sentiment + aspects
client.contract(file_url=...)                               # contract → terms + risks
client.chargeback(reason=..., transaction={"amount": 129})  # representment packet
client.enrich(email="sam@stripe.com")                       # company profile
client.account()                                            # balance

Error handling

from kynth import Kynth, KynthError

client = Kynth(api_key="ksk_live_...")
try:
    client.parse(file_url="https://.../invoice.pdf")
except KynthError as err:
    # err.code: "insufficient_credits" | "rate_limited" | "unauthorized" | ...
    print(err.code, err.status, err.message)

MIT © Kynth Studios

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

kynth-0.1.0.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

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

kynth-0.1.0-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for kynth-0.1.0.tar.gz
Algorithm Hash digest
SHA256 726f9c6b13858daafb889d61cab6fb66151f7fb932cc15a29c31539c94adeebd
MD5 8f04099721beb957d0a1a4af91de962b
BLAKE2b-256 e8977138713d0da7c2724d9d4c7bca6d1a9bd49c289c8e03d058b2438cc9166a

See more details on using hashes here.

File details

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

File metadata

  • Download URL: kynth-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.6

File hashes

Hashes for kynth-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3db97efc023799f8c66294b94c57c3ddc6b2e823d7452c6db804198e6ec47c39
MD5 fc5556a4104ebd0b6f8588a9db419985
BLAKE2b-256 88bb1df804eb7d3600ed5fb060895c625686e72eb429e404663abffd2a996d84

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