In an alternate timeline, somepony else got to the Mirror Portal before Sunset and stole both it and Celestia away. Acting Princess Cadance is willing to give Sunset a second chance, and hopes to have Sunset's help with a matter of national security.
Lemon Zest is pretty lucky for a pony who just got fried to death. She miraculously comes back as a ghost and stumbles on a haunted school where she can learn the basics of the afterlife. The fee of tuition? Recruiting more ghosts to school.