ACR Meeting Abstracts

ACR Meeting Abstracts

  • Meetings
    • ACR Convergence 2025
    • ACR Convergence 2024
    • ACR Convergence 2023
    • 2023 ACR/ARP PRSYM
    • ACR Convergence 2022
    • ACR Convergence 2021
    • 2020-2009 Meetings
    • Download Abstracts
  • Keyword Index
  • Advanced Search
  • Your Favorites
    • Favorites
    • Login
    • View and print all favorites
    • Clear all your favorites
  • ACR Meetings

Abstract Number: 1657

Extracting TNF Inhibitor Switching Reasons and Trajectories From Real-World Data Using Large Language Models

Brenda Miao1, Marie Binvignat2, Augusto Garcia-Agundez3, Maxim Bravo4, Christopher Williams5, Claire Miao4, Ahmed Alaa6, Vivek Rudrapatna5, gabriela Schmajuk7 and Jinoos Yazdany3, 1UCSF, Fremont, CA, 2Sorbonne University, Paris, France, 3UCSF, San Francisco, CA, 4UC Berkeley, San Francisco, 5UCSF, San Francisco, 6UC Berkeley, Berkeley, 7University of California, San Francisco, and San Francisco Veterans Affairs Medical Center, San Francisco, CA

Meeting: ACR Convergence 2025

Keywords: Anti-TNF Drugs, Biologicals, Data Management, informatics, Pharmacoepidemiology

  • Tweet
  • Click to email a link to a friend (Opens in new window) Email
  • Click to print (Opens in new window) Print
Session Information

Date: Monday, October 27, 2025

Title: Abstracts: Health Services Research (1656–1661)

Session Type: Abstract Session

Session Time: 1:15PM-1:30PM

Background/Purpose: Tumor necrosis factor inhibitors (TNFi) are cornerstones of autoimmune‑disease therapy, yet many patients switch agents because of loss of effectiveness, adverse events, or insurance barriers. Unstructured clinical notes contain the rationale for switching but are costly to review manually. Our objective was to determine whether large language models (LLMs) can automatically identify TNFi-to-TNFi switching and the reasons for switching in real‑world practice.

Methods: We conducted a retrospective observational study of de‑identified electronic health records (2012‑2023) from a single academic center. We defined TNFi-to-TNFi switching as a change from one TNFi to a different TNFi at consecutive encounters and include patients with a TNFi-to-TNFi switch and ≥6 months follow‑up. Using a zero‑shot prompt, GPT‑4‑turbo‑128k and eight open‑source LLMs extracted (1) TNFi stopped, (2) TNFi started, and (3) reason category between: adverse event, anti-drug antibodies, insurance/cost, lack of effectiveness, patient preference, other, or unknown. Performance was assessed on a subset of manually expert-annotated notes with micro-F1 scores.

Results: 2,112 patients met inclusion criteria (Table 1). On the manually annotated subset (n=146), GPT‑4 achieved micro‑F1 scores of 0.75 for stopped TNFi, 0.80 for started TNFi, and 0.83 for reason extraction. The best open‑source models approached GPT‑4 for medication identification: Starling‑7B‑beta (0.88 stopped, 0.79 started) and Llama‑3‑8B‑Instruct (0.82 stopped, 0.75 started). Only Llama‑3‑8B‑Instruct matched GPT‑4 for reason identification with F1=0.83. Figure 1 depicts a direct comparison between models. In the first switch, the leading reasons were lack of effectiveness (59%), adverse events (12%), and insurance/cost issues (11%). Subsequent switches showed a higher share of adverse events and patient preference and fewer effectiveness and cost‑driven changes (Figure 2).

Conclusion: GPT‑4 can extract complex TNFi switching patterns from clinical notes with high accuracy, substantially reducing the need for manual chart review. Several local models offer comparable performance. This capability enables scalable pharmacoepidemiologic studies of treatment lines and could power point‑of‑care tools that summarize medication histories for clinicians. Further work should evaluate generalizability to other biologic classes and multi‑institution datasets.

Supporting image 1Table 1. Patient characteristics and TNF inhibitor (TNFi) switch counts, n=2112.

Supporting image 2Figure 1. Average win minus loss percentage rates of open-source large language models compared to GPT-4 in identifying started and stopped medication on the manually reviewed note subset. Positive numbers indicate the model is superior to GPT-4 (the model correctly identified a started or stopped medication where GPT-4 did not), negative numbers indicate the contrary.

Supporting image 3Figure 2. Percentage of identified reasons for switching.


Disclosures: B. Miao: Quality Health, 12, Co-Founder; M. Binvignat: None; A. Garcia-Agundez: None; M. Bravo: None; C. Williams: None; C. Miao: None; A. Alaa: None; V. Rudrapatna: Dataunite, ZebraMD, AcucareAI, 1, Genentech, BeOne, Merck, Janssen, Takeda, Blueprint Medicines, Mitsubishi Tanabe, Stryker, 5, Ironwood, Natera, 2; g. Schmajuk: None; J. Yazdany: AstraZeneca, 2, Aurinia, 5, Gilead, 5.

To cite this abstract in AMA style:

Miao B, Binvignat M, Garcia-Agundez A, Bravo M, Williams C, Miao C, Alaa A, Rudrapatna V, Schmajuk g, Yazdany J. Extracting TNF Inhibitor Switching Reasons and Trajectories From Real-World Data Using Large Language Models [abstract]. Arthritis Rheumatol. 2025; 77 (suppl 9). https://acrabstracts.org/abstract/extracting-tnf-inhibitor-switching-reasons-and-trajectories-from-real-world-data-using-large-language-models/. Accessed .
  • Tweet
  • Click to email a link to a friend (Opens in new window) Email
  • Click to print (Opens in new window) Print

« Back to ACR Convergence 2025

ACR Meeting Abstracts - https://acrabstracts.org/abstract/extracting-tnf-inhibitor-switching-reasons-and-trajectories-from-real-world-data-using-large-language-models/

Advanced Search

Your Favorites

You can save and print a list of your favorite abstracts during your browser session by clicking the “Favorite” button at the bottom of any abstract. View your favorites »

Embargo Policy

All abstracts accepted to ACR Convergence are under media embargo once the ACR has notified presenters of their abstract’s acceptance. They may be presented at other meetings or published as manuscripts after this time but should not be discussed in non-scholarly venues or outlets. The following embargo policies are strictly enforced by the ACR.

Accepted abstracts are made available to the public online in advance of the meeting and are published in a special online supplement of our scientific journal, Arthritis & Rheumatology. Information contained in those abstracts may not be released until the abstracts appear online. In an exception to the media embargo, academic institutions, private organizations, and companies with products whose value may be influenced by information contained in an abstract may issue a press release to coincide with the availability of an ACR abstract on the ACR website. However, the ACR continues to require that information that goes beyond that contained in the abstract (e.g., discussion of the abstract done as part of editorial news coverage) is under media embargo until 10:00 AM CT on October 25. Journalists with access to embargoed information cannot release articles or editorial news coverage before this time. Editorial news coverage is considered original articles/videos developed by employed journalists to report facts, commentary, and subject matter expert quotes in a narrative form using a variety of sources (e.g., research, announcements, press releases, events, etc.).

Violation of this policy may result in the abstract being withdrawn from the meeting and other measures deemed appropriate. Authors are responsible for notifying colleagues, institutions, communications firms, and all other stakeholders related to the development or promotion of the abstract about this policy. If you have questions about the ACR abstract embargo policy, please contact ACR abstracts staff at [email protected].

Wiley

  • Online Journal
  • Privacy Policy
  • Permissions Policies
  • Cookie Preferences

© Copyright 2025 American College of Rheumatology