mirror of
https://fastgit.cc/https://github.com/anomalyco/opencode
synced 2026-04-30 13:51:48 +08:00
tweak: codex model logic (#23925)
This commit is contained in:
@@ -378,6 +378,8 @@ export async function CodexAuthPlugin(input: PluginInput): Promise<Hooks> {
|
||||
for (const [modelId, model] of Object.entries(provider.models)) {
|
||||
if (modelId.includes("codex")) continue
|
||||
if (allowedModels.has(model.api.id)) continue
|
||||
const match = model.api.id.match(/^gpt-(\d+\.\d+)/)
|
||||
if (match && parseFloat(match[1]) > 5.4) continue
|
||||
delete provider.models[modelId]
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user