fix: enable zai parallel tool calls (#530)
This commit is contained in:
@@ -30,6 +30,7 @@ function buildModelSettings(
|
||||
const isAnthropic =
|
||||
modelHandle.startsWith("anthropic/") ||
|
||||
modelHandle.startsWith(`${ANTHROPIC_PROVIDER_NAME}/`);
|
||||
const isZai = modelHandle.startsWith("zai/");
|
||||
const isGoogleAI = modelHandle.startsWith("google_ai/");
|
||||
const isGoogleVertex = modelHandle.startsWith("google_vertex/");
|
||||
const isOpenRouter = modelHandle.startsWith("openrouter/");
|
||||
@@ -70,6 +71,13 @@ function buildModelSettings(
|
||||
};
|
||||
}
|
||||
settings = anthropicSettings;
|
||||
} else if (isZai) {
|
||||
// Zai uses the same model_settings structure as other providers.
|
||||
// Ensure parallel_tool_calls is enabled.
|
||||
settings = {
|
||||
provider_type: "zai",
|
||||
parallel_tool_calls: true,
|
||||
};
|
||||
} else if (isGoogleAI) {
|
||||
const googleSettings: GoogleAIModelSettings & { temperature?: number } = {
|
||||
provider_type: "google_ai",
|
||||
|
||||
Reference in New Issue
Block a user