make engine more configurable, generator fixes