Swift improvement sees Espargaró on pole