Move code to lattice folder