Project Cable Car: Pharmacy Fax Classification


UCSF Health

UCSF Health

San Francisco, California
  • Submitted by: Ben Michaels, PharmD, MIDS, 340B-ACE and Mackenzie Clark, PharmD, APh, BCGP, BCPS
  • Case Study Type: Workflow Optimization
  • Tool Type: Non-Clinical, In-House Development, Internal / Operational
  • Published: May 2025




Case Overview:

The Medication Fax Folder Automation initiative employs AI to streamline pharmacy fax processing. Its core function is to automatically read, interpret, rename, and move medication-related faxes. This addresses the significant pharmacy/healthcare issue of time-consuming and error-prone manual fax processing. Staff currently spend excessive time on these tasks, diverting them from critical patient care and increasing the risk of errors. The AI solution aims to eliminate this inefficiency, improve patient safety, and enhance operational efficiency by automating the fax classification/labeling workflow.


Tool and Project Details:

The AI tool automates pharmacy fax classification and labeling. It reads, interprets, renames, and files faxes, integrating directly with existing fax servers and folder systems. The solution was developed internally in collaboration with the specialty pharmacy team and errors/issues are continually reported from the team. The process was integrated into their existing workflow.  An additional feature was added in early 2025 that identifies duplicate faxes (fax follow ups for the same patient/subject) and removes them to prevent duplicative work. 


Key Elements of Success:

The current process is being utilized by the specialty pharmacy at UCSF and will be expanded to our two retail locations. The entire specialty pharmacy team is involved in reporting errors and identifying mismatches. This has led to multiple versions of the project with each iteration having lower error rates and cost. Expansion to our clinic locations is being explored and will require review from our IT Portfolio committee and AI governance board.


Impact on Outcomes:

To date, over 19,000 faxes have been processed by the solution and 150 duplicates removed within one month of the go live. Deployed versions have been optimized to reduce error rates of classification and concept extraction/labeling. Version 3.5 is currently deployed and has a 0.48% error rate.  We are planning on sending a post implementation survey to poll users on their satisfaction with the solution.


Role of the Pharmacy and Pharmacists:

This tool was developed in tandem with the specialty pharmacy fax processing team.  We partnered with their team to determine how the solution could integrate into their current workflow and augment the processes already being used.  This team represents a mixture of both pharmacists and pharmacy technicians. Key stakeholders include the patients whose faxes are being processed along with the pharmacists and technicians that are interacting with the output of the tool. As the tool was designed to integrate into the existing workflow and automate the task of opening, reading, relabeling, and moving the fax that was already being performed, a short training and QA session was provided to the staff at go live. Updates are communicated via a Microsoft Teams channel daily.


Budget & Resource Allocation:

The project is a pilot and was able to be completed due to the availability of UCSF’s Versa instance which is a PHI approved LLM maintained by the AI Tiger team. This resource allows the Pharmacy team to benefit from the use of LLMs in a compliant manner. The cost and ROI is estimated by capturing metrics on both the number of faxes processed and the associated error rate.


Lessons Learned:

The biggest hurdle encountered with the process was the ability to parse the text from the fax image and upside-down images. For background, the PDF that is transmitted is not a text formatted PDF, but rather an image stored in a PDF. As a result, we had to parse the text from the image, which resulted in some images being too light. We applied a function that automatically adjusts the contrast of the image prior to text extraction. Additionally, there were instances of upside-down faxes being sent. For this, a classification model was trained and inserted into the pipeline. Based on the output, if the image was classified as upside-down, it would be flipped prior to text extraction. The specialty pharmacy team has been a champion and partner for the project.


Future Goals & Ongoing Monitoring:

Volume of faxes processed along with the number of duplicates and accuracy will continue to be monitored. New versions of the model will be tested and deployed based on user reported errors. We plan to expand the tool to our retail pharmacies and evaluate the potential of rolling the solution out to our outpatient clinics in the future.

Disclaimer

The information presented in this case study is provided for general informational purposes only and does not constitute legal, clinical, or professional advice. References to specific technologies, tools, or products are included solely to illustrate examples shared by the contributing organizations and do not imply endorsement by ASHP. ASHP makes no representations or warranties regarding the accuracy, completeness, or continued currency of the information presented. The information presented may contain errors, inaccuracies, inconsistencies and/or outdated information. Readers are encouraged to conduct their own due diligence and consult appropriate professionals before making decisions based on the information provided. ASHP disclaims any and all liability for damages or losses resulting from the use or reliance upon this content. © American Society of Health-System Pharmacists. All rights reserved.




ADVERTISEMENT

Member Only

Join ASHP today to get access to the full content