The AI That Treats Patients From Start to Finish Like an Emergency Room Doctor
Artificial Intelligence has already proven it can answer complex medical questions, interpret test results, and even help doctors hunt for diagnoses. But what if it could do all of that autonomously, from the very beginning to the very end of a real clinical encounter?
That is exactly the leap a group of researchers decided to explore in a study published in Nature, and the result has a name: MIRA, an autonomous medical AI agent that operates inside a virtual electronic health record and executes complete emergency department workflows, from the initial conversation with the patient all the way to the admission decision.
From isolated answers to complete clinical decisions
For a long time, the use of AI in medicine was limited to specific, one-off tasks. Large language models, the now-famous LLMs, had already been showing impressive performance on traditional medical benchmarks like multiple-choice questions and diagnostic reasoning scenarios. On top of that, several initiatives demonstrated the practical usefulness of these models in real hospital settings, including applications as decision-support tools for consulting oncology guidelines, extracting and structuring data from unstructured clinical notes, and generating clinical codes for documentation and billing purposes.
Useful? Absolutely. But still a far cry from how a real doctor operates day to day. In clinical practice, a healthcare professional does not just answer questions: they gather information from the patient through history-taking and physical examination, order laboratory and imaging tests, interpret results, formulate diagnostic hypotheses, prescribe medications, schedule surgical procedures, and decide whether the patient needs to be admitted or can be discharged. All of this happens inside an integrated electronic health record system, known as EHRs, which must follow standards like FHIR to ensure consistent information exchange across different hospital systems.
There is no fixed or predictable sequence. Every decision depends on what came before, what the patient reported, what the tests show, and how the clinical picture evolves minute by minute. It is a continuous, dynamic flow full of variables. And that is precisely where most Artificial Intelligence solutions still stumble. 😬
Traditional models were trained to answer specific questions well, but not to navigate a real healthcare system, deal with incomplete data, take initiative, or chain decisions together across an entire clinical encounter. The existing applications, however useful they were, drastically underutilized the broader potential of LLMs and fell short of the multifaceted demands of clinical workflows, which require optimizing diagnostic accuracy without overusing medical resources. That gap between what AI knows and what it can actually do autonomously is exactly the problem the MIRA research set out to solve.
What makes MIRA different from everything that came before
Published in Nature in June 2026, the MIRA study introduces something that had never been done this comprehensively: an autonomous medical AI agent capable of conducting entire clinical workflows inside a standardized virtual electronic health record environment. The differentiator is not just the ability to generate accurate answers, but the capacity to act sequentially and contextually, interpreting the environment, making decisions, and advancing through the encounter without needing a human to guide each step.
This is not a chatbot that suggests diagnoses. It is an agent that acts, that makes decisions step by step, just as a doctor would during an emergency department visit. MIRA’s architecture was built on top of large language models, but with an additional layer of structured clinical reasoning that allows the system to navigate electronic health records, converse with a simulated patient agent, interpret vital signs, order laboratory tests, evaluate results, and formulate diagnostic hypotheses with logic that follows the same principles of evidence-based medicine.
The system uses 11 different tools with more than 85,000 options to order and interpret laboratory, microbiological, and imaging studies, generate diagnostic hypotheses, and execute treatment plans, including scheduling surgical procedures, prescribing medications, and arranging hospital admissions. All of this follows the FHIR standard and six internationally recognized medical coding systems: ICD, LOINC, ATC, NDC, RxNorm, and SNOMED-CT.
The numbers that impressed the scientific community
Testing was conducted on more than 574 real cases extracted from the MIMIC-IV database, a public repository of de-identified electronic health records from approximately 300,000 patients treated at Beth Israel Deaconess Medical Center in Boston between 2008 and 2019. The cases spanned eight different diagnoses across three major areas: surgery, internal medicine, and oncology.
The conditions evaluated included appendicitis, cholecystitis, diverticulitis, pancreatitis, pneumonia, urinary tract infection, pulmonary embolism, and pancreatic cancer. This selection was designed to reflect both the high demand from symptoms that drive emergency department traffic, such as abdominal pain with roughly 13 million annual visits in the U.S., cough with 5.97 million, and shortness of breath with 5.89 million, as well as the frequency of the diagnoses themselves.
MIRA achieved an average diagnostic accuracy of 88.9% across the 574 cases evaluated. The highest accuracy was observed for appendicitis at 98.6%, followed by pancreatitis at 92.3%. Pneumonia and urinary tract infections showed lower accuracy at 72.4% and 77.6%, respectively.
But the most revealing test was the head-to-head comparison with human doctors. MIRA’s performance was measured against two distinct groups of professionals:
- Four board-certified specialists with 7 to 11 years of clinical practice
- A mixed group of six physicians with varying levels of experience, including four residents and two board-certified specialists
Under identical evaluation conditions, with access to the same information and tools, MIRA achieved an average diagnostic accuracy of 87.8%, compared to 78.1% for the board-certified specialists and 71.1% for the mixed group. The difference was statistically significant in both comparisons. The largest gap appeared in pancreatitis cases, where MIRA correctly diagnosed 95.2%, compared to 78.6% for the board-certified specialists and 61.9% for the mixed group. 🧠
How MIRA thinks and acts like a doctor
To understand why MIRA represents such a significant advance, you need to understand how AI-based medical agents operate in practice. Unlike a language model that simply generates text in response to a prompt, an autonomous agent is designed to interact with external tools, navigate interfaces, query databases, and execute actions based on what it observes in the environment.
Analysis of MIRA’s action traces revealed that it follows a workflow similar to a physician’s, progressing in a stepwise fashion from the initial emergency department presentation through to hospital admission. The system advances in the usual order of care, moving from less invasive steps like blood tests to more invasive interventions like surgical procedures.
In appendicitis cases, for example, MIRA collects the clinical history, defines an initial plan, orders and interprets physical examination findings, requests laboratory tests, moves on to imaging studies, initiates medication, identifies and orders the appropriate surgical intervention, adjusts perioperative medications, and recommends admission.
At each clinical stage, MIRA’s choices were consistent with routine practice, including the specific blood analytes, microbiological assays, and imaging modalities ordered. The agent ordered physical examinations with greater consistency than human physicians, averaging 97.1% compared to 87.8% for the board-certified specialists. The system also ordered a higher proportion of available blood tests, covering approximately 51.1% of those documented in MIMIC-IV, compared to 28.3% for the specialists. Even so, MIRA still ordered only about half of the laboratory analytes obtained in routine MIMIC-IV practice, indicating that the system does not adopt a strategy of ordering everything indiscriminately.
When it came to surgical procedures, MIRA correctly identified and ordered 53.5% of the relevant procedures across all eight diseases evaluated, compared to 38.3% for the board-certified specialists. The standout performance was in appendicitis and cholecystitis, where the system correctly identified 100% of laparoscopic appendectomies and 90.6% of laparoscopic cholecystectomies.
Medication safety and guideline adherence
One of the most critical aspects of any autonomous medical system is medication prescribing safety. The researchers conducted a systematic evaluation of MIRA’s prescriptions across six safety domains:
- High-severity drug-drug interactions
- Renal dosage compatibility based on glomerular filtration rate
- Drug-allergy incompatibilities
- QT prolongation risk
- Unsafe opioid prescribing
- Therapeutic duplication
The results were remarkable: no high-severity drug-drug interactions, renal dosage incompatibilities, drug-allergy incompatibilities, QT risks, or unsafe opioid prescriptions were observed across the 56 cases evaluated. Therapeutic duplication was identified in only three cases, all assessed as clinically reasonable, although the documentation could have been more explicit.
In terms of clinical guideline adherence, MIRA demonstrated higher concordance than human physicians in most categories evaluated. The average difference in guideline adherence was +35 percentage points compared to the board-certified specialists. For example, in pancreatitis cases, MIRA was significantly more likely to prescribe intravenous fluids as recommended by guidelines and showed greater consistency in prescribing appropriate analgesic therapy across most diseases.
However, the system was not perfect. Just like human physicians, MIRA did not achieve full concordance on antibiotic therapy across all diseases, with pneumonia being the only category where it reached 100% adherence in the evaluated group.
The patient agent that does not leak information
A fundamental component of the study was the patient agent, an AI model that simulates the responses of a real patient based exclusively on the documented clinical history. This agent needs to provide stable responses when different clinicians ask semantically equivalent questions worded differently, stay faithful to the clinical history, and most importantly, not reveal diagnostic conclusions prematurely.
Testing showed that the patient agent produced consistent responses in 99.4% of the question pairs evaluated and remained aligned with the documented clinical history in 99.3% of original responses. Across 933 audited patient-physician encounters, no premature diagnostic information leakage was observed.
Even when subjected to 11 adversarial attack patterns, including prompt injection attempts and social engineering across 880 interactions, no diagnostic information leakage was recorded. This robustness is essential to ensure the testing environment does not artificially favor MIRA over human physicians. 🔒
Safe admission decisions and robustness testing
The researchers also evaluated whether MIRA could make safe decisions about hospital admission versus discharge. For this, they focused on two diagnoses, pneumonia and pulmonary embolism, because validated clinical scoring systems exist, CURB-65 for pneumonia and sPESI for pulmonary embolism, that are routinely used by doctors to determine the site of care. The interesting detail is that MIRA was not given the results of these scores nor instructed to use them, it only had access to the underlying clinical data such as vital signs, laboratory results, and imaging studies.
The most important finding was that sensitivity for admission was 100% in both conditions. MIRA never failed to identify a patient who needed to be admitted. Specificity was 86% for pneumonia and 70% for pulmonary embolism, with the system showing a tendency to be overly cautious in pulmonary embolism cases, preferring to admit patients who could have been discharged. This bias toward safety is clinically preferable to sending a seriously ill patient home.
To assess whether MIRA maintains stable performance across different patient profiles, the researchers ran perturbation experiments with six distinct scenarios: changing the patient’s sex, patients convinced they are healthy, patients convinced they have cancer, overly anxious patients, and patients who speak only German or only French. Risk differences ranged from -1.2 percentage points for the anxiety bias to -10 percentage points for the sex bias, but none reached statistical significance after correction for multiple comparisons.
The landscape that made this advance necessary
The shortage of healthcare professionals is a global problem that affects developing countries and advanced economies alike. In this context, tools that can expand care capacity without compromising quality stop being a technological curiosity and become a strategic necessity.
Beyond the professional shortage, there is the burnout problem. The time doctors spend on electronic health record documentation keeps increasing, and that has a direct impact on the quality of care. Diagnostic errors, delayed decisions, and communication failures between teams are direct consequences of this reality.
It is in this context that the development of autonomous medical agents takes on a dimension far greater than simply impressing on academic benchmarks. The researchers themselves suggest that initial real-world adoption would likely focus on more bounded, high-volume tasks such as pre-admission medication reconciliation, assembling laboratory test panels, auto-drafting consultation requests, and suggesting guideline-compliant prescriptions, all under explicit physician review. This would free up professionals to redirect their attention to direct patient interactions. 🌍
The challenges that still need to be overcome
Despite the promising results, the researchers themselves were careful to point out the system’s limitations. The testing environment, while sophisticated, was built with simulated interactions derived from clinical history text extracted from discharge summaries. This can produce responses that are more structured than the actual speech of patients in emergency departments, which frequently includes inconsistencies, omissions, and disfluencies that no benchmark can fully capture.
Another important point is that MIMIC-IV is a widely used dataset that is publicly available to credentialed researchers. Although access requires prior registration, there is a theoretical possibility that MIMIC-IV data was included in the training corpus of the LLMs used, which means the reported performance may represent an upper bound and overestimate generalization to other cases.
The question of liability also remains without a clear answer. When an AI agent makes a clinical decision that results in harm to a patient, who is accountable? The doctor who relied on the recommendation? The hospital that deployed the tool? The company that developed the model? These questions still have no solution in any regulatory system in the world.
The researchers also emphasize that, although the evaluation focused on MIRA’s autonomous decision-making capabilities, medical AI agents should not currently be designed to replace healthcare professionals. The ideal role would be within collaborative clinical environments, assisting physicians in executing routine tasks under varying levels of human supervision or providing evidence-based therapeutic recommendations that remain subject to physician approval.
A relevant consideration is resource management. Any increase in test orders by MIRA was concentrated in low marginal cost blood analytes such as electrolytes and inflammatory markers, without a systematic increase in higher-cost imaging studies. This kept overall utilization below historical practice. Still, the researchers propose that future versions of MIRA incorporate an economic management sub-agent that monitors cumulative costs of tests and procedures in real time and suggests cheaper alternatives when available.
What to expect from the next steps
The MIRA research is not a finished product ready for hospital adoption tomorrow. It is, above all, a scientific demonstration that the level of sophistication of AI-based medical agents has reached a point where the question shifts from whether AI can support complex clinical decisions to how to do it safely, ethically, and at scale.
The authors themselves acknowledge that prospective validation will be essential to confirm whether this potential can be fully realized in real clinical settings. They also point out that the combination of approaches like MIRA, focused on automating workflows within the health record, and AMIE, a conversational diagnostic system developed by Google that incorporates up-to-date medical literature search during dialogue, may represent the most promising path toward clinical AI integration.
MIRA’s source code and framework have been made publicly available on GitHub, allowing other researchers to replicate the experiments, build on the existing architecture, and advance validation with new datasets and different clinical scenarios.
What becomes clear after analyzing everything MIRA represents is that AI-supported clinical decision-making is no longer a distant promise. It is a field under rapid construction, with serious challenges ahead, but also with transformative potential that could redefine access to quality healthcare on a global scale. And following this evolution closely, understanding both the advances and the limitations, is essential for anyone who wants to understand where technology is heading in the coming years. 🚀
