new encode docs