Skip to main content

Python SDK for the ColabOne API — unified access to multiple AI models

Project description

colabone-python

Python SDK for the ColabOne API — unified async access to multiple AI models (Claude, GPT, etc.).

Installation

pip install colabone-python

Quick Start

import asyncio
from colabone import ColabOne

async def main():
    client = ColabOne(api_key="your-api-key")

    response = await client.chat.completions.create(
        model="claude-sonnet-4-6",
        messages=[{"role": "user", "content": "Hello!"}],
        max_tokens=200,
    )
    print(response["choices"][0]["message"]["content"])

    await client.close()

asyncio.run(main())

Streaming

response = await client.chat.completions.create(
    model="claude-sonnet-4-6",
    stream=True,
    messages=[{"role": "user", "content": "Hello!"}],
    max_tokens=200,
)
async for chunk in response:
    delta = chunk.get("choices", [{}])[0].get("delta", {})
    print(delta.get("content") or "", end="", flush=True)

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

colabone_python-1.0.0.tar.gz (14.2 kB view details)

Uploaded Source

Built Distribution

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

colabone_python-1.0.0-py3-none-any.whl (24.3 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: colabone_python-1.0.0.tar.gz
  • Upload date:
  • Size: 14.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for colabone_python-1.0.0.tar.gz
Algorithm Hash digest
SHA256 0c86487692d523196735d70507d3ab7e04c3da57ba3aeefef0b992e225184200
MD5 4e7fb8d3bf37c65c3d506ae9da3bc1e9
BLAKE2b-256 a9bedd628309d756ea619ab7aff5d6c423cc9dcaba39e0ffc9ea86b8d69d8ebb

See more details on using hashes here.

Provenance

The following attestation bundles were made for colabone_python-1.0.0.tar.gz:

Publisher: publish.yml on colabintelligence-source/colabone-python

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

File details

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

File metadata

  • Download URL: colabone_python-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 24.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for colabone_python-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 47d0596b16176fe0100af053c77a629a32d96654b96506ef1cf7be959239ab73
MD5 6c1e0acfadcef7549f9f3f9233ddf6cd
BLAKE2b-256 7bc017b6750f4d95c14453bf498e7f29602f11555948ad10b04bc4eaad7805bb

See more details on using hashes here.

Provenance

The following attestation bundles were made for colabone_python-1.0.0-py3-none-any.whl:

Publisher: publish.yml on colabintelligence-source/colabone-python

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