fix(providers): wire MiMo to thinking_type to allow disabling reasoning (#3585)

The hosted Xiaomi MiMo API accepts {"thinking": {"type": "enabled"|"disabled"}}
to toggle reasoning, which is exactly the shape produced by the existing
thinking_type style. The xiaomi_mimo ProviderSpec just needed to opt in.

Before this fix, setting reasoning_effort="none" had no effect on MiMo
because no thinking_style was configured, so the disable signal never
reached the server. Default-on models (mimo-v2.5-pro and friends) kept
reasoning regardless of user configuration.

Source: https://platform.xiaomimimo.com/docs/en-US/api/chat/openai-api

Co-authored with Claude Opus 4.7. Strategy and review via Claude Desktop,
implementation via Claude Code.
This commit is contained in:
Alfredo Arenas authored and Xubin Ren committed 2026-05-11 14:38:28 +08:00
1 parent 271b674bf1
commit c6b7a9524c
2 files changed
+124

No files matched your search

+3
View File
@@ -368,6 +368,8 @@ PROVIDERS: tuple[ProviderSpec, ...] = (
reasoning_as_content=True,
),
# Xiaomi MIMO (小米): OpenAI-compatible API
# Hosted API (api.xiaomimimo.com) accepts {"thinking": {"type": "enabled"|"disabled"}}
# to toggle reasoning, matching the existing thinking_type style.
ProviderSpec(
name="xiaomi_mimo",
keywords=("xiaomi_mimo", "mimo"),
@@ -375,6 +377,7 @@ PROVIDERS: tuple[ProviderSpec, ...] = (
display_name="Xiaomi MIMO",
backend="openai_compat",
default_api_base="https://api.xiaomimimo.com/v1",
thinking_style="thinking_type",
),
# LongCat: OpenAI-compatible API
ProviderSpec(