Skip to content

fix error where model always thinking#9

Open
thezukiru wants to merge 1 commit into
XxxXTeam:mainfrom
thezukiru:patch-1
Open

fix error where model always thinking#9
thezukiru wants to merge 1 commit into
XxxXTeam:mainfrom
thezukiru:patch-1

Conversation

@thezukiru
Copy link
Copy Markdown

Summary

  • Fix model suffix handling so -thinking and -search explicitly control runtime features.
  • Prevent base model defaults from forcing thinking/search mode on non-suffixed model names.

Why

  • Previously, if a base model mapping had EnableThinking: true, using a plain model name like GLM-5.1 could still enable thinking mode unexpectedly.
  • Users expect GLM-5.1 to run without thinking, while GLM-5.1-thinking should explicitly enable thinking.

Changes

  • Updated GetModelMapping so parsed suffix flags override the base model mapping feature flags.
  • EnableThinking, WebSearch, and AutoWebSearch are now derived from the requested model suffixes.
  • This makes model behavior predictable:
    • GLM-5.1 → thinking/search disabled
    • GLM-5.1-thinking → thinking enabled
    • GLM-5.1-search → search enabled
    • GLM-5.1-thinking-search → thinking and search enabled

Test Plan

  • 本地构建通过
  • 关键功能已自测
  • 如涉及接口变更,已验证兼容性
  • 如涉及配置 / workflow 变更,已验证触发逻辑

Checklist

  • 已关联相关 Issue(如有)
  • 已避免引入无关改动
  • 已更新必要文档或说明(如适用)

Signed-off-by: thezukiru <121331256+thezukiru@users.noreply.github.com>
@thezukiru
Copy link
Copy Markdown
Author

Summary

  • Fix model suffix handling so -thinking and -search explicitly control runtime features.
  • Prevent base model defaults from forcing thinking/search mode on non-suffixed model names.

Why

  • Previously, if a base model mapping had EnableThinking: true, using a plain model name like GLM-5.1 could still enable thinking mode unexpectedly.
  • Users expect GLM-5.1 to run without thinking, while GLM-5.1-thinking should explicitly enable thinking.

Changes

  • Updated GetModelMapping so parsed suffix flags override the base model mapping feature flags.

  • EnableThinking, WebSearch, and AutoWebSearch are now derived from the requested model suffixes.

  • This makes model behavior predictable:

    • GLM-5.1 → thinking/search disabled
    • GLM-5.1-thinking → thinking enabled
    • GLM-5.1-search → search enabled
    • GLM-5.1-thinking-search → thinking and search enabled

Test Plan

  • 本地构建通过
  • 关键功能已自测
  • 如涉及接口变更,已验证兼容性
  • 如涉及配置 / workflow 变更,已验证触发逻辑

Checklist

  • 已关联相关 Issue(如有)
  • 已避免引入无关改动
  • 已更新必要文档或说明(如适用)

Summary

  • Fix model suffix handling so -thinking and -search explicitly control runtime features.
  • Prevent base model defaults from forcing thinking/search mode on non-suffixed model names.

Why

  • Previously, if a base model mapping had EnableThinking: true, using a plain model name like GLM-5.1 could still enable thinking mode unexpectedly.
  • Users expect GLM-5.1 to run without thinking, while GLM-5.1-thinking should explicitly enable thinking.

Changes

  • Updated GetModelMapping so parsed suffix flags override the base model mapping feature flags.

  • EnableThinking, WebSearch, and AutoWebSearch are now derived from the requested model suffixes.

  • This makes model behavior predictable:

    • GLM-5.1 → thinking/search disabled
    • GLM-5.1-thinking → thinking enabled
    • GLM-5.1-search → search enabled
    • GLM-5.1-thinking-search → thinking and search enabled

Test Plan

  • 本地构建通过
  • 关键功能已自测
  • 如涉及接口变更,已验证兼容性
  • 如涉及配置 / workflow 变更,已验证触发逻辑

Checklist

  • 已关联相关 Issue(如有)
  • 已避免引入无关改动
  • 已更新必要文档或说明(如适用)

ChatGPT 5.5-Thinking review:

The intent is good, but this change should not be merged as-is. It fixes plain base models by overriding feature flags from suffixes, but it also disables existing explicit mappings like GLM-5-Thinking, GLM-5-Search, and GLM-4.1V-Thinking-FlashX, because ParseModelName only handles lowercase -thinking / -search suffixes and the new code overwrites the mapping flags with false. It also does not add search MCP servers for generated -search variants. Please make suffix parsing case-insensitive, preserve exact builtin mappings, add/merge the required MCP servers for search variants, and add unit tests for base, thinking, search, thinking-search, uppercase builtin names, and intrinsic Thinking model names.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant