Metadata-Version: 2.4
Name: aiwave
Version: 0.2.0
Summary: AIWave API — One API key for 97 AI routes (10 Chinese families + 13 video routes), OpenAI compatible
Home-page: https://aiwave.live
Author: AIWave
Author-email: AIWave <support@aiwave.live>
License: MIT
Project-URL: Homepage, https://aiwave.live
Project-URL: Documentation, https://aiwave.live
Project-URL: Pricing, https://aiwave.live/pricing
Project-URL: Blog, https://aiwave.live/blog/
Project-URL: Repository, https://github.com/AIWaveAPI/aiwave-sdk-python
Project-URL: Issues, https://github.com/AIWaveAPI/aiwave-sdk-python/issues
Keywords: ai,llm,deepseek,glm,kimi,openai,api,chinese-ai,aiwave
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: openai>=1.0.0
Dynamic: author
Dynamic: home-page
Dynamic: license-file
Dynamic: requires-python

# AIWave Python SDK

**One OpenAI-compatible API for Chinese AI models — and AI video. 97 public routes, 10 Chinese families, 10 public video routes.**

[![PyPI](https://img.shields.io/pypi/v/aiwave)](https://pypi.org/project/aiwave/)
[![Models](https://img.shields.io/badge/public%20rate%20card-97%20routes-blue)](https://aiwave.live/models)
[![Video](https://img.shields.io/badge/public%20video%20routes-10-purple)](https://aiwave.live/models)
[![Python](https://img.shields.io/badge/python-3.8%2B-blue)](https://python.org)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)

AIWave gives developers one OpenAI-compatible API route for Chinese AI model families — DeepSeek, GLM, Kimi, Qwen, MiniMax, Doubao, StepFun, MiMo — plus AI video routes (Kling, Seedance, Hailuo, Wan, Vidu).

Get a key at [aiwave.live/register](https://aiwave.live/register) — free tier included.

Use this SDK when you want a Python client path to AIWave while keeping model IDs, dated USD rates, and request-level usage evidence visible during testing.

## Installation

```bash
pip install aiwave
```

## Quick start with the AIWave client

```python
import os
from aiwave import AIWave

client = AIWave(api_key=os.environ["AIWAVE_API_KEY"])

response = client.chat.completions.create(
    model="deepseek-v4-flash",
    messages=[{"role": "user", "content": "Hello"}],
)

print(response.choices[0].message.content)
print(response.usage)
```

Store API keys outside source control. The example above uses an environment variable and does not include a real key.

## OpenAI-compatible client path

For supported chat requests, you can also use the official OpenAI Python client with the AIWave base URL:

```python
import os
from openai import OpenAI

client = OpenAI(
    api_key=os.environ["AIWAVE_API_KEY"],
    base_url="https://aiwave.live/v1",
)

response = client.chat.completions.create(
    model="deepseek-v4-flash",
    messages=[{"role": "user", "content": "Hello"}],
)

print(response.usage)
```

## AI video

One key, video routes on Kling, Seedance, Hailuo, Wan and Vidu.

```python
from aiwave import AIWave

client = AIWave(api_key="YOUR_API_KEY_HERE")

job = client.video.generate(
    model="kling-v2-6",
    prompt="A red sports car drifting through a neon-lit city at night, cinematic tracking shot",
)
print(job.task_id)

done = client.video.wait(job.task_id)   # polls every 15s, 15 min max
print(done.status)
```

Video routes are experimental and need a paid account group (from $5). A single
shot takes 5-11 minutes.

## What to verify before production

- Confirm the current model ID in the [AIWave model catalog](https://aiwave.live/models/).
- Check the dated USD rates on the [AIWave pricing page](https://aiwave.live/pricing).
- Run one representative workload and review the request-level usage record.
- Keep timeout, retry, privacy, and model-quality acceptance checks in your own application.

## Resources

- [AIWave home](https://aiwave.live/)
- [Live pricing and model catalog](https://aiwave.live/pricing)
- [API docs](https://aiwave.live/docs/)
- [Developer field notes](https://aiwave.live/blog/)
- [Node.js SDK](https://github.com/AIWaveAPI/aiwave-sdk-node)

## License

MIT — [AIWave](https://aiwave.live)
