pnpm add @ai-stats/sdk
|
pip install ai-stats-py-sdk
100+ models across 10+ providers on the API today.
Use AI Stats as both a unified gateway API and a model intelligence database to compare real-world model performance.
- Route requests with policy-aware failover and provider selection.
- Use OpenAI-compatible endpoints plus gateway-specific controls.
- Track telemetry, spend, and reliability in one place.
- Compare model and provider performance across a broad database of benchmark and usage data.
- Build on a transparent OSS stack with security-first defaults.
| Surface | Status | Notes |
|---|---|---|
| REST API | Available | Unified gateway endpoints with OpenAI-compatible request patterns. |
TypeScript SDK (@ai-stats/sdk) |
Available | First-party SDK for TS/JS apps and services. |
Python SDK (ai-stats-py-sdk) |
Available | First-party Python SDK for backend and data workflows. |
| Model database + comparisons | Available | Explore benchmark, usage, and provider-level performance across models. |
| Other SDK languages (Go, C#, PHP, Ruby, more) | In progress | Generated SDKs and language support are actively expanding. |
| Web dashboard + docs | Available | Routing controls, usage visibility, and integration documentation. |
| Endpoint | Status | Notes |
|---|---|---|
/v1/responses |
Available | Primary unified endpoint for most generation workflows. |
/v1/chat/completions |
Available | OpenAI-compatible chat completions support. |
/v1/messages |
Available | Anthropic Messages-compatible support. |
/v1/embeddings |
Available | Vector embedding generation. |
/v1/moderations |
Available | Safety and moderation scoring. |
| Image generation | Roadmap (ASAP) | Priority rollout with unified input/output behavior. |
| Audio generation | Roadmap (ASAP) | Priority rollout for speech and related audio outputs. |
| Video generation | Roadmap (ASAP) | Priority rollout for async and long-running generation jobs. |
| Music generation | Roadmap (ASAP) | Priority rollout as part of multimodal expansion. |
Sign up at https://ai-stats.phaseo.app and create your first API key from the dashboard.
Top up credits in the dashboard, or start immediately with one of the free-supported models.
Use the Playground in the web app, or call the API from your app with @ai-stats/sdk, ai-stats-py-sdk, or direct HTTP.
Integrate AI Stats in any stack where you can make HTTP requests.
Our goal is to make AI as easy as possible to get running across many models and providers.
apps/web: Next.js web app.apps/api: Hono + Cloudflare Workers gateway.apps/docs: Mintlify docs.packages/sdk/*: All SDK implementations for the platform (TypeScript, Python, and other language SDKs).packages/sdk/sdk-ts: TypeScript SDK package (@ai-stats/sdk).packages/sdk/sdk-py: Python SDK package (ai-stats-py-sdk).
flowchart LR
Client["Your apps and SDKs"] --> Gateway["AI Stats Gateway API"]
Gateway --> Router["Routing and policy engine"]
Router --> Providers["Provider adapters"]
Gateway --> DB["Usage and metadata database"]
Gateway --> Cache["Caching and performance layer"]
Web["AI Stats web app"] --> DB
Docs["Documentation"] --> Spec["OpenAPI specification"]
import OpenAI from "openai"; const client = new OpenAI({ apiKey: process.env.AI_STATS_API_KEY, baseURL: "https://api.phaseo.app/v1", }); const result = await client.chat.completions.create({ model: "gpt-5-nano-2025年08月07日", messages: [ { role: "user", content: "Summarize AI Stats in one sentence." }, ], }); console.log(result.choices[0]?.message?.content);
import requests response = requests.post( "https://api.phaseo.app/v1/responses", headers={ "Authorization": "Bearer YOUR_API_KEY", "Content-Type": "application/json", }, json={ "model": "gpt-5-nano-2025年08月07日", "messages": [{"role": "user", "content": "Hello from Python."}], }, timeout=60, ) print(response.json())
curl https://api.phaseo.app/v1/chat/completions \ -H "Authorization: Bearer $AI_STATS_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "gpt-5-nano-2025年08月07日", "messages": [{"role":"user","content":"Hello from curl."}] }'
- API and developer docs:
https://docs.ai-stats.phaseo.app - Contribution guide:
./CONTRIBUTING.md - Code of Conduct:
./CODE_OF_CONDUCT.md - Security policy:
./SECURITY.md - Good First Issues
We actively welcome contributions across web, API, docs, data quality, SDKs, and tooling.
Every contribution is reviewed before merge, and we encourage both first-time and experienced contributors to get involved.
Please review ./CONTRIBUTING.md and ./CODE_OF_CONDUCT.md before opening a PR.
Please report vulnerabilities privately via GitHub Security Advisories (preferred) or security@phaseo.app.
- Multimodal coverage (ASAP): ship unified image, audio, video, and music generation support with consistent request/response behavior.
- Provider expansion: continue growing provider coverage and compatibility depth while improving failover quality.
- Routing intelligence: improve latency/throughput/cost-aware routing controls and observability for production workloads.
- SDK and docs parity: keep SDKs and documentation tightly aligned with gateway capabilities and release cadence.
- Developer workflow: keep making API onboarding, playground testing, and migration from other platforms simpler.
- Community-built roadmap: prioritize features with community input and contributor PRs.
- Core apps (
apps/web,apps/api,apps/docs) are AGPL-3.0. - SDKs under
packages/sdk/*are MIT. - Full terms:
./LICENSE.