One way to change our irrational beliefs is, in fact, to dispute them. That's to ask challenging questions that expose these beliefs for what they are: typically illogical, not based on reality or the evidence, and ultimately leading to more intense negative emotions that are necessary to get through the moment. Possibly they lead to maladaptive behaviors, because we know that extreme negative emotions can set the stage for people engaging in behaviors that are problematic. If you become really, really angry, you might become more aggressive, even if the anger is directed at yourself. If you become really, really angry, you may be tempted to drink or do something to detach yourself from that emotion.
Let me give you some examples of some questions you can ask in order to challenge or dispute the irrational beliefs. Let's look at some of these irrational beliefs. "I have to always act respectfully." While that's a good goal, believing that you have to under any and all circumstances is probably not realistic. A question you could ask, a type of dispute would be, "Where's the evidence that you have to always do that?" For most of us, we are pretty easily able to acknowledge that there isn't evidence for that, because there have been plenty of times, more than we would like, that we have, in fact, violated that rule. So there isn't evidence that we have to always, even if it is our goal. A more rational belief would be, "I prefer and I like to, and it would be better if I was respectful all the time, but if I'm not, it doesn't mean I'm a horrible person. It means I'm a person who can work to improve that particular behavior."
The second is, often when we're angry at ourselves, we're putting ourselves down. We're engaging in something call a global evaluation of worth. I bring down my value, or my worth, as a function of a specific behavior. After being disrespectful I may say something like, "I'm a real jerk because I spoke to her in that way." It may have been a very bad idea. It might have gone against my goals, my values, and my morals to have spoken to her in that way, which would be a good reason to actively do something to ensure that I don't do it again. But the question you would ask to dispute it would be, "How does it logically follow that you become what you do? That if you make a mistake you become a mistake?" That doesn't seem to logically make a whole lot of sense. If that were the case, then if I made a mistake at 1:00, I would become a mistake. Then at 2:00, what if I did something right and I succeeded, do I become a success? My identity or my worth and value would be in a constant state of transition. That doesn't make a whole lot of sense.
The kinds of beliefs that need to be challenged are ones that are typically very dogmatic and rigid. I'll give a few examples. Demanding that things should and have to be a certain way all of the time. Low frustration tolerance, "I can't stand that I did that." Awfulizing or catastrophizing, "I did an awful or horrible thing," even when it was just something disrespectful. Finally, global evaluations of worth, where I become what I do as opposed to rating the specific behavior as bad, and then working to change that behavior.