Suppr超能文献

使用微调临床语言模型识别临床文本中的药物不良事件:机器学习研究

Identifying Adverse Drug Events in Clinical Text Using Fine-Tuned Clinical Language Models: Machine Learning Study.

作者信息

Kopacheva Elizaveta, Henriksson Aron, Dalianis Hercules, Hammar Tora, Lincke Alisa

机构信息

Department of Computer Science and Media Technology, Faculty of Technology, Linnaeus University, Universitetsplatsen 1, Växjö, 352 52, Sweden, 46 737033730.

Department of Computer and Systems Sceince, Stockholm University, Kista, Sweden.

出版信息

JMIR Form Res. 2025 Sep 11;9:e71949. doi: 10.2196/71949.

Abstract

BACKGROUND

Medications are essential for health care but can cause adverse drug events (ADEs), which are harmful and sometimes fatal. Detecting ADEs is a challenging task because they are often not documented in the structured data of electronic health records (EHRs). There is a need for automatically extracting ADE-related information from clinical notes, as manual review is labor-intensive and time-consuming.

OBJECTIVE

This study aims to fine-tune the pretrained clinical language model, Swedish Deidentified Clinical Bidirectional Encoder Representations from Transformers (SweDeClin-BERT), for medical named entity recognition (NER) and relation extraction (RE) tasks, and to implement an integrated NER-RE approach to more effectively identify ADEs in clinical notes from clinical units in Sweden. The performance of this approach is compared with our previous machine learning method, which used conditional random fields (CRFs) and random forest (RF).

METHODS

A subset of clinical notes from the Stockholm EPR (Electronic Patient Record) Corpus, dated 2009-2010, containing suspected ADEs based on International Classification of Diseases, 10th Revision (ICD-10) codes in the A.1 and A.2 categories was randomly sampled. These notes were annotated by a physician with ADE-related entities and relations following the ADE annotation guidelines. We fine-tuned the SweDeClin-BERT model for the NER and RE tasks and implemented an integrated NER-RE pipeline to extract entities and relationships from clinical notes. The models were evaluated using 395 clinical notes from clinical units in Sweden. The NER-RE pipeline was then applied to classify the clinical notes as containing or not containing ADEs. In addition, we conducted an error analysis to better understand the model's behavior and to identify potential areas for improvement.

RESULTS

In total, 62% of notes contained an explicit description of an ADE, indicating that an ADE-related ICD-10 code alone does not ensure detailed event documentation. The fine-tuned SweDeClin-BERT model achieved an F1-score of 0.845 for NER and 0.81 for RE task, outperforming the baseline models (CRFs for NER and random forests for RE). In particular, the RE task showed a 53% improvement in macro-average F1-score compared to the baseline. The integrated NER-RE pipeline achieved an overall F1-score of 0.81.

CONCLUSIONS

Using a domain-specific language model like SweDeClin-BERT for detecting ADEs in clinical notes demonstrates improved classification performance (0.77 in strict and 0.81 in relaxed mode) compared to conventional machine learning models like CRFs and RF. The proposed fine-tuned ADE model requires further refinement and evaluation on annotated clinical notes from another hospital to evaluate the model's generalizability. In addition, the annotation guidelines should be revised, as there is an overlap of words between the Finding and Disorder entity categories, which were not consistently distinguished by the annotators. Furthermore, future work should address the handling of compound words and split entities to better capture context in the Swedish language.

摘要

背景

药物对医疗保健至关重要,但可能导致药物不良事件(ADE),这些事件有害,有时甚至致命。检测药物不良事件是一项具有挑战性的任务,因为它们通常未记录在电子健康记录(EHR)的结构化数据中。需要从临床笔记中自动提取与药物不良事件相关的信息,因为人工审查劳动强度大且耗时。

目的

本研究旨在对预训练的临床语言模型瑞典去识别化临床双向编码器表征(SweDeClin-BERT)进行微调,以用于医学命名实体识别(NER)和关系提取(RE)任务,并实施一种集成的NER-RE方法,以更有效地识别瑞典临床单位临床笔记中的药物不良事件。将该方法的性能与我们之前使用条件随机场(CRF)和随机森林(RF)的机器学习方法进行比较。

方法

从斯德哥尔摩电子病历(EPR)语料库中随机抽取2009 - 2010年的一部分临床笔记,这些笔记包含基于国际疾病分类第10版(ICD - 10)A.1和A.2类代码的疑似药物不良事件。这些笔记由一名医生按照药物不良事件注释指南对与药物不良事件相关的实体和关系进行注释。我们对SweDeClin-BERT模型进行微调以用于NER和RE任务,并实施一个集成的NER-RE管道,从临床笔记中提取实体和关系。使用来自瑞典临床单位的395份临床笔记对模型进行评估。然后将NER-RE管道应用于将临床笔记分类为包含或不包含药物不良事件。此外,我们进行了错误分析,以更好地理解模型的行为并确定潜在的改进领域。

结果

总体而言,62%的笔记包含对药物不良事件的明确描述,这表明仅一个与药物不良事件相关的ICD - 10代码并不能确保详细的事件记录。经过微调的SweDeClin-BERT模型在NER任务中的F1分数为0.845,在RE任务中的F1分数为0.81,优于基线模型(NER任务使用CRF,RE任务使用随机森林)。特别是,与基线相比,RE任务的宏观平均F1分数提高了53%。集成的NER-RE管道的总体F1分数为0.81。

结论

与CRF和RF等传统机器学习模型相比,使用像SweDeClin-BERT这样的特定领域语言模型来检测临床笔记中的药物不良事件显示出更高的分类性能(严格模式下为0.77,宽松模式下为0.81)。所提出的经过微调的药物不良事件模型需要在来自另一家医院的注释临床笔记上进一步完善和评估,以评估模型的通用性。此外应修订注释指南,因为在发现和病症实体类别之间存在词语重叠,注释者对此并未始终一致地区分。此外,未来的工作应解决复合词和拆分实体的处理问题,以更好地捕捉瑞典语中的上下文。

https://cdn.ncbi.nlm.nih.gov/pmc/blobs/e59b/12425423/e2394ff3013d/formative-v9-e71949-g001.jpg

文献AI研究员

20分钟写一篇综述,助力文献阅读效率提升50倍。

立即体验

用中文搜PubMed

大模型驱动的PubMed中文搜索引擎

马上搜索

文档翻译

学术文献翻译模型,支持多种主流文档格式。

立即体验