You want to keep your cheats to none. Be prepared, make sure you’re eating what you need to be satiated (“full”), and make sure you’re satisfied with what you’re eating. If you have to force yourself to eat something, it will never work out in the end. This is just a guideline on how you can eat on a ketogenic diet, so you’re very welcome to change up what kind of foods you eat!
Achieving optimal ketosis hinges on finding the right balance of macronutrients (or “macros” in keto-speak); these are the elements in your diet that account for the majority of your calories, a.k.a. energy—namely, fat, protein, and carbohydrates. By the way, it’s often “net grams” of carbohydrates that are counted toward your daily intake; “net” deducts the amount of fiber in a food from its carbohydrate total.
The first modern study of fasting as a treatment for epilepsy was in France in 1911. Twenty epilepsy patients of all ages were "detoxified" by consuming a low-calorie vegetarian diet, combined with periods of fasting and purging. Two benefited enormously, but most failed to maintain compliance with the imposed restrictions. The diet improved the patients' mental capabilities, in contrast to their medication, potassium bromide, which dulled the mind.