Skip to content

VladimirAlexiev/grammar-diagrams

Repository files navigation

Grammar Railroad Diagrams

Reading EBNF grammars is not easy. Seeing it on a diagram makes things easier. http://bottlecaps.de/rr/ui is an excellent tool: it can scrape EBNF grammars from W3C specs, generates either a single XHTML with embedded SVG, or a zip with many PNGs, cross-links the definitions and usages.

  • INCOMPLETE: ./ebnf2tdv.pl: convert ebnf to a list of node-node connections, for visualizing eg with d3

SPARQL 1.1 Query Language

I use this quite often while writing SPARQL. A bit hard to understand: use this for reference, but not for learning SPARQL.

SPARQL Railroad Diagram

Preview:

./SPARQL-diagram-preview.png

Chunked SPARQL Diagram

Here’s a chunked diagram, which however is partial: Discussion whether there’s a chunked generator. Preview:

http://1.bp.blogspot.com/_5Jqup-kC5TY/SVCGV19T6EI/AAAAAAAAALA/7UW3FznkRHM/s1600/SPARQL.png

SPARQL-star Railroad Diagram

Preview:

./SPARQL-star-diagram-preview.png

SHACLC

SHACL Compact grammar

Preview:

./SHACLC-diagram-preview.png

XSPARQL

XSPARQL is a melding of XQuery and SPARQL. Its syntax is pretty large, so the diagrams help. https://github.com/VladimirAlexiev/xsparql/blob/master/doc/:

Preview:

./XSPARQL-diagram-preview.png

About

Grammar Railroad Diagrams for SPARQL, XSPARQL

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages