Skip to content

该如何覆盖一些参数?比如 reasoning_effort #371

Closed

Description

@WslzGmzs

一些模型并不支持 claudecode 的参数比如 medium,xhigh

当设置了这些会报错,我希望在 cc 使用 Claude 路由到 glm 能够恒定 max 应该如何操作, 对于使用 Ultracode 也很有帮助,因为它会恒定xhigh

Activity

  1. fylorn commented on Oct 25, 2026

    @fylorn
    Contributor

    Thanks for the request. This is available in 2026.10.29.

    Pin the reasoning effort with a routing rule. Open Routing, edit the rule that forwards Claude Code to GLM, and under Parameter rewrites set Reasoning to max. Every request that rule matches is then sent with max, whatever the client asks for, including the xhigh that Ultracode always sends. The level applies to requests that already have reasoning on; requests without reasoning (such as title generation) are left unchanged. Off turns reasoning off.

    If the rule can fail over to another upstream and only GLM should get max, add a separate rule with the condition Selected upstream = your GLM upstream, On match = Continue matching, and Reasoning set there; such a rule applies only to that upstream.

    Unsupported levels are also handled without any setting. When an upstream answers 400 because it does not accept the requested level, ThinkWatch sends the request again once with a level it accepts (the one its error message lists, or the model's default), and remembers that for the model for 7 days, so later requests go out correctly the first time. Every change is shown in the request details.

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