Basic automaton constructor