MedicalRSI: Medical Recursive Self-Improving Agents via Clinical Model-Harness Co-Evolution

Ziqing Wang, Hamid Palangi, Lili Zhao, Kaize DingarXiv 2026

It’s late, you’ve had a long day, and the last thing you want is a dry lecture on gradient descent. So, let’s talk about a problem we’ve all seen: the "Groundhog Day" effect in AI.

Imagine a medical AI agent helping a doctor. It makes a mistake—say, it misses a 24-hour window for a lab test. You’d hope it learns. But usually, the next time a similar patient comes in, it makes the exact same mistake. Most medical agents are "frozen" once deployed. Even the ones that "self-improve" usually follow a fixed recipe for getting better.

The authors of MedicalRSI decided that wasn't good enough. They wanted an agent that doesn't just learn from its mistakes, but learns how to learn from them.

TL;DR

MedicalRSI is a framework for "Recursive Self-Improvement" where a medical AI agent plays two roles: a Solver that treats patients and an Improver that analyzes the Solver's failures to write better "harnesses" (instructions and tools). By training both roles together, the system creates a virtuous cycle where the agent's ability to improve itself keeps pace with its growing medical knowledge.

What Problem Does This Paper Address?

Most medical LLM agents are static. If you want them to improve, you usually have two choices:

  1. Weight-level improvement: Fine-tune the model on its successful attempts.
  2. Context-level improvement: Give the model a "harness"—a set of prompts, skills, or tools—to guide it.

The catch? The strategy used to update those weights or write those prompts is usually fixed. If the strategy itself doesn't adapt, the agent eventually hits a ceiling. Furthermore, medical workflows are messy; there’s rarely a "gold standard" instruction manual for every hospital's specific database. MedicalRSI tackles this by letting the agent co-evolve its own instructions based on where it's currently failing.

Methods

The core innovation is Clinical Model-Harness Co-Evolution. One model (like a Qwen or Gemma backbone) wears two hats:

  • The Solver: This is the doctor's assistant. It interacts with the Electronic Health Record (EHR), looks at labs, and places orders. It follows a Medical Harness—a set of natural language "skills" and reusable "tools" (like SQL queries).
  • The Improver: This is the "coach." It looks at the Solver’s failed attempts and writes a new, better harness to fix those specific errors.
The MedicalRSI workflow: The Solver attempts tasks, the Improver writes new harnesses from failures, and both are updated via a joint loss function.

The authors use Group Relative Policy Optimization (GRPO), a flavor of Reinforcement Learning, to train both roles simultaneously. The Improver is rewarded based on a Counterfactual Gain Reward: it only gets points if the new harness it wrote actually makes the Solver perform better than it did before.

Datasets

The researchers put MedicalRSI through its paces on:

  • MedAgentBench: A benchmark with 32 clinical workflows (like magnesium replacement or ECG ordering) across thousands of tasks.
  • MedAgentGym (EHR-SeqSQL): A benchmark focused on answering clinical questions by querying a MIMIC-III database.
  • eICU: A completely different hospital database used to test if the agent's learned "improvement skills" could transfer to a new environment without any extra training.

Key Insights and Ideas

  • Failures are a Signal: Instead of just learning from what it got right, MedicalRSI turns failures into a learning signal. The Improver specifically targets the "unsolvable" tasks, turning them into lessons for the Solver.
  • The Harness as a Bridge: By evolving a text-based harness (skills and tools) rather than just raw weights, the system becomes more interpretable and flexible. You can see exactly what "skill" the Improver wrote to fix a retrieval error.
  • Recursive Gains: As the Solver gets better, the errors it makes become more subtle. Because the Improver is also learning, it can adapt its coaching to tackle these increasingly complex mistakes.
  • Cross-Model Coaching: Surprisingly, an Improver trained on a small 9B model can write harnesses that help "frontier" models like GPT-4 or Claude Sonnet perform significantly better on medical tasks.
The co-evolution of Solver and Improver leads to much higher task success rates compared to improving only one or the other.

Key Results

MedicalRSI doesn't just improve; it dominates.

  • On MedAgentBench, it raised the success rate from a base of 36.9% to 85.1%, a massive +48.2 point jump.
  • It outperformed the strongest baselines (like GRPO Solver) by over 22 points.
  • Speed of Learning: After just two rounds of training, MedicalRSI already surpassed the final scores of all other methods.
  • Zero-Shot Transfer: When moved to the unseen eICU database, MedicalRSI outperformed the base agent by 11 points without any additional weight updates, simply by "writing its way" out of errors.
MedicalRSI outperforms existing methods on MedAgentBench and shows a steep, consistent improvement curve over training rounds.

Limitations and Future Work

While impressive, the authors note a few hurdles:

  • The Grader Dependency: Training still requires a "grader" to provide feedback on whether a task was solved correctly. In a real-world clinic, getting that ground truth in real-time is difficult.
  • Harness Complexity: The current harness format is limited to "skills" and "tools." Future versions might need to evolve more complex structures, like entire multi-agent sub-routines.
  • Safety: While the agent gets better at following workflows, "recursive self-improvement" in a medical context requires extreme safety guardrails to ensure the agent doesn't "hallucinate" a dangerous new clinical protocol.

In short, MedicalRSI is a step toward agents that don't just sit there—they get sharper every time they clock in.

Summary updated

Abstract

Medical agents built on large language models (LLMs) have advanced rapidly, yet most stay fixed once deployed and do not keep using their experience to improve later attempts. As a result, the same kind of error can recur across patients. To address this, existing self-improvement methods update an agent's weights or its medical harness from its own experience, but their improving strategy stays fixed and never learns which changes actually help, which caps how much the agent can improve. Recursive self-improvement (RSI) instead improves both the agent and its improving strategy. However, achieving RSI for medical agents is challenging, because clinical workflows rarely come with a reference harness, and a change that fixes early errors may not fix the problems the agent meets later. We propose MedicalRSI, an RSI framework built on Clinical Model-Harness Co-Evolution, in which one model plays two roles. The Solver is the medical agent itself, and the Improver is its learnable improving strategy, which writes a medical harness from the agent's failures. Each harness is rewarded by its gain over acting without it, and both roles are trained together, so the Improver keeps adapting to the problems the Solver has not yet solved. On multiple benchmarks and LLM backbones, MedicalRSI outperforms existing context-level and weight-level self-improvement methods and transfers well to unseen workflows, new LLMs and new databases, a step toward medical agents that keep improving.
BibTeX
@misc{wang2026medicalrsi,
  author = {Ziqing Wang and Hamid Palangi and Lili Zhao and Kaize Ding},
  title = {{MedicalRSI: Medical Recursive Self-Improving Agents via Clinical Model-Harness Co-Evolution}},
  year = {2026},
  eprint = {2611.26806},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.26806},
}
Figure