mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-10-10 09:19:42 +02:00
fix(codex): limit launch defaults to local sessions
This commit is contained in:
@@ -48,10 +48,10 @@
|
||||
'Default Codex model': 'Codex 默认模型',
|
||||
'Default Codex reasoning effort': 'Codex 默认思考强度',
|
||||
'Use Codex configuration': '使用 Codex 配置',
|
||||
'Model ID for new Codex sessions. Leave empty to use Codex configuration.':
|
||||
'新 Codex 会话使用的模型 ID。留空时使用 Codex 配置。',
|
||||
'Applies to new sessions; supported levels depend on the model and Codex version. Custom endpoints keep their own settings.':
|
||||
'应用于新会话;可用强度取决于模型和 Codex 版本。自定义端点保留自己的设置。',
|
||||
'Model ID for new local Codex sessions, including WSL. Leave empty to use Codex configuration.':
|
||||
'新本地 Codex 会话(包括 WSL)使用的模型 ID。留空时使用 Codex 配置。',
|
||||
'Applies to new local sessions; supported levels depend on the model and Codex version. Custom endpoints, Docker and remote sessions keep their own settings.':
|
||||
'应用于新本地会话;可用强度取决于模型和 Codex 版本。自定义端点、Docker 和远程会话保留自己的设置。',
|
||||
'Skip to terminal': '跳转到终端',
|
||||
'Go to main page': '返回主页',
|
||||
'Session tabs': '会话标签页',
|
||||
|
||||
@@ -2530,14 +2530,14 @@
|
||||
<div class="set-row" data-search="codex default model">
|
||||
<div class="set-row-text">
|
||||
<span class="set-row-label">Default Codex model</span>
|
||||
<span class="set-row-desc">Model ID for new Codex sessions. Leave empty to use Codex configuration.</span>
|
||||
<span class="set-row-desc">Model ID for new local Codex sessions, including WSL. Leave empty to use Codex configuration.</span>
|
||||
</div>
|
||||
<input id="appSettingsCodexModel" class="set-input" type="text" maxlength="100" aria-label="Default Codex model" placeholder="Use Codex configuration" autocomplete="off" spellcheck="false">
|
||||
</div>
|
||||
<div class="set-row" data-search="codex default reasoning effort thinking">
|
||||
<div class="set-row-text">
|
||||
<span class="set-row-label">Default Codex reasoning effort</span>
|
||||
<span class="set-row-desc">Applies to new sessions; supported levels depend on the model and Codex version. Custom endpoints keep their own settings.</span>
|
||||
<span class="set-row-desc">Applies to new local sessions; supported levels depend on the model and Codex version. Custom endpoints, Docker and remote sessions keep their own settings.</span>
|
||||
</div>
|
||||
<select id="appSettingsCodexReasoningEffort" class="set-select" aria-label="Default Codex reasoning effort">
|
||||
<option value="">Use Codex configuration</option>
|
||||
|
||||
@@ -1104,7 +1104,8 @@ export function registerSessionRoutes(
|
||||
const globalNice = await ctx.getGlobalNiceConfig();
|
||||
const modelConfig = await ctx.getModelConfig();
|
||||
const mode = body.mode || 'claude';
|
||||
const launchCodexConfig = mode === 'codex' ? await resolveCodexLaunchDefaults(body.codexConfig) : body.codexConfig;
|
||||
const launchCodexConfig =
|
||||
mode === 'codex' && !remote ? await resolveCodexLaunchDefaults(body.codexConfig) : body.codexConfig;
|
||||
// Where a model override comes from is a capability, and the three answers are
|
||||
// genuinely different mechanisms:
|
||||
// 'flag' — the CLI takes --model, so read the value the caller sent
|
||||
@@ -3835,7 +3836,9 @@ export function registerSessionRoutes(
|
||||
const niceConfig = await ctx.getGlobalNiceConfig();
|
||||
const qsModelConfig = await ctx.getModelConfig();
|
||||
const qsLaunchCodexConfig =
|
||||
mode === 'codex' && !remote ? await resolveCodexLaunchDefaults(codexConfig, !!customModel) : codexConfig;
|
||||
mode === 'codex' && !remote && !docker
|
||||
? await resolveCodexLaunchDefaults(codexConfig, !!customModel)
|
||||
: codexConfig;
|
||||
// See the create path for why this is a capability rather than a mode ladder.
|
||||
const qsModelSource = getCli(mode)?.capabilities.model;
|
||||
const qsModel =
|
||||
|
||||
Reference in New Issue
Block a user