I vaguely remember Krayt developing the ability to self-resurrect after dying the first time around. More precisely, it was Force based healing that was powerful enough to bring him back to life and also purge his body of weird alien junk that had been killing him. That said, while it's something Palpatine would want to learn, it's also not quite quick enough to stop Krayt from getting killed and then destroyed beyond repair by the Senate's lightning.