llm-catalog-litellm
LiteLLM CustomLLM plugin for llm-catalog.
One implementation serves both in-process use and the central proxy.
For in-process use, call register() once to wire the handler into LiteLLM.
from llm_catalog.litellm import register
register() # reads ai-sdk-catalog.json (LLM_CATALOG_CONFIG or default path)
import litellm
resp = litellm.completion(
model="examplegw/fast",
messages=[{"role": "user", "content": "hi"}],
)
For the proxy, reference llm_catalog.litellm.handler from config.yaml's custom_provider_map (no register() call needed).
The handler resolves each model from ai-sdk-catalog.json itself (the JSON config shared verbatim with — and named after — ai-sdk-catalog; the legacy llm-catalog.json remains a deprecated fallback), so the proxy config never needs gateway details in litellm_params, sidestepping LiteLLM issue #18216.
Requires Python 3.12–3.14: LiteLLM declares requires-python <3.15, and this adapter mirrors that cap until LiteLLM lifts it.
LiteLLM is built on httpx and requires openai<3, while llm-catalog-pydantic-ai and llm-catalog-ai-sdk need openai>=3 (the httpx2 line), so install this adapter in its own environment rather than alongside those two.
See the repository README for the proxy operations guide and the verification notes (§9), including whether LiteLLM honours a custom httpx client (the route-1/route-2 decision in §6.2).
import namespace: llm_catalog.litellm
Metadata
Release files for llm-catalog-litellm 0.8.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| llm_catalog_litellm-0.8.1.tar.gz | 12.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| llm_catalog_litellm-0.8.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 25.8 kB
Release files / llm_catalog_litellm-0.8.1.tar.gz
| Download URL | llm_catalog_litellm-0.8.1.tar.gz |
|---|---|
| Size | 12.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fb87e62e8b3eecf0f42868c7444360cc9ab781bf455b91094dacf3ad26f1590c
|
|
BLAKE2b-256 checksum How to use checksums |
9f2ebc6d161e7fb71327f89a089c8942d4802a2836558c1dc471be6ace40ae75
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.0 {"installer":{"name":"uv","version":"0.13.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / llm_catalog_litellm-0.8.1-py3-none-any.whl
| Download URL | llm_catalog_litellm-0.8.1-py3-none-any.whl |
|---|---|
| Size | 13.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ec77580b454af7a6e86a45c4079882b65b51e65e99ea73bf595be9c73fa83c75
|
|
BLAKE2b-256 checksum How to use checksums |
b960f0cb1dbda31d814d65056f09118981739bb76cbfbaafcaaaf3ad0cf8cbcc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.0 {"installer":{"name":"uv","version":"0.13.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|