Skip to content

Commit fbe899e

Browse files
committed
fix: rerank error
--bug=1052035 --user=王孝刚 【模型管理】SiliconFlow的重排模型,重排后的内容不正确 https://www.tapd.cn/57709429/s/1651239
1 parent 8b32944 commit fbe899e

File tree

1 file changed

+2
-1
lines changed
  • apps/setting/models_provider/impl/siliconCloud_model_provider/model

1 file changed

+2
-1
lines changed

apps/setting/models_provider/impl/siliconCloud_model_provider/model/reranker.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,8 @@ def compress_documents(self, documents: Sequence[Document], query: str, callback
7373
"model": self.model,
7474
"query": query,
7575
"documents": texts,
76-
"top_n": self.top_n
76+
"top_n": self.top_n,
77+
"return_documents": True,
7778
}
7879

7980
response = requests.post(f"{self.api_base}/rerank", json=payload, headers=headers)

0 commit comments

Comments
 (0)