FSMkit is a workbench for finite state machines that takes you from plain text to a verified diagram. Describe a machine in a short text file, check it for mistakes, and find paths through it. Then export it to Graphviz, SCXML, CSV, or Z notation in plain text and LaTeX.
Plain Python 3 with no dependencies.
python3 fsmkit.py examples/phone.txt
Then type verify, list all, or export dot at the prompt. Everything
else is in MANUAL.md.
fsmkit.pyis the interactive console. Start here.fsm.pyis the core engine: parsing, editing, verification, and path search. It also works on its own as a batch checker.fsm_ex.pyadds the export formats on top offsm.py.examples/holds ready-made machines to load and play with.MANUAL.mdis the user manual.
fsm.py and fsm_ex.py can be imported and used without the console if you
want to drive an FSM from your own script.
FSMkit was written by Ilya Levin.
Copyright 2012-2017 Literatecode
Re-released by the author under the MIT License in 2026, see LICENSE.