NEW
Also known as: Shapes Constraint Language
A language for validating RDF graphs against shapes and constraints.
DESCRIPTION
SHACL is a W3C standard that defines shapes and constraints to validate RDF graphs. It enables declarative rules to ensure data conforms to expected structures and semantics. SHACL supports property shapes, node shapes, and custom constraints using SPARQL. It is widely used in knowledge graph quality assurance and interoperability. SHACL complements schemas and ontologies by enforcing data quality and governance policies.
ALTERNATIVE DEFINITIONS
W3C Recommendation
SHACL is a language for validating RDF graphs against a set of conditions.
Official specification defining validation of RDF graphs via conditions.
Wikipedia
SHACL (Shapes Constraint Language) is a World Wide Web Consortium (W3C) specification to describe and validate RDF graphs.
Highlights W3C status and focus on RDF validation.
TopQuadrant
SHACL defines a language and vocabulary for describing constraints on RDF graphs and provides mechanisms to validate data against those constraints.
Practical primer emphasizing constraints and validation mechanisms.
RELATED TERMS
RDF OWL SPARQL RDF Schema JSON-LD Data Quality Constraints Validation W3C
COMPETING TERMS
KNOWLEDGE AREAS
Semantic & Knowledge Modeling Data Quality Data Management Data Integration & Interoperability
TARGET AUDIENCE
Data Architect Data Modeler Data Steward Software Developer Data Management Consultant
EXTERNAL SOURCES
- Wikipedia - SHACL
- W3C - Official SHACL specification
- pySHACL - Python SHACL validator library
- TopQuadrant - Practical SHACL primer
TOP QUESTIONS
Why use SHACL for RDF validation?
SHACL provides a declarative, standardized way to enforce structural and semantic constraints on RDF data, improving quality and interoperability.
Category: Benefits
How do SHACL shapes relate to ontologies?
Ontologies define semantics; SHACL enforces data conformance. They complement each other for modeling and quality assurance.
Category: Concepts
What is a property shape in SHACL?
A property shape constrains values of a specific RDF property, such as datatype, cardinality, or allowed classes.
Category: Definition
Can SHACL run custom constraints?
Yes, SHACL supports SPARQL-based constraints to express complex validation rules beyond built-in features.
Category: HowTo
How does SHACL compare to ShEx?
ShEx emphasizes concise, schema-like expressions; SHACL integrates with SPARQL and broader W3C tooling. Choice depends on ecosystem and preference.
Category: Alternatives
Where is SHACL applied in practice?
Knowledge graphs, linked data portals, and governance frameworks use SHACL to validate ingested RDF data.
Category: Example
What are common SHACL pitfalls?
Overly complex constraints harm performance; unclear shape definitions impede reuse. Start with core constraints and optimize.
Category: Mistakes
How do I start with SHACL?
Define basic node and property shapes, validate sample data with pySHACL, iterate constraints from data profiling results.
Category: HowTo
Does SHACL integrate with data catalogs?
Yes, shapes can be referenced in metadata, enabling automated validation pipelines and governance checks.
Category: Management