I'd be generally on board with that. In the food stamps scenario, I'd agree with limiting use of them to foods within a certain range of nutritional content. For example, they can be used for fresh produce, meat, fish, milk, eggs, and bread...but not for premium items like Wagyu beef, custom-ordered cakes and breads, or the special this-week-only seafood. They could not be used for alcohol, tobacco, or - in my scenario - nutrient poor foods like donuts and potato chips. Basically, the stuff around the outside of the store is food stamp eligible, the ultra-processed stuff in the middle of the store is not.
Translating that to legal defense...the staples should be funded, which means a competent defense. The public won't pay for Johnny Cochrane or some $1,000/hour attorney, or for cutting edge technology. And they shouldn't have to - the state is already footing the bill to prove beyond a reasonable doubt that someone is guilty - they should not also be paying to prove that someone is not guilty. We're not supposed to have to prove innocence anyway, so if the state can't prove guilt with the resources they're using....the defense's resources should be moot.