mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-07-27 16:26:16 +08:00
feat(claude): upgrade effort toggle from "high" to "max"
Per Anthropic's effort parameter docs, "high" is the API default and setting effortLevel="high" is equivalent to omitting the field entirely. The toggle previously produced no effect. Claude Opus 4.6, Sonnet 4.6, and Opus 4.7 now support a "max" level that enables unconstrained reasoning. Rename the checkbox (effortHigh -> effortMax) and write effortLevel="max" when toggled on. Existing "high" values in user configs are left untouched. Updates zh/en/ja locales and user-manual entries accordingly.
This commit is contained in:
@@ -81,7 +81,7 @@ export function CommonConfigEditor({
|
||||
enableToolSearch:
|
||||
config?.env?.ENABLE_TOOL_SEARCH === "true" ||
|
||||
config?.env?.ENABLE_TOOL_SEARCH === "1",
|
||||
effortHigh: config?.effortLevel === "high",
|
||||
effortMax: config?.effortLevel === "max",
|
||||
disableAutoUpgrade:
|
||||
config?.env?.DISABLE_AUTOUPDATER === "1" ||
|
||||
config?.env?.DISABLE_AUTOUPDATER === 1,
|
||||
@@ -91,7 +91,7 @@ export function CommonConfigEditor({
|
||||
hideAttribution: false,
|
||||
teammates: false,
|
||||
enableToolSearch: false,
|
||||
effortHigh: false,
|
||||
effortMax: false,
|
||||
disableAutoUpgrade: false,
|
||||
};
|
||||
}
|
||||
@@ -128,9 +128,9 @@ export function CommonConfigEditor({
|
||||
if (Object.keys(config.env).length === 0) delete config.env;
|
||||
}
|
||||
break;
|
||||
case "effortHigh":
|
||||
case "effortMax":
|
||||
if (checked) {
|
||||
config.effortLevel = "high";
|
||||
config.effortLevel = "max";
|
||||
} else {
|
||||
delete config.effortLevel;
|
||||
}
|
||||
@@ -227,11 +227,11 @@ export function CommonConfigEditor({
|
||||
<label className="inline-flex items-center gap-2 text-sm text-muted-foreground cursor-pointer">
|
||||
<input
|
||||
type="checkbox"
|
||||
checked={toggleStates.effortHigh}
|
||||
onChange={(e) => handleToggle("effortHigh", e.target.checked)}
|
||||
checked={toggleStates.effortMax}
|
||||
onChange={(e) => handleToggle("effortMax", e.target.checked)}
|
||||
className="w-4 h-4 text-blue-500 bg-white dark:bg-gray-800 border-border-default rounded focus:ring-blue-500 dark:focus:ring-blue-400 focus:ring-2"
|
||||
/>
|
||||
<span>{t("claudeConfig.effortHigh")}</span>
|
||||
<span>{t("claudeConfig.effortMax")}</span>
|
||||
</label>
|
||||
<label className="inline-flex items-center gap-2 text-sm text-muted-foreground cursor-pointer">
|
||||
<input
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
"hideAttribution": "Hide AI Attribution",
|
||||
"enableTeammates": "Teammates Mode",
|
||||
"enableToolSearch": "Enable Tool Search",
|
||||
"effortHigh": "High Effort Thinking",
|
||||
"effortMax": "Max Effort Thinking",
|
||||
"disableAutoUpgrade": "Disable Auto-Upgrade"
|
||||
},
|
||||
"header": {
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
"hideAttribution": "AI署名を非表示",
|
||||
"enableTeammates": "Teammates モード",
|
||||
"enableToolSearch": "Tool Search を有効化",
|
||||
"effortHigh": "高強度思考",
|
||||
"effortMax": "最大強度思考",
|
||||
"disableAutoUpgrade": "自動アップグレードを無効化"
|
||||
},
|
||||
"header": {
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
"hideAttribution": "隐藏 AI 署名",
|
||||
"enableTeammates": "Teammates 模式",
|
||||
"enableToolSearch": "启用 Tool Search",
|
||||
"effortHigh": "高强度思考",
|
||||
"effortMax": "最大强度思考",
|
||||
"disableAutoUpgrade": "禁用自动升级"
|
||||
},
|
||||
"header": {
|
||||
|
||||
Reference in New Issue
Block a user