Schematron
About Schematron
Schematron is an ISO-standardized validation language for structured data (ISO/IEC 19757:3). It lets you evaluate assertion tests for selected parts of a document. It was first designed as an international standard in 2006 and has been updated continuously. The standardization process of the 4th edition is in its final stages and is expected to finish in September this year.
Schematron's use of XPath both as the language to select the portion of a document and as the language of the assertion tests gives Schematron the flexibility to validate arbitrary relationships and dependencies of information items in a document. What also sets Schematron apart from other languages is that it encourages the use of natural language descriptions targeted to human readers. This way, validation can be more than just a binary distinction (document valid/invalid) but also support authors of in-progress documents with quick feedback on erroneous or unwanted document structure and content. The flexibility and (relative) simplicity of Schematron make it an invaluable tool for XML-based text-encoding projects.
SchXslt/SchXslt2
SchXslt is a modern implementation of ISO Schematron, powered by the mature XSL Transformations language. It goes beyond the features of the ISO standard and supports, among other things, streaming validation. It is MIT-licensed and used across a wide range of industries, such as publishing and the digital encoding of humanities artifacts (TEI/MEI).
Following flavours or version of SchXslt are available.
SchXslt2 Schematron to XSLT 3.0 transpiler
Status | Under active development |
---|---|
Homepage | https://codeberg.org/schxslt/schxslt2 |
Query language(s) | XSLT 3 |
License | MIT |
SchXslt
Status | Maintenance, bug fixes only |
---|---|
Homepage | https://codeberg.org/schxslt/schxslt |
Query language(s) | XSLT 1, XSLT 2, XSLT 3 |
License | MIT |
Other Schematron implementations
pyschematron
Homepage | https://github.com/robbert-harms/pyschematron |
---|---|
Implementation language(s) | Python |
Query language(s) | ? |
License | MIT |
Author | Robbert Harms |
Latest version | 1.1.8 |
ph-schematron
A pure Java implementation for the XPath query language binding and wrappers for both, the Skeleton and SchXslt transpilers.
Homepage | https://github.com/phax/ph-schematron |
---|---|
Implementation language(s) | Java |
Query language(s) | XSLT 1.0, XSLT 2.0, XSLT 3.0, XPath 3.0 |
License | Apache 2.0 |
Author | Philip Helger |
Latest version | 9.0.0 |
Skeleton
The ISO Schematron to XSLT transpiler aka "The Skeleton API" was the first and for a long time only publicly available ISO Schematron implementation around. While the Skeleton itself has been unmaintained for years it was the base for many integrated solutions such as in <oXygen/>, XML Mind and other XML editors.
Homepage | https://github.com/schematron/schematron |
---|---|
Implementation language(s) | XSLT 1.0, XSLT 2.0 |
Query language(s) | XSLT 1.0, XSLT 2.0 |
License | MIT |
Author | Rick Jelliffe and others |
Latest version | - |
XQS
Homepage | https://github.com/andrewsales/xqs |
---|---|
Implementation language(s) | XQuery 3 |
Query language(s) | XQuery 3 |
License | Apache 2.0 |
Author | Andrew Sales |
Latest version | 1.0.1 |