Tweaked occurrence syntax
Add support for diagrams and preferences for formatting