Patient portals have become the front door of modern healthcare. Millions of people message their doctors through them every day, asking about test results, requesting prescription refills, describing new symptoms and following up on treatment. The volume is enormous, and buried inside it are messages that need an urgent reply. A new study suggests that artificial intelligence tools could help hospitals find those urgent messages sooner, before they sink beneath the routine ones.
The research, from Mass General Brigham, tested six large language models on 1,303 patient messages and compared their urgency judgments with those of practicing physicians. The findings, published in the journal npj Digital Medicine, suggest that AI tools correctly flagged most of the messages physicians considered urgent. Just as importantly, the study found that models running on a hospital’s own servers performed as well as commercial models hosted in a protected cloud environment, a result with real implications for patient privacy.
None of the models tested are in clinical use, and no patient care was affected by the research. The findings are preliminary evidence about what these tools can do, not proof that hospitals should deploy them tomorrow. But they arrive at a moment when clinicians are drowning in portal messages, and the question of how to sort them has become one of the most practical problems in healthcare technology.
A New Study From Mass General Brigham
The study was led by Valdery Moura Junior, PhD, MBA, lead AI scientist at the Clinical Trials Network and Institute in the Department of Psychiatry at Mass General Brigham, and published in npj Digital Medicine in December 2026. Its full title is “Cloud vs. on-premise large language models for urgent patient-portal message screening: a comparative evaluation.”
The researchers set out to answer a practical question. Patient portal messages vary enormously in urgency. Some are routine administrative requests. Some describe symptoms that need a same-day response. Clinicians currently read through them in the order they arrive, or rely on patients to flag their own messages as urgent, a system the researchers describe as unreliable. The team wanted to know whether large language models could sort messages by urgency accurately, and whether hospitals could run those models themselves rather than sending patient data to a commercial cloud service.
Six models were tested. Three were commercial OpenAI models, GPT-4o, GPT-5 and GPT-5 Mini, running inside Mass General Brigham’s secure Microsoft Azure environment. Three were open-weight models that hospitals could download and run locally: Meta’s Llama 4 Scout, Google’s Gemma 3 27B and OpenAI’s GPT-OSS 20B. The comparison between the two groups was the heart of the study, because it tested whether a hospital could get the same performance without sending patient data outside its own walls.
The results were strong on the measure that matters most: catching urgent messages. One model, GPT-5, missed none of the 134 urgent messages in the primary care group. Four of the six models caught at least 97 of every 100 messages physicians had deemed urgent, and when those four cleared a message as routine, they were right about 98 times out of 100. In other words, the models were very good at the dangerous direction, missing something urgent, and the cost of their errors fell mostly in the other direction.
How the AI Tools Triage Messages
The tools in the study are large language models, the same class of technology behind chatbots and writing assistants, applied to a sorting task. A message arrives in the portal, the model reads it, and it classifies the message as urgent or routine according to patterns it has learned from language. The model does not diagnose the patient or decide on treatment. It ranks the message so that a clinician sees the urgent ones first.

The distinction between screening and diagnosing matters. Screening is a sorting job, closer to a receptionist deciding which call to put through first than to a doctor making a clinical judgment. The researchers frame the tool that way: a way to order the queue, not a way to replace the clinician who reads it. The final decision about what a message means and what to do about it remains with a human.
The study is part of a larger project called Luna Baker, a multi-agent AI system for patient portal messages that the Mass General Brigham group developed with support from the Baker Family Initiative in Patient Experience and Outcomes. Luna Baker sorts portal messages, flags urgent ones, reviews the patient’s chart and drafts replies for clinicians to approve, using GPT-4o, one of the top performers in the study. The urgency screening tested in the new research will help inform Luna Baker’s design, but the system is not currently in clinical use.
The local-versus-cloud finding is the part of the study most likely to change hospital planning. One top performer, Google’s Gemma 3 27B, runs on local hardware, and the researchers found that a model downloaded and run on the hospital’s own servers performed just as well as the commercial models. As Moura Junior put it, “We found a model we downloaded and ran on our own servers performed just as well.” For hospitals without enterprise cloud agreements, that could lower the barriers to trying AI triage, and for all hospitals it offers greater control over where patient data is processed.
What the Numbers Actually Mean
The headline numbers are impressive, but they need careful reading. Catching 97 of every 100 urgent messages sounds close to perfect, yet the 3 that are missed are the ones that matter most, and the study does not claim the tools are ready to run without human oversight. A screening tool that misses a small number of urgent messages is useful only if a clinician still reads the rest of the queue, which is exactly how the researchers propose using it.
The other side of the numbers is the false alarm rate. The models flagged too many routine messages as urgent. The best tool correctly cleared 73 of every 100 routine ones, which means more than a quarter of routine messages were still escalated. Clinics using such a tool would still have a substantial number of messages to read, just a smaller queue in better order. The labour saving is real but partial, and anyone promising that AI will empty the inbox is overselling the study.
Performance also varied by setting. The best-performing model was not the same in every group of messages, which the authors read as a warning that a system validated at one hospital needs rechecking at another. A model trained and tested on messages from one health system may behave differently on messages from a different population, written in different language, about different conditions. Local validation is not a nice extra. It is a requirement.
Context from other research supports that caution. A separate study from the Southern California Permanente Medical Group, published in JAMA Network Open and reported earlier in 2026, found that a natural language processing tool achieved 81 percent accuracy in categorising portal messages, compared with 44 percent accuracy for patient self-reports of urgency, and was linked to a 17-hour reduction in response time for high-acuity messages, from 22 hours to 5 hours. That study analysed more than 3 million messages from over a million patients, a far larger sample than the Mass General Brigham work, and it tested a system already in use rather than a laboratory comparison.
Meanwhile, a Columbia University study of AI-drafted replies, published in JAMA Network Open in October 2026, found a more mixed picture. When clinicians used an AI draft, patients got answers about 29 percent sooner, but clinicians used the drafts only about 5 percent of the time, and overall the tool was not linked to a reduction in after-hours work. The lesson from Columbia is that a tool’s accuracy in testing is only half the story. Whether clinicians actually use it, and how it fits into their working day, decides whether patients benefit.
The Privacy Question That Decided the Study Design
The most consequential choice in the Mass General Brigham study was not which models to test, but where to run them. Sending patient messages to a commercial cloud service raises questions that hospitals take seriously: who holds the data, what contracts govern it, how long it is kept, and what happens if it leaks. Those questions have slowed the adoption of AI in healthcare more than any technical limitation.
The study’s finding that local models performed as well as cloud models is therefore more than a technical detail. It is a result about access. Open-weight models such as Gemma 3 27B can be downloaded and run on hardware the hospital owns, which means the data never leaves the building. For hospital leaders weighing AI triage against privacy, contracting and cost concerns, that is the finding that may matter most.
The broader picture in healthcare AI is moving in the same direction. AI tools are being adopted across hospitals for tasks from language translation to clinical documentation, and the institutions making progress tend to be the ones that keep tight control of their data. A recent example is the use of AI to ease language barriers in safety-net hospitals, where patients who speak limited English face some of the worst access problems in healthcare. Readers interested in that angle can read how AI tools are easing language barriers in the safety net, a story about technology reaching the patients who need it most.
What Happens Next
The most likely near-term future is a hybrid: AI sorts the queue, a clinician reads the urgent messages first, and the rest are handled in turn. That is a modest vision, and deliberately so. It does not replace doctors, it does not diagnose patients, and it does not promise to empty the inbox. It promises something smaller and more useful: that the message that needs an answer today is less likely to be buried under the ones that can wait until next week. Hospitals exploring the wider adoption of AI across their systems can also look at how OpenEvidence made enterprise AI free for health systems to integrate, which shows how quickly the cost barriers around clinical AI are falling.
Bottom Line
A new study from Mass General Brigham, published in npj Digital Medicine, found that AI tools based on large language models correctly flagged most patient messages that physicians considered urgent, with GPT-5 catching all 134 urgent messages in the primary care group and four of six models catching at least 97 in every 100. Crucially, the study also found that models running on a hospital’s own servers performed as well as commercial models in a protected cloud environment, which could make AI triage accessible to more hospitals while keeping patient data inside the health system.
The findings are preliminary. The models over-flag routine messages, the best performer varied by setting, and none of the tools are in clinical use. The research is part of the Luna Baker project, a multi-agent AI system that sorts portal messages, flags urgent ones and drafts replies for clinicians to approve, and the study will help inform that system’s urgency screening. What the study shows, above all, is that AI-assisted triage is a realistic prospect, not a distant one, and that the hospitals that adopt it will need to validate it locally, keep clinicians in charge, and measure whether it actually helps patients. Clinics already using AI for routine patient communication, such as automated reminders, show how these tools fit into daily practice, as covered in how to automate appointment reminders with AI for clinics.


