Eating well in India without getting ill - how careful do you really need to be?

We love Indian food and would hate to live on plain rice out of fear, but the warnings do make us cautious. What we can’t gauge is how you actually tell a safe place from a risky one - and whether having a guide who knows where to eat keeps you out of trouble. Did travelling with a group help you avoid the dodgy spots and still eat properly?