Skip to content
Blog

Preloaded RDF databases

To help users get started with RDFGraphs, we’ve uploaded ready-made databases for a few examples of popular RDF datasets that have already been imported to Kùzu. You can download these databases without any additional setup and start querying them in Cypher with Kùzu.

Note on database versions: The below databases have been preloaded to work with Kùzu version 0.2.0. Because Kùzu’s storage continually evolves, it’s important to use the same version of Kùzu as was used to create the database, in this case, v0.2.0.

Preloaded RDFGraphs

The names shown in the first column below are the RDFGraph names the RDFGraphs in Kùzu you will see when you
download these databases.

Download URLDescriptionDatabase Size
zipped/uncompressed
# Resources# Literals# TriplesLicenseDetails
DBPediaEntire DBPedia knowledge graph. See: dbpedia.org25GB/100GB129037240344778409867469010CC 3.0 and GNU Free Doc. See here.Converted from latest core DBPedia dump on Feb 15-2024 from here.
EWordnetEnglish Wordnet lexical database. See: WordNet68MB/367MB9878164949162892034CC 4.0Converted from this english-wordnet-2023.ttl.gz file.
GeonamesPopular geographical database. See: geonames.org3.7GB/20GB4921375163882790181846462CC 4.0Converted from this all-geonames-rdf.zip file.
OpenCycPopular common sense knowledge graph. See: Cyc project.70MB/359MB60857310831922413894CCConverted from this opencyc-latest.owl.gz file. Skipped 43755 triples with malformed integers.
WKLexemesWikidata lexicographical information. See: here2.5GB/15GB2347755442780808162821310CC 3.0Converted from this wikidata-20240209-lexemes-BETA.ttl.gz file.
YagoSchemaUpper taxonomy, constraints, & property definitions of Yago. See: here81KB/16MB668481085CC 3.0Converted from the yago-schema.ttl file extracted from this yago-4.5.0.2.zip file.
YagoTaxonomyFull taxonomy of Yago 4.5. See: here7.7MB/50MB1328830166366CC 3.0Converted from the yago-taxonomy.ttl file extracted from this yago-4.5.0.2.zip file.
YagoFactsFacts about entities that have an English Wikipedia page in Yago 4.5. See: here4.7GB/31GB11138914284724159312652091CC 3.0Converted from the yago-facts.ttl file extracted from this yago-4.5.0.2.zip file.
YagoBWkFacts about entities that do not have an English Wikipedia page in Yago 4.5. See: here20GB/136GB8952240513229098791472516819CC 3.0Converted from the yago-beyond-wikipedia.ttl file extracted from this yago-4.5.0.2.zip file.
YagoEntire Yago 4.5 knowledge graph. See: here25GB/166GB9931389716076340861785336361CC 3.0Union of the above 4 Yago files.

To verify your download, please use the MD5 checksums here.

If you would like to see another popular RDF dataset in Kùzu hosted here, please email us or chat with our team on Discord.

Getting Started With a Preloaded Kùzu RDFGraph

Below are the instructions for the English Wordnet that is stored as EWordnet RDFGraph. The same instructions apply to all other RDFGraphs.

Download the zip file

Pick a location to download the Kùzu database from. Let ${KZ-DB-BASE-DIR} be the address of that location. The commands for doing this from your terminal are showb below, but you also can download it to ${KZ-DB-BASE-DIR} directory by just clicking on the above link and double clicking on the zip file.

Terminal window
> cd ${KZ-DB-BASE-DIR}
> wget https://rgw.cs.uwaterloo.ca/kuzu-rdf-database/0.2.0/zips/e-wordnet-kz.zip
> unzip e-wordnet-kz.zip
> ls
e-wordnet

If the download was successful, you should see the e-wordnet directory when you run the ls command in ${KZ-DB-BASE-DIR}.

Now you are ready to query and explore the database in Kùzu via Cypher! Below, we show how you query the database with Kùzu CLI but you can also use Kùzu Explorer or any of Kùzu’s client libraries.

Visualize the data in KùzuExplorer

To get familiar with the database and its schema, you can use KùzuExplorer, our visualization tool. See the download instructions here (note that you need Docker installed and running on your machine first).

Connect the Docker server to your local directory volume by specifying the -v flag and the absolute path to the database directory as follows:

Terminal window
docker run -p 8000:8000 \
-v /path/to/your/local/database:/database \
--rm kuzudb/explorer:latest

You can visualize the EWordnet RDFGraph schema from the Explorer by clicking on the “Schema” tab on the top right.

Run the following query in the editor to see 20 random triples as follows:

MATCH (s:EWordnet_r)-[p:EWordnet]->(o)
RETURN * LIMIT 20;

Query the database using the CLI

If you prefer to work in the terminal, you can just as well use the Kùzu CLI to query the database.

Follow the instructions here and replace the HTTPS URL to download the CLI compatible with Kùzu version 0.2.0.

Connect to the downloaded database’s directory via the terminal as follows:

Terminal window
./kuzu ${KZ-DB-BASE-DIR}/e-wordnet

Then run the following command on your shell to start the CLI and issue a query:

Display the available tables in the database as follows:

Terminal window
kuzu> CALL show_tables() return *;

Output:

------------------------------------
| name | type | comment |
------------------------------------
| EWordnet_r | NODE | |
------------------------------------
| EWordnet_l | NODE | |
------------------------------------
| EWordnet_rt | REL | |
------------------------------------
| EWordnet_lt | REL | |
------------------------------------
| EWordnet | RDFGraph | |
------------------------------------
(5 tuples)

You can also run a count query to see the number of triples that match a specific condition:

Terminal window
kuzu> MATCH (s:EWordnet_r)-[p:EWordnet]->(o)
RETURN COUNT(*);

Output:

----------------
| COUNT_STAR() |
----------------
| 2892034 |
----------------