Completed the initial generation code.