Commit Graph

5871 Commits

Author SHA1 Message Date
Ryan Crabbe e45c82aea0 docs: add LITELLM_DISABLE_REDACT_SECRETS to environment variable reference 2026-03-14 15:59:52 -07:00
yuneng-jiang e4fa6f51c9 Merge remote-tracking branch 'origin' into litellm_internal_dev_03_14_2026 2026-03-14 14:22:01 -07:00
Ishaan Jaff af0c2f6792 docs: add Claude Code skills page for litellm-skills (#23642)
* docs: add Claude Code skills page for litellm-skills

* docs: move skills page to new 'Manage with AI Agents' section

* docs: simplify install to one-liner, rename to LiteLLM Skills
2026-03-14 13:24:16 -07:00
yuneng-jiang 0066ad7291 Merge pull request #23649 from Harshit28j/litellm_tests_leak
add tests for fix
2026-03-14 12:32:39 -07:00
yuneng-jiang 8be79c965c [Docs] Add Vantage environment variables to config_settings reference
The documentation test checks that all env vars used in code are
documented. The Vantage integration added 5 new env vars without
updating the reference table.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-14 12:16:19 -07:00
yuneng-jiang 4897faafc0 Merge pull request #23333 from Harshit28j/litellm_FOCUS_preserve-summary
Add Vantage integration for FOCUS CSV export
2026-03-14 10:15:05 -07:00
Harshit28j d72a34dbe2 add docs and export fixes 2026-03-14 22:19:56 +05:30
Ishaan Jaff b87d1f8dad [Feat] - Ishaan main merge branch (#23596)
* fix(bedrock): respect s3_region_name for batch file uploads (#23569)

* fix(bedrock): respect s3_region_name for batch file uploads (GovCloud fix)

* fix: s3_region_name always wins over aws_region_name for S3 signing (Greptile feedback)

* fix: _filter_headers_for_aws_signature - Bedrock KB (#23571)

* fix: _filter_headers_for_aws_signature

* fix: filter None header values in all post-signing re-merge paths

Addresses Greptile feedback: None-valued headers were being filtered
during SigV4 signing but re-merged back into the final headers dict
afterward, which would cause downstream HTTP client failures.

Made-with: Cursor

* feat(router): tag_regex routing — route by User-Agent regex without per-developer tag config (#23594)

* feat(router): add tag_regex support for header-based routing

Adds a new `tag_regex` field to litellm_params that lets operators route
requests based on regex patterns matched against request headers — primarily
User-Agent — without requiring per-developer tag configuration.

Use case: route all Claude Code traffic (User-Agent: claude-code/x.y.z) to
a dedicated deployment by setting:

  tag_regex:
    - "^User-Agent: claude-code\\/"

in the deployment's litellm_params. Works alongside existing `tags` routing;
exact tag match takes precedence over regex match. Unmatched requests fall
through to deployments tagged `default`.

The matched deployment, pattern, and user_agent are recorded in
`metadata["tag_routing"]` so they flow through to SpendLogs automatically.

* fix(tag_regex): address backwards-compat, metadata overwrite, and warning noise

Three issues from code review:

1. Backwards-compat: `has_tag_filter` was widened to activate on any non-empty
   User-Agent, which would raise ValueError for existing deployments using plain
   tags without a `default` fallback. Fix: only activate header-based regex
   filtering when at least one candidate deployment has `tag_regex` configured.

2. Metadata overwrite: `metadata["tag_routing"]` was overwritten for every
   matching deployment in the loop, leaving inaccurate provenance when multiple
   deployments match. Fix: write only for the first match.

3. Warning noise: an invalid regex pattern logged one warning per header string
   rather than once per pattern. Fix: compile first (catching re.error once),
   then iterate over header strings.

Also adds two new tests covering these cases, and adds docs page for
tag_regex routing with a Claude Code walk-through.

* refactor(tag_regex): remove unnecessary _healthy_list copy

* docs: merge tag_regex section into tag_routing.md, remove standalone page

- Add ## Regex-based tag routing (tag_regex) section to existing
  tag_routing.md instead of a separate page
- Remove tag_regex_routing.md standalone doc (odd UX to have a separate
  page for a sub-feature)
- Remove proxy/tag_regex_routing from sidebars.js
- Add match_any=False debug warning in tag_based_routing.py when regex
  routing fires under strict mode (regex always uses OR semantics)

* fix(tag_regex): address greptile review - security docs, strict-mode enforcement, validation order

- Strengthen security note in tag_routing.md: explicitly state User-Agent
  is client-supplied and can be set to any value; frame tag_regex as a
  traffic classification hint, not an access-control mechanism
- Move tag_regex startup validation before _add_deployment() so an invalid
  pattern never leaves partial router state
- Enforce match_any=False strict-tag policy: when a deployment has both
  tags and tag_regex and the strict tag check fails, skip the regex fallback
  rather than silently bypassing the operator's intent
- Extract per-deployment match logic into _match_deployment() helper to
  keep get_deployments_for_tag() readable
- Add two new tests: strict-mode blocks regex fallback, regex-only
  deployment still matches under match_any=False

* fix(ci): apply Black formatting to 14 files and stabilize flaky caplog tests

- Run Black formatter on 14 files that were failing the lint check
- Replace caplog-based assertions in TestAliasConflicts with
  unittest.mock.patch on verbose_logger.warning for xdist compatibility
- The caplog fixture can produce empty text in pytest-xdist workers
  in certain CI environments, causing flaky test failures

Co-authored-by: Ishaan Jaff <ishaan-jaff@users.noreply.github.com>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: Ishaan Jaff <ishaan-jaff@users.noreply.github.com>
2026-03-14 09:40:00 -07:00
Shivam Rawat 2405e0d400 Merge pull request #23592 from BerriAI/docs_per_model_tpm_rpm_for_teams
added doc
2026-03-13 17:35:43 -07:00
shivam 546ecfb084 added doc 2026-03-13 17:24:15 -07:00
Ishaan Jaff 1b96064600 fix(proxy): prevent OOM/Prisma connection loss from unbounded managed-object poll (#23472)
* fix(proxy): cap managed-object poll size + expire stale rows + kill-switch flag to prevent OOM/Prisma connection loss

* fix(constants): simplify PROXY_BATCH_POLLING_ENABLED readability

* docs+test: document new polling env vars, add pagination+stale-cleanup tests

* fix: exclude stale_expired from batch poll queries; fix update_many assertions in tests

* fix: scope stale cleanup to file_purpose, fix file_object mocks, add CheckBatchCost tests

* fix: avoid duplicate cost logging in fallback path; guard integer constants against zero/negative values

* fix: cache _has_batch_processed_column; guard cleanup from aborting poll; narrow fallback except

* fix: add complete/completed to primary query not_in; fix vacuous test assertion

- Primary find_many was missing "complete" and "completed" in its not_in
  filter, creating asymmetry with the fallback query. A job whose status
  was set to "complete" but whose batch_processed flag update failed would
  be silently re-fetched and re-processed every cycle, emitting duplicate
  cost logs.

- test_fallback_completion_update_omits_batch_processed patched
  _is_base64_encoded_unified_file_id to return None, causing an immediate
  continue — so update() was never called and the assertion looped over an
  empty list (vacuously true). Rewrote the test to mock the full
  completion pipeline, verify update() is called exactly once, and assert
  batch_processed is absent from the update data.

- Added symmetric test (primary path) proving batch_processed IS included
  when the column exists.

Made-with: Cursor
2026-03-13 11:01:40 -07:00
Ishaan Jaff 2b61f2a41b ui logo (#23556) 2026-03-13 08:44:08 -07:00
yuneng-jiang 62c8494423 Merge pull request #23490 from BerriAI/litellm_add_pkce_env_key_docs
[Docs] Add PKCE_STRICT_CACHE_MISS to env variables reference
2026-03-12 15:35:06 -07:00
yuneng-jiang 372cc45164 [Docs] Add PKCE_STRICT_CACHE_MISS to environment variables reference
Document the PKCE_STRICT_CACHE_MISS environment variable in config_settings.md
to fix the CI env key documentation check.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 15:32:35 -07:00
Chesars 690ad4c45b fix(openai): drop all reasoning_effort for gpt-5.4 + tools, including 'none'
OpenAI rejects any reasoning_effort (even 'none') with tools in
/v1/chat/completions for gpt-5.4. Update the guard to drop reasoning_effort
regardless of value. Add docs explaining the auto-drop behavior.
2026-03-12 16:22:40 -03:00
Cesar Garcia ec763784e0 Merge branch 'main' into litellm_oss_staging_03_11_2026 2026-03-12 16:21:28 -03:00
Sameer Kankute 8bbebb5d75 Improve doc for WebRTC 2026-03-12 22:45:36 +05:30
Sameer Kankute cf1d330e63 Improve doc for WebRTC 2026-03-12 22:41:39 +05:30
Cesar Garcia e01d722803 Merge branch 'main' into litellm_oss_staging_03_11_2026 2026-03-12 13:53:14 -03:00
Sameer Kankute 507bced04f Fix the live tester 2026-03-12 22:14:08 +05:30
Cesar Garcia 6bd7cd7573 Merge branch 'main' into litellm_oss_staging_03_11_2026 2026-03-12 10:43:08 -03:00
Sameer Kankute b7cfcdd35d Add docs 2026-03-12 19:06:57 +05:30
Chesars 1be6b31e2f merge: resolve conflicts between main and litellm_oss_staging_03_11_2026 2026-03-12 09:38:31 -03:00
Shivam Rawat 74a9dbd8ac Merge pull request #23413 from BerriAI/docs_policyy_builder
v1.82.0 promote to stable
2026-03-11 19:19:15 -07:00
shivam 0c7c0a93ed v1.82.0 promote to stable 2026-03-11 19:15:21 -07:00
Shivam Rawat 50e68dc387 Merge pull request #23410 from BerriAI/docs_policyy_builder
Docs policyy builder
2026-03-11 19:03:55 -07:00
Mr. Ånand 05fba27b0c Add Retool Assist tutorial with LiteLLM Proxy to docs (#21952)
* docs: add Retool Assist integration guide

- Add tutorials/retool_assist.md with setup instructions
- Add screenshots: Resources screen, Custom Provider config, resource query test
- Add retool_assist to AI Tools sidebar

Co-authored-by: Cursor <cursoragent@cursor.com>

* docs: refine Retool Assist guide layout

Co-authored-by: Cursor <cursoragent@cursor.com>

* docs: update Retool Assist guide with new screenshots

- Add Resources screen after step 1
- Update AI category and LiteLLM config modal images

Co-authored-by: Cursor <cursoragent@cursor.com>

* Apply suggestion from @greptile-apps[bot]

Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>

* updated blank line

* Added video & gifs

Made-with: Cursor

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2026-03-11 13:17:08 -07:00
Cesar Garcia cb24b8b05e Merge pull request #19104 from Chesars/fix/vertex-ai-zai-org-global-region
feat(vertex_ai): route region for partner models and add GLM support
2026-03-11 15:19:33 -03:00
Chesars f9a538b583 fix(docs): close unclosed code block before Examples heading 2026-03-11 14:15:54 -03:00
Cesar Garcia 274bf42493 Update docs/my-website/docs/providers/openai.md
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2026-03-11 14:13:56 -03:00
Chesars 9e7a6a73ed docs: remove duplicate gpt-5.4 tip block 2026-03-11 13:48:47 -03:00
Chesars 01a6c707a3 docs: restore gpt-5.4 reasoning_effort tip lost during rebase 2026-03-11 13:48:07 -03:00
Chesars d0d09e037e docs: clarify when to use openai/responses/ prefix for built-in tools
The existing documentation for the Responses API bridge only showed
examples with models that have `mode: responses` (like o3-deep-research),
which work automatically. This update clarifies that models with
`mode: chat` (like gpt-4o, gpt-5) require the `openai/responses/` prefix
to use built-in tools like web_search_preview.

Changes:
- Explain the `mode` property from model_prices_and_context_window.json
- List models with mode: responses vs mode: chat
- Add example showing the common error and how to fix it
- Add SDK example using the prefix with gpt-4o
- Update proxy example with both automatic and prefix-based configs
- Fix invalid trailing comma in original JSON example
2026-03-11 13:47:57 -03:00
michelligabriele 24ad510617 feat(mcp): add AWS SigV4 auth support in UI and fix credential merge on edit (#23282) 2026-03-11 09:43:28 -07:00
Chesars bb5d57645f docs: add VertexAI ZAI (GLM) documentation 2026-03-11 13:18:12 -03:00
Chesars 9eff611b1a feat(anthropic): add Files API support for SDK
Implement Anthropic Files API (upload, retrieve, list, delete, content)
using the BaseFilesConfig provider pattern. Adds multipart form-data
support to BaseLLMHTTPHandler for file uploads.
2026-03-11 12:45:19 -03:00
Sameer Kankute 20980f6c26 Merge pull request #23322 from BerriAI/litellm_gemini_embedding_2_support
[Feat]: Add support for gemini embedding 2 preview
2026-03-11 19:30:09 +05:30
michelligabriele db4cd87979 docs(web_fetch): add newer Claude models to supported models list (#23251)
Add Claude Opus 4.6, Sonnet 4.6, Opus 4.5, Sonnet 4.5, and Haiku 4.5
to the web fetch supported models documentation. These models were
missing from the list despite supporting the web_fetch tool.
2026-03-11 19:09:28 +05:30
Sameer Kankute f243e5615f Merge branch 'main' into litellm_oss_staging_03_10_2026 2026-03-11 18:50:03 +05:30
Sameer Kankute 43217c8a4b Merge branch 'main' into litellm_oss_staging_03_10_2026 2026-03-11 18:32:17 +05:30
Sameer Kankute 3dab62023c Merge branch 'main' into litellm_oss_staging_03_04_2026 2026-03-11 18:31:20 +05:30
dependabot[bot] a78bd9a468 build(deps): bump hono from 4.10.6 to 4.12.7 in /litellm-js/spend-logs (#23312)
* Rename 'Team-Based Guardrails' to 'Team Bring-Your-Own Guardrails' (#23307)

Co-authored-by: Cursor Agent <cursoragent@cursor.com>

* build(deps): bump hono from 4.10.6 to 4.12.7 in /litellm-js/spend-logs

Bumps [hono](https://github.com/honojs/hono) from 4.10.6 to 4.12.7.
- [Release notes](https://github.com/honojs/hono/releases)
- [Commits](https://github.com/honojs/hono/compare/v4.10.6...v4.12.7)

---
updated-dependencies:
- dependency-name: hono
  dependency-version: 4.12.7
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Krish Dholakia <krrishdholakia@gmail.com>
Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-11 14:13:33 +05:30
Sameer Kankute 1c144fc896 Add embedding model documentation 2026-03-11 11:02:49 +05:30
Cesar Garcia 260c37d670 Merge pull request #21398 from Chesars/feat/openai-like-responses-api
feat(openai_like): add Responses API support to JSON providers
2026-03-11 00:15:06 -03:00
Chesars a5f0e1a741 docs: expand aliases section in add_model_pricing guide
Add usage example with concrete model entry, explanation of load-time
expansion, and cross-reference to model_alias_map to clarify the
difference between the two features.
2026-03-10 22:42:18 -03:00
Chesars c0dbff21a6 feat: add model cost aliases expansion support 2026-03-10 22:42:18 -03:00
Cesar Garcia 3d2df7e8b5 Revert "feat: add model_cost aliases expansion support" 2026-03-10 22:39:19 -03:00
shivam 864bcd7c57 policy builder docs 2026-03-10 18:16:25 -07:00
shivam 0bf9945969 docs: fix REDIS_CLUSTER_NODES example formatting
Made-with: Cursor
2026-03-10 18:11:19 -07:00
shivam 86d02d107a docs update 2026-03-10 18:08:30 -07:00