Dr. Eric Berg has a great Youtube channel where he explains his take on how a ketogenic diet and also intermittent fasting (and the two together) can help to reduce insulin resistance (and type 2 diabetes) and improve metabolism. I personally find his explanations very helpful: