All Projects → afonsonf → tlaplus-graph-explorer

afonsonf / tlaplus-graph-explorer

Licence: MIT license
A static web application to explore and animate a TLA+ state graph.

Programming Languages

javascript
184084 projects - #8 most used programming language
HTML
75241 projects
CSS
56736 projects
Yacc
648 projects
shell
77523 projects

Labels

Projects that are alternatives of or similar to tlaplus-graph-explorer

tla-tools
TLA+ tools for Emacs
Stars: ✭ 27 (-85.64%)
Mutual labels:  tlaplus
CommunityModules
TLA+ snippets, operators, and modules contributed and curated by the TLA+ community
Stars: ✭ 167 (-11.17%)
Mutual labels:  tlaplus
CRDT-TLA
Specifying and Verifying CRDT Protocols using TLA+
Stars: ✭ 28 (-85.11%)
Mutual labels:  tlaplus
tree-sitter-tlaplus
A tree-sitter grammar for TLA+
Stars: ✭ 31 (-83.51%)
Mutual labels:  tlaplus
tezedge-specification
TLA+ specs and models for the TezEdge node's p2p overlay network, shell, and consensus
Stars: ✭ 19 (-89.89%)
Mutual labels:  tlaplus
tla2json
Convert TLA+ output (and values) into JSON
Stars: ✭ 19 (-89.89%)
Mutual labels:  tlaplus
tlacli
A script for running TLA+/TLC from the command line
Stars: ✭ 75 (-60.11%)
Mutual labels:  tlaplus
tlaplus specs
Different TLA+ specifications, mostly for learning purposes
Stars: ✭ 25 (-86.7%)
Mutual labels:  tlaplus
specifica
Basic TLA+ related Haskell libraries (parser, evaluator, pretty-printer)
Stars: ✭ 19 (-89.89%)
Mutual labels:  tlaplus

TLA+ Graph Explorer

This is a static web application to explore and animate a TLA+ state graph.

The application works by parsing a dot file generated by a TLA+ specification and then having visual representations to more easily understand and go through the reachable states.

The application is written to support big dot files and not load the whole file into memory. This is achieved by reading the file in chunks and storing only the location of the node in the file. The structure to save the nodes location, in my experiments, takes around 1/10th of the dot file size.

Examples

For more examples: examples.

Example 1 - Default Configuration

Spec: https://github.com/tlaplus/Examples/tree/master/specifications/MissionariesAndCannibals.

Example 2 - Personalized state

Spec: https://github.com/afonsonf/ceph-consensus-spec.

How to use

The application is in the folder src. To run it, open the index.html file in a browser (tested in Chrome and Firefox).

The default way to represent a state is showing the pretty printed version, as shown previously in example 1.

The representation of a state can be personalized by changing the function drawState in the file tla-state.js. An example of a personalized state representation is shown in the example 2 and the source code is in examples/ceph-consensus. There are other examples in the folder examples.

To help create a personalized representation of a state, the application comes with a parser that parses a tla+ state into JavaScript structures. The parser definition is in folder expr-parser and example usage of the parser (function parseVars) can be found in the examples.

Related tools

The ideas behind this tool were inspired by TLA+ Animation Module and Runway.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].