mirror of
https://github.com/tiennm99/litellm.git
synced 2026-06-19 11:42:52 +00:00
40cc61c8f3
* build(model_prices_and_context_window.json): mark all gemini-2.5 models as supporting pdf input Closes https://github.com/BerriAI/litellm/issues/11881 * fix(anthropic_transformation.py): set custom llm provider custom property Fixes https://github.com/BerriAI/litellm/issues/11861 * test: add unit test for checking supports_reasoning * test: add test for vertex ai flow * feat(bedrock/anthropic): ensure thinking param correctly passed for bedrock/invoke
25 lines
784 B
Python
25 lines
784 B
Python
import os
|
|
import json
|
|
|
|
gemini_model_cost_map = json.load(open("model_prices_and_context_window.json"))
|
|
|
|
for model, model_info in gemini_model_cost_map.items():
|
|
if (
|
|
(
|
|
model_info.get("litellm_provider") == "gemini"
|
|
or model_info.get("litellm_provider") == "vertex_ai-language-models"
|
|
)
|
|
and model_info.get("mode") == "chat"
|
|
and ("gemini-2.5" in model and "tts" not in model)
|
|
and model_info.get("supports_pdf_input") is None
|
|
):
|
|
"""
|
|
Update all gemini chat models to support pdf input
|
|
"""
|
|
model_info["supports_pdf_input"] = True
|
|
print(f"Updated {model} to support pdf input")
|
|
|
|
json.dump(
|
|
gemini_model_cost_map, open("model_prices_and_context_window.json", "w"), indent=4
|
|
)
|