Skip to content

Commit

Permalink
expand rerank range
Browse files Browse the repository at this point in the history
  • Loading branch information
KevinHuSh committed Oct 8, 2024
1 parent 5cc9981 commit d2a9c53
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rag/nlp/search.py
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ def retrieval(self, question, embd_mdl, tenant_id, kb_ids, page, page_size, simi
if not question:
return ranks
RERANK_PAGE_LIMIT = 3
req = {"kb_ids": kb_ids, "doc_ids": doc_ids, "size": page_size*RERANK_PAGE_LIMIT,
req = {"kb_ids": kb_ids, "doc_ids": doc_ids, "size": max(page_size*RERANK_PAGE_LIMIT, 128),
"question": question, "vector": True, "topk": top,
"similarity": similarity_threshold,
"available_int": 1}
Expand Down

0 comments on commit d2a9c53

Please sign in to comment.