Thoughts of self-harm: exploring how these are generated

I have resources to address this with therapy, but would like to explore how I am generating thoughts of self-harm in the model. I consider these thoughts a result as follows:

C: Thesis advisor tells me his opinion on what I should do more of to be successful in academia.
T: I was okay with my somewhat disappointing academic career before this conversation.
F: Confused
A: ….most of my actions seem more like thoughts (think about what I could/should do differently)
R: I generate feelings of self-harm.

For the action line, it seems my thoughts typically go on this trajectory when this happens:
compare myself to someone else–>feel there is something wrong with me–>blame myself for not measuring up–>OR blame society, other people, people close to me, advisors, my research, my past choices, my personality, etc. for it instead of myself.