Claude cannot think; it can only imitate. You must treat it like a fancy autocomplete and not like a programmer.
The smartest way to use AI may not be letting it interact with your files, but asking it to write software that handles them ...