But I had to stop the keto diet because it makes me stupid when I'm on it. I'm not talking the "keto fog" that you experience for a few days when your body is adjusting; operating in extended ketosis for me correlated with a marked decline in mental capacity. I went from being a rockstar knowledge worker to someone who couldn't do simple arithmetic. And my mental faculties would return within an hour if I ate a bagel.
Ketones (what your body burns for energy when there are no sugars available) don't penetrate to the brain, so your body produces sugars from protein through gluconeogenesis, but it wasn't really enough to keep me functioning at 100%. Also, you don't want to be frequently transitioning in/out of ketosis; it gives you horrible headaches.