Function tools with reasoning_effort are not supported for gpt-5.6-luna in /v1/c...
错误信息
Provider API error: Function tools with reasoning_effort are not supported for gpt-5.6-luna in /v1/chat/completions. To use function tools, use /v1/responses or set reasoning_effort to 'none'. (request id: 20260904180809160997205qoXWu30s) (HTTP Status: 400, Param: reasoning_effort) (4028)
AI 解决方案
🔍 报错分析
1. 🌐 错误翻译
原文:Provider API error: Function tools with reasoning_effort are not supported for gpt-5.6-luna in /v1/chat/completions. To use function tools, use /v1/responses or set reasoning_effort to 'none'. (request id: 20260904180809160997205qoXWu30s) (HTTP Status: 400, Param: reasoning_effort) (4028)
译文:提供方API错误:对于gpt-5.6-luna,在/v1/chat/completions端点中不支持带有reasoning_effort参数的函数工具。若要使用函数工具,请改用/v1/responses端点或将reasoning_effort设置为'none'。(请求ID:20260904180809160997205qoXWu30s)(HTTP状态码:400,参数:reasoning_effort)(4028)
2. 🎯 原因分析
该错误是由于在使用gpt-5.6-luna模型时,在
/v1/chat/completions端点中同时启用了函数工具(Function Tools)和reasoning_effort参数,而模型不支持这种组合导致的参数冲突。3. 💡 解决方案
根据错误提示,有两种解决方式:
方案一:将reasoning_effort设置为'none'
// 修复后的请求示例
{
"model": "gpt-5.6-luna",
"messages": [{ "role": "user", "content": "你的提示词" }],
"reasoning_effort": "none", // 关键修复:设置为none
"tools": [...] // 你的函数工具配置
}
方案二:改用/v1/responses端点
// 改用responses端点的请求示例
{
"model": "gpt-5.6-luna",
"input": [{ "role": "user", "content": "你的提示词" }],
"reasoning_effort": "medium", // 可以正常使用reasoning_effort
"tools": [...] // 你的函数工具配置
}