diff --git a/apps/next/src/content/docs/llamaindex/modules/data_stores/vector_stores/qdrant.mdx b/apps/next/src/content/docs/llamaindex/modules/data_stores/vector_stores/qdrant.mdx index 5b86585b102a519392db4017755e853845465123..05e506b4b5309159006e81da758058c9a3b404d5 100644 --- a/apps/next/src/content/docs/llamaindex/modules/data_stores/vector_stores/qdrant.mdx +++ b/apps/next/src/content/docs/llamaindex/modules/data_stores/vector_stores/qdrant.mdx @@ -56,10 +56,10 @@ const vectorStore = new QdrantVectorStore({ ```ts const document = new Document({ text: essay, id_: path }); - -const index = await VectorStoreIndex.fromDocuments([document], { - vectorStore, -}); +const storageContext = await storageContextFromDefaults({ vectorStore }); + const index = await VectorStoreIndex.fromDocuments([document], { + storageContext, + }); ``` ## Query the index @@ -91,11 +91,11 @@ async function main() { }); const document = new Document({ text: essay, id_: path }); - + const storageContext = await storageContextFromDefaults({ vectorStore }); const index = await VectorStoreIndex.fromDocuments([document], { - vectorStore, + storageContext, }); - + const queryEngine = index.asQueryEngine(); const response = await queryEngine.query({