SHaclEX is a Scala library that implements both ShEx and SHACL.

The library has been implemented in Scala which means that it can be used in any JVM environment. In principle, it could also work on Javascript compiling it with ScalaJs, but we haven’t tried it yet (see issue 117)

SHaclEX can be used as: - An independent comman line tool - A JAR library that can be invoked from other Scala or Java programs - Integrated in a Web application (see rdfshape)

About ShEx and SHACL

Modules and repositories

The library is composed of several modules and repositories.

The following diagram depicts the main modules and dependencies:

diagram classes

Schema

This module handles schema validation. It is a top-level module that invokes ShEx and SHACL engines.

Converter

This module can be used to convert between different schema formats and schema engines. As an example, it can be used to convert from ShEx to SHACL and from SHACL to ShEx.

Currently, only a subset of both languages can be converted.

ShEx-s

Scala implementation of ShEx. This module has been separated to its own its own repository

SHACL-s

Scala implementation of SHACL. This module has been separated to its own repository.

ShapeMaps

Scala implementation of ShapeMaps. This module has been separated to its own repository.

shexJava

A simple Java application that invokes Shaclex.

RDFShape

RDFShape is a web service implemented using http4s.

RDFShape clients

RDFShape-client

A client of RDFShape which is deployed at http://rdfshape.weso.es. It is implemented in Javascript using React.

Wikishape

Another client of RDFShape specialized on Wikidata and wikibase. It is deployed at http://wikishape.weso.es

YaSHE

A Shape Expressions Editor. Deployed at: http://www.weso.es/YASHE/

SRDF

Simple RDF library. This module contains a simple RDF interface for Scala. The module has its own repository and documentation.

We have two implementations of SRDF: - SRDFJena for Apache Jena - RDF4J for RDF4j

SchemaInfer

This module allows to infer schemas from RDF data.

SLang

This module contains an implementation of the S-Language, which is a minimal language that can represent both SHACL and ShEx.

The S-Language is described in this paper

ScalaDoc