add encode field