mirror of
https://github.com/perstarkse/minne.git
synced 2026-07-01 10:31:34 +02:00
feat: reranking with fastembed added
This commit is contained in:
@@ -118,11 +118,17 @@ pub async fn get_response_stream(
|
||||
};
|
||||
|
||||
// 2. Retrieve knowledge entities
|
||||
let rerank_lease = match state.reranker_pool.as_ref() {
|
||||
Some(pool) => Some(pool.checkout().await),
|
||||
None => None,
|
||||
};
|
||||
|
||||
let entities = match retrieve_entities(
|
||||
&state.db,
|
||||
&state.openai_client,
|
||||
&user_message.content,
|
||||
&user.id,
|
||||
rerank_lease,
|
||||
)
|
||||
.await
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user