Bauhaus launched to the far side of the road after a quick leadout from world champion Julian Alaphilippe (Deceuninck-Quickstep), edging out Ballerini in the finish.
"It was a super-fast final" said Bauhaus. "The team did really really well today. I wanted this result really bad. I went for it, and I was happy I could pass the guys at the front.
"I knew I needed to be in front with 600 metres to go, then I was strong enough to finish it off. It’s always good as a sprinter to win races. But I’m also happy for the team, it takes some pressure off us now we have that win. It gives us confidence for the next races."
Nacer Bouhanni (Arkea-Samsic) finished third on the day, remonstrating with Ballerini after the finish, but it appeared that Ballerini barely deviated from his sprinting line, if at all.
Sosa claimed the overall race victory after his superb win on Mont Ventoux on Stage 3, although there was a shift on the podium, with Alaphilippe moving up from third to second overall after claiming bonus seconds at the intermediate sprint to leapfrog Egan Bernal (INEOS Greandiers).