Skip to main content

celedog (Python)

OpenAI-compatible Python client for Celedog.io — one API, 400+ AI models, pay as you go.

pip install celedog

Quick start

import celedog

# Reads CELEDOG_API_KEY from the env; or pass it directly:
#   celedog.Client(api_key="sk-celedog-...")
client = celedog.Client()

resp = client.chat.completions.create(
    model="gpt-4o",
    messages=[{"role": "user", "content": "Hello, Celedog!"}],
)
print(resp.choices[0].message.content)

Async + streaming

import asyncio
import celedog

async def main():
    client = celedog.AsyncClient()
    stream = await client.chat.completions.create(
        model="gpt-4o",
        messages=[{"role": "user", "content": "Stream me a sentence."}],
        stream=True,
    )
    async for chunk in stream:
        print(chunk.choices[0].delta.content or "", end="", flush=True)

asyncio.run(main())

celedog.Client is a thin subclass of openai.OpenAI — every feature OpenAI ships (multimodal input, structured outputs, tool calling, vision, batch) works unchanged. Just point the SDK at Celedog with your sk-celedog-... key.

Configuration

Source Variable Default
Constructor api_key= —
Env CELEDOG_API_KEY —
Env (fallback) OPENAI_API_KEY —
Constructor base_url= https://celedog.io/v1
Env CELEDOG_BASE_URL https://celedog.io/v1

Other languages

Language Install
Python this package
Node.js / TypeScript npm install celedog
Go go get github.com/AIRES-Technology/celedog-go
Java Maven coordinate io.celedog:celedog:0.1.0 (GitHub Packages — see celedog-java)

License

MIT — free to use and integrate. The Celedog gateway server itself is AGPL-3.0 (see celedog.io); SDK code is permissive so you can ship it inside your closed-source app.

Metadata

Release files for celedog 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for celedog 0.1.0
File Size Uploaded Provenance Actions
celedog-0.1.0.tar.gz 3.7 kB Without provenance Details for celedog-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for celedog 0.1.0
File Interpreter ABI Platform Actions
celedog-0.1.0-py3-none-any.whl Python 3 none any Details for celedog-0.1.0-py3-none-any.whl

Total release size: 7.7 kB

Release files / celedog-0.1.0.tar.gz

Download URL celedog-0.1.0.tar.gz
Size 3.7 kB
Tags Source
SHA-256 checksum
How to use checksums
49c18efc40df368cee521d0586d41b7bb18ad989eff22b5cb735e9e4e474272b
BLAKE2b-256 checksum
How to use checksums
b1c3e3413567b36922676b4aea063fd2b9be47894741c1fb9346d5d0f94941e5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Release files / celedog-0.1.0-py3-none-any.whl

Download URL celedog-0.1.0-py3-none-any.whl
Size 4.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f67cf8842f0f3a4720c37063c08dd17bbc3ae74ecd71cc4284a131f02474ae68
BLAKE2b-256 checksum
How to use checksums
16db428bd3aa2167d875865632a4de12364a0dba1b1e8c69f2c3a0cb8e2b9bc5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Security for celedog 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page