This is the code I used for my master's thesis. It is based on Automated Scoring of the Autobiographical Interview with Natural Language Processing by Dr. Ruben D.I. van Genugten and Dr. Daniel L. Schacter. This code has a couple additional edits to make it work with the data I had.
My thesis used a pre-trained machine-learning based natural language processing model to quantify episodic and non-episodic details from descriptions about positive and negative future events to examine whether they predict presence of suicidal ideation and its severity.