Add new version of directory-encoder