Proceedings

X-FEMR: A Token-level Explainable Approach for Electronic Health Records Foundation Models using Transformer-based Models

Download BibTeX Cite

Proceedings of the Thirty-Fifth International Joint Conference on Artificial Intelligence. AI and Health. Pages 6734-6742.

https://doi.org/10.24963/ijcai.2026/749

Abstract

Foundation Models for Electronic Health Records (FEMRs) are pretrained on large-scale structured patient data, enabling them to convert longitudinal patient trajectories into generalizable representations for diverse clinical prediction tasks. Despite their effectiveness, FEMRs remain black-box models, raising concerns about bias, interpretability, and clinical trust. To address this, we propose the first token-level explainability approach for FEMRs. We train a Transformer-based surrogate model on input-output pairs from the FEMR across two prediction tasks, approximating its behavior while preserving temporal dynamics. We identify the most influential tokens, providing insights into how FEMRs leverage different aspects of patient history for predictions. To evaluate clinical relevance, we introduce a novel clinical alignment metric that quantifies the correspondence between the surrogate model’s key tokens and clinically validated features. Our results demonstrate that the surrogate closely approximates FEMR predictions and that token-level explanations align well with clinical knowledge, offering a practical framework for interpretable and trustworthy clinical AI.

  1. [Abbas et al., 2025] Qaiser Abbas, Woonyoung Jeong, and Seung Won Lee. Explainable ai in clinical decision sup- port systems: A meta-analysis of methods, applications, and usability challenges. Healthcare, 13(17), 2025.
  2. [Ali et al., 2023] Sajid Ali, Tamer Abuhmed, Shaker El- Sappagh, Khan Muhammad, Jose M. Alonso-Moral, Roberto Confalonieri, Riccardo Guidotti, Javier Del Ser, Natalia Díaz-Rodríguez, and Francisco Herrera. Explain- able artificial intelligence (xai): What we know and what is left to attain trustworthy artificial intelligence. Informa- tion Fusion, 99:101805, 2023.
  3. [Almeida et al., 2026] Tiago Almeida, Plinio Moreno, and Catarina Barata. Prediction of 30-day hospital readmis- sion with clinical notes and ehr information. In Nuno Gonc ¸alves, Hélder P. Oliveira, and Joan Andreu Sánchez, editors, Pattern Recognition and Image Analysis, pages 220-232, Cham, 2026. Springer Nature Switzerland.
  4. [Bienefeld et al., 2023] Nadine Bienefeld, Jens Michael Boss, Rahel Lüthy, Dominique Brodbeck, Jan Azzati, Mirco Blaser, Jan Willms, and Emanuela Keller. Solv- ing the explainable AI conundrum by bridging clini- cians' needs and developers' goals. npj Digital Medicine, 6(1):94, May 2023. [BMJ, 2012] BMJ. A national early warning score for acutely ill patients. BMJ, 345, 2012.
  5. [Cavalcante et al., 2025] Guilherme J. Cavalcante, José Gabriel A. Moreira, Gabriel A. B. do Nascimento, Vincent Dong, Alex Nguyen, Thaís G. do Rêgo, Yuri Malheiros, Telmo M. Silva Filho, Carla R. Zeballos Torrez, James C. Gee, Anne Marie McCarthy, Andrew D. A. Maidment, and Bruno Barufaldi. Toward explainable ai approaches for breast imaging: adapting foundation models to diverse populations, 2025.
  6. [Deschepper et al., 2025] Mieke Deschepper, Chloë De Smedt, and Kirsten Colpaert. A literature-based approach to predict continuous hospital length of stay in adult acute care patients using admission variables: A single univer- sity center experience. International Journal of Medical Informatics, 193:105678, 2025.
  7. [Gokhale et al., 2023] Swapna Gokhale, David Taylor, Jaskirath Gill, Yanan Hu, Nikolajs Zeps, Vincent Le- quertier, Luis Prado, Helena Teede, and Joanne Enticott. Hospital length of stay prediction tools for all hospital admissions and general medicine populations: system- atic review and meta-analysis. Frontiers in Medicine, 10:1192969, August 2023.
  8. [Guo et al., 2024] Lin Lawrence Guo, Jason Fries, Ethan Steinberg, Scott Lanyon Fleming, Keith Morse, Catherine Aftandilian, Jose Posada, Nigam Shah, and Lillian Sung. A multi-center study on the adaptability of a shared foun- dation model for electronic health records. NPJ Digital Medicine, 7(1):171, 2024.
  9. [Guo et al., 2025] Fei Guo, Renchu Guan, Yaohang Li, Qi Liu, Xiaowo Wang, Can Yang, and Jianxin Wang. Foundation models in bioinformatics. Natl. Sci. Rev., 12(4):nwaf028, April 2025.
  10. [Hripcsak George et al., 2015] Hripcsak George, Duke Jon D., Shah Nigam H., Reich Christian G., Huser Vojtech, Schuemie Martijn J., Suchard Marc A., Park Rae Woong, Wong Ian Chi Kei, Rijnbeek Peter R., Van Der Lei Jo- han, Pratt Nicole, Norén G. Niklas, Li Yu-Chuan, Stang Paul E., Madigan David, and Ryan Patrick B. Obser- vational Health Data Sciences and Informatics (OHDSI): Opportunities for Observational Researchers. In Studies in Health Technology and Informatics. IOS Press, 2015.
  11. [Kaplan et al., 2020] Jared Kaplan, Sam McCandlish, Tom Henighan, Tom B. Brown, Benjamin Chess, Rewon Child, Scott Gray, Alec Radford, Jeffrey Wu, and Dario Amodei. Scaling Laws for Neural Language Models, January 2020. arXiv:2001.08361 [cs].
  12. [Lee et al., 2025] Hyeokjong Lee, Jaewon Kim, Sangmin Kwak, Azka Rehman, Sang Min Park, and Jooy- oung Chang. Optimizing retinal images based carotid atherosclerosis prediction with explainable foundation models. npj Digital Medicine, 8(1):582, September 2025.
  13. [Liu et al., 2019] Jianfang Liu, Elaine Larson, Amanda Hes- sels, Bevin Cohen, Philip Zachariah, David Caplan, and Jingjing Shang. Comparison of Measures to Predict Mor- tality and Length of Stay in Hospitalized Patients. Nursing Research, 68(3):200-209, May 2019.
  14. [Lundberg and Lee, 2017] Scott M Lundberg and Su-In Lee. A unified approach to interpreting model predictions. In I. Guyon, U. Von Luxburg, S. Bengio, H. Wallach, R. Fer- gus, S. Vishwanathan, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 30. Cur- ran Associates, Inc., 2017.
  15. [McDonald et al., 2003] Clement J McDonald, Stanley M Huff, Jeffrey G Suico, Gilbert Hill, Dennis Leavelle, Ray- mond Aller, Arden Forrey, Kathy Mercer, Georges De- Moor, John Hook, Warren Williams, James Case, Pat Mal- oney, and for the Laboratory LOINC Developers. LOINC, a Universal Standard for Identifying Laboratory Observa- tions: A 5-Year Update. Clinical Chemistry, 49(4):624- 633, April 2003.
  16. [Nelson et al., 2011] Stuart J Nelson, Kelly Zeng, John Kil- bourne, Tammy Powell, and Robin Moore. Normalized names for clinical drugs: Rxnorm at 6 years. Journal of the American Medical Informatics Association, 18(4):441- 448, 04 2011.
  17. [Rasmy et al., 2021] Laila Rasmy, Yang Xiang, Ziqian Xie, Cui Tao, and Degui Zhi. Med-BERT: pretrained contex- tualized embeddings on large-scale structured electronic health records for disease prediction. npj Digital Medicine, 4(1):86, May 2021.
  18. [Renc et al., 2024] Pawel Renc, Yugang Jia, Anthony E Samir, Jaroslaw Was, Quanzheng Li, David W Bates, and Arkadiusz Sitek. Zero shot health trajectory prediction us- ing transformer. NPJ Digit. Med., 7(1):256, September 2024.
  19. [Renc et al., 2025] Pawel Renc, Michal K Grzeszczyk, Nas- sim Oufattole, Deirdre Goode, Yugang Jia, Szymon Bie- ganski, Matthew B A McDermott, Jaroslaw Was, An- thony E Samir, Jonathan W Cunningham, David W Bates, and Arkadiusz Sitek. Foundation model of electronic med- ical records for adaptive risk estimation. Gigascience, 14(giaf107), January 2025.
  20. [Ribeiro et al., 2016] Marco Tulio Ribeiro, Sameer Singh, and Carlos Guestrin. "Why Should I Trust You?": Ex- plaining the Predictions of Any Classifier. In Proceed- ings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, pages 1135- 1144, San Francisco California USA, August 2016. ACM.
  21. [Ruan et al., 2025] Yucheng Ruan, Daniel J Tan, See-Kiong Ng, Ling Huang, and Mengling Feng. Towards accurate and reliable icu outcome prediction: a multimodal learn- ing framework based on belief function theory using struc- tured ehrs and free-text notes. Journal of Healthcare In- formatics Research, pages 1-42, 2025.
  22. [S Band et al., 2023] Shahab S Band, Atefeh Yarahmadi, Chung-Chian Hsu, Meghdad Biyari, Mehdi Sookhak, Rasoul Ameri, Iman Dehzangi, Anthony Theodore Chronopoulos, and Huey-Wen Liang. Application of ex- plainable artificial intelligence in medical health: A sys- tematic review of interpretability methods. Informatics in Medicine Unlocked, 40:101286, 2023.
  23. [Saraswat et al., 2022] Deepti Saraswat, Pronaya Bhat- tacharya, Ashwin Verma, Vivek Kumar Prasad, Sudeep Tanwar, Gulshan Sharma, Pitshou N Bokoro, and Ravi Sharma. Explainable AI for healthcare 5.0: Opportunities and challenges. IEEE Access, 10:84486-84517, 2022.
  24. [Sarker, 2021] Iqbal H Sarker. Machine learning: Algo- rithms, real-world applications and research directions. SN computer science, 2(3):160, 2021.
  25. [Simonyan et al., 2014] Karen Simonyan, Andrea Vedaldi, and Andrew Zisserman. Deep Inside Convolutional Networks: Visualising Image Classification Models and Saliency Maps, April 2014. arXiv:1312.6034 [cs.
  26. [Smith et al., 2019] Gary B Smith, Oliver C Redfern, Marco Af Pimentel, Stephen Gerry, Gary S Collins, James Malycha, David Prytherch, Paul E Schmidt, and Pe- ter J Watkinson. The National Early Warning Score 2 (NEWS2). Clinical Medicine, 19(3):260, May 2019.
  27. [Street et al., 2025] Andrew Street, Laia Maynou, Joanna M Blodgett, and Simon Conroy. Association between Hospi- tal Frailty Risk Score and length of hospital stay, hospital mortality, and hospital costs for all adults in England: a nationally representative, retrospective, observational co- hort study. The Lancet Healthy Longevity, 6(8):100740, August 2025.
  28. [Sundararajan et al., 2017] Mukund Sundararajan, Ankur Taly, and Qiqi Yan. Axiomatic attribution for deep net- works. In Proceedings of the 34th International Confer- ence on Machine Learning -Volume 70, ICML'17, page 3319-3328. JMLR.org, 2017.
  29. [Timilsina et al., 2025] Mohan Timilsina, Samuele Buosi, Muhammad Asif Razzaq, Rafiqul Haque, Conor Judge, and Edward Curry. Harmonizing foundation models in healthcare: A comprehensive survey of their roles, rela- tionships, and impact in artificial intelligence's advancing terrain. Computers in Biology and Medicine, 189:109925, 2025.
  30. [Tonekaboni et al., 2019] Sana Tonekaboni, Shalmali Joshi, Melissa D. McCradden, and Anna Goldenberg. What clin- icians want: Contextualizing explainable machine learning for clinical end use. In Finale Doshi-Velez, Jim Fackler, Ken Jung, David Kale, Rajesh Ranganath, Byron Wallace, and Jenna Wiens, editors, Proceedings of the 4th Machine Learning for Healthcare Conference, volume 106 of Pro- ceedings of Machine Learning Research, pages 359-380. PMLR, 09-10 Aug 2019.
  31. [Verma, 2024] Amol A. Verma. Toward the Rigorous Eval- uation of Early Warning Scores. JAMA Network Open, 7(10):e2438966, October 2024.
  32. [Wang et al., 2025] Song Wang, Yishu Wei, Haotian Ma, Max Lovitt, Kelly Deng, Yuan Meng, Zihan Xu, Jingze Zhang, Yunyu Xiao, Ying Ding, Xuhai Xu, Joydeep Ghosh, and Yifan Peng. A multi-stage large language model framework for extracting suicide-related social de- terminants of health. Commun. Med. (Lond.), 5(1):404, September 2025.
  33. [Wellner et al., 2017] Ben Wellner, Joan Grand, Elizabeth Canzone, Matt Coarr, Patrick W Brady, Jeffrey Simmons, Eric Kirkendall, Nathan Dean, Monica Kleinman, Peter Sylvester, et al. Predicting unplanned transfers to the in- tensive care unit: a machine learning approach leverag- ing diverse clinical elements. JMIR medical informatics, 5(4):e8680, 2017.
  34. [Wornow et al., 2023a] Michael Wornow, Rahul Thapa, Ethan Steinberg, Jason Fries, and Nigam Shah. Ehrshot: An ehr benchmark for few-shot evaluation of foundation models. 2023.
  35. [Wornow et al., 2023b] Michael Wornow, Yizhe Xu, Rahul Thapa, Birju Patel, Ethan Steinberg, Scott Fleming, Michael A Pfeffer, Jason Fries, and Nigam H Shah. The shaky foundations of large language models and foun- dation models for electronic health records. npj digital medicine, 6(1):135, 2023.
  36. [Yin et al., 2025] Pengfei Yin, Abel Armas Cervantes, and Daniel Capurro. Measuring and visualizing healthcare process variability. Journal of Biomedical Informatics, 170:104918, 2025.
  37. [Young et al., 2003] Michael P. Young, Valerie J. Gooder, Karen McBride, Brent James, and Elliott S. Fisher. Inpa- tient transfers to the intensive care unit: Delays are asso- ciated with increased mortality and morbidity. Journal of General Internal Medicine, 18(2):77-83, February 2003.

References were extracted automatically from the PDF and may contain errors.

Welcome Future Conferences AI Journal Division IJCAI Proceedings About IJCAI IJCAI Awards