Added stricter checks. More direct generator conversion