adapting letter generation to new model