initial flow in place + code formatting