对接 deepseek 模型

This commit is contained in:
yangyongju
2024-08-12 17:36:18 +08:00
parent cf1c8e8f2a
commit 9fdf7ef78f
16 changed files with 473 additions and 21 deletions

View File

@@ -22,5 +22,8 @@ export function cloudflareAIGatewayUrl(fetchUrl: string) {
}
// TODO: Amazon Bedrock, Groq, HuggingFace...
}
if ("api.deepseek.com" == paths[2]) {
return paths.slice(0, 3).concat(paths.slice(-3)).join("/");
}
return fetchUrl;
}