feat: add embedding and rerank support

This commit is contained in:
Kayphoon
2026-05-03 17:32:41 +08:00
parent 3e2eca4fd0
commit 5abe664d65
87 changed files with 5520 additions and 184 deletions
@@ -16,6 +16,22 @@ pub(super) fn classify_ai_public_route(
"openai:chat",
true,
))
} else if method == http::Method::POST && normalized_path == "/v1/embeddings" {
Some(classified(
"ai_public",
"openai",
"embedding",
"openai:embedding",
true,
))
} else if method == http::Method::POST && normalized_path == "/v1/rerank" {
Some(classified(
"ai_public",
"openai",
"rerank",
"openai:rerank",
true,
))
} else if method == http::Method::POST
&& matches!(normalized_path, "/v1/responses" | "/v1/responses/compact")
{