Abstract: We present a framework for developing “virtual patients” to augment training for Mental Health Professionals (MHPs) with a process that is more scalable and systematic than current practice which relies on human role-play for the training and evaluation of patient interaction. We show how to combine large language models, retrieval-augmented personification (a novel variant of retrieval-augmented generation), and custom code-based logic to create a psychology engine that simulates realistic patient responses by emulating several key psychological mechanisms: short- and long-term memory, varying levels of conscious awareness about topics (as well as modulation of such awareness), and dynamic mood states where attitudes toward topics of conversation evolve over the course of the dialogue. We also describe algorithms for creating realistic patients with coherent symptom profiles and backstories. Taken together, these tools produce a realistic training partner for an MHP, enabling both training-at-scale as well as automated evaluation of specific skill sets. We discuss how our psychology engine framework makes training qualified MHPs more efficient and scalable, facilitates the continuing education needed as potential new treatments such as psychedelics emerge from clinical trials, and how the framework could be generalized to applications beyond MHP training. We also introduce an evaluation framework, in which generated transcripts demonstrate the enhanced capabilities of virtual patients as compared to approaches using system prompts alone. These comparisons comprise consistency of personas, coherence of memory across conversations, conversational realism, and compute efficiency.
Bio: Patrick Staples is a Principal Data Scientist and Engineer at Compass Pathways, where he leads efforts to develop AI-driven innovations in mental health. He also serves as an Instructor at Stanford Continuing Studies, teaching a course on statistical inference, machine learning, and artificial intelligence. Prior to these roles, he was Vice President of Data Science at Alto Neuroscience, building and managing data science teams and advancing precision therapeutics for mental health. He has also held senior data science positions at Migo, where he created and refined creditworthiness models for emerging markets, and at Mindstrong, where he developed statistical and machine learning techniques for smartphone-based mental health monitoring. Dr. Staples completed his doctoral work in Biostatistics at Harvard University, focusing on digital phenotyping and causal inference. His research interests lie at the intersection of AI, causal modeling, and mental health, with a particular emphasis on developing scalable methods to personalize treatment in healthcare.

Patrick Staples
Title
Principal Data Scientist and Engineer | COMPASS Pathways LLC


