rewrote generators