We should take inspiration from python3 type hints and https://www.python.org/dev/peps/pep-0483/
It would make things more solid, and would also provide simple python3 compatibility.
The type checker would operate at runtime, with the types providing a "contract" regarding the message structure and content.
Later we might want to extend it to provide contracts for complex node behaviors...