This is an important point. I hope they'll address this soon. I've just started tinkering with Code and took it for granted that I wouldn't lose the "conversation" when the terminal restarted.
Maybe just ask it to save off the contents of the session as it goes?