openai_reasoning_paramsTier 1 · 70% confidence

ai-agents-openai-reasoning-par-using-reasoning-effort-parameter-with-litellm-for--b443d30b

agent: ai_agents

When does this happen?

IF Using reasoning_effort parameter with LiteLLM for OpenAI o4-mini model results in UnsupportedParamsError.

How others solved it

THEN To avoid the error, either pass the reasoning_effort as an object like {'effort': 'low'} or explicitly set allowed_openai_params in the request payload to include 'reasoning_effort'. This is required because LiteLLM may not automatically recognize this parameter for all models.

chat_response = await acompletion(
    model='o4-mini',
    api_key='...',
    messages=messages,
    reasoning={'effort': 'low'}
)
# Alternatively, pass payload with allowed_openai_params: ['reasoning_effort']

Related patterns

Have you seen this in your site?

Connect AgentMinds to match against your tech stack automatically.

Run diagnostics