🎉 This is by far the most common feature request for PySHACL 🎉
This adds an alternative operating mode, as first described in the discussion in #60
Rather than validating the DataGraph against a Shapes and Constraints, this mode will run only the SHACL Functions and SHACL Rules as defined in the SHACL-AF spec.
By default it will output a new graph containing a copy of the existing DataGraph Triples plus the expanded triples
Run with inplace mode to expand the new triples directly into the input DataGraph
When combining this mode with the recently added Shapes Selection and Focus-node targeting options, this allows running selected expansion runs on selected nodes, enabling some very powerful procedural SHACL workflows.
This PR is pretty big.
There was some refactoring done to Validator, to allow for alternate run modes
the addition of the new run modes and the pyshacl_rules CLI script
tests for SHACL Rules Expander run mode
tests for pyshacl_rules CLI script
refactoring of SHACL TripleRules, SPARQLRules, and JSRules to allow the selective gathering from specified Shapes, and the selective application to specified focus nodes
Some new typing annotations were added to keep everything happy.
🎉 This is by far the most common feature request for PySHACL 🎉
This adds an alternative operating mode, as first described in the discussion in #60
Rather than validating the DataGraph against a Shapes and Constraints, this mode will run only the SHACL Functions and SHACL Rules as defined in the SHACL-AF spec.
When combining this mode with the recently added Shapes Selection and Focus-node targeting options, this allows running selected expansion runs on selected nodes, enabling some very powerful procedural SHACL workflows.
This PR is pretty big.