initial generator implementation