Automated Extraction and Coding of Qualitative Data Within Physician-Patient Communication in Cancer Care Using Natural Language Processing: Development and Validation Study.
Jay Sureshbhai Patel, Laura A Siminoff, Zasim Azhar Siddiqui, Maria D Thomson, Ritwik Katiyar, Oqba Memar
Center for Artificial Intelligence, Data Science, and Informatics, Department of Oral Health Sciences, Kornberg School of Dentistry, Temple University, 400-C, 3223 N Broad St, Philadelphia, PA, 19140, United States, 1 (215) 204-7000. · Department of Social and Behavioral Sciences, College of Public Health, Temple University, Philadelphia, PA, United States.
Key points
From the paper's conclusion- A fine-tuned transformer model (RoBERTa) was better suited to capturing the complexity of patient encounter transcripts than traditional ML, rule-based approaches, or an OoB LLM. The findings demonstrate the feasibility of using a manually validated, web-based NLP application trained on gold-standard annotations to transform large-scale physician-patient communication transcripts into structured qualitative data. Hybrid systems combining rule-based precision with the contextual capabilities of transformer models may further improve the identification of longer conversational sequences, including emotional expressions, question-answer exchanges, and multitopic utterances.
Abstract
BACKGROUND: Large-scale analysis of qualitative clinical communication data typically requires substantial manual coding. Natural language processing (NLP) may reduce this burden by converting unstructured physician-patient communication transcripts into structured qualitative data. OBJECTIVE: This study aimed to develop, test, and validate an NLP application for identifying quality-of-life factors in cancer care communication. We also compared traditional machine learning (ML), rule-based, transformer-based, and out-of-the-box (OoB) large language model (LLM) approaches. METHODS: We analyzed 434 standardized patient encounter transcripts of physician-patient interactions collected from a prior study. A rule-based SpaCy model, traditional ML models, bidirectional encoder representations from transformer (BERT), Robustly Optimized BERT Pretraining Approach (RoBERTa), and the OoB Qwen3 LLM were evaluated using F1-scores. The highest-performing model was incorporated into a web-based NLP application and further assessed through manual validation. RESULTS: Transformer-based models demonstrated the strongest performance. RoBERTa achieved the highest initial F1-score of 83%, outperforming BERT at 80%, the OoB Qwen3 LLM model at 39%, and the rule-based SpaCy baseline at 34%. Manual validation of the RoBERTa model produced an F1-score of 91%. The comparatively low performance of Qwen3 indicated that OoB LLM use alone may not produce reliable results for qualitative, domain-specific clinical communication tasks. CONCLUSIONS: A fine-tuned transformer model (RoBERTa) was better suited to capturing the complexity of patient encounter transcripts than traditional ML, rule-based approaches, or an OoB LLM. The findings demonstrate the feasibility of using a manually validated, web-based NLP application trained on gold-standard annotations to transform large-scale physician-patient communication transcripts into structured qualitative data. Hybrid systems combining rule-based precision with the contextual capabilities of transformer models may further improve the identification of longer conversational sequences, including emotional expressions, question-answer exchanges, and multitopic utterances.
Read the paper
Discussion
Science Skim's AI key points, plus readers' public thoughts
Readers' thoughts
No reader thoughts yet.
Related papers
- EPPC-CARE: Staged Hierarchical Annotation of Communication Behaviors in Secure Patient-Provider MessagesarXiv · 2026
- A locally deployed large language model for pathology-informed and nurse-reviewed communication support in bladder cancer immunotherapy.Frontiers in medicine · 2026
- When the Judge Is an LLM: An Oncologist and a Language Model Evaluator Disagree on Responses to Inpatient Oncology Consultations-A Retrospective Blinded Study.Current oncology (Toronto, Ont.) · 2026
- Validating LLM judges for automated oversight of patient communicationmedRxiv · 2026
- An autonomous agentic workflow for clinical detection of cognitive concerns using large language modelsnpj Digital Medicine · 2026
- AI large language models versus physicians in psycho-oncology cancer communication: A blinded multicenter comparisonPalliative and Supportive Care · 2026