Skip to main content

CFLabs Python SDK

Project description

CFLabs SDK

Python SDK for interacting with the CFLabs/Octavian API.

Installation

pip install cflabs

Usage

from cflabs import CFLabs

# Initialize the client
client = CFLabs(
    api_key="your-api-key",  # or set CFLABS_API_KEY environment variable
    base_url="https://api.cflabs.com"  # optional, defaults to localhost:8000
)

# Run a prompt by ID
result = client.run(
    var_parameters={"input": "your input"}
)

# Or use a prompt slug
from cflabs import Prompt

prompt = Prompt(slug="my-prompt-slug", client=client)
result = prompt.run(var_parameters={"input": "your input"})

Configuration

The SDK can be configured using:

  • Constructor arguments
  • Environment variables: CFLABS_API_KEY

Requirements

  • Python >= 3.8
  • requests >= 2.31.0

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

cflabs-0.1.5.tar.gz (15.8 kB view details)

Uploaded Source

Built Distribution

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

cflabs-0.1.5-py3-none-any.whl (6.8 kB view details)

Uploaded Python 3

File details

Details for the file cflabs-0.1.5.tar.gz.

File metadata

  • Download URL: cflabs-0.1.5.tar.gz
  • Upload date:
  • Size: 15.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for cflabs-0.1.5.tar.gz
Algorithm Hash digest
SHA256 30cd3bd831990a948d2f4cf5b2965f13e27cf2a9b684561fb2dd55843941af1e
MD5 8e7157ea2080651c8630f2da63a13dd8
BLAKE2b-256 e4e6a34b5b081dbd0f8102711cbd535f48cadf7229314989fa5e7e51778e8250

See more details on using hashes here.

Provenance

The following attestation bundles were made for cflabs-0.1.5.tar.gz:

Publisher: publish-pypi.yml on chainforge-ai/sdk_octavian

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file cflabs-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: cflabs-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 6.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for cflabs-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 0e97271d38274728e2224b89199f7904fe3b7d3d3583253c2ea9ad565b4db7e4
MD5 5c140224e511ea4dd9c9bc76aea7705e
BLAKE2b-256 84b24e6fce18fbdbf0a89f1b8b13034c11cc10bd5e3332ef6abf903f51072173

See more details on using hashes here.

Provenance

The following attestation bundles were made for cflabs-0.1.5-py3-none-any.whl:

Publisher: publish-pypi.yml on chainforge-ai/sdk_octavian

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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