add encoding to the models & libs