The answers are already implied in your questions. There is the “you“ and there are “the negative thoughts”. Negative and positive thoughts or voices have been “installed” in your conscious and unconscious mind from early childhood on. These voices change based on social situations. Some of them you don’t even hear, but unconsciously project onto others. The problem is if the voices become your persona; if they define who you are and how you react.
However, getting rid of these voices is impossible and would be unwise, as they often provide you with useful feedback. In addition, repression, splitting off, or dissociation is never a good idea. The solution is to first differentiate all the different voices in your head by getting into a respectful and honorable dialog with them to befriend them. Through this process, you disidentify from them and strengthen your witness consciousness or authentic self. You then no longer perceive the voices as negative, as they no longer have power over you. Instead, they support you in your learning, healing, growing, and awakening towards loving more deeply and creating more truth, goodness, beauty, and functioning in your life.