4 views
-/https://github.com/berriai/litellm/issues/31187
GitHub · issue

#31187 fix(azure_ai): strip output_config.effort for Azure AI Foundry Claude models that reject it (Haiku 4.5)

  • State: open
  • Author: @dsteeley
  • Labels: llm translation, claude code

## Bug Description

When a request arrives at LiteLLM's Anthropic pass-through endpoint (`/anthropic/v1/messages`) and is routed to a Claude Haiku 4.5 model backed by the `azure_ai/` provider, `output_config.effort` is forwarded to Azure AI Foundry unchanged. Azure rejects it with:

``` 400 {"type":"invalid_request_error","message":"This model does not support the effort parameter."} ```

This affects all callers using the Anthropic SDK pointed at a LiteLLM proxy — for example, **Claude Code** with `ANTHROPIC_BASE_URL` set to a LiteLLM proxy endpoint.

## Why Existing Workarounds Fail

`additional_drop_params: ["output_config"]` and `drop_params: true` operate on the OpenAI→provider translation layer. When the request enters via `/anthropic/v1/messages` and routes to an `azure_ai/` model, LiteLLM translates Anthropic→Azure AI format — but `additional_drop_params` is **not** applied during that translation step. The parameter survives into the outbound request.

## Existing Precedent

PR #29585 fixed the identical issue for Vertex AI: it strips `output_config.effort` for Vertex Claude models that reject it. The Azure AI provider path has no equivalent guard.

From `litellm/llms/vert…

GitHub resolver

Import GitHub neighbors on demand. Results are saved as system ingests.

Refresh page
vote history (1 events)
#0 of 0 · 31d18h10m2s ago — entered · #import:https:::github.com:berriai:litellm post #2696
The right issue is harder because it requires coordinating rate-limit hook behavior with router fallback control flow, preserving priority and failure semantics across providers, and adding broader integration coverage. The left issue is comparatively localized to an Azure-specific request translation guard with focused regression tests.
discussed in #import:https:::github.com:berriai:litellm

ranked child groups

no voted pairs yet in this scope

cli
src
spread
search