Hello! I'm having an issue that when trying to insert a Document to a QdrantVectorStore with the
insert
method, I get the error
AttributeError: 'NoneType' object has no attribute 'create_collection'
My code looks like this:
documents = [
Document(
text="LlamaIndex is a simple, flexible data framework for connecting custom data sources to large language models.",
metadata={
"tenant": "llama_index",
},
),
Document(
text="Qdrant is a vector database & vector similarity search engine.",
metadata={
"tenant": "qdrant",
},
),
]
llm = OpenAI(model="gpt-3.5-turbo", temperature=0)
aclient = AsyncQdrantClient(
url="localhost",
port=6333,
prefer_grpc=True,
)
vector_store = QdrantVectorStore(
collection_name="multitenant",
aclient=aclient,
enable_hybrid=True,
batch_size=20,
prefer_grpc=True
)
qdrant_index = VectorStoreIndex.from_vector_store(
llm=llm,
vector_store=vector_store,
embed_model=FastEmbedEmbedding(
model_name="BAAI/bge-base-en-v1.5"
),
transformations=[splitter],
use_async=True,
show_progress=True,
)
for document in documents:
# qdrant_index.insert(document)
await qdrant_index.insert(document)