encoder: initial commit