Generator for migration and module injection