[feature] add constant encoder, useful for versioning of codecs