Low: misc: split out autogen functions to utils file