Skip to content

MaastrichtU-IDS/kg-metadata

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

85 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wikidata Metadata Validation SHACL Syntax Validation

Knowledge Graph Metadata Specification and Validation

This project helps you:

  • Describe your Knowledge Graph (KG) using our metadata schema
  • Validate your KG metadata using our SHACL shapes
  • Publish your KG and make it discoverable by Google (instructions below)

Example Usage

The file "data/wikidata_hcls_metadata.ttl" in this repo is an example of specification conformance metadata generated for Wikidata KG. run the SHACL validation to check conformance of Wikidata metadata to proposed specification.

setup the environment

prepare the local environment

    python -m venv .venv

activate the local environment

    source .venv/bin/activate

install the python packages

    python -m pip install -r requirements.txt

run the test

    python validate.py -i data/wikidata_hcls_metadata.ttl -s shacl/full-hcls_shacl.ttl

Publish KG Metadata

Make your dataset discoverable via Google Dataset Search using the steps below.


1. Create Metadata

Use the provided JSON-LD context/KG specification to define your KG metadata.

2. Generate index.html

Embed your metadata in JSON-LD format inside a <script> block, see example index.hml for food health claim kg here https://github.com/MaastrichtU-IDS/food-claims-kg/blob/gh-pages/index.html

3. Deploy via GitHub Pages

  1. Place index.html in your KG's GitHub repository.

  2. Go to Settings → Pages.

  3. Under Source, choose:

    • Branch: gh-pages
  4. Visit your public page at:
    https://<username>.github.io/<repo-name>/ Example:
    \url{https://maastrichtu-ids.github.io/food-claims-kg/}

4. Validate with Google Rich Results Test

Visit Google Rich Results Test, enter the published URL, and verify structured data compatibility.

5. Verify Site Ownership (Google Search Console)

About

A SHACL metadata specification for knowledge graphs

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Contributors 2

  •  
  •