Commit graph

13131 commits

Author SHA1 Message Date
Ishaan Jaff
43c402b8b2 is_database_connection_error 2025-03-26 14:55:40 -07:00
Ishaan Jaff
f85c0dac4f Merge branch 'main' into litellm_stability_fixes 2025-03-26 14:41:43 -07:00
Ishaan Jaff
f77fcbcad3 rename _is_model_gemini_spec_model 2025-03-26 14:28:26 -07:00
Ishaan Jaff
826deea6fb test_gemini_fine_tuned_model_request_consistency 2025-03-26 14:18:11 -07:00
Ishaan Jaff
e291c10b4f _get_model_name_from_gemini_spec_model 2025-03-26 12:16:18 -07:00
Krish Dholakia
7873080223 Nova Canvas complete image generation tasks (#9177) (#9525)
* Nova Canvas complete image generation tasks (#9177)

* add initial support for Amazon Nova Canvas model

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* adjust name to AmazonNovaCanvas and map function variables to config

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* tighten model name check

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* fix quality mapping

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* add premium quality in config

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* support all Amazon Nova Canvas tasks

* remove unused import

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* add tests for image generation tasks and fix payload

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* add missing util file

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* update model prices backup file

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* remove image tasks other than text->image

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* add color guided generation task for Nova Canvas

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* fix merge

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* add nova canvas image generation documentation

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

* add nova canvas unit tests

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>

---------

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>
Co-authored-by: Krish Dholakia <krrishdholakia@gmail.com>

* ci(config.yml): bump ci config

* test: fix test

---------

Signed-off-by: omrishiv <327609+omrishiv@users.noreply.github.com>
Co-authored-by: omrishiv <327609+omrishiv@users.noreply.github.com>
2025-03-26 11:28:20 -07:00
Ishaan Jaff
654536b561 rename _is_model_gemini_spec_model 2025-03-26 11:14:51 -07:00
Ishaan Jaff
0767a3cc88 Merge branch 'main' into litellm_fix_vertex_ai_ft_models 2025-03-26 11:11:54 -07:00
Ishaan Jaff
2ff72b66db undo changes to utils 2025-03-26 11:09:29 -07:00
Ishaan Jaff
31bfb7e171 pick_cheapest_chat_models_from_llm_provider 2025-03-26 10:59:02 -07:00
Ishaan Jaff
166ec84c01 undo code changes 2025-03-26 10:57:08 -07:00
Ishaan Jaff
1baa4b2058 fix llm request utils 2025-03-26 10:55:56 -07:00
Ishaan Jaff
172c9d5689 _is_model_gemini_gemini_spec_model 2025-03-26 10:53:23 -07:00
Krrish Dholakia
0d4d8d95f4 build(model_prices_and_context_window.json): add commercial rate limits for gemini 2.0 flash lite 2025-03-26 08:58:35 -07:00
Ishaan Jaff
ad5d26f664 fix user_api_key_auth example config 2025-03-26 08:36:11 -07:00
Ishaan Jaff
cb64ecee07 Merge branch 'main' into litellm_stability_fixes 2025-03-26 07:16:31 -07:00
Ishaan Jaff
e81a96d4ae select_model_for_request_transformation 2025-03-26 07:12:25 -07:00
Ishaan Jaff
1913df8668 fix util vertex 2025-03-26 00:08:16 -07:00
Ishaan Jaff
59a773920e _transform_request_body 2025-03-26 00:05:45 -07:00
Ishaan Jaff
fdd2b21d37 fix get_optional_params 2025-03-25 23:54:57 -07:00
Ishaan Jaff
290e26fd4a fix base_model in param mapping 2025-03-25 23:54:29 -07:00
Krish Dholakia
1ab5d49132 Support litellm.api_base for vertex_ai + gemini/ across completion, embedding, image_generation (#9516)
* test(tests): add unit testing for litellm_proxy integration

* fix(cost_calculator.py): fix tracking cost in sdk when calling proxy

* fix(main.py): respect litellm.api_base on `vertex_ai/` and `gemini/` routes

* fix(main.py): consistently support custom api base across gemini + vertexai on embedding + completion

* feat(vertex_ai/): test

* fix: fix linting error

* test: set api base as None before starting loadtest
2025-03-25 23:46:20 -07:00
Ishaan Jaff
14ad499aa7 fix gemini/gemini-2.0-flash-lite on model cost map 2025-03-25 23:20:43 -07:00
Ishaan Jaff
a063423940 Merge pull request #9523 from BerriAI/litellm_add_gemini_flash_lite
[Feat - New Model] Add VertexAI `gemini-2.0-flash-lite` and Google AI Studio `gemini-2.0-flash-lite`
2025-03-25 23:11:44 -07:00
Ishaan Jaff
e449b2d677 run ci/cd again 2025-03-25 21:57:45 -07:00
Ishaan Jaff
fea5213517 add test config 2025-03-25 19:21:51 -07:00
Ishaan Jaff
6493a6422d fixes for auth checks 2025-03-25 15:44:13 -07:00
Ishaan Jaff
ea209661d5 fix ProxyErrorTypes 2025-03-25 14:40:11 -07:00
Ishaan Jaff
74e3600367 UserAPIKeyAuthExceptionHandler 2025-03-25 14:07:14 -07:00
Ishaan Jaff
e9cc72cc66 add gemini/gemini-2.0-flash-lite 2025-03-25 07:51:42 -07:00
Ishaan Jaff
029a1ceffa add vertex gemini-2.0-flash-lite 2025-03-25 07:48:33 -07:00
Krish Dholakia
6a40d50bc5 fix vertex ai multimodal embedding translation (#9471)
* remove data:image/jpeg;base64, prefix from base64 image input

vertex_ai's multimodal embeddings endpoint expects a raw base64 string without `data:image/jpeg;base64,` prefix.

* Add Vertex Multimodal Embedding Test

* fix(test_vertex.py): add e2e tests on multimodal embeddings

* test: unit testing

* test: remove sklearn dep

* test: update test with fixed route

* test: fix test

---------

Co-authored-by: Jonarod <jonrodd@gmail.com>
Co-authored-by: Emerson Gomes <emerson.gomes@thalesgroup.com>
2025-03-24 23:23:28 -07:00
Krrish Dholakia
4a91e2116d test: improve flaky test 2025-03-24 23:15:04 -07:00
Krish Dholakia
71848566c5 Add vertexai topLogprobs support (#9518)
* Added support for top_logprobs in vertex gemini models

* Testing for top_logprobs feature in vertexai

* Update litellm/llms/vertex_ai/gemini/vertex_and_google_ai_studio_gemini.py

Co-authored-by: Tom Matthews <tomukmatthews@gmail.com>

* refactor(tests/): refactor testing to be in correct repo

---------

Co-authored-by: Aditya Thaker <adityathaker28@gmail.com>
Co-authored-by: Tom Matthews <tomukmatthews@gmail.com>
2025-03-24 22:42:38 -07:00
Krish Dholakia
f09f4a6396 Merge pull request #9512 from BerriAI/litellm_dev_03_24_2025_p3
fix(invoke_handler.py): remove hard coded chunk on streaming usage
2025-03-24 21:21:36 -07:00
Ishaan Jaff
a61925448a fix import mcp router 2025-03-24 21:08:24 -07:00
Ishaan Jaff
dc899570ce fix code quality 2025-03-24 21:06:17 -07:00
Ishaan Jaff
a616375b3c fix mcp import 2025-03-24 21:02:54 -07:00
Ishaan Jaff
c6424d6246 Merge branch 'main' into litellm_exp_mcp_server 2025-03-24 19:03:56 -07:00
Ishaan Jaff
f600899ff7 fix linting errors 2025-03-24 18:48:43 -07:00
Ishaan Jaff
d0834f791a Merge pull request #9508 from BerriAI/litellm_fix_gcs_pub_sub
[Fix] Use StandardLoggingPayload for GCS Pub Sub Logging Integration
2025-03-24 18:22:43 -07:00
Krrish Dholakia
017a9b882a fix(invoke_handler.py): remove hard code 2025-03-24 17:58:26 -07:00
Ishaan Jaff
20fb49a0de default to use SLP for GCS PubSub 2025-03-24 15:21:59 -07:00
Krrish Dholakia
2f01caa919 fix(litellm_logging.py): always log the api base
Fixes issue where api base missing from spend logs due to refactor
2025-03-24 13:45:39 -07:00
Ishaan Jaff
d4b53d3fa9 fix mcp type imports 2025-03-24 11:01:29 -07:00
Ishaan Jaff
f133bb07d1 fix pydantic import error 2025-03-24 07:11:48 -07:00
Tyler Hutcherson
785f9714ca update redisvl dependency 2025-03-24 08:42:11 -04:00
Krish Dholakia
8afa12b78b Merge pull request #9473 from BerriAI/litellm_dev_03_22_2025_p2
Litellm dev 03 22 2025 p2
2025-03-22 21:57:15 -07:00
Krrish Dholakia
b02ea8fa47 build: add new vertex text embedding model 2025-03-22 21:50:21 -07:00
Ishaan Jaff
d932206bfb Merge branch 'main' into litellm_exp_mcp_server 2025-03-22 18:51:25 -07:00