litellm/tests/test_litellm/llms/anthropic
Abhimanyu Kapur 831dbbc4df fix(anthropic): translate raw adaptive thinking for chat completions on pre-4.6 models
Clients that pass thinking={"type": "adaptive"} directly (not via the
reasoning_effort alias) on the /chat/completions interface had it forwarded
unmodified to pre-4.6 Anthropic models, which reject the shape. Mirrors the
translation already applied on the native /v1/messages passthrough (#32867):
translate to legacy thinking={type: enabled, budget_tokens}, capped below
max_tokens, dropping thinking when max_tokens can't fit even the minimum
budget. Hoists the shared budget-capping helper onto AnthropicConfig so both
paths use one implementation.
2026-07-11 14:20:48 -07:00
..
batches test(batches): add 1:1 test file scaffold for batches component paths (#30529) 2026-06-29 09:22:58 +05:30
chat fix(anthropic): translate raw adaptive thinking for chat completions on pre-4.6 models 2026-07-11 14:20:48 -07:00
experimental_pass_through fix(anthropic): translate adaptive thinking/effort to pre-4.6 model support (#32867) 2026-07-10 21:04:46 -07:00
files fix(batches): price anthropic passthrough message batches correctly in batch cost job (#32307) 2026-07-06 20:33:57 -07:00
messages fix(anthropic): require caller api_key and SSRF-validate api_base in advisor tool (#32093) 2026-07-04 12:06:09 -07:00
__init__.py test(batches): add 1:1 test file scaffold for batches component paths (#30529) 2026-06-29 09:22:58 +05:30
test_anthropic_common_utils.py fix(anthropic): thread real provider through capability probes instead of pinning anthropic 2026-07-11 12:15:59 -07:00
test_anthropic_count_tokens_transformation.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
test_anthropic_files_and_batches.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
test_anthropic_structured_output.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
test_azure_ai_cache_pricing.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
test_cost_calculation_dict_safety.py fix: completion_cost AttributeError on streaming Anthropic web_search responses (#26153) (#27346) 2026-06-10 21:20:11 -07:00
test_count_tokens_oauth.py style: run black formatter on files from main merge 2026-04-17 13:02:59 -07:00
test_message_sanitization.py fix(anthropic, mcp): sanitize tool names to match Anthropic's [a-zA-Z0-9_-]{1,128} pattern (#26788) 2026-05-06 00:00:36 +00:00