Files
openclaw/extensions/moonshot/provider-policy-api.ts
Peter Steinberger 8c7e5c6918 feat(moonshot): add Kimi K2.7 Code support (#92554)
* feat(moonshot): add Kimi K2.7 Code support

* test(moonshot): surface K2.7 live provider errors

* ci(live): accept Kimi key for Moonshot sweeps

* test(moonshot): verify K2.7 across API regions
2026-06-12 17:37:28 -07:00

22 lines
723 B
TypeScript

// Moonshot policy module exposes model-specific thinking controls before runtime registration.
import type { ProviderDefaultThinkingPolicyContext } from "openclaw/plugin-sdk/core";
export const KIMI_K2_7_CODE_MODEL_ID = "kimi-k2.7-code";
export function resolveThinkingProfile(context: ProviderDefaultThinkingPolicyContext) {
if (context.modelId.trim().toLowerCase() === KIMI_K2_7_CODE_MODEL_ID) {
return {
levels: [{ id: "low" as const, label: "on" }],
defaultLevel: "low" as const,
preserveWhenCatalogReasoningFalse: true,
};
}
return {
levels: [
{ id: "off" as const, label: "off" },
{ id: "low" as const, label: "on" },
],
defaultLevel: "off" as const,
};
}