feat: Add Jina reranking support for OpenAI adaptor

This commit is contained in:
1808837298@qq.com
2025-02-26 21:46:06 +08:00
parent c802b3b41a
commit 287caf8e38
3 changed files with 6 additions and 3 deletions

View File

@@ -9,7 +9,7 @@ import (
"one-api/service"
)
func jinaRerankHandler(c *gin.Context, resp *http.Response) (*dto.OpenAIErrorWithStatusCode, *dto.Usage) {
func JinaRerankHandler(c *gin.Context, resp *http.Response) (*dto.OpenAIErrorWithStatusCode, *dto.Usage) {
responseBody, err := io.ReadAll(resp.Body)
if err != nil {
return service.OpenAIErrorWrapper(err, "read_response_body_failed", http.StatusInternalServerError), nil