Renamed read_all to read_gen