FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Provider API: reasoning_effort "none" is rejected with 400; "off" fails on models that can't disable thinking · Issue #985 · CommandCodeAI/command-code · GitHub

Repository navigation

Provider API: reasoning_effort "none" is rejected with 400; "off" fails on models that can't disable thinking #985

Description

Summary

On /provider/v1/chat/completions, reasoning_effort: "none", the value OpenAI's API uses to turn reasoning off, is rejected with a 400 on every model I tried. The Command Code-specific value "off" works only on models that can disable thinking; on the others it is also a 400. A standard OpenAI client therefore has no reasoning-off value that works across the catalog.

Possibly related to #697, which was closed after a fix, but "none" is still rejected.

Expected Behavior

  • reasoning_effort: "none" is accepted as an alias for "off".
  • On models where thinking can't be turned off, "none"/"off" don't hard-fail. They fall back to the lowest supported effort or are ignored, so a client asking for "as little reasoning as possible" gets a response instead of a 400.

Actual Behavior

Model "none" "off"
deepseek/deepseek-v4-flash 400 200 ✅
z-ai/glm-5.3-flash 400 400
xiaomi/mimo-v2.6-flash 400 400

"none":

{"type":"invalid_request_error","message":"Invalid option: expected one of \"off\"|\"low\"|\"medium\"|\"high\"|\"xhigh\"|\"max\"","param":"reasoning_effort"}

"off" on a model that can't disable thinking:

{"type":"invalid_request_error","code":"unsupported_value","message":"Model \"z-ai/glm-5.3-flash\" does not support reasoning_effort \"off\". Only models that can turn thinking off accept it.","param":"reasoning_effort"}

Steps to reproduce the issue

curl https://api.commandcode.ai/provider/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" -H "Content-Type: application/json" \
  -d '{"model":"z-ai/glm-5.3-flash","reasoning_effort":"none","max_tokens":16,
       "messages":[{"role":"user","content":"Reply OK"}]}'

Swap the model and "none"/"off" to reproduce the table.

Command Code Version

N/A (Provider API, direct HTTP)

Operating System

Linux

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions


      Back | FazBrowse Home | New Git URL