validate MathML more strictly - #27
Conversation
|
MathML 3.0 RNG schema is more than 4 times bigger than our current RNG schema (MathML 2.0). I hope it works with our MathML 2.0 equations. There is also this unofficial MathML 2.0 RNG schema (btw. the one we use is also unoffical when looking at the comments) which is around 50% bigger than our current RNG. I've found it on relaxng.org |
|
Here is the script I used for downloading and validating all the books: Click me to show/hide the scriptAlso, I used the https://www.w3.org/Math/RelaxNG/mathml3-restricted/ files with a slight tweak (I removed references to anyElement to get jing to stop complaining) Just in the first few books there were thousands of validation errors. Here are a few (most are invalid attribute values):
All the validation errors (1600)There are 46 unique errors and this is how frequently each one occurs. We can write automated fixes for the most common ones which should help reduce the manual burden: |
Click me to show/hide the script
|
Currently the MathML grammar allows multiple children in superscripts and subscript elements. It should be stricter instead of relying on MathJax to clean up the math. Sifter link
refs openstax/rhaptos.cnxmlutils#195
TODO
mathml3-relaxng.zip