Skip to main content

Official SDK for building apps on the Claritty Platform

Project description

claritty-sdk

Official Python SDK for building apps on the Claritty Platform.

Generated apps deployed on Claritty automatically get a CLARITTY_PLATFORM_URL and CLARITTY_AUTH_TOKEN injected at runtime. The SDK reads those env vars and routes all LLM calls through the platform proxy — metering them against the app owner's plan, supporting BYOK (bring-your-own-key) when configured.

Installation

pip install claritty-sdk

Quick start

from claritty_sdk.llm import get_llm_client

client = get_llm_client("claude-sonnet-4-6")
result = client.chat([{"role": "user", "content": "Explain quantum computing"}])
print(result.content)

Streaming:

for delta in client.chat_stream(messages=[
    {"role": "user", "content": "Write me a haiku about kubernetes"}
]):
    print(delta, end="", flush=True)

Wire format

The proxy speaks OpenAI Chat Completions, so you can also point the official openai Python package at ${CLARITTY_PLATFORM_URL}/api/v1 if you want a drop-in replacement. The surface here just gives you sensible Python defaults (env-var auto-config, dict messages, generator-based streaming).

License

MIT

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

claritty_sdk-2.2.0.tar.gz (93.2 kB view details)

Uploaded Source

Built Distribution

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

claritty_sdk-2.2.0-py3-none-any.whl (110.2 kB view details)

Uploaded Python 3

File details

Details for the file claritty_sdk-2.2.0.tar.gz.

File metadata

  • Download URL: claritty_sdk-2.2.0.tar.gz
  • Upload date:
  • Size: 93.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.4

File hashes

Hashes for claritty_sdk-2.2.0.tar.gz
Algorithm Hash digest
SHA256 d0b761abf6d9f1a31c5d1557399b8896cf06fe5ffb6a309f0a02c0ced3f70d2f
MD5 638b053a12391c4eaf6c2639ef6ece81
BLAKE2b-256 7b57841be22e4e13dfdc81635afdee22368b31c0b2a0252d5be8c04878bcc5b3

See more details on using hashes here.

File details

Details for the file claritty_sdk-2.2.0-py3-none-any.whl.

File metadata

  • Download URL: claritty_sdk-2.2.0-py3-none-any.whl
  • Upload date:
  • Size: 110.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.4

File hashes

Hashes for claritty_sdk-2.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e3001c6a9aee1aa1c271edb2bbb25d538062d69ffb62b1b90b09fd7cf680d06e
MD5 41e48322e5cc73c2e1c291466da732c3
BLAKE2b-256 f121cd0da10d1f908f1ca78168bc2432e3f59130ae7fcb757388ac334f5ff248

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