In the past when I’ve caught myself comparing my accomplishments to those of other people and feeling bad, there are a few things that helped. One was seeing it as “Okay, so if I feel bad that they’re doing thing X and I’m not doing thing X, my feeling bad means that maybe I’m not prioritizing something that matters to me and I should try pursuing this thing” and then other times if I realize that I don’t actually want to do the thing they’re doing, or prioritize it the way they have, then I remember the cool stuff I do, and the great stuff in my own life, like maybe they’re on an archeological dig or whatever, but that means a lot of discomfort that if I’m honest with myself I’d rather not deal with, and instead of doing that I like… spent my time learning to make a really kickass reuben sandwich or snuggling with D or perfecting an internet meme, or writing an article, and like prioritizing what I actually want to do and love doing is better than prioritizing stuff I don’t love because I feel like I “should” if I want to be as good as whoever.
IDK if that’s the kind of jealousy/inferiority you meant? If you mean romantic stuff, I did in the past, and basically realizing that “hey everyone has impulses, but my partner chooses to be with me, and prioritizes me, and if they aren’t prioritizing me, or are taking me for granted or treating me like a consolation prize, why am I with this person who I’m clearly not really compatible with” and remembering like “why would they be with me if they thought I was a shitty knockoff of whoever they really want, and if it’s because they can’t get with whoever they really want, why am I with someone who’s just using me as a surrogate for someone else?