litellm/tests/test_litellm/llms
Cesar Garcia c892c2c83d
fix(anthropic): use dynamic max_tokens based on model (#17900)
* fix(anthropic): use dynamic max_tokens based on model

When users don't specify max_tokens in requests to Anthropic models,
LiteLLM now uses the correct max_output_tokens value from the model
pricing JSON instead of a hardcoded 4096.

This fixes truncated responses for Claude 3.5+ models which support
higher output limits (8192 for Claude 3.5, 128k for Claude 3.7, etc.)

Fixes #8835

* fix(anthropic): restore env var support for backwards compatibility

Keep DEFAULT_ANTHROPIC_CHAT_MAX_TOKENS as fallback when model is not
found in JSON, allowing users to configure via environment variable.
2025-12-14 08:31:27 +05:30
..
amazon_nova/chat [New Model] Add Amazon Nova as first party provider for chat completions (#17351) 2025-12-06 14:43:55 -08:00
anthropic fix(anthropic): use dynamic max_tokens based on model (#17900) 2025-12-14 08:31:27 +05:30
azure [Fix] CI/CD – Clean Up Performance PR Changes & others (#17838) 2025-12-11 12:50:03 -08:00
azure_ai fix(azure_ai): Remove unsupported params from Azure AI Anthropic requests (#17822) 2025-12-11 08:09:13 -08:00
baseten/chat
bedrock Merge pull request #17873 from BerriAI/litellm_rerank_foraward_headers 2025-12-12 22:25:57 +05:30
bytez/chat
chat
cohere fix(unified_guardrail.py): support during_call event type for unified guardrails (#17514) 2025-12-04 22:06:13 -08:00
cometapi/chat
compactifai
custom_httpx 🐛 Fix proxy caching between requests in aiohttp transport (#17122) 2025-12-02 14:37:45 -08:00
dashscope
databricks Update Databricks model pricing and add new models (including databricks pricing test). (#17277) 2025-12-01 20:06:47 -08:00
datarobot
deepgram
deepinfra
docker_model_runner fix docker model runner tests 2025-11-22 11:07:56 -08:00
featherless_ai/chat
fireworks_ai Add fireworks rerank support 2025-12-08 20:29:50 +05:30
gemini fix: add speechConfig to GenerationConfig for Gemini TTS (#17851) 2025-12-12 03:56:44 -08:00
github_copilot fix(github_copilot): preserve encrypted_content in reasoning items for multi-turn conversations (#17130) 2025-12-05 12:42:25 -08:00
heroku
hosted_vllm
huggingface
jina_ai/embedding
lemonade
litellm_proxy/chat
llamafile/chat
lm_studio
meta_llama
mistral
moonshot
nebius
novita/chat
nscale/chat
oci/chat OCI Provider: Fix pydantic validation errors during tool call with streaming. (#16899) 2025-11-23 22:03:44 -08:00
ollama Fixes #13652 - auth not working with ollama.com (#17191) 2025-12-05 15:52:54 -08:00
openai feat(openai): add reasoning_effort='xhigh' support for gpt-5.2 models (#17875) 2025-12-12 11:40:35 -08:00
openai_like Refactor: Skip PublicAI tests if API key is not set (#17540) 2025-12-05 10:22:07 -08:00
openrouter/chat Support Deepseek 3.2 with Reasoning (#17384) 2025-12-02 22:00:19 -08:00
ovhcloud Add support of audio transcription for OVHcloud (#17305) 2025-12-01 18:26:39 -08:00
perplexity fix(perplexity): use API-provided cost instead of manual calculation (#17887) 2025-12-14 08:24:44 +05:30
pg_vector/vector_stores
publicai Fix: Lack of None value checks & update publicai_chat_transformation tests (#17539) 2025-12-05 09:43:52 -08:00
ragflow/chat fix failing vertex tests 2025-12-06 00:04:04 +05:30
recraft
runwayml
sagemaker
sambanova
sap [New provider] Sap gen ai hub (#16053) 2025-12-08 12:31:06 -08:00
snowflake
stability feat(stability): add Stability AI image generation support (#17894) 2025-12-14 08:29:45 +05:30
vercel_ai_gateway
vertex_ai fix gemini web search requests count (#17921) 2025-12-14 08:18:26 +05:30
volcengine
voyage/rerank [Fix] CI/CD – Clean Up Performance PR Changes & others (#17838) 2025-12-11 12:50:03 -08:00
wandb
watsonx [Bug Fix] Watsonx Audio Transcription - ensure only correct params are sent to API (#17840) 2025-12-11 15:21:09 -08:00
xai Prompt security litellm (#16365) 2025-11-24 11:44:20 -08:00
zai feat(provider): add Z.AI (Zhipu AI) as built-in provider (#17307) 2025-12-01 19:56:47 -08:00