mirror of
https://github.com/hanzoai/bot.git
synced 2026-11-01 07:38:30 +00:00
The automated rebrand sed script replaced "OpenClaw" with "Hanzo Bot" (with space) instead of "HanzoBot" in 8,315 TypeScript identifier occurrences across 1,632 files. This fixes all broken class names, type names, function names, and variable names. Co-authored-by: Hanzo Dev <[email protected]>
32 lines
1022 B
TypeScript
32 lines
1022 B
TypeScript
import {
|
|
applyProviderConfigWithDefaultModelPreset,
|
|
type HanzoBotConfig,
|
|
} from "openclaw/plugin-sdk/provider-onboard";
|
|
import {
|
|
buildMistralModelDefinition,
|
|
MISTRAL_BASE_URL,
|
|
MISTRAL_DEFAULT_MODEL_ID,
|
|
} from "./model-definitions.js";
|
|
|
|
export const MISTRAL_DEFAULT_MODEL_REF = `mistral/${MISTRAL_DEFAULT_MODEL_ID}`;
|
|
|
|
function applyMistralPreset(cfg: HanzoBotConfig, primaryModelRef?: string): HanzoBotConfig {
|
|
return applyProviderConfigWithDefaultModelPreset(cfg, {
|
|
providerId: "mistral",
|
|
api: "openai-completions",
|
|
baseUrl: MISTRAL_BASE_URL,
|
|
defaultModel: buildMistralModelDefinition(),
|
|
defaultModelId: MISTRAL_DEFAULT_MODEL_ID,
|
|
aliases: [{ modelRef: MISTRAL_DEFAULT_MODEL_REF, alias: "Mistral" }],
|
|
primaryModelRef,
|
|
});
|
|
}
|
|
|
|
export function applyMistralProviderConfig(cfg: HanzoBotConfig): HanzoBotConfig {
|
|
return applyMistralPreset(cfg);
|
|
}
|
|
|
|
export function applyMistralConfig(cfg: HanzoBotConfig): HanzoBotConfig {
|
|
return applyMistralPreset(cfg, MISTRAL_DEFAULT_MODEL_REF);
|
|
}
|