mirror of
https://github.com/openclaw/openclaw.git
synced 2026-04-18 04:31:10 +00:00
refactor(plugins): move provider seams to owning extensions
This commit is contained in:
@@ -1,6 +1,10 @@
|
||||
import type { OpenClawConfig } from "../config/config.js";
|
||||
import { ensureModelAllowlistEntry } from "./provider-model-allowlist.js";
|
||||
import { applyAgentDefaultPrimaryModel } from "./provider-model-primary.js";
|
||||
export {
|
||||
applyOpencodeZenModelDefault,
|
||||
OPENCODE_ZEN_DEFAULT_MODEL,
|
||||
} from "../../extensions/opencode/api.js";
|
||||
|
||||
export const OPENAI_DEFAULT_MODEL = "openai/gpt-5.4";
|
||||
export const OPENAI_CODEX_DEFAULT_MODEL = "openai-codex/gpt-5.4";
|
||||
@@ -12,12 +16,6 @@ export const OPENAI_DEFAULT_EMBEDDING_MODEL = "text-embedding-3-small";
|
||||
export const GOOGLE_GEMINI_DEFAULT_MODEL = "google/gemini-3.1-pro-preview";
|
||||
export const OLLAMA_DEFAULT_BASE_URL = "http://127.0.0.1:11434";
|
||||
export const OPENCODE_GO_DEFAULT_MODEL_REF = "opencode-go/kimi-k2.5";
|
||||
export const OPENCODE_ZEN_DEFAULT_MODEL = "opencode/claude-opus-4-6";
|
||||
|
||||
const LEGACY_OPENCODE_ZEN_DEFAULT_MODELS = new Set([
|
||||
"opencode/claude-opus-4-5",
|
||||
"opencode-zen/claude-opus-4-5",
|
||||
]);
|
||||
|
||||
export function applyGoogleGeminiModelDefault(cfg: OpenClawConfig): {
|
||||
next: OpenClawConfig;
|
||||
@@ -75,14 +73,3 @@ export function applyOpencodeGoModelDefault(cfg: OpenClawConfig): {
|
||||
} {
|
||||
return applyAgentDefaultPrimaryModel({ cfg, model: OPENCODE_GO_DEFAULT_MODEL_REF });
|
||||
}
|
||||
|
||||
export function applyOpencodeZenModelDefault(cfg: OpenClawConfig): {
|
||||
next: OpenClawConfig;
|
||||
changed: boolean;
|
||||
} {
|
||||
return applyAgentDefaultPrimaryModel({
|
||||
cfg,
|
||||
model: OPENCODE_ZEN_DEFAULT_MODEL,
|
||||
legacyModels: LEGACY_OPENCODE_ZEN_DEFAULT_MODELS,
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user