improving latex templates