Skip to main content

rates

A pricing registry and decision layer. One domain ships today: AI API rates, per-unit prices, capabilities, and lifecycle for 7,000+ models.

Before you start

rates needs Python 3.10+. Check with python3 --version; if that fails, install it from python.org/downloads.

Install

pip install rates

Zero dependencies, data bundled, works offline.

See it work

rates ai list
PROVIDER  MODEL                                TYPE  REASONING                  IN $/MTOK  OUT $/MTOK  STATUS
302ai     MiniMax-M1                           chat                             0.132      1.254       active
302ai     MiniMax-M2                           chat                             0.33       1.32        active
302ai     MiniMax-M2.1                         chat  yes                        0.3        1.2         active
...

20 of 7252 shown (--limit 0 shows all)
rates ai filter --provider anthropic --price-max 3 --price-unit input_mtok

Or from Python:

import rates.ai

registry = rates.ai.load()
under_a_dollar = registry.filter(price_max=1, price_unit="input_mtok")
cheapest_first = under_a_dollar.sort_by("price.input_mtok", descending=False)

The full manual, CLI and Python API both, is USAGE.md.

Why this exists

Provider pricing pages change often, aren't machine-readable, and don't answer the question a dev has mid-build: which option, for this job, at this budget. Several raw feeds exist (models.dev, genai-prices, LiteLLM's model_prices_and_context_window.json, OpenRouter), each missing pieces the others carry. rates fuses them into one schema rather than duplicating any single one, cross-validates prices between them, and ships the result as a dated, versioned snapshot none of them offer on their own.

The registry holds what could be gathered with verifiable per-unit pricing; services whose pricing isn't published, isn't accessible, or isn't per-unit at all aren't listed. See ARCHITECTURE.md for the design, and ERD.md for the schema itself.

License

rates is MIT licensed. The bundled ledger is derived from the upstream sources above, which carry their own licenses and terms; NOTICE reproduces their copyright notices and records what each one contributes.


By Mo Shehu

Metadata

Release files for rates 1.0.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 rates 1.0.0
File Size Uploaded
rates-1.0.0.tar.gz 340.9 kB Details

Built distribution (wheel)

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

Total release size: 612.2 kB

Release files / rates-1.0.0.tar.gz

Download URL rates-1.0.0.tar.gz
Size 340.9 kB
Tags Source
SHA-256 checksum
How to use checksums
1d3bade7bb6d4c875da7c1210f00931ced33df220d0b12f72bd9d3a3b997f208
BLAKE2b-256 checksum
How to use checksums
e32b3fe09e4fa6ed17673c0ce3e89ad70b43746be10ba9d2001c013a1496cdd6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 10, 2026.

Transparency log

Release files / rates-1.0.0-py3-none-any.whl

Download URL rates-1.0.0-py3-none-any.whl
Size 271.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a680214d886915eb6585096193f764e759cea6ee20f2ac0f92bb22a251066265
BLAKE2b-256 checksum
How to use checksums
9fdeebac5e3ca9d93e52f18f8e79c6700a641751d3f72df83e92bb25f2891664
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 10, 2026.

Transparency log

Release history Release notifications | RSS feed

1.1.0

2 release files

1.0.2

2 release files

1.0.1

2 release files

This release

1.0.0 This release

2 release files

0.0.4

2 release files

0.0.3

2 release files

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