Change genSpec into a pure function