BSD Ports

ai/py-litellm 1.102.1 MidnightBSD

Call all LLM APIs using the OpenAI format

System
MidnightBSD
Repository
mports
Maintainer
[email protected]
Last update
Commit
c47321e65f
License
mit
Categories
ai, python

Description

Call all LLM APIs using the OpenAI format [Bedrock, Huggingface, VertexAI, TogetherAI, Azure, OpenAI, etc.]

LiteLLM manages:

  • Translate inputs to provider's completion, embedding, and image_generation endpoints
  • Consistent output, text responses will always be available at ['choices'][0]['message']['content']
  • Retry/fallback logic across multiple deployments (e.g. Azure/OpenAI)
    • Router
  • Track spend & set budgets per project OpenAI Proxy Server

Install

Binary package:

mport install ${PYTHON_PKGNAMEPREFIX}litellm

From mports:

cd /usr/mports/ai/py-litellm && make install clean

To depend on this port in another port's Makefile:

RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}litellm>0:ai/py-litellm

Dependencies

As this port's Makefile names them.

Build 1

Library 1

Runtime 14

Build dependencies 2
Run dependencies 15
Required by 1

Configuration

Options name: ai_litellm

OptionDefaultDescription
DOCSoff
USES
cargo python shebangfix
Service scripts
none

Files

distinfo 412
FileSizeSHA256
litellm-1.102.1.tar.gz1.8489222e+077216f46e6a1eba50f4dbb6000afdb1f5b77360eb498a4f341fc655191108cfd4
rust/crates/adler2-2.0.1.crate13366320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa
rust/crates/ahash-0.8.12.crate434135a15f179cd60c4584b8a8c596927aadc462e27f2ca70c04e0071964a73ba7a75
rust/crates/aho-corasick-1.1.5.crate184315c982642fa9e8606056828ee9a8505737230110bb1099153c79efe865c59d12ba
rust/crates/alloca-0.4.0.crate4257e5a7d05ea6aea7e9e64d25b9156ba2fee3fdd659e34e41063cd2fc7cd020d7f4
rust/crates/android_system_properties-0.1.6.crate5625ae221649c9976a6f6c56ae1facf410f3ddb33cc661c4b7b61020a912d4237fbc
rust/crates/anes-0.1.6.crate238574b46cbb362ab8752921c97e041f5e366ee6297bd428a31275b9fcf1e380f7299
rust/crates/anstyle-1.0.14.crate17787940b3a0ca603d1eade50a4846a2afffd5ef57a9feac2c0e2ec2e14f9ead76000
rust/crates/arc-swap-1.9.2.crate81495c049c0be4daef0b145cb3555416b3b8ef5b7888a38aea1a3a155801fe7b0810b
rust/crates/async-compression-0.4.46.crate1030734f10dafd0c8d2e51ae9a748805777613ed0bbe17bf586b76c8311f45c020a32f
rust/crates/async-lock-3.4.2.crate39826290f7f2596bd5b78a9fec8088ccd89180d7f9f55b94b0576823bbbdc72ee8311
rust/crates/async-trait-0.1.91.crate32108ae36dc4177970ef04fde5178d3e2429882def40e57a451f919c098f72baa6cec
rust/crates/atomic-waker-1.1.2.crate124221505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0
rust/crates/autocfg-1.5.1.crate18911f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53
rust/crates/aws-config-1.9.0.crate15824147712fde1909402600ccfbb26e47d482d2e58bb9e9e603d9f17e67cc435a6319
rust/crates/aws-credential-types-1.3.0.crate21288e93964ffdaf57857f544be3666a5f57570bb699e934700f11b49708f61bb556e
rust/crates/aws-lc-rs-1.17.3.crate24246900bdb5da18dac48ca2cc7cd4a98e533e8635a58e2361d13a1a4ee3888e0d72f1
rust/crates/aws-lc-sys-0.43.0.crate9.662543e+0643103168cc76fe62678a375e722fc9cb3a0146159ac5828bc4f0dfd755c2224c
rust/crates/aws-runtime-1.8.1.crate862557816e98ee912159f45d307e5ee6bfea4a335a55aee15f7f3e32f81a6f3000f1d
rust/crates/aws-sdk-sts-1.108.0.crate2037633c72b08911d8128dd360fe1b22a9fec0fa8b552dde8ec828dcf20ef5ec974e9f
Master sites 1
  • PYPI

Commit history 4

DateCommitCreditsLog message
c47321e65f Lucas Holt ai/py-litellm: update to 1.102.1, convert to cargo + maturin (#1609)
Closes #1271. Updates `ai/py-litellm` from 1.91.4 to 1.102.1, the current PyPI release. From 1.92.0, upstream builds with maturin and ships a pyo3 Rust extension (`litellm.rust_bridge._native`), so the package is no longer pure Python. The earlier blockers, #1269 (aiohttp) and #1270 (boto3), are both closed. ## Changes - `USES=cargo python shebangfix`. `CARGO_CARGOTOML`/`CARGO_CARGOLOCK` point at the `litellm-rust/` workspace, and maturin drives cargo (`CARGO_BUILD=no`, `CARGO_INSTALL=no`, `MAKE_ENV=${CARGO_ENV}`, `BINARY_ALIAS=python3=${PYTHON_CMD}`). This follows `textproc/py-tokenizers`, which also has its Cargo workspace in a subdirectory. - `Makefile.crates` lists 411 crates, generated with `bmake cargo-crates`. None come from git. …
d31e6c7450 Lucas Holt *: bump PORTREVISION for py-aiohttp and py-brotli updates (#1280)
Rebuilds dependents of the two large version jumps in #1269: `www/py-aiohttp` 3.9.3 -> 3.14.3 (#1279) and `archivers/py-brotli` 1.0.9 -> 1.2.0 (#1278). 25 ports, `PORTREVISION` lines only — no other change in the diff. ### py-aiohttp dependents (18) plus devel/py-vcrpy `ai/py-datasets`, `ai/py-langchain-community`, `ai/py-langchain-google-community`, `ai/py-litellm`, `ai/py-tritonclient`, `devel/py-aiobotocore`, `devel/py-azure-core`, `devel/py-black`, `devel/py-gql`, `devel/py-sentry-sdk`, `devel/py-strawberry-graphql`, `devel/py-vcrpy`, `dns/py-idna_ssl`, `filesystems/py-s3fs`, `ftp/py-parfive`, `mail/py-postfix-mta-sts-resolver`, `security/py-google-auth`, `textproc/py-elasticsearch`, `www/py-google-resumable-media` …
6acc65e460 Lucas Holt ai/py-litellm: update to 1.91.4 (#1267)
Update `ai/py-litellm` from 1.89.3 to 1.91.4. Dependency constraints are unchanged from 1.89.3, so no `RUN_DEPENDS` edits are needed and `PORTREVISION` resets. ### Why 1.91.4 and not 1.101.0 The current release is 1.101.0, but everything above 1.91.4 pulls in work outside a version bump: | Boundary | What changes | | --- | --- | | 1.91.5+ | aiohttp floor rises to `>=3.14.2`; `www/py-aiohttp` is at 3.9.3. Updating it needs two new ports (`propcache`, `aiohappyeyeballs`), a `www/py-yarl` bump to `>=1.17.0`, and `PORTREVISION` bumps across its 30 dependents. | | 1.92.0+ | Build backend moves from `uv_build` to `maturin` with a pyo3 Rust extension — needs `USES=cargo`, `CARGO_CRATES` for 258 crates, and dropping `NO_ARCH`. | …
dee1e47e52 Lucas Holt ai: add new category and move AI/ML ports from misc
Create the ai category (Artificial intelligence and machine learning) and relocate 42 AI/ML ports from misc into it. - Register ai in Mk/bsd.mport.mk VALID_CATEGORIES and the top-level Makefile - Add ai/Makefile; drop the moved entries from misc/Makefile (also removes the stale linux-claude SUBDIR left over from the claude-code rename) - git mv 42 ports and set their primary CATEGORIES to ai - Rewrite misc/<port> dependency origins to ai/<port> in external dependents (devel/py-beartype, math/py-faiss, multimedia/py-torchcodec, textproc/py-tokenizers) and among the moved ports themselves - Record the origin migrations in MOVED Ports moved: chatgpt-shell-cli, claude-code, claude-code-legacy, clawhub, codex, gemini-cli, github-copilot-cli, grok-cli, lean-ctx, llama-cpp, ollama, …