use parseProxyModelName for toolSupport

This commit is contained in:
Nate 2025-05-20 13:41:13 -07:00
parent 860fb83906
commit a4f025111e

View file

@ -1,11 +1,11 @@
import { parseProxyModelName } from "@continuedev/config-yaml";
export const PROVIDER_TOOL_SUPPORT: Record<
string,
(model: string) => boolean | undefined
> = {
"continue-proxy": (model) => {
// see getContinueProxyModelName
const provider = model.split("/")[2];
const _model = model.split("/")[3];
const { provider, model: _model } = parseProxyModelName(model);
if (provider && _model && provider !== "continue-proxy") {
const fn = PROVIDER_TOOL_SUPPORT[provider];
if (fn) {