Add missing files, fix syntax and formatting