Exercise. Coherence for retractions [01IP]

Let f:A\to B be a function equipped with a retraction s_f:B\to A. Show that the type \mathsf {retractionOf}(f) \equiv {\mathop {\mathchoice {\textstyle \sum }{\textstyle \sum }{\scriptstyle \sum }{\scriptscriptstyle \sum } }_{(r:B\to A)}} r\circ f \sim 1_B of retractions of f is a proposition.