Using railroady for diagrams.

See generated diagrams in /doc -- this is generated from [railroady](https://github.com/preston/railroady).