umlSHaclEX is a library that transforms ShEx and SHACL shapes to UML.

umlSHaclEX 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)


This project has been implemented in Scala using sbt.

Command line usage

Generate a SVG diagram

sbr run --schema examples/shex/paper.shex --schemaFormat "SHEXC" -o examples/shex/paper.svg -f svg

Example diagram

Given the following ShEx code.

prefix schema: <>
prefix xsd:   <>
prefix dcterms: <>
prefix it:    <>
prefix foaf:  <>
prefix :      <>

:User IRI {
 a                    [ foaf:Person ];
 schema:birthDate     xsd:date?  ;
 foaf:knows           @:User* ;
 foaf:topic_interest  @:Topic {0,10}

:Topic {
  dcterms:title   xsd:string ;
  dcterms:creator IRI ;

:Item {
  dcterms:title [@en @fr @es] ;
  dcterms:subject @:Topic

The library generates a diagram like: