fix: modified QdrantVectorStoreComponent to use server_kwargs correctly (#3751)
* resolveQdrant Vector Store doesnt' use the advanced fields when ingesting documents #3749 * resolveQdrant Vector Store doesnt' use the advanced fields when ingesting documents #3749 * [autofix.ci] apply automated fixes --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
parent
4519f9ffa8
commit
8a84299a47
1 changed files with 5 additions and 4 deletions
|
|
@ -66,11 +66,12 @@ class QdrantVectorStoreComponent(LCVectorStoreComponent):
|
|||
|
||||
server_kwargs = {
|
||||
"host": self.host if self.host else None,
|
||||
"port": int(self.port), # Garantir que port seja um inteiro
|
||||
"grpc_port": int(self.grpc_port), # Garantir que grpc_port seja um inteiro
|
||||
"port": int(self.port), # Ensure port is an integer
|
||||
"grpc_port": int(self.grpc_port), # Ensure grpc_port is an integer
|
||||
"api_key": self.api_key,
|
||||
"prefix": self.prefix,
|
||||
"timeout": int(self.timeout) if self.timeout else None, # Garantir que timeout seja um inteiro
|
||||
# Ensure timeout is an integer
|
||||
"timeout": int(self.timeout) if self.timeout else None,
|
||||
"path": self.path if self.path else None,
|
||||
"url": self.url if self.url else None,
|
||||
}
|
||||
|
|
@ -89,7 +90,7 @@ class QdrantVectorStoreComponent(LCVectorStoreComponent):
|
|||
raise ValueError(msg)
|
||||
|
||||
if documents:
|
||||
qdrant = Qdrant.from_documents(documents, embedding=self.embedding, **qdrant_kwargs)
|
||||
qdrant = Qdrant.from_documents(documents, embedding=self.embedding, **qdrant_kwargs, **server_kwargs)
|
||||
else:
|
||||
from qdrant_client import QdrantClient
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue