Well... in early TOS, there's few doubts Kirk would have had a word with the leaders of this world and explained... what... the human.... rights... are.
However, given the context you described, I don't think the players would hesitate much (unless they really don't care about the Prime Directive). If this planet is on our technology level, they would beam the surviving scientists out of there and warp away (maybe with a bit of masquerade to have the locals think they died).
However, there may be many ways to twist the plot so that things were not that easy. For instance, the civilisation could be much more advanced, like a few years before inventing warp, and it's entrance in the UFP could be vital (presence dilithium mines or strategical position, etc).
"The main difference between Trekkies and Manchester United fans is that Trekkies never trashed a train carriage. So why are the Trekkies the social outcasts?"
Terry Pratchett