contribution/compass
BerriAI/litellm

LiteLLM

399 signals · 416 observation events

Open repository ↗

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

56.3K stars10.5K forksPythonNOASSERTIONai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmkeyword: LiteLLM
PROJECT NEWS

Release, roadmap, and discussion

All news →
BerriAI/litellm

LiteLLM

AI Infrastructure
Latest stable

v1.96.2

v1.96.2
  • Verify Docker Image Signature
  • The cosign claims were validated
  • The signatures were verified against the specified public key
  • What's Changed
  • chore(release): backport proxy request-handling maintenance and refresh runtime deps for 1.96.1 by @yuneng-berri in https://github.com/BerriAI/litellm/pull/36494
Original release notes ↗

Publicly indicated next

Prereleases and milestones indicate public plans; they are not delivery commitments.

Observation trail

  1. discoveredinitial snapshot
  2. discoveredinitial snapshot
  3. changedupdatedAt, metrics
  4. changedtext, updatedAt, metrics
  5. changedupdatedAt, metrics
  6. changedupdatedAt
  7. discoveredinitial snapshot
  8. changedupdatedAt, metrics
  9. changedupdatedAt, metrics
  10. changedupdatedAt
  11. changedupdatedAt, state
  12. changedupdatedAt, state
  13. changedupdatedAt, state
  14. changedupdatedAt, metrics
  15. changedupdatedAt
  16. discoveredinitial snapshot
  17. changedupdatedAt
  18. changedupdatedAt, metrics
  19. changedtext, updatedAt, metrics
  20. changedupdatedAt
  21. changedupdatedAt
  22. changedtext, updatedAt, metrics
  23. discoveredinitial snapshot
  24. discoveredinitial snapshot
  25. changedupdatedAt
  26. discoveredinitial snapshot
  27. discoveredinitial snapshot
  28. discoveredinitial snapshot
  29. changedtext, updatedAt, metrics
  30. discoveredinitial snapshot
49 shown
pull request

refactor(ui): migrate team detail controls to shadcn

## TLDR Problem this solves: - Shared team-detail controls still depend on antd and Tremor - Those dependencies block the shared-component migration track How it solves it: - Replaces both controls with installed shadcn primitives - Preserves member and virtual-key behavior with existing tests ## User Flow Before: an admin sees legacy controls inside a team

importance 3@yuneng-berriclosedOriginal evidence ↗
pull request

fix(cost): honor an explicit zero tier rate instead of the fallback

## TLDR Problem this solves: - A tiered-pricing tier that prices cached reads or reasoning tokens at an explicit `0.0` is billed at the fallback rate instead of being free - `calculate_tiered_cost` and `tier_rate` resolved a tier's per-token cost with `tier.get(cost_key) or tier.get(fallback_cost_key, 0)`, and the `or` short-circuits on a falsy `0.0`, so a r

importance 3@hsusulopenOriginal evidence ↗
pull request

refactor(ui): migrate guardrails content tables to shared DataTable

## TLDR Problem this solves: - Content filtering still rendered four legacy Ant Design tables - Table styling differed from the rest of the dashboard How it solves it: - Moves content filtering tables onto the shared DataTable - Preserves existing selects, buttons, tags, and callbacks ## User Flow Before: an admin configures content filtering through legacy

importance 3@yuneng-berriclosedOriginal evidence ↗
pull request

fix(cost): honor an explicit zero cache-creation cost in batch pricing

## TLDR Problem this solves: - A model that prices cache-write (cache creation) tokens at an explicit `0.0` is billed at the plain input rate in batch cost, not at 0 - `batch_cost_calculator` resolved the cache-write rate with `model_info.get("cache_creation_input_token_cost") or input_cost_per_token`, and the `or` short-circuits on a falsy `0.0`, so a real

importance 3@hsusulopenOriginal evidence ↗
pull request

docs(claude): drop the @ prefix from the PR template path

## TLDR Problem this solves: - `@`-prefixed path auto-inlines the PR template - Inlined copies get their HTML comment rules stripped How it solves it: - Reference the path as plain text instead ## User Flow Not user facing, this only changes agent guidance in CLAUDE.md ## Relevant issues ## Linear ticket ## Pre-Submission checklist - [x] I have added meaning

importance 3@devin-ai-integration[bot]closedOriginal evidence ↗
pull request

test(interactions): follow Google spec drift replacing Turn with typed steps

## TLDR Problem this solves: - Google removed the `Turn` schema from its live Interactions OpenAPI spec - The compliance test fetches that spec at CI time, so `test_turn_schema` now fails with `KeyError: 'Turn'` - That test is part of a required check, blocking every open PR How it solves it: - Replaces the `Turn` assertions with assertions on the step schem

importance 3@mateo-berriclosedOriginal evidence ↗
pull request

fix(interactions): map step and turn history to Responses API roles and content types

## TLDR Problem this solves: - Google's Interactions API sends step-based multi-turn input since Aug 13 - The bridge passed Google `{"type": "text"}` parts raw, so OpenAI models 400 - Step types and the legacy `model` role were never mapped to `assistant` - Anthropic rejected turn history; accepted step history but misattributed it How it solves it: - Maps `

importance 3@mateo-berriopenOriginal evidence ↗
pull request

refactor(ui): migrate TokenFlow and JsonViewer to shadcn

## TLDR Problem this solves: - Two log drawer components still render through antd - Both are shared by three routes, so neither had a test - Nothing proved a markup swap kept them identical How it solves it: - Characterise both against antd first, in their own commit - Migrate second, leaving those tests untouched and green - Prove pixel parity by driving t

importance 3@yuneng-berriopenOriginal evidence ↗
pull request

fix: forward claude-code-20250219 beta header for anthropic provider

## Summary - `claude-code-20250219` was missing from `anthropic_beta_headers_config.json`, causing `filter_and_transform_beta_headers` to silently drop it for every provider - Without this header reaching the upstream Anthropic API, the server never enters Claude Code mode, so IDE-integration tools (`Bash_ide`, `Skill_ide`, `Workflow_ide`) are never made ava

importance 3@Christian-SidakopenOriginal evidence ↗
pull request

refactor(ui): migrate SimpleMessageBlock and SimpleToolCallBlock to shadcn

## TLDR Problem this solves: - Two log-drawer message blocks still render through antd - Both hardcode hex colours instead of design tokens How it solves it: - Replaces antd Typography with plain elements and token classes - Keeps both components' existing tests green, unedited ## User Flow Before: an operator reading a request's messages sees blocks built f

importance 3@yuneng-berriopenOriginal evidence ↗
pull request

fix(helm): render nodeSelector on the migrations job

## TLDR Problem this solves: - Helm chart ignores `nodeSelector` on the migration job - The job lands on the wrong nodes and gets OOM-killed - Nothing warns you: the values look correct How it solves it: - Render `nodeSelector` in the migration job template - Add the chart test that would have caught it ## User Flow Before: an operator pins their LiteLLM ins

importance 3@yuneng-berriclosedOriginal evidence ↗
pull request

fix(proxy): prevent batch cost reconciliation starvation

Fixes #36640. Retire permanently unroutable unified batch IDs and provider 404s after recording the existing error metric, while continuing to retry configuration-dependent and transient failures. Adds focused regression coverage for permanent routing classification.

importance 3@mikemikimikeopenOriginal evidence ↗
pull request

fix(responses): sync logging stream state

## TLDR Problem this solves: - Bridged ChatGPT responses calls could miss cost tracking - Internal streams were logged as non-streaming requests How it solves it: - Records the provider-resolved streaming state before iteration - Keeps logging deduplication open until stream assembly completes ## User Flow Before: a developer sends a non-streaming chat reque

importance 3@steveonjavaopenOriginal evidence ↗
pull request

fix(model_prices): refresh deprecation dates, add grok-4.6 and gemini 3.1 flash tts

## TLDR Problem this solves: - Model map missed xai/grok-4.6 and Gemini 3.1 Flash TTS - Several deprecation dates were missing or stale vs provider docs How it solves it: - Adds xai/grok-4.6, xai/grok-4.6-latest, gemini/gemini-3.1-flash-tts-preview - Fixes gemini-embedding-001 shutdown date (2026-07-14, was 2028-05-14) - Adds published shutdown dates to Gemi

importance 3@devin-ai-integration[bot]openOriginal evidence ↗
pull request

test(e2e): assert the model allow-list permits, not only denies

## TLDR Problem this solves: - Every access-control case asserted only that something was refused - A gateway denying the allowed model too would pass them all - The unknown-model case accepted any JSON, even `{}` How it solves it: - Adds the allow-list's positive half: allowed model works - Requires a real error envelope with a client-surfaceable message ##

importance 3@yuneng-berriopenOriginal evidence ↗
pull request

fix(http_handler): preserve upstream error for streaming request bodies

## Summary Pipeline [#77387](https://app.circleci.com/pipelines/github/BerriAI/litellm/77387/workflows/7d02784e-92e7-4709-a6a5-ec0336e8b55c) failed mostly because the test OpenAI account has run out of quota (429 `insufficient_quota`) — that is an environment issue, not a code regression. While triaging the logs I found one real code bug that this PR fixes.

importance 2@mateo-berriclosedOriginal evidence ↗
pull request

feat(vertex-ai): support gemini 3.1 flash tts

## Relevant issues N/A ## Linear ticket N/A ## Pre-Submission checklist - [x] I have added meaningful tests - [ ] My PR passes all unit tests on `make test-unit` - [x] My PR's scope is as isolated as possible; it only solves 1 specific problem - [ ] I have requested a Greptile review by commenting `@greptileai` and received a Confidence Score of at least 4/5

importance 2@emerzonopenOriginal evidence ↗
pull request

fix(router): await budget redis pipeline before sync reads

## Relevant issues Fixes #32614 Refs #20886 Backports #20888 onto `litellm_internal_staging` ## Linear ticket ## Pre-Submission checklist **Please complete all items before asking a LiteLLM maintainer to review your PR** - [x] I have added meaningful tests - [x] My PR passes all CI/CD checks (e.g., lint, format, unit tests) - [x] My PR's scope is as isolated

importance 2@emerzonopenOriginal evidence ↗
pull request

fix(proxy): return rpm_limit and tpm_limit from /v2/user/info

## Relevant issues Fixes #33347 ## Linear ticket ## Pre-Submission checklist - [x] I have added meaningful tests - [x] My PR passes all CI/CD checks (e.g., lint, format, unit tests) - [x] My PR's scope is as isolated as possible; it only solves 1 specific problem - [x] I have received a Greptile **Confidence Score of at least 4/5** before requesting a mainta

importance 2@Souravrajvi0closedOriginal evidence ↗
pull request

Fix ModelResponse() PydanticUserError: forward reference not fully defined

## Summary Fixes #36384 Calling `ModelResponse()` with no arguments crashes with: ``` pydantic.errors.PydanticUserError: `Message` is not fully defined; you should define `ChatCompletionReasoningSummaryTextBlock`, then call `Message.model_rebuild()`. ``` ## Root Cause In `litellm/types/llms/openai.py`, the `ChatCompletionReasoningItem` TypedDict has a field:

importance 2@PiedPiper911openOriginal evidence ↗
pull request

fix: propagate budget_duration when creating new budget in /customer/update

## Summary When calling `/customer/update` with `budget_duration` and `max_budget`, the `budget_duration` was not being propagated to the newly created budget. This meant the budget reset schedule was never set. This PR fixes the issue by: 1. Adding `budget_duration` field to `UpdateCustomerRequest` in `_types.py` 2. Computing `budget_reset_at` from `budget_

importance 2@PiedPiper911Original evidence ↗
pull request

fix(ollama): ensure streaming chunks share consistent id and tool_calls finish_reason

## Problem When using Ollama with strict OpenAI API clients (e.g. Zed's coding agent), tool calling fails because: 1. **Each streaming chunk gets a different `id`** OpenAI's spec requires all chunks in a streaming response to share the same `id`. Previously, `OllamaChatCompletionResponseIterator.chunk_parser` called `str(uuid.uuid4())` on every chunk, so the

importance 2@fortesoftwareclosedOriginal evidence ↗
pull request

refactor(ui): migrate usage tables to shared DataTable

## TLDR Problem this solves: - Usage still rendered six legacy table implementations - A private DataTable duplicated the shared component How it solves it: - Moves usage tables onto the shared DataTable - Removes the unused private DataTable and its tests ## User Flow Before: an admin opens usage analytics and sees legacy table treatments 1. They open https

importance 2@yuneng-berriclosedOriginal evidence ↗
pull request

refactor(ui): migrate guardrails monitor table to shared DataTable

## TLDR Problem this solves: - Guardrails Monitor still used an Ant Design table - Sorting and loading used a separate table implementation How it solves it: - Moves performance data onto the shared DataTable - Preserves sorting, row selection, loading, and empty states ## User Flow Before: an admin reviews guardrail performance in a legacy table 1. They ope

importance 2@yuneng-berriclosedOriginal evidence ↗
pull request

refactor(ui): migrate TruncatedValue and OutputCard to shadcn

## TLDR Problem this solves: - Two log-drawer components still render antd Typography and Tooltip - antd in shared components blocks the dashboard's shadcn migration - Truncated ids are shortened in the page, not just visually How it solves it: - TruncatedValue moves to the shadcn Tooltip plus the shared CopyButton - OutputCard drops antd Typography for toke

importance 2@yuneng-berriopenOriginal evidence ↗
pull request

fix(router): resolve session.model to the picked deployment in _ageneric_api_call_with_fallbacks_helper

## TLDR Problem this solves: - Realtime `client_secrets` calls through a Router model group ignore the resolved deployment - `session.model` still holds the caller's original alias, not the picked deployment - `acreate_realtime_client_secret` prefers `session.model`, so it fails provider inference How it solves it: - `Router._ageneric_api_call_with_fallbacks

importance 2@danielva-mondayopenOriginal evidence ↗
pull request

fix(responses): raise on failed chat streams

## TLDR Problem this solves: - Failed Responses streams silently become successful empty chat completions - Router fallbacks never run after upstream stream failures How it solves it: - Raise an API error for failed and error events - Cover both upstream event shapes with regression tests ## User Flow Before: a developer streaming chat completions receives a

importance 2@nightcitybladeopenOriginal evidence ↗
pull request

fix(ui): make per-user usage filter searchable

## TLDR Problem this solves: - User Usage filters require scrolling through every user How it solves it: - Reuses Global Usage search and pagination behavior - Keeps the picker usable when searches return no matches ## User Flow Before: an admin cannot type to find a user in User Usage 1. They open `http://localhost:4000/ui/?page=usage` 2. They select `User

importance 2@daniel-meismer-zocdocopenOriginal evidence ↗
pull request

refactor(ui): migrate SectionHeader and ToolsSection to shadcn

## TLDR Problem this solves: - Log drawer still pulls antd Typography, Button, Tooltip, Collapse - Hex colours and inline styles ignore the design tokens - Hover states run through JS mouse handlers, not CSS How it solves it: - SectionHeader now uses shadcn Button and Tooltip - ToolsSection now uses shadcn Collapsible with lucide chevrons - Characterisation

importance 2@yuneng-berriopenOriginal evidence ↗
pull request

Fix Prometheus model-per-key rate limit gauges

<!-- CURSOR_AGENT_PR_BODY_BEGIN --> ## Relevant issues Fixes Prometheus model-per-key remaining RPM/TPM gauge fallback from additional headers. ## Linear ticket N/A ## Pre-Submission checklist - [x] I have Added testing in the [`tests/test_litellm/`](https://github.com/BerriAI/litellm/tree/main/tests/test_litellm) directory, **Adding at least 1 test is a har

importance 1@ishaan-berriclosedstaleOriginal evidence ↗
pull request

fix(anthropic_messages): strip non-user_id keys from metadata before forwarding

<!-- CURSOR_AGENT_PR_BODY_BEGIN --> ## Relevant issues <!-- e.g. "Fixes #000" --> ## Linear ticket <!-- if you are an internal contributor, add the Linear ticket e.g. "Resolves LIT-1234" to magically link the Linear ticket to the GitHub PR --> ## Pre-Submission checklist **Please complete all items before asking a LiteLLM maintainer to review your PR** - [x]

importance 1@mateo-berriclosedstaleOriginal evidence ↗
pull request

fix(usage_ai_chat): route through llm_router so proxy model aliases work

<!-- CURSOR_AGENT_PR_BODY_BEGIN --> ## Relevant issues ## Linear ticket ## Pre-Submission checklist **Please complete all items before asking a LiteLLM maintainer to review your PR** - [x] I have Added testing in the [`tests/test_litellm/`](https://github.com/BerriAI/litellm/tree/main/tests/test_litellm) directory, **Adding at least 1 test is a hard requirem

importance 1@mateo-berriclosedstaleOriginal evidence ↗
pull request

Improve budget ownership context

<!-- CURSOR_AGENT_PR_BODY_BEGIN --> ## Relevant issues Fixes confusing budget IDs in the Budgets page by showing what each budget is attached to. ## Linear ticket N/A ## Pre-Submission checklist - [x] I have Added testing in the `tests/test_litellm/` directory - [ ] My PR passes all unit tests on `make test-unit` - [x] My PR's scope is as isolated as possibl

importance 1@ishaan-berriclosedstaleOriginal evidence ↗
pull request

fix(ci): unflake build_and_test pipeline

## Summary The `build_and_test` job on `litellm_fix_v3_stash_leak_provider-ceb3` failed on every recent workflow attempt. Investigation showed it wasn't broad flakiness — a handful of distinct issues compound under `pytest -x`, and a CI rerun bug turns every auto-retry into a guaranteed failure. ### 1. CircleCI rerun step was a guaranteed failure ```yaml --c

importance 1@mateo-berriopenstaleOriginal evidence ↗
pull request

Add configurable user banner

<!-- CURSOR_AGENT_PR_BODY_BEGIN --> ## Summary Adds an admin-configurable dashboard banner backed by UI settings, with publish state, message text, and alert style persisted through the existing proxy UI settings endpoint. The dashboard renders the published banner under the navbar in both routing shells. ## Relevant issues ## Linear ticket Resolves LIT-3042

importance 1@krrish-berri-2closedOriginal evidence ↗
pull request

fix(docker): support OpenShift arbitrary-UID runs on the stock image

## TLDR Problem this solves: - OpenShift runs containers as a random UID in group 0 - Stock image only grants root write on /app - DB schema step fails, so customers must rebuild the image internally How it solves it: - Builder stage aligns group perms with owner perms on /app - Runtime COPY layers carry them, so no extra venv-sized chmod layer - HOME=/app p

importance 1@yassin-berriaiopenOriginal evidence ↗
pull request

fix(nebius): route requests to Token Factory

## TLDR Problem this solves: - Nebius requests target the retired AI Studio endpoint - Provider docs claim four unsupported API surfaces How it solves it: - Routes chat and embeddings to Token Factory - Tests routing, authentication, models, and overrides - Aligns branding and capability metadata with implementation ## User Flow Before: a developer using Lit

importance 1@demianarcopenOriginal evidence ↗
pull request

fix(otel): route gen_ai.system through cast_as_primitive_value_type in metrics and events paths (Fixes #36759)

## Summary `gen_ai.system` was reaching the OTLP exporter as `None` from the metrics path (`_record_metrics`) and the semantic-log events path (`_emit_semantic_logs`, per-message and per-choice events). The OTLP protobuf encoder raises `Invalid type <class 'NoneType'> of value None` on every record, which the OTel SDK catches and logs at ERROR level with a f

importance 1@Harsh23KashyapopenOriginal evidence ↗
pull request

fix(lint): pull LIT012 count back under the type-discipline ceiling

## TLDR Problem this solves: - Push-triggered lint job on litellm_internal_staging fails at LIT012 gate - Recent adds pushed the LIT012 total to 4522, over the 4519 ceiling How it solves it: - Mark the new UsagePerChunk fields inference_geo and speed as ReadOnly - Suppress the new NvidiaNimPassageObject.image field with writable-ok - Net effect drops the LIT

importance 1@cursor[bot]openOriginal evidence ↗
pull request

build(deps): bump nanoid to 3.3.18 to clear osv-scan

## TLDR Problem this solves: - `osv-scan` is red on `litellm_internal_staging` - GHSA-2v37-7h3g-55p8 (CVSS 8.2) hits nanoid 3.3.17 How it solves it: - lock-only bump of nanoid to 3.3.18 - no other package or config touched ## User Flow Before: a maintainer opening any PR into a `litellm_**` branch sees the `osv-scan` check fail before they can merge 1. They

importance 1@devin-ai-integration[bot]openOriginal evidence ↗
pull request

test(ui): scope workflows role-gate assertion to workflow endpoints

## TLDR Problem this solves: - UI Unit Tests fails on litellm_internal_staging every push - The workflows role-gate test asserts fetch was never called at all - useCan now transitively fetches /organization/list via useIsOrgAdmin How it solves it: - Drop the over-broad assertion, keep the scoped /v1/workflows check - Matches what PR #35176 already did for th

importance 0@cursor[bot]openOriginal evidence ↗
pull request

test(ui): scope the workflows role-gate assertion to workflow URLs

## TLDR Problem this solves: - UI Unit Tests are red on litellm_internal_staging - `workflows/page.integration.test.tsx` still asserts zero fetches for a denied role How it solves it: - Scope the waitFor to `/v1/workflows` URLs, matching the neighbour memory and guardrails-monitor tests ## User Flow Not user-facing, test-only change ## Relevant issues None #

importance 0@cursor[bot]openOriginal evidence ↗
pull request

chore(deps): bump nanoid to 3.3.18 to resolve osv-scan CVE

## TLDR Problem this solves: - osv-scan turned red on every PR after nanoid 3.3.17 got a CVE How it solves it: - lock-only bump of nanoid to 3.3.18 in the dashboard's package-lock ## User Flow Before: a contributor opens any PR and CI immediately fails on osv-scan, blocking review 1. They push a branch and open a PR against litellm_internal_staging 2. The os

importance 0@cursor[bot]openOriginal evidence ↗