Rules_Rail_Road - visualizing rule-based models

Visualize models in BNGL format

Visualize BNGL BNGL overview Rules Railroad Concept Visualizing conventions Examples About

Syntax diagrams

Rule-based languages such as BNGL (BioNetGen Language) consists of symbolic sentences describing molecules, species, observables, reaction rules, and other parts of BNGL file. The structure of input file follows rules of context-free grammar that is a set of production rules that describe all possible strings in BNGL. Example of the grammar for BNGL in Extended Backus-Naur Form (EBNF) is shown below. It is a simplified form of the full BNGL grammar described in Harris et al., 2016. BioNetGen 2.2: advances in rule-based modeling, with some BNGL features like compartments and matching omitted.

Name = Letter, [{Letter|Digit|"_"}];
State = “~",Name;
Site = Name, [{"~",State}];
Molecule = Name, ["(",[Site,[{",",Site}]],")"];


This formal description is difficult to follow, so syntax diagrams (also called railroad diagrams) were introduced to visualize this grammar. The name declaration is

The site description is

The molecule description would be

Note the definition of the formal grammar - is a set of production rules that describe all possible strings in BNGL. Using this approach, we extended the railroad diagrams to visuallydescribe specific elements of rule-based description that can be combined into all possible strings in BNGL - essentially giving the full description of reaction networks generated by BioNetGen.