Commit Graph
541 Commits
Author SHA1 Message Date
Elias TOURNEUX ef9d1ddc40 feat: Add OVHCloud AI Endpoints as a provider 2025-09-12 13:37:03 +02:00
Krish DholakiaandGitHub d72081113e Merge pull request #14111 from dharamendrak/feature/aiohttp-dependency-injection
feat: Add dependency injection support to BaseLLMAIOHTTPHandler
2025-09-09 22:35:30 -07:00
Dharamendra Kumar 92596e48fe Merge branch 'main' into feature/aiohttp-dependency-injection 2025-09-07 17:54:55 -07:00
Dharamendra Kumar 009106def0 docs for custom aiohttp session 2025-09-07 17:42:26 -07:00
Krish DholakiaandGitHub ba10173ec7 Merge branch 'main' into heroku-llms 2025-09-06 22:10:20 -07:00
Krish DholakiaandGitHub 8b11452d9e Merge branch 'main' into add-vercel-ai-gateway-provider 2025-08-29 22:27:08 -07:00
Carson GeeandGitHub e74f1b6b62 Added DataRobot provider to sidebar (#14074) 2025-08-29 13:15:33 -07:00
Krish DholakiaandGitHub c43706061f Merge branch 'main' into heroku-llms 2025-08-27 22:21:36 -07:00
Ishaan JaffandGitHub 04dc1a5351 [Feat] Add support for returning images with gemini/gemini-2.5-flash-image-preview with /chat/completions (#13983)
* add gemini-2.5-flash-image-preview

* add gemini-2.5-flash-image-preview

* add image in ChatCompletionResponseMessage

* test_gemini_image_generation_async

* Revert "Merge pull request #13394 from Deviad/feature/enhance_logging_for_containers"

This reverts commit 539b94ad4e, reversing
changes made to 71af7bcf9c.

* include `image` in Delta

* fix _process_candidates should show the image response

* fix: _handle_special_delta_attributes

* test_gemini_image_generation_async_stream

* image_generation_chat

* UI - allow looking at generated images from /chat/completions

* _create_streaming_choice

* fix import StreamingChoices

* fix ChatCompletionResponseMessage

* test_gemini_image_generation

* add gemini img migration

* fix _extract_candidate_metadata

* ui fix

* fix batch endpoint test
2025-08-27 16:16:19 -07:00
Krish DholakiaandGitHub 45f465d84f Merge pull request #13572 from Noma-Security/noma-security-guardrails-support
Add Noma Security guardrail support
2025-08-26 23:15:17 -07:00
Krrish Dholakia 5c1b27af99 docs(quick_start.md): add back to navbar
useful for showing setup via cli
2025-08-20 15:09:19 -07:00
Ishaan JaffandGitHub 76d25926d4 [Feat] New provider - Azure AI Flux Image Generation (#13592)
* init files

* add AzureFoundryModelInfo

* fix api_version property

* add azure_ai img gen

* use AzureFoundryModelInfo

* get_base_image_generation_call_args

* add azure_ai/FLUX-1.1-pro

* add util for route_image_generation_cost_calculator

* docs azure ai flux

* fixes for flux

* fixes for AzureFoundryFluxImageGenerationConfig

* ruff fix
2025-08-13 17:20:30 -07:00
Dor Zion 6a1f5bdc2f Add Noma Security guardrail support 2025-08-13 13:39:21 +03:00
Timothy LowrimoreandGitHub 95d9e30448 Merge branch 'main' into heroku-llms 2025-08-11 09:45:52 -06:00
Sannan NasirandGitHub 0e53b1feab Add digitalocean provider (#12169)
* Add digitalocean provider

* Add digitalocean provider

* Revert "Add digitalocean provider"

This reverts commit 96dda40f45b3d12ea03e861d060ec81460b7759e.

* changes

* fixes

* Update transformation

* refactoring

* rename provider to Gradient AI

* fixes

* Incorporte review comments

* revert changes

* fix typo

* revert change

* incorporated review comments

* Revert "Incorporte review comments"

This reverts commit 37bd51bd54ef4fd52ccc12866e47f8de9476d597.

* changes

* Revert "Revert "Incorporte review comments"

This reverts commit 37bd51bd54ef4fd52ccc12866e47f8de9476d597."

This reverts commit 68c8a198ee0d6441c3a52f6c6a49c9c95a4cb0a8.

* changes

* fixes

* Update provider_specific_fields.tsx
2025-08-09 16:26:33 -07:00
Ishaan JaffandGitHub 94c33200a4 docs - native prompt mgmt (#13463) 2025-08-09 09:39:16 -07:00
Timothy LowrimoreandGitHub 1b2dc23e7a Merge branch 'main' into heroku-llms 2025-08-06 10:11:52 -06:00
breno-aumoandGitHub 056b60a9fa Support OCI provider (#13206)
* create OCI required files

* request and response conversion for non-streaming chat

* support tool calling with OCI generic API without streaming

* adaptation of api call for generic and cohere format

* include tool calls and responses in generic api and dropping support for cohere

* fix invalid content-length error

* support streaming for generic api

* fix auth error when using acompletion with streaming

* refactor: use base_llm_http_handler and include API type definitions

* update types and add type safety in different methods

* fix OCIFunction format

* create custom stream wrapper for decoding OCI stream

* remove unused files

* create unit tests for OCI

* lint the code

* remove manual test

* docs: update the docs to include OCI
2025-08-04 15:59:25 -07:00
Ishaan Jaff 340b64a46a docs - Track Usage for Coding Tools 2025-08-02 15:18:04 -07:00
Ishaan Jaff 8d6b333909 docs computer use 2025-08-02 15:00:48 -07:00
Josh fde381a396 Merge branch 'main' into add-vercel-ai-gateway-provider 2025-07-31 18:49:03 -07:00
Timothy LowrimoreandGitHub a973202cb1 Merge branch 'main' into heroku-llms 2025-07-31 15:47:48 -06:00
joshualipman123 1ea28ccf67 Add Vercel AI Gateway provider support 2025-07-30 10:01:05 -07:00
Ishaan Jaff 33510120fd docs 2025-07-28 22:02:35 -07:00
Cole McIntoshandGitHub 3a347922c8 docs: add Qwen Code CLI tutorial (#12915)
- Add new tutorial for integrating Qwen Code CLI with LiteLLM Proxy
- Update sidebar to include Qwen Code CLI in both AI Tools and main Tutorials sections
- Document environment variables for OpenAI-compatible configuration
- Include examples for routing to various providers (Anthropic, OpenAI, Bedrock)
2025-07-28 21:39:02 -07:00
Timothy LowrimoreandGitHub 94273dc8b7 Merge branch 'main' into heroku-llms 2025-07-25 16:46:01 -06:00
Timothy Lowrimore 0eb05ad23f adds sidebar link to Heroku provider docs 2025-07-25 16:11:39 -06:00
Ishaan Jaff 50574c0c3e docs - auto routing 2025-07-25 07:31:39 -07:00
Igal BoxermanandGitHub d118cc7098 feat: Add Pillar Security guardrail integration (#12791)
* feat: Add Pillar Security guardrail integration

Implements comprehensive LLM security guardrails using Pillar Security API with support for prompt injection detection, PII/secret detection, content moderation, and multi-mode execution (pre_call, during_call, post_call). Includes complete documentation, testing, and configurable actions on flagged content.

* fix: Resolve MyPy type error in Pillar guardrail config

Restructure PillarGuardrailConfigModel to properly inherit from GuardrailConfigModel[T]
and resolve return type compatibility issue in get_config_model method.

* fix: Resolve MyPy type error in Pillar guardrail config

Restructure PillarGuardrailConfigModel to properly inherit from GuardrailConfigModel[T]
and resolve return type compatibility issue in get_config_model method.

* fix docs

* fix docs

* improved docs

* fix examples, READY
2025-07-22 23:17:33 -07:00
Ishaan Jaff bf300f8ca7 Revert "Litellm dev 07 21 2025 p1 (#12848)"
This reverts commit e4e10aa4ed.
2025-07-22 18:28:36 -07:00
Ishaan Jaff 03baf23ad1 [Feat] Add Recraft Image Generation API Support - New LLM Provider (#12832)
* add recraft

* init RecraftImageGenerationConfig

* add get_complete_url + validate_environment

* add image_generation_handler in llm http clas

* fixes for transform

* working recraft request

* fixed img gen transform

* fixes for llm http handler

* test: TestRecraftImageGeneration

* fixes for llm_http_handler

* fix RecraftImageGenerationConfig

* TestRecraftImageGenerationTransformation

* add recraft API

* docs recraft API

* fix code QA

* map_openai_params

* fix recraft

* cost tracking for recraft/recraftv3

* fix code qa check
2025-07-21 22:19:58 -07:00
Krish DholakiaandGitHub e4e10aa4ed Litellm dev 07 21 2025 p1 (#12848)
* fix(main.py): fix async retryer

Fixes https://github.com/BerriAI/litellm/issues/12830

* fix(forward_clientside_headers_by_model_group.py): filter out 'content-type' from forwardable headers

clientside content-type != proxy content type, can cause requests to hang

* test(tests/): update tests
2025-07-21 22:09:39 -07:00
Cole McIntosh 34ccda10ed Merge upstream/main - resolve conflicts to include both hyperbolic and recraft providers 2025-07-21 17:38:17 -06:00
Ishaan JaffandGitHub 2941a555a8 [Feat] Add Recraft Image Generation API Support - New LLM Provider (#12832)
* add recraft

* init RecraftImageGenerationConfig

* add get_complete_url + validate_environment

* add image_generation_handler in llm http clas

* fixes for transform

* working recraft request

* fixed img gen transform

* fixes for llm http handler

* test: TestRecraftImageGeneration

* fixes for llm_http_handler

* fix RecraftImageGenerationConfig

* TestRecraftImageGenerationTransformation

* add recraft API

* docs recraft API

* fix code QA

* map_openai_params

* fix recraft

* cost tracking for recraft/recraftv3

* fix code qa check
2025-07-21 15:01:32 -07:00
Cole McIntoshandGitHub 774af8085e docs: add Google Cloud Model Armor guardrail documentation (#12814)
- Add comprehensive documentation for Model Armor integration
- Include configuration examples and parameter descriptions
- Add Model Armor to sidebars navigation
- Document authentication methods and error handling
2025-07-21 14:24:44 -07:00
Cole McIntoshandGitHub c5b51cd2b4 feat: add Morph provider support (#12821)
* feat: add Morph provider support

- Add MorphChatConfig implementation for OpenAI-compatible API
- Support morph-v3-fast and morph-v3-large models
- Add pricing: morph-v3-fast (/bin/zsh.8/.2 per 1M tokens), morph-v3-large (/bin/zsh.9/.9 per 1M tokens)
- Both models support 16k context window and system messages
- Add comprehensive documentation and unit tests
- Update all necessary integration points (constants, init, provider logic)

* feat: Add Morph provider support in ProviderConfigManager

- Extend ProviderConfigManager to include MorphChatConfig for the Morph LLM provider.
- Update MorphChatConfig by removing unused parameters from the configuration.
2025-07-21 13:52:45 -07:00
Cole McIntosh 6040c329a4 feat: add Hyperbolic provider support
- Add Hyperbolic as a new OpenAI-compatible provider
- Implement HyperbolicChatConfig inheriting from OpenAILikeChatConfig
- Register Hyperbolic in provider lists and constants
- Add comprehensive model configurations with pricing for:
  - DeepSeek models (V3, R1, etc.)
  - Qwen models (2.5, 3, QwQ, etc.)
  - Meta Llama models (3.1, 3.2, 3.3)
  - Other models like Kimi K2, Hermes 3, etc.
- Configure default API base URL: https://api.hyperbolic.xyz/v1
- Add provider documentation with usage examples
- Create unit tests for provider functionality
- Support all standard OpenAI parameters

Hyperbolic provides low-cost inference with OpenAI-compatible APIs,
supporting latest models without infrastructure overhead.
2025-07-21 13:18:50 -06:00
Cole McIntoshandGitHub 41436fefa0 feat: Add Lambda AI provider support (#12817)
* feat: add Lambda AI provider support

Add support for Lambda AI (lambda.ai) as a new LLM provider in LiteLLM. Lambda AI provides access to a wide range of open-source models through their cloud GPU infrastructure.

Changes:
- Add Lambda AI provider implementation (OpenAI-compatible)
- Register 20 Lambda AI models with accurate pricing and 131k context windows
- Add comprehensive tests for Lambda AI integration
- Add detailed documentation with usage examples
- Use "lambda_ai" as provider name to avoid Python keyword conflict

Models include Llama 3.x, DeepSeek, Hermes, Qwen, and specialized models for coding and vision tasks.

* fix(tests): ensure lambda_ai_models list is repopulated after model cost reload

Updated test cases to clear and repopulate the lambda_ai_models list after reloading the model cost map. This ensures that the tests accurately reflect the current state of available models.

* feat: add Lambda AI chat configuration support

Added support for Lambda AI chat configuration in the ProviderConfigManager. This enhancement allows the integration of Lambda AI as a provider, expanding the capabilities of LiteLLM.
2025-07-21 10:23:10 -07:00
Pavan GudiwadaandGitHub 1faedd599f Adding HolmesGPT to projects using LiteLLM (#12798) 2025-07-21 09:24:09 -07:00
Krrish Dholakia c946ae8550 docs(bulk_edit_users.md): add guide on bulk editing existing users 2025-07-19 18:26:09 -07:00
Ishaan JaffandGitHub 2cf4d164fc docs - vector stores (#12781)
* docs vertex vector store

* guide for using other non openai providers

* docs polish

* docs KBs

* docs search endpoint

* docs vector stores
2025-07-19 17:07:44 -07:00
Cole McIntoshandGitHub bf046c9d5d feat: add v0 provider support (#12751)
* feat: add v0 provider support to LiteLLM

- Add v0 as a new OpenAI-compatible provider
- Support all three v0 models: v0-1.0-md, v0-1.5-md, v0-1.5-lg
- Configure correct token limits and pricing for each model
- Enable vision support for all v0 models (multimodal)
- Add provider detection for v0/ prefix and api.v0.dev endpoint
- Include comprehensive unit tests for the provider

The v0 provider uses the standard OpenAI-compatible implementation
and supports all standard features including streaming, function
calling, and system messages.

* fix: add v0 provider to ProviderConfigManager

Add V0ChatConfig to the get_provider_chat_config method to fix
test_supports_tool_choice test failure. The v0 provider needs to
be included in the provider config manager to return the correct
configuration for tool choice support detection.

* docs: add documentation for v0 provider

- Add comprehensive v0 provider documentation
- Cover all supported models and their capabilities
- Include examples for SDK usage, proxy configuration, and all features
- Document supported OpenAI parameters based on v0 API docs
- Add v0 to the providers sidebar navigation

* fix: correct v0 supported OpenAI parameters

Based on review feedback and v0 API documentation:
- v0 only supports: messages, model, stream, tools, tool_choice
- Remove unsupported parameters like temperature, max_tokens, etc.
- Update tests to verify correct parameter set
- Update documentation to reflect actual API capabilities
- Remove JSON mode example as response_format is not supported

Reference: https://v0.dev/docs/v0-model-api#request-body

* fix: remove supports_response_schema from v0 models

Remove the supports_response_schema property from all v0 models in the model configuration files as v0 does not support this feature.

Models updated:
- v0/v0-1.0-md
- v0/v0-1.5-md
- v0/v0-1.5-lg
2025-07-18 18:26:44 -07:00
Ishaan JaffandGitHub 95f7290e44 [Feat] Proxy - New LLM API Routes /v1/vector_stores and /v1/vector_stores/vs_abc123/search (#12699)
* add Search + Create vector stores

* add new vector_stores routes

* add avector_store_search routes

* docs vector stores

* docs vector stores

* Create Vector Store

* fix - refactor

* add vector_store_router

* fix imports

* fix ruff
2025-07-17 11:19:25 -07:00
Cole McIntoshandGitHub 3a0ea80c75 Add Claude Code LiteLLM tutorial (#12650)
* Add concise Claude Code + LiteLLM Gateway tutorial

- Create focused tutorial matching existing tutorial style
- Step-by-step guide from installation to advanced configurations
- Multi-provider configuration examples (AWS Bedrock, Azure OpenAI, Load Balancing)
- Based on Anthropic's official LiteLLM configuration documentation
- Added to sidebar with clean title 'Use LiteLLM with Claude Code'
- Fixed sidebar reference from 'secret' to 'set_keys' for proper document resolution

* Update config_settings.md to correct documentation links for key management and Hashicorp Vault settings. Changed references from 'secret.md' to 'set_keys.md' for improved clarity and accuracy.

* Update sidebar and config_settings.md to reflect changes in key management documentation. Changed sidebar reference from 'set_keys' to 'secret' and updated links in config_settings.md for Hashicorp Vault settings to point to 'secret.md' for improved accuracy.

* Remove extra tutorial and update sidebar accordingly

* Update tutorial title from 'WebUI' to 'Open WebUI' for clarity and consistency in documentation.

* Remove Python version requirement from Claude Responses API tutorial for clarity and to align with updated prerequisites.
2025-07-16 23:07:29 -07:00
Cole McIntoshandGitHub d51aee1b84 Add GitHub Copilot LiteLLM tutorial (#12649)
* Add comprehensive GitHub Copilot + LiteLLM integration tutorial

- Complete setup guide from installation to production deployment
- Multiple configuration examples including authentication, load balancing, and cost tracking
- Docker and Kubernetes deployment configurations
- Troubleshooting section with common issues and solutions
- Best practices for security, monitoring, and reliability
- Usage examples for code completion, chat interface, and direct API integration

* Add concise GitHub Copilot + LiteLLM tutorial

- Create focused tutorial matching Gemini CLI style
- Step-by-step guide from installation to production deployment
- Multi-provider configuration examples (OpenAI, Anthropic, Bedrock)
- Load balancing and fallback configuration
- Docker deployment instructions
- Troubleshooting section with common issues
- Updated sidebar with clean title 'Use LiteLLM with GitHub Copilot'

* Refactor GitHub Copilot integration tutorial

- Removed outdated production deployment and direct API usage sections
- Streamlined troubleshooting steps for clarity
- Ensured documentation aligns with current best practices and configurations

* Add proper credit to Sergio Pino for GitHub Copilot tutorial

- Reference original DEV.to article in info box
- Add credits section acknowledging foundational work
- Maintain attribution to original author's guide
2025-07-16 09:40:27 -07:00
Krish DholakiaandGitHub 7c392475e6 Control Plane + Data Plane support (#12601)
* feat(route_checks.py): allow admin to disable proxy management endpoints on instance

useful for preventing multiple instances from doing admin actions

* docs(scaling_multiple_instances.md): add architecture doc on scaling multiple litellm instances

provide guidance on scaling proxy

* docs(scaling_multiple_instances.md): add doc on scaling across multiple regions for litellm

* fix(route_checks.py): allow disabling llm api endpoints on an instance

allows pure admin instance to exist

* refactor(enterprise/route_checks.py): refactor env var checks

* refactor: finish refactoring

* docs(control_plane_and_data_plane.md): refactor docs

* test: update tests
2025-07-14 21:31:56 -07:00
Krish DholakiaandGitHub 78baeae6d8 Updated release notes (#12594)
* docs(index.md): cleanup docs

* docs(index.md): add more highlights

* docs(model_hub.md): cleanup doc
2025-07-14 17:03:11 -07:00
27ff234b7d [Feat] New LLM API Integration - Add Moonshot API (Kimi) (#12551) (#12592)
* [Feat] New LLM API Integration - Add Moonshot API (Kimi) (#12551)

* Add Moonshot AI provider support to LiteLLM

Co-authored-by: ishaan <ishaan@berri.ai>

* Refactor Moonshot provider params handling and transformation logic

Co-authored-by: ishaan <ishaan@berri.ai>

* fix constants

* add Moonshot AI

* fix get_supported_openai_params

* handle kimi temp

* add tool choice handling

* test moonshot unit tests

* fix kimi

* fix linting

* Add pricing information for Moonshot AI's kimi-k2 model (#12566)

* Add pricing information for Moonshot AI's kimi-k2 model

* Update model name to kimi-k2-0711-preview

- Changed model name from moonshot/kimi-k2 to moonshot/kimi-k2-0711-preview
- This reflects the specific model version as requested

* Update moonshot_models list to match model_context JSON

---------

Co-authored-by: openhands <openhands@all-hands.dev>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: ishaan <ishaan@berri.ai>
Co-authored-by: Xingyao Wang <xingyao@all-hands.dev>
Co-authored-by: openhands <openhands@all-hands.dev>

* update docs

* docs moonshot

* fixes model cost map

* fix map_openai_params

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: ishaan <ishaan@berri.ai>
Co-authored-by: Xingyao Wang <xingyao@all-hands.dev>
Co-authored-by: openhands <openhands@all-hands.dev>
2025-07-14 15:23:34 -07:00
Aaron VoglerandGitHub 2b2ba8a2b1 Add Bytez to the list of providers in the docs (#12588)
* Get the basics of the integration working.

* Cleanup bytez integration.

* Update user agent for Bytez integration.

* Use the config class directly. Create the start of the docs.

* Finish up bytez documentation. Include a provider integration guide.

* Fix typing bug in custom_logger_utils. Add tests for bytez integration.

* Add token tracking for model usage for Bytez integration.

* Create a units test for the Bytez config.

* Make changes to Bytez transformation code per PR feedback.

* Cleanup coment in Bytez transformation test.

* Remove LRU usage for bytez integration.

* Consolidate Bytez tests into a single file. Conform to project structure for tests.

* Fix linting error with Bytez impl.

* Add Bytez to the list of providers in the docs.
2025-07-14 14:17:56 -07:00
Aaron VoglerandGitHub 4c466ef157 Integration: Bytez as a model provider (#12121)
* Get the basics of the integration working.

* Cleanup bytez integration.

* Update user agent for Bytez integration.

* Use the config class directly. Create the start of the docs.

* Finish up bytez documentation. Include a provider integration guide.

* Fix typing bug in custom_logger_utils. Add tests for bytez integration.

* Add token tracking for model usage for Bytez integration.

* Create a units test for the Bytez config.

* Make changes to Bytez transformation code per PR feedback.

* Cleanup coment in Bytez transformation test.

* Remove LRU usage for bytez integration.

* Consolidate Bytez tests into a single file. Conform to project structure for tests.

* Fix linting error with Bytez impl.
2025-07-12 10:50:39 -07:00