Transformer-based Model for ASR N-Best Rescoring and Rewriting