Coder Social home page Coder Social logo

zazuko / shacl-playground Goto Github PK

View Code? Open in Web Editor NEW
23.0 8.0 7.0 2.24 MB

Implementation of a fully client-side SHACL validation playground. Supports a wide variety of RDF serializations.

Home Page: https://shacl-playground.zazuko.com/

License: Other

JavaScript 93.47% HTML 2.47% Dockerfile 1.43% TypeScript 2.63%
shacl rdf validation playground

shacl-playground's Introduction

Zazuko SHACL Playground

You want to use SHACL shapes to validate RDF-based data but find it hard to go back and forth in your IDE? Are you unsure if the rules even make sense and are applied to your data? Stop worrying and use our SHACL playground!

SHACL playground allows you to define Data Shapes according to the W3C Shapes Constraint Language (SHACL) and test them against sample data.

The implementation of the validation is 100% in JavaScript and thus 100% client-side. We provide an instance of our validator at https://shacl-playground.zazuko.com/.

To run it locally, install the dependencies with npm i, then either start a webpack dev server with npm run --workspace 'packages/app' start and access it at http://localhost:8080, or create a production build with npm run --workspace 'packages/app' build and serve the created dist directory, e.g. with nginx.

To run it using docker, create an image with docker build -t shacl-playground ., then run it using docker run -p 80:80 shacl-playground and access it at http://localhost/.

It is built on our JavaScript-based SHACL library.

Contributions & feedback are very welcome! Enjoy & happy SHACL.

shacl-playground's People

Contributors

dependabot[bot] avatar ght avatar github-actions[bot] avatar ktk avatar ludovicm67 avatar martinmaillard avatar simonstey avatar tpluscode avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

shacl-playground's Issues

shacl:maxCount "n"^^xsd:integer;

When testing such a constraint in a shape I always get ": More than n values".

Is this supported: shacl:maxCount "n"^^xsd:integer;?

sh:targetNode not working?

https://s.zazuko.com/bnmxce

Given following shapes and data graphs:

Shapes Graph Data Graph
@prefix ex: <http://example.org/ns#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix sh:	<http://www.w3.org/ns/shacl#> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .

ex:PersonShape
   a sh:NodeShape ;
   sh:targetNode ex:Alice ;
   sh:property [
 	sh:path foaf:mbox ;
         sh:minCount 1 ;
         sh:maxCount 1 ;
   ] .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix ex: <http://example.org/ns#> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .

# invalid, foaf:mbox is missing
ex:Alice a ex:Person . 

# valid, not focus node of ex:PersonShape
ex:Bob a ex:Person .   

I would have expected to get a validation result for ex:Alice as e.g. provided by shacl.org/playground, however none is returned:
image

(fwiw, I found this possibly related issue: zazuko/rdf-validate-shacl#59)

Turtle serialization: booleans in collections

When trying

<a> <b> ( true ) .

I get the following error message:

this._dc_factory.boolean is not a function

when I trying booleans alone such as:

<a> <b> true .

or lists such as:

<a> <b> ( "Arnold" ) .

No error is thrown

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.