Scripts

added codegen and fixed a few things in utils