mirror of
https://github.com/tiennm99/litellm.git
synced 2026-06-28 19:09:32 +00:00
c892c2c83d
* 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.
In total litellm runs 1000+ tests
[02/20/2025] Update:
To make it easier to contribute and map what behavior is tested,
we've started mapping the litellm directory in tests/test_litellm
This folder can only run mock tests.