From 3801d80362b1734a38ef88d2a180b8d946d61395 Mon Sep 17 00:00:00 2001 From: Anush008 Date: Tue, 29 Oct 2024 21:59:40 +0530 Subject: [PATCH] chore: No Arc Signed-off-by: Anush008 --- rig-qdrant/src/lib.rs | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/rig-qdrant/src/lib.rs b/rig-qdrant/src/lib.rs index 8ca50558..1be039db 100644 --- a/rig-qdrant/src/lib.rs +++ b/rig-qdrant/src/lib.rs @@ -7,14 +7,13 @@ use rig::{ vector_store::{VectorStoreError, VectorStoreIndex}, }; use serde::Deserialize; -use std::sync::Arc; /// Represents a vector store implementation using Qdrant - https://qdrant.tech/ as the backend. pub struct QdrantVectorStore { /// Model used to generate embeddings for the vector store - model: Arc, + model: M, /// Client instance for Qdrant server communication - client: Arc, + client: Qdrant, /// Default search parameters query_params: QueryPoints, } @@ -29,8 +28,8 @@ impl QdrantVectorStore { /// Reference: https://api.qdrant.tech/v-1-12-x/api-reference/search/query-points pub fn new(client: Qdrant, model: M, query_params: QueryPoints) -> Self { Self { - client: Arc::new(client), - model: Arc::new(model), + client, + model, query_params, } }