You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/docs/ops/storages.md
+44-19Lines changed: 44 additions & 19 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -386,19 +386,7 @@ You can find end-to-end examples fitting into any of supported property graphs i
386
386
387
387
### Neo4j
388
388
389
-
If you don't have a Neo4j database, you can start a Neo4j database using our docker compose config:
390
-
391
-
```bash
392
-
docker compose -f <(curl -L https://raw.githubusercontent.com/cocoindex-io/cocoindex/refs/heads/main/dev/neo4j.yaml) up -d
393
-
```
394
-
395
-
:::warning
396
-
397
-
The docker compose config above will start a Neo4j Enterprise instance under the [Evaluation License](https://neo4j.com/terms/enterprise_us/),
398
-
with 30 days trial period.
399
-
Please read and agree the license before starting the instance.
400
-
401
-
:::
389
+
#### Spec
402
390
403
391
The `Neo4j` target spec takes the following fields:
404
392
@@ -417,17 +405,32 @@ Neo4j also provides a declaration spec `Neo4jDeclaration`, to configure indexing
417
405
*`primary_key_fields` (required)
418
406
*`vector_indexes` (optional)
419
407
420
-
###Kuzu
408
+
#### Neo4j dev instance
421
409
422
-
CocoIndex supports talking to Kuzu through its [API server](https://github.com/kuzudb/api-server).
423
-
You can bring up a Kuzu API server locally by running:
410
+
If you don't have a Neo4j database, you can start a Neo4j database using our docker compose config:
424
411
425
412
```bash
426
-
KUZU_DB_DIR=$HOME/.kuzudb
427
-
KUZU_PORT=8123
428
-
docker run -d --name kuzu -p ${KUZU_PORT}:8000 -v ${KUZU_DB_DIR}:/database kuzudb/api-server:latest
413
+
docker compose -f <(curl -L https://raw.githubusercontent.com/cocoindex-io/cocoindex/refs/heads/main/dev/neo4j.yaml) up -d
429
414
```
430
415
416
+
If will bring up a Neo4j instance, which can be accessed by username `neo4j` and password `cocoindex`.
417
+
You can access the Neo4j browser at [http://localhost:7474](http://localhost:7474).
418
+
419
+
:::warning
420
+
421
+
The docker compose config above will start a Neo4j Enterprise instance under the [Evaluation License](https://neo4j.com/terms/enterprise_us/),
422
+
with 30 days trial period.
423
+
Please read and agree the license before starting the instance.
424
+
425
+
:::
426
+
427
+
428
+
### Kuzu
429
+
430
+
#### Spec
431
+
432
+
CocoIndex supports talking to Kuzu through its [API server](https://github.com/kuzudb/api-server).
433
+
431
434
The `Kuzu` target spec takes the following fields:
432
435
433
436
*`connection` (type: [auth reference](../core/flow_def#auth-registry) to `KuzuConnectionSpec`): The connection to the Kuzu database. `KuzuConnectionSpec` has the following fields:
@@ -440,3 +443,25 @@ Kuzu also provides a declaration spec `KuzuDeclaration`, to configure indexing o
440
443
* Fields for [nodes to declare](#declare-extra-node-labels), including
441
444
*`nodes_label` (required)
442
445
*`primary_key_fields` (required)
446
+
447
+
#### Kuzu dev instance
448
+
449
+
If you don't have a Kuzu instance yet, you can bring up a Kuzu API server locally by running:
450
+
451
+
```bash
452
+
KUZU_DB_DIR=$HOME/.kuzudb
453
+
KUZU_PORT=8123
454
+
docker run -d --name kuzu -p ${KUZU_PORT}:8000 -v ${KUZU_DB_DIR}:/database kuzudb/api-server:latest
455
+
```
456
+
457
+
To explore the graph you built with Kuzu, you can use the [Kuzu Explorer](https://github.com/kuzudb/explorer).
458
+
Currently Kuzu API server and the explorer cannot be up at the same time. So you need to stop the API server before running the explorer.
*[Install Postgres](https://cocoindex.io/docs/getting_started/installation#-install-postgres) if you don't have one.
18
-
*[Install Neo4j](https://cocoindex.io/docs/ops/storages#neo4j) if you don't have one.
17
+
* Install [Neo4j](https://cocoindex.io/docs/ops/storages#neo4j-dev-instance) or [Kuzu](https://cocoindex.io/docs/ops/storages#kuzu-dev-instance) if you don't have one.
18
+
* The example uses Neo4j by default for now. If you want to use Kuzu, find out the "SELECT ONE GRAPH DATABASE TO USE" section and switch the active branch.
19
19
*[Configure your OpenAI API key](https://cocoindex.io/docs/ai/llm#openai).
20
20
21
21
## Documentation
@@ -45,21 +45,18 @@ cocoindex update main.py
45
45
46
46
### Browse the knowledge graph
47
47
48
-
After the knowledge graph is build, you can explore the knowledge graph you built in Neo4j Browser.
48
+
After the knowledge graph is built, you can explore the knowledge graph.
49
49
50
-
For the dev enviroment, you can connect neo4j browser using credentials:
51
-
- username: `neo4j`
52
-
- password: `cocoindex`
53
-
which is pre-configured in the our docker compose [config.yaml](https://raw.githubusercontent.com/cocoindex-io/cocoindex/refs/heads/main/dev/neo4j.yaml).
50
+
* If you're using Neo4j, you can open the explorer at [http://localhost:7474](http://localhost:7474), with username `neo4j` and password `cocoindex`.
51
+
* If you're using Kuzu, you can start a Kuzu explorer locally. See [Kuzu dev instance](https://cocoindex.io/docs/ops/storages#kuzu-dev-instance) for more details.
54
52
55
-
You can open it at [http://localhost:7474](http://localhost:7474), and run the following Cypher query to get all relationships:
53
+
You can run the following Cypher query to get all relationships:
Copy file name to clipboardExpand all lines: examples/product_recommendation/README.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,8 @@ Please drop [CocoIndex on Github](https://github.com/cocoindex-io/cocoindex) a s
9
9
10
10
## Prerequisite
11
11
*[Install Postgres](https://cocoindex.io/docs/getting_started/installation#-install-postgres) if you don't have one.
12
-
*[Install Neo4j](https://cocoindex.io/docs/ops/storages#neo4j) if you don't have one.
12
+
* Install [Neo4j](https://cocoindex.io/docs/ops/storages#neo4j-dev-instance) or [Kuzu](https://cocoindex.io/docs/ops/storages#kuzu-dev-instance) if you don't have one.
13
+
* The example uses Neo4j by default for now. If you want to use Kuzu, find out the "SELECT ONE GRAPH DATABASE TO USE" section and switch the active branch.
13
14
*[Configure your OpenAI API key](https://cocoindex.io/docs/ai/llm#openai).
14
15
15
16
## Documentation
@@ -39,18 +40,17 @@ cocoindex update main.py
39
40
40
41
### Browse the knowledge graph
41
42
42
-
After the knowledge graph is built, you can explore the knowledge graph you built in Neo4j Browser.
43
+
After the knowledge graph is built, you can explore the knowledge graph.
43
44
44
-
For the dev enviroment, you can connect neo4j browser using credentials:
45
-
- username: `neo4j`
46
-
- password: `cocoindex`
47
-
which is pre-configured in the our docker compose [config.yaml](https://raw.githubusercontent.com/cocoindex-io/cocoindex/refs/heads/main/dev/neo4j.yaml).
45
+
* If you're using Neo4j, you can open the explorer at [http://localhost:7474](http://localhost:7474), with username `neo4j` and password `cocoindex`.
46
+
* If you're using Kuzu, you can start a Kuzu explorer locally. See [Kuzu dev instance](https://cocoindex.io/docs/ops/storages#kuzu-dev-instance) for more details.
48
47
49
-
You can open it at [http://localhost:7474](http://localhost:7474), and run the following Cypher query to get all relationships:
48
+
You can run the following Cypher query to get all relationships:
0 commit comments