Hello Solid5nake,
Thank you for using Apple Support Communities!
Sounds like we have some unexpected behaviour from this iPhone 5s here becoming unresponsive, and restarting on its own. After having reset all settings, next I would reset the phone:
iOS: Turning off and on (restarting) and resetting
http://support.apple.com/kb/ht1430
If your device stops responding, you can reset it by pressing and holding both the Sleep/Wake and Home buttons for at least ten seconds, until the Apple logo appears.
If the issue persists, I would try and take note if it happens when you are in a certain app, and if so, would suggest this article to help you troubleshoot that app.
iOS: Troubleshooting apps purchased from the App Store
http://support.apple.com/kb/TS1702
If the issue occurrs no matter what you do, then it does look like the next step would be to backup and restore the device with iTunes.
iOS: How to back up and restore your content
http://support.apple.com/kb/HT1766
All the best,
Sterling