There are three garments and tools through which the soul expresses itself: thought, word, and action. Regarding the latter two, word and action, there is the situation in which the soul does not invest itself in them; that is, they are not used, and the person remains silent and does nothing with their capacity for action.
However, even when thought is not being used to serve the intellect (thinking of new ideas or delving deeper into what is already known) or to serve the emotions (reflecting on the good or bad of something or someone), it nevertheless continues to think and imagine. Thought is never interrupted. It may shift from one subject to another, but it never ceases to be active.
When a person uses their thinking ability in a positive way, they reap positive results from their thoughts. However, when their thoughts lack something positive to contemplate, they automatically begin to dwell on strange and evil matters. It is explained in our holy books that the reason for strange or evil thoughts is "emptiness of mind": when a person lacks holy content, such as memorized Torah verses, they have no means to combat evil thoughts.
That is why it is very important to memorize passages from the written and oral Toah, so that we have ready these "weapons" with which to fight against negative thoughts.
Excellent! Food for thought and reflection.