Skip to content

fix(api-server): 'max' and 'ultra' reasoning efforts no longer silently ignored (salvage #78216 api_server hunk) - #90558

Merged
teknium1 merged 1 commit into
mainfrom
fix/api-server-effort-vocab
Aug 20, 2026
Merged

fix(api-server): 'max' and 'ultra' reasoning efforts no longer silently ignored (salvage #78216 api_server hunk)#90558
teknium1 merged 1 commit into
mainfrom
fix/api-server-effort-vocab

Conversation

@teknium1

Copy link
Copy Markdown
Contributor

Summary

API/browser requests with reasoning_effort: max or ultra are no longer silently ignored — the API server now accepts the full internal ladder, matching every other entry surface (/reasoning, config.yaml, dashboard).

_request_reasoning_config() whitelisted none..xhigh, so a client sending max/ultra fell through to the default effort with no error. Wire clamping to each provider's vocabulary happens downstream via agent.reasoning_effort (#90350/#90441), so the entry gate has no reason to be narrower than the ladder.

Changes

  • gateway/platforms/api_server.py: _REASONING_EFFORTS widened to the full ladder + none
  • New test pins every VALID_REASONING_EFFORTS level as accepted; bespoke levels still ignored

Salvages the api_server hunk of #78216 (credit @snowzlmbot). That PR's other hunks — removing the transport-level ultra clamp and the terminal_tool lifecycle bypass — were declined separately.

Validation

113 API-server tests green (new ladder test + full test_api_server.py).

Infographic

the api door fits the whole ladder

…lently ignored on API/browser requests

_request_reasoning_config() whitelisted none..xhigh, so a client sending
max or ultra (valid /reasoning + config.yaml levels) fell through to the
default effort with no error. The server now accepts the full internal
ladder (hermes_constants.VALID_REASONING_EFFORTS); per-provider wire
clamping happens downstream via agent.reasoning_effort, same as every
other entry surface. Salvages the api_server hunk of #78216 (credit
@snowzlmbot); the un-clamping half of that PR was rejected separately.
@github-actions

github-actions Bot commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

૮ >ﻌ< ა ci review

ran on 7ec75b6 — fix(api-server): 'max' and 'ultra' reasoning efforts are no

⚠️ Warnings

OSV vulnerability scan · View job

7 known vulnerabilities found in pinned dependencies.

How to fix:

Review the findings in the Security tab. Update the affected dependencies if a patched version is available.


debug info

CI timings

CI timings · View report · View job

Wall time 3m37s vs 6m2s (-40.1%). 15 job(s) slower, 9 faster,

  • Python tests / Run tests slice 4/12: -37.0s
  • Python tests / Run tests slice 3/12: +33.0s
  • Python tests / Run tests slice 7/12: -27.0s
  • Python tests / Run tests slice 1/12: +26.0s
  • Python tests / Run tests slice 11/12: +22.0s

@teknium1
teknium1 merged commit 2d59cb4 into main Aug 20, 2026
47 checks passed
@teknium1
teknium1 deleted the fix/api-server-effort-vocab branch August 20, 2026 05:56
@alt-glitch alt-glitch added type/bug Something isn't working comp/gateway Gateway runner, session dispatch, delivery P2 Medium — degraded but workaround exists labels Aug 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/gateway Gateway runner, session dispatch, delivery P2 Medium — degraded but workaround exists type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants