Skip to content

Commit de8f023

Browse files
committed
Update.
1 parent 89e2024 commit de8f023

File tree

1 file changed

+17
-2
lines changed

1 file changed

+17
-2
lines changed

retrieval/vector-search/vector_search_example.ipynb

+17-2
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,25 @@
2929
"# Build a Movie Similarity Search Engine with Vector Search in Memgraph\n",
3030
"\n",
3131
"In this example, we will demonstrate how vector search can be used to find movies based on their plots or short descriptions. For this, we will use the Wikipedia Movie Plots dataset, available on Kaggle.\n",
32-
"To get started, launch Memgraph with the `--experimental-enabled=vector-search` flag and the appropriate `--experimental-config flag`.\n",
32+
"To get started, launch Memgraph. \n",
3333
"\n",
3434
"To start Memgraph, run:\n",
35-
"`docker run -p 7687:7687 -p 7444:7444 memgraph/memgraph:latest --experimental-enabled=vector-search --experimental-config='{\"vector-search\": {\"movies_index\": {\"label\": \"Movie\",\"property\": \"embedding\",\"dimension\": 384,\"capacity\": 100, \"metric\": \"cos\"}}}'`"
35+
"`docker run -p 7687:7687 -p 7444:7444 memgraph/memgraph:3.0.0`\n",
36+
"\n",
37+
"After that we need to create an Vector index in Memgraph, you can do it via Python client: "
38+
]
39+
},
40+
{
41+
"cell_type": "code",
42+
"execution_count": null,
43+
"metadata": {},
44+
"outputs": [],
45+
"source": [
46+
"import neo4j\n",
47+
"\n",
48+
"driver = neo4j.GraphDatabase.driver(\"bolt://localhost:7687\", auth=(\"\", \"\"))\n",
49+
"with driver.session() as session:\n",
50+
" session.run(\"\"\"CREATE VECTOR INDEX movies_index ON :Movie(embedding) WITH CONFIG {\"dimension\": 384, \"capacity\": 100, \"metric\": \"cos\"};\"\"\")\n"
3651
]
3752
},
3853
{

0 commit comments

Comments
 (0)