added package, corrected automaton and updated demo