Encode and OT updates