Pricing, context window, capabilities, and release date — pulled from each provider's public docs. Both are available via the same AIgateway OpenAI-compatible endpoint; flip the model string to switch.
Both models stream in parallel through your own AIgateway key. Tokens, latency, and cost update as they arrive.
| Stable-Diffusion-XL-Lightning bytedance/stable-diffusion-xl-lightning | Stable-Diffusion-XL-Base-1.0 stabilityai/stable-diffusion-xl-base-1.0 | |
|---|---|---|
| Provider | ByteDance | Stability AI |
| Family | Stable Diffusion | Stable Diffusion |
| Modality | image | image |
| Context window | — | — |
| Max output | — | — |
| Released | 2024-02-27 | 2023-11-10 |
| Input price | $0.0000 /img | $0.0000 /img |
| Output price | — | — |
| Cache read | — | — |
| Tools | — | — |
| Streaming | — | — |
| Vision | — | — |
| JSON mode | — | — |
| Reasoning | — | — |
| Prompt caching | — | — |
SDXL-Lightning is a lightning-fast text-to-image generation model. It can generate high-quality 1024px images in a few steps.
Diffusion-based text-to-image generative model by Stability AI. Generates and modify images based on text prompts.
# pip install aigateway-py openai
# aigateway-py: sub-accounts, evals, replays, jobs, webhook verify.
# openai SDK: chat/embeddings/images/audio — drop-in compat per our SDK's own guidance.
from openai import OpenAI
client = OpenAI(
base_url="https://api.aigateway.sh/v1",
api_key="sk-aig-...",
)
# Try Stable-Diffusion-XL-Lightning
client.chat.completions.create(
model="bytedance/stable-diffusion-xl-lightning",
messages=[{"role":"user","content":"hello"}],
)
# Try Stable-Diffusion-XL-Base-1.0 — same client, same key
client.chat.completions.create(
model="stabilityai/stable-diffusion-xl-base-1.0",
messages=[{"role":"user","content":"hello"}],
)