mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-09-21 14:22:14 +03:00
DefaultExecutor only invoked the reasoning_content injector (open-sse/utils/reasoningContentInjector.ts, ported from 9router#1480) for provider === "kimi"/"moonshot". The `bai` gateway resells DeepSeek's deepseek-reasoner thinking-mode models but was never added to that allowlist, so a follow-up turn was forwarded upstream with no reasoning_content on the prior assistant message, triggering DeepSeek's 400 "reasoning_content in the thinking mode must be passed back". Adds a `requiresReasoningContentEcho` capability flag on RegistryEntry so this is driven by the registry instead of a second provider-id allowlist, sets it on `bai`, and widens DefaultExecutor's gate + the injector helper's signature accordingly. Regression test: tests/unit/issue-13599-bai-deepseek-reasoning-content-echo.test.ts