Regional high performance manager Gafyn Cooper said, "It's realy tough on the boys. We were missing some key players but they faced up to the challenge and were fully deserving of their lead.
"Unfortunately, in the end, they were out on their feet and all credit to the Ospreys for keeping the ball alive and scoring three tries in 10 minutes."
James Connors (2) and Matthew Edwards scored tries for the Bues with Treorchy outside half Celyn Ashton adding 11 points from three penalties and a conversion.
However, the Ospreys, who went in to the game with a 15 point advantage over the third placed Dragons struck back with three converted tries.
Neil White and Jason Howells had already bagged a try for the Ospreys before Anthony Rogers, Ross Cridland and Jonathan Spratt raced over for the table toppers.
Aaron Bramwell added three conversions to make doubly sure of a crucial victory.
The game between the Dragons and Scarlets was postponed and will now be played next Wednesday.